Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

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.

Reply
Anonymous
Not applicable

NEED HELP WITH RANKING

here iam using this measure to calculate rank it is correct  but what if there is a missing weeknumber in the slicer Screenshot (2)1.pngthen it returns 111 need to calculate previous week rank but if a weeknumber  is missing then it shows rank of one more priovous week need help to make  a rankmeasure as i mentioned thanks.Screenshot (2).png

rankprevious week = 
 CALCULATE( RANKX(ALL('Table 3'[CompanyTitle]),[salepayment],,DESC,Dense),FILTER(ALL('tbl_Calendar_ph'),tbl_Calendar_ph[Week Rank]=MAX(tbl_Calendar_ph[Week Rank])-1))

 

1 REPLY 1
VahidDM
Super User
Super User

HI @Anonymous 

 

You need to add a Date table to your report:https://www.vahiddm.com/post/creating-calendar-table-with-3-steps

then add a relationship between Date table and your table. In the date table add your rank for weeks as a calculated column, and use this column in your slicer.

 

Share your PBIX file if it's possible

 

If this post helps, please consider accepting it as the solution to help the other members find it more quickly.
Appreciate your Kudos!!
LinkedIn: 
www.linkedin.com/in/vahid-dm/

 

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors