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

Grow your Fabric skills and prepare for the DP-600 certification exam by completing the latest Microsoft Fabric challenge.

Reply
reidnmorrison
Resolver II
Resolver II

Add column with previous month value

Hello,

 

I am looking to add a column to a table that shows the [Due Date] from the previous month. I have a date table that is linked to the [Import Date] column in the table. 

 

reidnmorrison_2-1668608729172.png

Any help on how to do this would be much appreaciated.

 

 

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@reidnmorrison ,

new column =

maxx(filter(Table, [Site Name] = earlier([Site Name])  && [Import Date] <earlier([Import Date]) ) , [Due Date])

View solution in original post

2 REPLIES 2
reidnmorrison
Resolver II
Resolver II

Thank you @amitchandak  thats great.  did have to change the column it filters to [Site_Task] as [Site] is not unique due to many tasks at each site.  

amitchandak
Super User
Super User

@reidnmorrison ,

new column =

maxx(filter(Table, [Site Name] = earlier([Site Name])  && [Import Date] <earlier([Import Date]) ) , [Due Date])

Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel1

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.