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

Next up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now

Reply
Anonymous
Not applicable

Report changes from historical data

Hello everyone,

I have set up a dataset in Power BI that every week import the same list of projects from an external file and saves the import date. Something like the table below:

Import DateProject IDExpected Finish Date
1-JanA15-Feb
1-JanB30-Mar
1-JanC25-Feb
8-JanA15-Feb
8-JanB10-Apr
8-JanC25-Feb
8-JanD14-Apr
15-JanA1-Mar
15-JanB10-Apr
15-JanC20-Mar
15-JanD14-Apr

 

I would like to plot the delays per project over time. Therefore getting a new table that looks like:

CHANGE8-Jan15-Jan
A014
B110
C023
DNEW0

And a consequent graph like 

pappagani_0-1669059885000.png

 

 

What do you think it's the best/easiest way to achieve this? 

Please consider that I am still very new in Power BI.

 

Thanks!

1 ACCEPTED SOLUTION
v-jingzhang
Community Support
Community Support

Hi @Anonymous 

 

You can add a calculated column with the following formula in the original table. 

Delay Days = 
VAR _lastFinishDate = MAXX(FILTER('historical data','historical data'[Project ID]=EARLIER('historical data'[Project ID])&&'historical data'[Import Date]=EARLIER('historical data'[Import Date])-7),'historical data'[Expected Finish Date])
RETURN
DATEDIFF(_lastFinishDate,'historical data'[Expected Finish Date],DAY)

vjingzhang_0-1669099000440.png

Then add above new column to Y-axis of a Stacked column chart. Use "Import Date" on X-axis and "Project ID" as Legend. 

vjingzhang_1-1669099180542.png

 

Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.

View solution in original post

1 REPLY 1
v-jingzhang
Community Support
Community Support

Hi @Anonymous 

 

You can add a calculated column with the following formula in the original table. 

Delay Days = 
VAR _lastFinishDate = MAXX(FILTER('historical data','historical data'[Project ID]=EARLIER('historical data'[Project ID])&&'historical data'[Import Date]=EARLIER('historical data'[Import Date])-7),'historical data'[Expected Finish Date])
RETURN
DATEDIFF(_lastFinishDate,'historical data'[Expected Finish Date],DAY)

vjingzhang_0-1669099000440.png

Then add above new column to Y-axis of a Stacked column chart. Use "Import Date" on X-axis and "Project ID" as Legend. 

vjingzhang_1-1669099180542.png

 

Best Regards,
Community Support Team _ Jing
If this post helps, please Accept it as Solution to help other members find it.

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.