The ultimate Microsoft Fabric, Power BI, Azure AI, and SQL learning event! Join us in Stockholm, Sweden from September 24-27, 2024.
2-for-1 sale on June 20 only!
Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started
I'm trying to rank some records by the date, but I'm getting rather unexpected results. Here's my column formula:
But here's the result I'm getting:
Solved! Go to Solution.
Hi @kman42 ,
When I use your expression to create a column, it returns "1" for each row. But, when use it to create a measure, it works well.
If you want to create a column, try this:
Date Rank Index 2 column = RANKX ( 'award', 'award'[award_begin_date],, DESC )
Best Regards,
Icey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi,
Write these 2 measures
Begin_Date = MIN(Award[award_begin_date])
Rank_Date = RANKX(ALLSELECTED(Award[award_begin_date]),[Begin_Date],,DESC)
Hope this helps.
Hello Ashish,
I was trying to implement your solution but I'm getting an error:
Hi,
Replace CALCULATE with RANKX
Oh how I didn't notice it! Thank you so much.
If you allow I have one more question, is there a way to reverse columns order with dates by having this measure created? Don't really know how to do this.
You are welcome. I do not understand your question.
So I would like to change the order of columns, the first column should be 4/1/2024 and the last should be 1/1/2024. I was thinking that creating this measure with rank could help me, but still no idea how to manage it. Hope it's more clear now.
Hi @kman42 ,
When I use your expression to create a column, it returns "1" for each row. But, when use it to create a measure, it works well.
If you want to create a column, try this:
Date Rank Index 2 column = RANKX ( 'award', 'award'[award_begin_date],, DESC )
Best Regards,
Icey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.
Check out the June 2024 Power BI update to learn about new features.
User | Count |
---|---|
102 | |
97 | |
80 | |
62 | |
57 |
User | Count |
---|---|
264 | |
120 | |
115 | |
83 | |
70 |