Forum Discussion
kevpuk
7 years agoFrequent Visitor
Dynamic measure, based on period?
Hi All So, I have been struggling with how to resolve a problem. I have a set of data, made up of individual measures on rows, with period in columns (2015-2019)......what I am trying to do is m...
- 7 years ago
Hi kevpuk,
Could you mean to calculate the [Fall] and [Trip] measure with sample data for 2016, 2017, 2018 and use another measure for 2019?
If so, could you have tried with IF function?
Fall = IF(CALCULATE(MAX('sample_data'[Period])<>"2019"),calculate(Sum(sample_data[Value]),sample_data[Metric]="Fall"),0)(You could replace the 0 in the formula to the measure of calculating "2019")
Regards,
Daniel He
v-danhe-msft
7 years agoMicrosoft Employee
Hi kevpuk,
Could you mean to calculate the [Fall] and [Trip] measure with sample data for 2016, 2017, 2018 and use another measure for 2019?
If so, could you have tried with IF function?
Fall = IF(CALCULATE(MAX('sample_data'[Period])<>"2019"),calculate(Sum(sample_data[Value]),sample_data[Metric]="Fall"),0)
(You could replace the 0 in the formula to the measure of calculating "2019")
Regards,
Daniel He
kevpuk
7 years agoFrequent Visitor
Hi Daniel
Well, that is elegant, nice and simple - thank-you very much :)