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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
jaryszek
Memorable Member
Memorable Member

How to get multiple CSV files from Blob storage using power query?

Hi,

I have 3 different csv files and do not want to go and filter each binary file like here in this link (it requires to creare 3 seperate queries): 
Solved: How to transform multiple CSV files from Blob stor... - Microsoft Fabric Community

I want to get just all tables automatically (in dynamic way) based on file names in blob storage as seperated queries. 
It is possible?

Best,
Jacek

1 ACCEPTED SOLUTION
PwerQueryKees
Super User
Super User

Starting here:

PwerQueryKees_0-1736975907372.png

Add a column with

Table.AddColumn(Source, "Custom", each Csv.Document([Content],[Delimiter=",", Columns=8, Encoding=65001, QuoteStyle=QuoteStyle.None]))

Produces this:

PwerQueryKees_1-1736976000594.png

Keep/Remove any columns you want. I chose to only keep the original file name:

= Table.SelectColumns(#"Added Custom",{"Name", "Custom"})

PwerQueryKees_2-1736976112664.png

Now press the little icon:

PwerQueryKees_3-1736976256064.png

Select all the fields you want:

PwerQueryKees_5-1736976409104.png

To produce this:

PwerQueryKees_6-1736976543189.png

 

Now this is the simplest case. As you can see the column headings are repeated.

You can fix this by changing the "Table.Addcolumn".

For example like this:

= Table.AddColumn(Source, "Custom", each 
     let 
        csv = Csv.Document([Content],[Delimiter=",", Columns=8, Encoding=65001, QuoteStyle=QuoteStyle.None]),
        csv_with_headers =  Table.PromoteHeaders(csv, [PromoteAllScalars=true])
     in csv_with_headers)

You will have to change the Expand columns step and you get this:

PwerQueryKees_7-1736977123253.png

 

Did I answer your question? Then please mark my post as the solution and make it easier to find for others having a similar problem.
If I helped you, please click on the Thumbs Up to give Kudos.

 

Kees Stolker

A big fan of Power Query and Excel

View solution in original post

2 REPLIES 2
PwerQueryKees
Super User
Super User

Starting here:

PwerQueryKees_0-1736975907372.png

Add a column with

Table.AddColumn(Source, "Custom", each Csv.Document([Content],[Delimiter=",", Columns=8, Encoding=65001, QuoteStyle=QuoteStyle.None]))

Produces this:

PwerQueryKees_1-1736976000594.png

Keep/Remove any columns you want. I chose to only keep the original file name:

= Table.SelectColumns(#"Added Custom",{"Name", "Custom"})

PwerQueryKees_2-1736976112664.png

Now press the little icon:

PwerQueryKees_3-1736976256064.png

Select all the fields you want:

PwerQueryKees_5-1736976409104.png

To produce this:

PwerQueryKees_6-1736976543189.png

 

Now this is the simplest case. As you can see the column headings are repeated.

You can fix this by changing the "Table.Addcolumn".

For example like this:

= Table.AddColumn(Source, "Custom", each 
     let 
        csv = Csv.Document([Content],[Delimiter=",", Columns=8, Encoding=65001, QuoteStyle=QuoteStyle.None]),
        csv_with_headers =  Table.PromoteHeaders(csv, [PromoteAllScalars=true])
     in csv_with_headers)

You will have to change the Expand columns step and you get this:

PwerQueryKees_7-1736977123253.png

 

Did I answer your question? Then please mark my post as the solution and make it easier to find for others having a similar problem.
If I helped you, please click on the Thumbs Up to give Kudos.

 

Kees Stolker

A big fan of Power Query and Excel

Thank you @Kees Stolker, Great answer!

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Kudoed Authors