Forum Discussion
To compute some rows dynamically
Hi,
Thank you for the reply!!
1.I have added the measure QuantityOfLastWeek in the file but is not showing any value in the report.
2.I have added the Total order type in the file.
Please find the updated pbi file in the link
https://drive.google.com/drive/folders/12Ou3PcwDie0aju7ZV8ISSbeKsvXdZ6Vp
Hi,
Additionally I would like to ask if there is any way to modify the query instead of writing up DAX expression for representing this calculation in the report.
- sajal1612928 years agoHelper V
Hi,
I have modified my pbi file with adding up a new measure for representing the previous week sales.
Now i am stuck up while re-assigning the value of previous week sales to the field Total.
Is there any way to perform iteration in DAX and traverse for each record?
Please find the link of new pbi file below
https://drive.google.com/drive/folders/12Ou3PcwDie0aju7ZV8ISSbeKsvXdZ6Vp
Thanks for your help!!
- sajal1612928 years agoHelper V
Hi,
Can anyone please help me with this?
I am really stuck up on it,have tried to implement this functionality in sql but it has become a way too complex.
I need this really badly.
- v-jiascu-msft8 years agoMicrosoft Employee
Hi sajal161292,
Sorry so late. Too much work to do. I found a workaround though it isn't prefect. You can try it and may get some ideas. You can test it in this file.
Measure = CALCULATE ( SUMX ( SUMMARIZE ( '0ShortageData', '0ShortageData'[Org], '0ShortageData'[Part], '0Calendar'[Week], "value", SUM ( '0ShortageData'[Quantity] ) ), [value] ), ALL ( '0ShortageData'[OrderType (groups)] ), FILTER ( ALL ( '0Calendar' ), '0Calendar'[Week] < MAX ( '0Calendar'[Week] ) ) )Best Regards,
Dale