Forum Discussion
SErgey-kuznetso
6 years agoFrequent Visitor
Insert previous value
How can I use DAX formula to insert values from previous months? Example: There is a table http://prntscr.com/qufdjt it is necessary that the value of the Steps is rolled in the current month fro...
- 6 years ago
You need to add more conditions like Region
Example
Last Month column = minx(FILTER('Date','Date'[Date]=EARLIER('Date'[Prev Month Value]) && 'Date'[Region]= earlier('Date'[Region])),'Date'[Month-Year])
SErgey-kuznetso
6 years agoFrequent Visitor
amitchandak
Ok! First step helped me to figure out Prev_Month_Value but due to the function MINX it insert the minimal value from previous month.
There are many repeated Regions with different values of the Steps and I need to insert the Previous Value of the Region from Last Month in current.
Here another example of table http://prntscr.com/qugxns
amitchandak
6 years agoSuper User
You need to add more conditions like Region
Example
Last Month column = minx(FILTER('Date','Date'[Date]=EARLIER('Date'[Prev Month Value]) && 'Date'[Region]= earlier('Date'[Region])),'Date'[Month-Year])
- SErgey-kuznetso6 years agoFrequent Visitor
amitchandak
Thanks, It works! I really appreciate your help