Forum Discussion
Tito
2 years agoHelper IV
add new column in PowerQuery
Hello, I would like to add a new column in PowerQuery. If a customer has Group A, it should return "Group A", otherwise "non Group A". Best regards Tito Data: Rsult
- 2 years ago
Hi Tito ,
You could create it as a Calculated column in the front end=
Group A =var Namecur = [Name] --Current Namevar grouphigh = COUNTROWS(FILTER(List, Table[Group] = "A" && List[Name] = Namecur ))returnif(grouphigh > 0, "Group A", "non Group A")
SamWiseOwl
2 years agoSuper User
Hi Tito
Sadly calculated columns cannot be made dynamic.
They are only recalculated when the data is refreshed.
Tito
2 years agoHelper IV
Hello SamWiseOwl
I tried it, but it didn't work.
Group dynamic =
var _Group = SELECTEDVALUE(Tabelle[Group])
var Namecur = [Name] --Current Name
var grouphigh = COUNTROWS(FILTER(Tabelle, Tabelle[Group] = _Group && Tabelle[Name] = Namecur ))
return
if(
grouphigh > 0, "Group " & _Group, "non Group " & _Group )