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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
FritzVPL
Advocate II
Advocate II

Calculate function results change based on default sort order of a column

I need some help explaining this behavior. It caught me off guard and I can't seem to get my head around why its occuring.

 

See these two calculate metrics.

 

Test Filter = CALCULATE(sum('Test Fact Table'[Amount]),FILTER(Test_Dim_Table,Test_Dim_Table[Service Level]="Ground"))
 
Test No Filter = CALCULATE(sum('Test Fact Table'[Amount]),Test_Dim_Table[Service Level]="Ground")
 
FritzVPL_0-1721248331730.png

As expected, the "No Filter" test metric is repeating the value for ground on each service level.

 

However, if you change the default sort of service level to be off a different column, it will yield this result.

FritzVPL_1-1721249493296.png

 

Why does using the "Sort by Column" feature change the results of this calculation? Is this expected or a potential bug?

 

 

2 REPLIES 2
muhssamy
Resolver I
Resolver I

you are using "Sort by Column" not sorting from the grid itself ?

Correct, "Sort by column" sorting based on a different column on the same dimension table

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

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