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
GstrandAK
New Member

M Syntax for Importing multiple tables from single DB

Our org. requested that we limit the use of our data models for performance/resource management. I can create one Power BI data model through the desktop, and use separate SQL queries to import the tables.  The tables are unrelated, so append/merge not an option.  However, I fear that each SQL call to the same DB might be the same as having multiple data models with the single table query? 

 

I am a novice Power BI user and have never written M statements.   Is there a way to write a M query that could import all the tables?  Ideally, the Power BI table names would be the same as the SQL DB names.  

1 ACCEPTED SOLUTION
edhans
Super User
Super User

You won't really be saving much. You'd just have a TON of calls in one model vs a few calls in many models.

 

There are ways to optimize by publishing certified data sets, or using Data Flows to sync and then using those as the basis for your Power BI models. The latter might be the best, but you'd need someone to set up the right type of data flows to ensure all relevant data is published for use. Then you could have those refresh 2-3 times a day, or less if not needed more often. Then it wouldn't matter if a thousand Power BI models hit the Data Flows 7-8 times a day. Your internal server wouldn't be impacted by that.



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

View solution in original post

1 REPLY 1
edhans
Super User
Super User

You won't really be saving much. You'd just have a TON of calls in one model vs a few calls in many models.

 

There are ways to optimize by publishing certified data sets, or using Data Flows to sync and then using those as the basis for your Power BI models. The latter might be the best, but you'd need someone to set up the right type of data flows to ensure all relevant data is published for use. Then you could have those refresh 2-3 times a day, or less if not needed more often. Then it wouldn't matter if a thousand Power BI models hit the Data Flows 7-8 times a day. Your internal server wouldn't be impacted by that.



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

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.

Top Solution Authors
Top Kudoed Authors