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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

grand total division instead of sum

Hi,

I have a simple fact table with different transactions and values.

And just one measure that sums the "Value" column:

qty = sum(transactiontable[Value])
 

Reuben_0-1643634572378.png

 

when I draw a matrix table I filter it "Category2" by "liquid"and "production"

Reuben_1-1643634786260.png

Showing the folling result:

Reuben_2-1643634841974.png

 

I was wondering is there is any way to show the division between waste & activity for each branch/plant as it is shown in the image bellow:

 

Reuben_3-1643636725608.png

 

Im also attaching a link to the PBI model is case it helps

https://www.dropbox.com/s/lgfkjf40csfc6t4/grand%20total%20by%20branch%20plant.pbix?dl=0 

 

Thank you very much for you support

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , You can create a measure for that and force that plant level using isinscope.

The column of Activity , Waste should not be in scope

https://www.kasperonbi.com/use-isinscope-to-get-the-right-hierarchy-level-in-dax/

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

3 REPLIES 3
Anonymous
Not applicable

Thanks again @amitchandak ! I got it with your help.

Isinscope2 =
SWITCH (
    TRUE (),
    ISINSCOPE ( transactiontable[Category2] ), sum(transactiontable[Value]),
    ISINSCOPE ( transactiontable[Category] ), sum(transactiontable[Value]),
    FORMAT (
        DIVIDE (
            CALCULATE (
                sum(transactiontable[Value]),
                transactiontable[Category2] = "Production"
            ),
            CALCULATE (
                sum(transactiontable[Value]),
                Movimientos[Category] = "Liquid"
            )
        ),
        "Percent"
    )
)

 

Anonymous
Not applicable

thanks for the tip @amitchandak !! I will try!!

amitchandak
Super User
Super User

@Anonymous , You can create a measure for that and force that plant level using isinscope.

The column of Activity , Waste should not be in scope

https://www.kasperonbi.com/use-isinscope-to-get-the-right-hierarchy-level-in-dax/

 

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.