The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
Hello Team,
I have the below table:
Client Code | PAX |
1010 | 2 |
2020 | 3 |
1010 | 2 |
1010 | 2 |
3030 | 4 |
I need your help with a DAX formula to calculate the Total Pax but it has to take into account the unique client code.
From the table: My result should be 9 PAX (1010 = 2 + 2020 = 3 and 3030 = 4)
Thank you for your help.
Kind Regards,
Hash
Solved! Go to Solution.
Hi @Hash2023 ,
Try the following code:
Total PAX = SUMX(SUMMARIZE(Table, Table[Client], Table[CodePAX]), Table[CodePAX])
I'm assuming based on your sample that the CodePAX is always the same for the sames client.
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsHi @Hash2023 ,
Try the following code:
Total PAX = SUMX(SUMMARIZE(Table, Table[Client], Table[CodePAX]), Table[CodePAX])
I'm assuming based on your sample that the CodePAX is always the same for the sames client.
Regards
Miguel Félix
Proud to be a Super User!
Check out my blog: Power BI em PortuguêsHi Miguel,
Thank you for your help. It works.
Kind Regards,
User | Count |
---|---|
69 | |
64 | |
62 | |
55 | |
28 |
User | Count |
---|---|
203 | |
82 | |
65 | |
48 | |
38 |