Forum Discussion
Recursive Calculation in DAX
I am currently trying to perform a price forecast calculation in DAX in excel. I have quarterly price data and a base price. I need to take the base price and add the price difference of the previous two quarters to the base price to find a new calculated price. This needs to be repeated using the new calculated price as the base price and carry on for future pricing. An image of the Excel logic is included, for example. DAX code to avoid self-referencing would help a lot. Calculated columns are ok, as I believe that is the only way to reach the goal at this point. Thank you!
You cannot do conditional aggregations in DAX. Your only option is List.Accumulate in Power Query.
5 Replies
- lbendlinSuper User
You cannot do conditional aggregations in DAX. Your only option is List.Accumulate in Power Query.
- DekuSuper User
You can have a look at the Dax financial functions. Not used them myself but there might be something there
- v-veshwara-msftCommunity Support
Hi lbaysinger20 ,
Thank you for engaging with the Microsoft Fabric Community.
Just following up to check if your query has been resolved and whether the responses from lbendlin and Deku were helpful. If so, please consider marking the helpful replies as Accepted Solutions to assist others with similar queries. If further assistance is needed, please reach out.
Thank you. - v-veshwara-msftCommunity Support
Hi lbaysinger20 ,
Just checking in to see if you query is resolved and if any responses were helpful. If so, kindly consider marking the helpful reply as 'Accepted Solution' to help others with similar queries.
Otherwise, feel free to reach out for further assistance.
Thank you.
- v-veshwara-msftCommunity Support
Hi lbaysinger20 ,
Following up to see if your query has been resolved. If any of the responses helped, please consider marking the relevant reply as the 'Accepted Solution' to assist others with similar questions.
If you're still facing issues, feel free to reach out.
Thank you.