Forum Discussion
IlikePBI
4 years agoFrequent Visitor
Multiply total measure by calculated column
Hello, I'm started to use DAX and I need some help please. Actualy I'm trying to multiply a measure which is a total of measure values obtained by using Removefilters function, by a calculated colu...
- 4 years ago
IlikePBI Seems like it should be:
'FACT_NCM_QFRZ'[Baseline]*MAX(MD_TIME[Reporting Month Number])
Greg_Deckler
4 years agoCommunity Champion
IlikePBI Seems like it should be:
'FACT_NCM_QFRZ'[Baseline]*MAX(MD_TIME[Reporting Month Number])- IlikePBI4 years agoFrequent Visitor
Perfect, it's working. Thank you so much!
However I don't understand yet how the MAX has resolved it. If you can please clarify?
Thank you again!
- Greg_Deckler4 years agoCommunity Champion
IlikePBI So, the MAX simply gets the maximum value of the column in context. So, each row in your table visual supplys a filter context for the Reporting Month Number. In the first row of the table visual the context is 1, second row 2, etc. So you could have also used MIN intead of MAX and if it is truly a numeric value you could technically use any of the basic aggregators, SUM, AVERAGE, etc. because the context of the row in the visual is filtering the column to a single value.
- IlikePBI4 years agoFrequent Visitor
Great! Thank you so much!