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

RankX in Direct Query

I have a table where I need to Rank Sales by their total Volume I have two merged tables to grab their names that are synced. I'm getting 1 for all people 

 

Rank Current Month = RANKX(ALLSELECTED(LoanMaster),CALCULATE(SUM('LoanMaster'[Loan Amount]),AllExcept(LoanMaster,LoanMaster[NMLS Loan Originator ID])),,DESC,DENSE)
 
I have tried everything and can't get this figured out
 
3 REPLIES 3
v-lili6-msft
Community Support
Community Support

hi, @Anonymous 

I have test on my side, it works well. If you drag the [NMLS Loan Originator ID] field in the visual?

For this formula, you must keep the [NMLS Loan Originator ID] for the row context of this measure.

If you still have the problem, please share some sample data and your expected out. There should be something wrong in other.

 

Best Regards,

Lin

Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

So you're saying I have to have that column in my visual? Because it is not something I want showing. 

hi, @Anonymous 

Measure is a formula that is evaluated in the context in which it is used. For example, if you use a measure in a matrix visual, the formula will be evaluated for each matrix row and column combination separately.

and this is not something you want showing, what is your expected output?

 

Just share some simple sample data and expected output, and i will give you right measure formula.

Please see this post regarding How to Get Your Question Answered Quickly:
https://community.powerbi.com/t5/Community-Blog/How-to-Get-Your-Question-Answered-Quickly/ba-p/38490

 

Best Regards,

Lin

Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

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.