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

Enhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.

Reply
phantomias33
Regular Visitor

Question about how a Source is identified in Power Query

I currently have a dashboard that utilizes 5 different Excel sheets, all share a common root folder (some nested in subfolders).  As of now, the report works great and is published on the corporate enterprise network.  IT set up an SVC.PowerBI account with rights to the common root folder of all the sources. My issue is that apparently in order to setup a scheduled refresh of the semantic model on the workspace (and save IT from setting up individual connections to each source), I need to modify my source settings within Power Query from:

 

Source = Excel.Workbook(File.Contents("\\network path to folder"), nuyll, true),

to:

Source = Folder.Files("\\network path to folder")

 

I've started modifying the "Source =" setting by copying and pasting the "Source = Folder.Files" pathway when selecting Source in the Applied Steps section of Power Query.  I then take the following steps within Power Query:

  • Identify the file for that particular query
  • Click on the 'Combine Files' icon
  • When asked if I want to insert a step, I confirm yes
  • Identify the relevant sheet within that Excel file
  • Click Ok

I then go through the process of troubleshooting any subsequent errors in the applied steps, including newly formed duplicated steps.  

 

However, this process produces a plethora of 'Helper Queries' and I have to think I'm going about this the wrong way.  I'm not sure if I'm making any sense but I guess the essence of my question is:

 

How do I change a currently functioning dashboard from using:

Source = Excel.Workbook(File.Contents("\\network path to folder"), nuyll, true),

to:

Source = Folder.Files("\\network path to folder")

 

Any help or pointers would be greatly appreciated.

1 ACCEPTED SOLUTION
lbendlin
Super User
Super User

Click on the 'Combine Files' icon

Yeah, don't do that.  That feature is for beginners.  What you can do is study how it works, then delete that group and create your own process.

 

1. Connect to folder

2. Filter for the files you want

3. pick one file (any file) and transform it into the raw table

4. Inspect the M code and convert it into a function

5. Delete the steps from 3.

6. Add a custom column that calls the function you created in 4.

7. Expand the table column

8. Apply the rest of the transforms (like changing column types)

View solution in original post

2 REPLIES 2
lbendlin
Super User
Super User

Click on the 'Combine Files' icon

Yeah, don't do that.  That feature is for beginners.  What you can do is study how it works, then delete that group and create your own process.

 

1. Connect to folder

2. Filter for the files you want

3. pick one file (any file) and transform it into the raw table

4. Inspect the M code and convert it into a function

5. Delete the steps from 3.

6. Add a custom column that calls the function you created in 4.

7. Expand the table column

8. Apply the rest of the transforms (like changing column types)

lbendlin-

 

Thank you!  I'm not sure I've graduated past beginner status but you've definitely given me some new avenues to chase.  (New-ish to DAX but not coding so I'll dive in) 

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
Top Kudoed Authors