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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
padinator
Helper I
Helper I

Save subtotal in measure and use as dynamic multiplier

Hello all, to illustrate my issue i would like to show the following screenshot

As you see i have basically 3 categories of costs which is Picking (here i add up any cost except my storage costs) and the other 2 dimensions are costs for storage&unmoved storage cost.

Long story short, i am desperately looking for a way to dynamically save the cost amounts for (Storage & Unmoved) in some kind of measure which is then used to be multiplied by the corresponding "Spread" in any line. It is important to understand that this is just one block of many within my pivot table, which means i have about 100 blocs of Picking | Storage & Unmoved sums, while for any of these blocs i need to find a way to dynamically store its corresponding amount for Storage in a variable which is then used within the lines above to multiply the spread with it.

 

padinator_1-1643899514321.png

 

Any help or hint is highly appreciated!

Thanks !

 

3 REPLIES 3
Anonymous
Not applicable

Hi @padinator,

Can you please share a pbix or some dummy data that keep raw data structure with expected results? It should help us clarify your scenario and test to coding formula.

How to Get Your Question Answered Quickly  

Regards,

Xiaoxin Sheng

amitchandak
Super User
Super User

@padinator , check if measure like this can help

 

calculate(sum(table[COST]), filter(allselected(Table[Category]), Table[Category] in {"Storage","Unmoved"} ) )

 

or

 

calculate(sum(table[COST]), filter(all(Table[Category]), Table[Category] in {"Storage","Unmoved"} ) )

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Wll unfortunately it does not work. Idk why but generally it does not seem that any of the formulas gets even accepted. I get an #ERROR in nearly any formula i am trying to use. I should mention that i use PowerPivot and not PowerBI , but regarding the syntax this should not make a difference?

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.