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

Be one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now

Reply
Anonymous
Not applicable

How to get Bottom M 1 excluding zeros

Hi,

I am trying to get the next bottom ranked value that is not zero. This is what I currently have written to return the first ranked lowest value.

Least COUNT =
CALCULATE(
    Audit[Sum Audits and Entries],
    FILTER(
        System_Users,
        RANKX(
            System_Users,
            Audit[Sum Audits and Entries],,
            ASC,
            DENSE
        ) = 1
    )
 ) + 0
Results
IGotTheP0werBI_0-1664226776926.png
Need it to return 31. I am new to power BI so any help is greatly appreciated.
IGotTheP0werBI_1-1664226915193.png

 

 

4 REPLIES 4
Anonymous
Not applicable

Is there a way to write something that says
IF result = 0 then 

    FILTER(
        System_Users,
        RANKX(
            System_Users,
            Audit[Sum Audits and Entries],,
            ASC,
            DENSE
        ) = 2 
Else 1 
lazurens2
Frequent Visitor

Maybe this to return positives only into the measure : 

Least COUNT =
VAR _rank = CALCULATE(
    Audit[Sum Audits and Entries],
    FILTER(
        System_Users,
        RANKX(
            System_Users,
            Audit[Sum Audits and Entries],,
            ASC,
            DENSE
        ) = 1
    )
 ) + 0
VAR Result = If ( _rank > 0 , _rank )
Return 
     Result 

Good luck !

Anonymous
Not applicable

Great thought. Unfortunately it just removes the results with zero.

IGotTheP0werBI_0-1664286348683.png

 

Anonymous
Not applicable

IGotTheP0werBI_0-1664227228701.png

Visualization Filters 

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

Dec Fabric Community Survey

We want your feedback!

Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.

ArunFabCon

Microsoft Fabric Community Conference 2025

Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.

December 2024

A Year in Review - December 2024

Find out what content was popular in the Fabric community during 2024.