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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Anonymous
Not applicable

Aggregate time series monthly in matrix

Hi, I'm pretty new to Power Bi and ran into this problem today and I'm not sure how to proceed.

 

So I have 16 stand alone querys with time series data where each query have a timestamp column and a value column. 

Every query belongs to category 1,2,3 or 4 and belongs to a parameter category A,B,C,D.

 

How do I aggregate these monthly so I can view their monthly aggregated values in a matrix? The matrix should look like this and the values should be in the empty spaces.

 

Parameter1234

A

    
B    
C    
D    

 

Hoping for some guidance!

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , Not so clear to me Append and unpivot. or Unpivot and append

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

 

https://radacad.com/pivot-and-unpivot-with-power-bi
Transpose : https://yodalearning.com/tutorials/power-query-helps-transposing-data/

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

@amitchandak Thank you for the advice, it gave me some tips and tricks on how would I approach this problem!
If anyone else stumbels upon my problem, i've left a guide below:


I solved my problem by merging my queries then expanding them in my new query and then I made a new column namned MonthYear which comes from my timestamp column (= year*100 + month) . After that I used group by to aggregate them monthly using MonthYear (here I gave each grouping a name which is a combination of their respective two categories), then i used Unipivot to get a attribute column for each value, Then i split that attribute column so I got two columns so I could get the two categories I wanted. 
And because I use the hourly data for other visuals I created a "translational" table to map the hourly timestamps to the YearMonth table so I get the right data when changing my slicer.

 

amitchandak
Super User
Super User

@Anonymous , Not so clear to me Append and unpivot. or Unpivot and append

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

 

https://radacad.com/pivot-and-unpivot-with-power-bi
Transpose : https://yodalearning.com/tutorials/power-query-helps-transposing-data/

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
August Power BI Update Carousel

Power BI Monthly Update - August 2025

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

August 2025 community update carousel

Fabric Community Update - August 2025

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

Top Solution Authors