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

Get inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.

Reply
user_95
Frequent Visitor

Optimizing Power BI report model with multiple tables pulled from different schemas

Hello all,

I have a new report requirement that requires pulling in multiple database tables with similar structure, but from different schemas. The data is for different customers and each of them have their own schema along with their specific tables. The requirement here is to create a consolidated report that shows data for all customers.

I need to pull around 3 tables with similar structure from each customer schema into a single report. We have around 10 customers and that would mean around 30 tables in total that would need to be pulled into Power BI and this count would most probably increase over time. This could make the PBI data model quite messy. Each of the tables might have around 25-50K records. The database is Azure SQL server.

 

Please let me know if you have any suggestions to optimize this model or a better way to fetch all this data into a single report.

 

Customer 1 - Table A, Table and Table C 

Customer 2 - Table A, Table and Table C

Customer 3 - Table A, Table and Table C and so on

1 ACCEPTED SOLUTION
MFelix
Super User
Super User

Hi @user_95 ,

 

Since the tables have similar configuration I suggest that you make an append of the tables into a single query that way you have consistency among the data and just need to get an additional column to get the customer name on each line.

 

The fact that tables have 50K records should not be an issue.

 

You can do this making the query for all the tables and then disabling them and do a single query with the append, or do it in a single query making the join trough different steps or a SQL code to union them.

 

Be aware that when I say a single table it may mean 4/5 tables but each one of those combining the similar tables of Azure for each customer into a single one.

 

So if you have a product table for each customer you combine it in a single table etc.

 

The only thing you need to be carefull is to have composite keys for any common dimensions that you may have that combine the customer key and the table key column that will give you a unique value that you can then use to make a star schema.


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



View solution in original post

1 REPLY 1
MFelix
Super User
Super User

Hi @user_95 ,

 

Since the tables have similar configuration I suggest that you make an append of the tables into a single query that way you have consistency among the data and just need to get an additional column to get the customer name on each line.

 

The fact that tables have 50K records should not be an issue.

 

You can do this making the query for all the tables and then disabling them and do a single query with the append, or do it in a single query making the join trough different steps or a SQL code to union them.

 

Be aware that when I say a single table it may mean 4/5 tables but each one of those combining the similar tables of Azure for each customer into a single one.

 

So if you have a product table for each customer you combine it in a single table etc.

 

The only thing you need to be carefull is to have composite keys for any common dimensions that you may have that combine the customer key and the table key column that will give you a unique value that you can then use to make a star schema.


Regards

Miguel Félix


Did I answer your question? Mark my post as a solution!

Proud to be a Super User!

Check out my blog: Power BI em Português



Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

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

March2025 Carousel

Fabric Community Update - March 2025

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

Top Kudoed Authors