The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredCompete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.
Hi,
I have a scenario where I need to calculate against CostItem ( Cost_item_id)
Budget * MP
BudgetMarkup =
VAR _tb = SUMMARIZECOLUMNS(CostItem[Cost_item_id],Budget_Markup[CostItemId],Budget_Markup[MP],"Budget",[Budget])
RETURN
CALCULATE(SUMX(_tb,[MP]*[Budget]) , CostItem[Is_terminal]=true)
The relationship is
Attaching a sample file.
https://github.com/suvechha/samplepbi/blob/main/sample_b.pbix
Solved! Go to Solution.
Hi,
I am not sure what is your expected result, but please try something like below.
BudgetMarkup =
VAR _tb =
SUMMARIZECOLUMNS (
CostItem[Cost_item_id],
Budget_Markup[MP],
"Budget", [Budget]
)
RETURN
SUMX ( _tb, [MP] * [Budget] )
Your measure looks fine but what result do you expect?
Hi,
I am not sure what is your expected result, but please try something like below.
BudgetMarkup =
VAR _tb =
SUMMARIZECOLUMNS (
CostItem[Cost_item_id],
Budget_Markup[MP],
"Budget", [Budget]
)
RETURN
SUMX ( _tb, [MP] * [Budget] )