The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi,
I have a measure which identifies the "Project Name", based on the "Project Priority Score" (the lowered the score is the highest priority).
Top Ranked Project v2= CALCULATE(SELECTEDVALUE('PowerBi Data Export'[Project Name]),TOPN(1,ALLSELECTED('PowerBi Data Export'),'PowerBi Data Export'[Project Priority Score], ASC))
This formula is working fine. However, I would like to show the "Status" of the project along with the "Project Name". Ideally Project Status would come in a new line. Any idea how to modify the formula?
Any help would be appreciated. Thanks.
Solved! Go to Solution.
Hi @Rubal ,
I‘m not sure whether you wanna show as below?
If so,just modify your measure as below:
Top Ranked Project v2= CALCULATE(SELECTEDVALUE('PowerBi Data Export'[Project Name])&"-"&SELECTEDVALUE('PowerBi Data Export'[Status]),TOPN(1,ALLSELECTED('PowerBi Data Export'),'PowerBi Data Export'[Project Priority Score], ASC))
If it is not what you need,show me your expected output.
Much appreciated.
Hi @Rubal ,
I‘m not sure whether you wanna show as below?
If so,just modify your measure as below:
Top Ranked Project v2= CALCULATE(SELECTEDVALUE('PowerBi Data Export'[Project Name])&"-"&SELECTEDVALUE('PowerBi Data Export'[Status]),TOPN(1,ALLSELECTED('PowerBi Data Export'),'PowerBi Data Export'[Project Priority Score], ASC))
If it is not what you need,show me your expected output.
Much appreciated.
If you any data grouping that will change your top N or Rank. As you have already taken the project in the row/group/axis take status as MAX, that will convert it into the measure and it can work
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