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.
Hello, I am looking for the DAX formula which allows to calculate the rank of an Id according to its decreasing Qty value by date: example in attachment ... either in a calculated column, or by a measure. Can you help me?
Solved! Go to Solution.
Try this:
Rank =
VAR __date =
SELECTEDVALUE ( 'Table'[Date] )
RETURN
IF (
HASONEVALUE ( 'Table'[id] ),
RANKX (
ALL ( 'Table'[Date], 'Table'[id] ),
CALCULATE ( SUM ( 'Table'[qty] ), 'Table'[Date] = __date )
)
)
Proud to be a Super User!
Try this:
Rank =
VAR __date =
SELECTEDVALUE ( 'Table'[Date] )
RETURN
IF (
HASONEVALUE ( 'Table'[id] ),
RANKX (
ALL ( 'Table'[Date], 'Table'[id] ),
CALCULATE ( SUM ( 'Table'[qty] ), 'Table'[Date] = __date )
)
)
Proud to be a Super User!
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 |
---|---|
114 | |
100 | |
78 | |
75 | |
50 |
User | Count |
---|---|
144 | |
109 | |
108 | |
87 | |
61 |