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

Compete to become Power BI Data Viz World Champion! First round ends August 18th. Get started.

Reply
Anonymous
Not applicable

Load data from selected folder

I have several folder by names of t25_jan2021,  t25_feb2021 ..so on.

So a folder for every month .And each folder has same 10 csv files but data may be different .

Some file names are just names like profitgenerated, EBITA etc.

Some files will have date with them like taxpaid_20210112101317 

 

I want that user when he clicks on a button within dashboard , he should get the option to select which folder he wants to 

load the data.And when user selects different folder, the report in power bi should show the data for which the folder was selected.

 

Please let me know if we can do this in power bi , if yes then how?

 

2 REPLIES 2
Anonymous
Not applicable

Hi @Anonymous,

Currently, you can't use 'data view' filters to affect the backend query tables. They are working on different levels. (data model tables are generated from query tables, you can't use child level to affect its parent)

Did these folder files have the same data structures? If that is the case, you can create a query parameter to parameterize the 'folder path' in your data connector. Then you can edit the query parameter in the data view to change underlying data sources.

Notice: the data level of power bi.

Database(external) -> query table(query, custom function, query parameters) -> data model table(table, calculate column/table) -> data view with virtual tables(measure, visual, filter, slicer)

Parameters - Power Query | Microsoft Docs

Deep Dive into Query Parameters and Power BI Templates | Microsoft Power BI Blog | Microsoft Power BI

Regards,

Xiaoxin Sheng

lbendlin
Super User
Super User

Users cannot choose which data to load. They can only filter data that is already loaded. 

So you as the developer can write a Power Query script that loads all files from all folders, and you can make that Power Query script dynamic, regardless of folder name or file name.   Of course assuming that all files have the same format, or at the very least make sense when appended all together into one large table. (That table would then also have columns for folder name and file name so you know where each row comes from, and so your users can filter as you intended.

Helpful resources

Announcements
July 2025 community update carousel

Fabric Community Update - July 2025

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

July PBI25 Carousel

Power BI Monthly Update - July 2025

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