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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.

Reply
Anonymous
Not applicable

Add more years to a table

Hi everyone!

I have a table from SQL with some data by years/months that stops at December 2023.

I want to add more years with the same data as previous year, where Value is multiplied by 5%. 

Example for 2024, I need to have the same number of rows with the same data, except culmun Value which will be = Value * 5%.

Is it possible? Maybe in power query?

Thank you!

adriandumitru_0-1675250877231.png

 

1 ACCEPTED SOLUTION
johnt75
Super User
Super User

In Power Query you could duplicate the query for 2023, switch to the transform ribbon and use the Standard section from the Number column section to add 1 to the year and multiply the value by 1.05. Then append the 2 queries.

View solution in original post

3 REPLIES 3
johnt75
Super User
Super User

In Power Query you could duplicate the query for 2023, switch to the transform ribbon and use the Standard section from the Number column section to add 1 to the year and multiply the value by 1.05. Then append the 2 queries.

Anonymous
Not applicable

Thank You, but maybe there is a more automated solution?

I will need at least 3 more years to replicate and append, this will have an impact on performance.

You could do it in the SQL. Depending on the flavour of SQL you could take the query which currently pulls data for 2022 and use that to define a CTE. Then the query which returns data could be a union of the base data and as many copies as you need, adding values to the year column and changing the data values.

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

Check out the July 2025 Power BI update to learn about new features.