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
Whitewater100
Solution Sage
Solution Sage

Looking for Table in DAX

Remaining Inventory after Finalized orders Subtracted 

 

Hello Community:

 

I have created a table using some basic measures, see attached. I am looking for suggestions on how to write DAX as a table function for my main visual. Inventory is stored in multiple locations and orders in this case are subtracted from inventory if they are noted as finalized. 

I have the main visual which I'm looking to produce as a DAX table function.

Thank you!

1 ACCEPTED SOLUTION

Hi, @Whitewater100 

 

new Table = 
SUMMARIZECOLUMNS(Products[Product],WH_Loc[WH_Area],WH_Name[WH Name],
                 "total wh qty",SUM(WH_Inv[WH_Qty]),
                 "finalized order qty", CALCULATE(SUM(Orders[Order Qty]),Orders[Order Status]="finalized"),
                 "balance of INV(oh-final oq)",SUM(WH_Inv[WH_Qty])-CALCULATE(SUM(Orders[Order Qty]),Orders[Order Status]="finalized")
                 )

 

Dangar332_0-1698605812772.png

 

View solution in original post

3 REPLIES 3
Whitewater100
Solution Sage
Solution Sage

Please find link to report. Sorry it was not shared correctly the first time!

 

https://drive.google.com/file/d/1VQurjakljRyT1x9bBtHzFF_UjsDw3xbY/view?usp=sharing 

Hi, @Whitewater100 

 

new Table = 
SUMMARIZECOLUMNS(Products[Product],WH_Loc[WH_Area],WH_Name[WH Name],
                 "total wh qty",SUM(WH_Inv[WH_Qty]),
                 "finalized order qty", CALCULATE(SUM(Orders[Order Qty]),Orders[Order Status]="finalized"),
                 "balance of INV(oh-final oq)",SUM(WH_Inv[WH_Qty])-CALCULATE(SUM(Orders[Order Qty]),Orders[Order Status]="finalized")
                 )

 

Dangar332_0-1698605812772.png

 

Thanks very much! Nice job:-)

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.