Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.
Hi guys,
you can change the source in the Power Query from an Excel file to an Azure Blob storage. The structure remains exactly the same - only the source changes?
thanks in advance
greetings lukas
Solved! Go to Solution.
Hi @Anonymous - you didn't say how you were connecting to the Excel file - local drive, SharePoint, etc. However, the change is pretty straight forward.
If you open the advanced editor of your Excel queries you might see something like this:
let
Source = Excel.Workbook(File.Contents("C:\Users\username\OneDrive\Purchasing Wait List.xlsx"), null, true),
OldBookList_Table = Source{[Item="OldBookList",Kind="Table"]}[Data],
#"Changed Type" = Table.TransformColumnTypes(OldBookList_Table,{{"Date", type date}, {"Title", type text}, {"Author", type text}, {"Category", type text}, {"Priority", Int64.Type}, {"Comments", type text}, {"Date Started", type any}})
in
#"Changed Type"
What you need to do is connect to the Azure Storage Blob the way you normally would, then get the query editor down to the same place as where I have the #"Changed Type" step, as that is where the real work begins.
Then, you copy those first 2-3 Azure Storage lines in the advanced editor and replace the first 2/3 lines of your Excel queries. A few notes:
See the instructions below too as they can walk you through the process.
See this article if you need help using this M code in your model.
If you need specific help, do the following:
I or someone else can assist in merging the code.
DAX is for Analysis. Power Query is for Data Modeling
Proud to be a Super User!
MCSA: BI ReportingHi @Anonymous - you didn't say how you were connecting to the Excel file - local drive, SharePoint, etc. However, the change is pretty straight forward.
If you open the advanced editor of your Excel queries you might see something like this:
let
Source = Excel.Workbook(File.Contents("C:\Users\username\OneDrive\Purchasing Wait List.xlsx"), null, true),
OldBookList_Table = Source{[Item="OldBookList",Kind="Table"]}[Data],
#"Changed Type" = Table.TransformColumnTypes(OldBookList_Table,{{"Date", type date}, {"Title", type text}, {"Author", type text}, {"Category", type text}, {"Priority", Int64.Type}, {"Comments", type text}, {"Date Started", type any}})
in
#"Changed Type"
What you need to do is connect to the Azure Storage Blob the way you normally would, then get the query editor down to the same place as where I have the #"Changed Type" step, as that is where the real work begins.
Then, you copy those first 2-3 Azure Storage lines in the advanced editor and replace the first 2/3 lines of your Excel queries. A few notes:
See the instructions below too as they can walk you through the process.
See this article if you need help using this M code in your model.
If you need specific help, do the following:
I or someone else can assist in merging the code.
DAX is for Analysis. Power Query is for Data Modeling
Proud to be a Super User!
MCSA: BI ReportingCovering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City
Check out the April 2024 Power BI update to learn about new features.