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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
jacksonlam
New Member

undefined

I have a excel worksheet with several excel tables and new tables will be added from time to time. Is it possible to configure Power BI query to automatically detect and connect to new tables as data source?

4 REPLIES 4
Jimmy801
Community Champion
Community Champion

Hello @jacksonlam 

 

yes, you can. Use the function Excel.Workbook(File.Contents(yourfilename),null, true) to create a table with your Excelobjects. Apply a filter if needed on this table. Apply a function to the table if you would like to transform the data or use Table.ExpandTableColumn to extract your data.

 

If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too

Have fun

Jimmy

edhans
Community Champion
Community Champion

How would you get those new tables to automatically expand to new queries though @Jimmy801 - I would assume the tables would not be the same format, otherwise, they would just be additional rows in existing tables.



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
Jimmy801
Community Champion
Community Champion

Hello @edhans 

 

for sure they have to have the same format, or at least following the same logic to extract the data. I had one time a case were they maintained assetts in one big excel-file, and whenever a assett was created from a template and by adding a new sheet, this new data needed to be integrated in a power-pivot database. 

 

BR

 

Jimmy

Greg_Deckler
Community Champion
Community Champion

@jacksonlam - That's a tall order. I am going to say no but I'm more than willing to be proven wrong by someone, perhaps @ImkeF or @edhans . Here is a similar thread:

https://community.powerbi.com/t5/Desktop/Dynamically-generate-query-tables/td-p/20519

 

I don't see a solution there.



Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.