Forum Discussion
srigag900
1 year agoFrequent Visitor
Power BI Calculated Measure - Returning the figures correctly in the matrix.But the total is incorr
Hi Experts, Im working with this power bi dashboard which calculates the stock price that are at risk. Here is my calculations Stock In hand = (SUM('Inventory Table'[QTY])+SUM(BudgetForecas...
- 1 year ago
srigag900 Sub-Total was not the issue, grand total is showing incorrect.
After exporting data i can see Grand Total is 227200, not 13975000.
Revenue at Risk Corrected = SUMX( SUMMARIZECOLUMNS( 'Stock Type'[Name], 'Size Table'[SIZE] ), VAR CurrentStock = CALCULATE([Stock in Hand]) VAR CurrentUnitPrice = CALCULATE(SUM('Price Table'[Unit Price])) RETURN IF( CurrentStock < 0, CurrentUnitPrice * ABS(CurrentStock), 0 ) )Test this measure and let me know the progress.
Royel
Super User
1 year agosrigag900 Sub-Total was not the issue, grand total is showing incorrect.
After exporting data i can see Grand Total is 227200, not 13975000.
Revenue at Risk Corrected =
SUMX(
SUMMARIZECOLUMNS(
'Stock Type'[Name],
'Size Table'[SIZE]
),
VAR CurrentStock = CALCULATE([Stock in Hand])
VAR CurrentUnitPrice = CALCULATE(SUM('Price Table'[Unit Price]))
RETURN
IF(
CurrentStock < 0,
CurrentUnitPrice * ABS(CurrentStock),
0
)
)
Test this measure and let me know the progress.