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

We've captured the moments from FabCon & SQLCon that everyone is talking about, and we are bringing them to the community, live and on-demand. Starts on April 14th. Register now

Reply
abhisheksan007
New Member

Need to understand how DAX formula is being calculated for combination of SUMX, ALLEXCEPT AND SUM

Dear All,

 

I am struggling to understand the backend functioning of some DAX Formulae.

Below is my test data :

abhisheksan007_0-1694313547128.png

I am trying to understand how below meaures are being calculated in some scenarios :

1. Scenario 1

Category Sales = SUMX(ALLEXCEPT(Sheet1,Sheet1[Category]),SUM(Sheet1[Sales]))
Output :
abhisheksan007_2-1694313791531.png

 


2. Scenario 2

Category Sales = SUMX(ALLEXCEPT(Sheet1,Sheet1[Sub Cat]),SUM(Sheet1[Sales]))

 

Output :

abhisheksan007_3-1694313907710.png

3. Scenario 3

Category Sales = SUMX(ALL(Sheet1[Category]),SUM(Sheet1[Sales]))

Output:

abhisheksan007_4-1694314043383.png

 

4. Scenario 4

Category Sales = SUMX(ALL(Sheet1[Sub Cat]),SUM(Sheet1[Sales]))

Output:

abhisheksan007_5-1694314136689.png

5. Scenario 5: Added calculated table

Table = ALLEXCEPT(Sheet1,Sheet1[Sub Cat])
Category Sales = SUMX('Table',SUM('Table'[Sales]))
Output :
abhisheksan007_6-1694314447340.png

 

6. Scenario 6: Added calcualted table

Table = ALLEXCEPT(Sheet1,Sheet1[Category])
Category Sales = SUMX('Table',SUM('Table'[Sales]))
Output
abhisheksan007_7-1694314751814.png

 

It would be great help if someone can help me understand how the calcualtions are being computed on the backend in all these scenarios in absence of CALCULATE function and how the output is being generated. Thanks in advance!

 

Regards,

AD

1 REPLY 1
ThxAlot
Super User
Super User

Here's the reference to ALLEXCPET

ALLEXCEPT - DAX Guide

 

Use such a measure to reveal some details of calculation

DEBUG = TOCSV( ALLEXCEPT(Sheet1,Sheet1[Category]), 100, ", ", TRUE() )

ThxAlot_0-1694325136838.png



Expertise = List.Accumulate(


        {Days as from Today},


        {Skills and Knowledge},


        (Current, Everyday) => Current & Day.LearnAndPractise(Everyday)


)



Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.