Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Kev74
Frequent Visitor

Get the previous value of calculated column

I am stucked in a problem during a few days, 

 

So my problem is I want to retrive the data of the previous row of my same calculated column, but the problem If i create an another column and make LOOKUP in order to retrive the previous row and with this same column to retrive the current row , I will get a circular error dependancy... 

 

I don't have any ideas how to ride about this problem ?

 

 

 

This is the problem in Excel to better understand (I want make the same thing than N column) :

 

Kev74_0-1689939521690.png

 

If you want more details, please say me, thanks you

 

1 ACCEPTED SOLUTION
AlanFredes
Resolver IV
Resolver IV

Hi Kev,

The EARLIER DAX function can help you with this. You will also need to create a numeric Index column.
In the below example, you can see I can calculate the cumulative sum of the row using the EARLIER function. You can change this aggregated function to find MAX, MIN or AVERAGE of the list up until the row you are on.

AlanFredes_0-1690062710812.png

Did I answer your question? Mark my post as a solution!

View solution in original post

1 REPLY 1
AlanFredes
Resolver IV
Resolver IV

Hi Kev,

The EARLIER DAX function can help you with this. You will also need to create a numeric Index column.
In the below example, you can see I can calculate the cumulative sum of the row using the EARLIER function. You can change this aggregated function to find MAX, MIN or AVERAGE of the list up until the row you are on.

AlanFredes_0-1690062710812.png

Did I answer your question? Mark my post as a solution!

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

Find out what's new and trending in the Fabric community.