Hello,
I wish to calculate percent of change from month to month and to automatically return values only with fulfilled conditions.
Can I do all that using just DAX.
My thinking is something like this.
I have May and April for example. And columns with Date, Product_Name and Product_Sales.
Tot_SUM := sum(Table[Product_Sales])
SUM_PrMonth := CALCULATE( [Tot_SUM] ; PREVIOUSMONTH( Table[Date] ))
Percent_Change := Tot_SUM / SUM_PrMonth - 1
And in slicer I will choose month. Now, I want to show in table in Power BI only rows with product names where Percent of change is less than -20% and greater than 20%.
I tried with a given formula but unfortunately not very successful.
Measure := CALCULATE( [Tot_SUM]; FILTER( Table; [Percent_Change] < 0,2 && [Percent_Change] > 0,2 ))
Thanks in advance
I wish to calculate percent of change from month to month and to automatically return values only with fulfilled conditions.
Can I do all that using just DAX.
My thinking is something like this.
I have May and April for example. And columns with Date, Product_Name and Product_Sales.
Tot_SUM := sum(Table[Product_Sales])
SUM_PrMonth := CALCULATE( [Tot_SUM] ; PREVIOUSMONTH( Table[Date] ))
Percent_Change := Tot_SUM / SUM_PrMonth - 1
And in slicer I will choose month. Now, I want to show in table in Power BI only rows with product names where Percent of change is less than -20% and greater than 20%.
I tried with a given formula but unfortunately not very successful.
Measure := CALCULATE( [Tot_SUM]; FILTER( Table; [Percent_Change] < 0,2 && [Percent_Change] > 0,2 ))
Thanks in advance