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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Anonymous
Not applicable

Use previous months actuals as current months actuals?

Hi,

 

I have a dataset looking like this:

 

YearMonth | MeasurementType | Measurment

201810       |  Hum                      |    0.3

201810       |  Tmp                       |    20.1

201811       |  Hum                      |     0.9

201811       |  Tmp                       |     22.3

In my Power Query i would like to copy previous month actuals to use as current month actuals - reason being I don't get the new actuals before end of month.. So I'd like output to be:

YearMonth | MeasurementType | Measurment

201810       |  Hum                      |    0.3

201810       |  Tmp                       |    20.1

201811       |  Hum                      |     0.9

201811       |  Tmp                       |     22.3

201812       |  Hum                      |     0.9

201812       |  Tmp                       |     22.3

 

Then when month is over - when the actuals are actually there, the "interpolated" numbers should be replaced..

 

Can anyone think of an elegant way to do this?

 

Best, Jon

3 REPLIES 3
v-lili6-msft
Community Support
Community Support

hi, @Anonymous

You may try to use Append Function Power Query.

here are some tutorial for you to refer to:

https://www.youtube.com/watch?v=jcHqWNAGV1w

http://radacad.com/append-vs-merge-in-power-bi-and-power-query

 

 

Best Regards,

Lin

Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

I have data for all months except the current.

So I need to

 

1. Extract the previous month

2. Add 1 to the month

3. Append this to original table

 

I just can't seem to make in a nice way with M. Any suggestions?

 

Jon

hi, @Anonymous

It should be achieved, Could you share a sample pbix file or some data sample and expected output.  Do mask sensitive data before uploading.

 

 

Best Regards,

Lin

Community Support Team _ Lin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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