Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.
Hi,
I am using a from folder query to identify folder names to be used as a source from a parameter.
However, when the .pbix is refreshed, the new folders added to the location are not shown in the parameter?
I am not sure why it is not using the source query when it seems to be refreshed.
I am using folders in C:/Temp, and every time I add a folder, it appears in the data in the table, but not in the parameter as a choice.
Power BI File link:
Filename Size URL Expires at
forumfile.pbix |
19.70 KB |
https://tmpfiles.org/dl/3324034/forumfile.pbix |
2023-12-08 05:43 UTC |
Any help appreciated.
let
Source = Folder.Files("C:\Temp"),
#"Removed Other Columns" = Table.SelectColumns(Source,{"Folder Path"}),
#"Split Column by Delimiter" = Table.SplitColumn(#"Removed Other Columns", "Folder Path", Splitter.SplitTextByDelimiter("\", QuoteStyle.Csv), {"Folder Path.1", "Folder Path.2", "Folder Path.3", "Folder Path.4"}),
#"Removed Other Columns1" = Table.SelectColumns(#"Split Column by Delimiter",{"Folder Path.3"}),
#"Renamed Columns" = Table.RenameColumns(#"Removed Other Columns1",{{"Folder Path.3", "Folder Name"}}),
#"Folder Name" = #"Renamed Columns"[Folder Name]
in
#"Folder Name"
The main input comes from the solution provided by Patrick LeBlanc in the following youtube video: https://www.youtube.com/watch?v=Z0U9UL9ORh8 .
You need use a parameter and make the first script into a function. The first parameter inout for the trial script should be the text you need to pull in the first data: Folder1
When you've created the function you need a table to which you can add a column. Whereby there's a column value that you can use as a parameter. Reading your question you could use the data your already loading, because the file names are included in that data.
You could then use the column with the Folder as the parameter input. To do this add a new function column
Let's name this column input. You can then add a new function column. (Example in dutch)
It will ask for an input column.Just chose the just created column we called input. This will add a table for every row. The last step would be to click expand. This should get you a table with all your data.
Patrick LeBlanc explains this using NFL data. I already used this solution multiple times for reading data from maps.
Hope this helps
Thanks for this, however it didn't work or wasn't quite the solution for my issue.
My problem is demonstrated in this video I prepared.
Video showing the exact issue: https://www.youtube.com/watch?v=c-HOeucry3s
Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!
Check out the September 2025 Power BI update to learn about new features.