March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hello,
I have the below raw data
PersonID | TravelDate | ContactCount |
John | 11/1/2023 | 5 |
John | 11/2/2023 | 6 |
John | 11/3/2023 | 3 |
Nick | 11/1/2023 | 4 |
Nick | 11/2/2023 | 7 |
Steve | 11/3/2023 | 5 |
Mary | 11/2/2023 | 3 |
For each person, there is a goal and the way i did it is to create two measures.
1)maxperson = max(MainTable[PersonID])
and then
2) persongoal = IF(MainTable[maxperson] ="Mary",8,10)
At the end i display the goal filled %. Now, i expect to have the result as
PersonID | ContactCount | Goal | GoalFilled |
John | 14 | 10 | 140% |
Nick | 11 | 10 | 110% |
Steve | 5 | 10 | 50% |
Mary | 3 | 8 | 38% |
Total | 33 | 38 | 87% |
But i get the result as below.
PersonID | ContactCount | Goal | GoalFilled |
John | 14 | 10 | 140% |
Nick | 11 | 10 | 110% |
Steve | 5 | 10 | 50% |
Mary | 3 | 8 | 38% |
Total | 33 | 10 | 330% |
The columns work, but the total gets messed up. Any recommendation on how to fix the total .
Thank you.
Solved! Go to Solution.
It's a measure totals issue.
Try
SUMX(VALUES(MainTable[PersonID]),IF ([maxperson] ="Mary", 8,10))
--
As a convention when we use a measure in another measure, we don't precede it with the table name
It's a measure totals issue.
Try
SUMX(VALUES(MainTable[PersonID]),IF ([maxperson] ="Mary", 8,10))
--
As a convention when we use a measure in another measure, we don't precede it with the table name
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
134 | |
91 | |
90 | |
64 | |
58 |
User | Count |
---|---|
201 | |
137 | |
107 | |
72 | |
68 |