Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!
Hello friends,
I have a spreadsheet that has the total number of cancellations as 293 and I have a table that has the top 10 cities with cancelations and the total of the top 10 is 257. I need to create a card that shows 87%.
The table has a TOPN filter. I tried to create a measure with two variables, one counting the total number of rows (293) and another variable with the topN of the same count (like the table).
It didn't work. Can you guys help me?
Solved! Go to Solution.
@raphazzz , Assuming cancels is not a TOPN measure create topn meausre
M1= SUMX(keepfilters(topn(10, ALL('Table'[Customer City]) , [Cancels], desc)), [Cancels])
M1 % = divide(M1= SUMX(keepfilters(topn(10, ALL('Table'[Customer City]) , [Cancels], desc)), [Cancels]), calculate([Cancels], allselected()) )
or
M1 % = divide(M1= SUMX(keepfilters(topn(10, ALL('Table'[Customer City]) , [Cancels], desc)), [Cancels]), calculate([Cancels], all()) )
@raphazzz , Assuming cancels is not a TOPN measure create topn meausre
M1= SUMX(keepfilters(topn(10, ALL('Table'[Customer City]) , [Cancels], desc)), [Cancels])
M1 % = divide(M1= SUMX(keepfilters(topn(10, ALL('Table'[Customer City]) , [Cancels], desc)), [Cancels]), calculate([Cancels], allselected()) )
or
M1 % = divide(M1= SUMX(keepfilters(topn(10, ALL('Table'[Customer City]) , [Cancels], desc)), [Cancels]), calculate([Cancels], all()) )
Thanks for your help! I tweaked the second formula a little bit and it's working.
User | Count |
---|---|
128 | |
108 | |
100 | |
64 | |
62 |
User | Count |
---|---|
136 | |
113 | |
102 | |
71 | |
60 |