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
Well Done!
Tito
2 years agoHelper IV
- SamWiseOwl2 years agoSuper UserDynamic Group =var Namecur = SELECTEDVALUE('Group'[Please choose group])--Current NameVAR SelGroup = SELECTEDVALUE('Group'[Please choose group])var grouphigh =CALCULATE(COUNTROWS(List),all(List[Group]), List[Group] = SelGroup)returnif(grouphigh > 0, "Group " & Namecur, "non Group "& Namecur)
- Tito2 years agoHelper IV
Hello SamWiseOwl
perfect , it worked. Thank you very much.