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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
y2gabs
Frequent Visitor

Grouping data from 3 tables, based on a date field in each, in a matrix with fiscal quarters as rows

Sorry if I've improperly labelled my question here but hoping someone can help.  I'm using directquery datasource to sql database with 3 tables each with a date column.  i've already created a new column in each that groups rows based on fiscal quarter using CONCATENATE("Q",ROUNDUP(month('table'[datefield])/3,0))

 

So basically I'm able to create a matrix for each table that summarizes financial data (in the same table) in to fiscal quarters.  

 

Now what I'm trying to do is create a single matrix for all 3 tables where financial data from each table will be summarized in a column in the matrix for the coresponding fiscal quarterly row.

 

Hopefully I'm making sense here.

 

Any help from the pros is greatly apprciated. 

 

Thanks! 

2 REPLIES 2
v-piga-msft
Resident Rockstar
Resident Rockstar

Hi @y2gabs,

 

Have you solved your problem by the solution provided by @MarcoRotta?

 

If you have solved, please always accept the replies making sense as solution to your question so that people who may have the same question can get the solution directly.

 

If you need additonal help, please feel free to ask.

 

Best Regards,

Cherry

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

That's a classic data model challenge.

 

The best approach here, in my opinion, would be to adopt a calender table, where you'd have all the dates and could create the corresponding quarters, etc. A very nice one is provided free or charge by Avi Singh here.

 

If you don't want to go that far (despite my strong recommendation), you could (1) combine all your three tables in a single one, (2) remove all the other columns and leave only the date column, (3) remove the duplicates for the date column and (4) then create calculated columns such as quarters based on that single "date table". You can do all that easily in the Query Editor (no manual coding required).

 

The final result would be a table that contains all your existing dates from the 3 data tables. To finish, just assign relationships to your original 3 tables based on the date, and then use the quarters from this new date table in your visuals.

 

I hope my writing could be clear enough for you to understand what I mean. This is certainly easier shown than said. 🙂


Regards.

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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