Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
I have a report where the user chooses the date period and the cards update to show the number of purchases and individual customers. I've also created a card that show the average number of purchases per customer, by using one measure divided by the other measure.
I'd also like to display the largest number of purchases made by one customer, but unsure how to approach this. I tried summarise, but this creates a new table and the date slicer has no effect on the table.
Solved! Go to Solution.
Hi @Anonymous ,
Try measure like this:
Measure =
CALCULATE (
MAXX (
SUMMARIZE (
'Table',
'Table'[customer],
"Total", SUM ( 'Table'[Purchase] )
),
[sum_]
),
ALLSELECTED('Table'[date]
))
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous ,
Try measure like this:
Measure =
CALCULATE (
MAXX (
SUMMARIZE (
'Table',
'Table'[customer],
"Total", SUM ( 'Table'[Purchase] )
),
[sum_]
),
ALLSELECTED('Table'[date]
))
Best Regards,
Liang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
@V-lianl-msft If i wanted to display a column chart, based on this dataset, the x-axis would be the number of purchases made eg in your dataset 15, 33, 37, y-axis would be the number of customers making those number of purchase eg, your dataset would be, 1,1,1.
How can I make that table above that would change with the dates? I suspect it's something to with the same code with SUMMARIZE, but without the MAXX function and create a table? Something like below, but correct?!
@Anonymous , Create a Rank on the customers on no of purchase and you can filter on Rank =1 for top customer
For Rank Refer these links
https://radacad.com/how-to-use-rankx-in-dax-part-2-of-3-calculated-measures
https://radacad.com/how-to-use-rankx-in-dax-part-1-of-3-calculated-columns
https://radacad.com/how-to-use-rankx-in-dax-part-3-of-3-the-finale
https://community.powerbi.com/t5/Community-Blog/Dynamic-TopN-made-easy-with-What-If-Parameter/ba-p/367415
Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.
User | Count |
---|---|
112 | |
100 | |
80 | |
64 | |
57 |
User | Count |
---|---|
146 | |
110 | |
93 | |
84 | |
67 |