Load a Dynamic file from a sharepoint folder
Anusha Muniraju
0
Reputation points
Hi, I have a scenario where we upload the input data file (File name and the sheet name can change) into the SharePoint folder which is then used in PowerBI to pull the data. The power query every time looks for the excel file with the same name, How do I solve this.
let
Source = SharePoint.Files("My sharepoint site url", [ApiVersion = 15]),
#"Filtered Rows" = Table.SelectRows(Source, each ([Folder Path] = "My folder Path that is always constant")),
#"Receipts Recon Master xlsx_MyFolderPAth" = #"Filtered Rows"{[Name="Receipts Recon Master.xlsx",#"Folder Path"=My folder path that is always constant}[Content],
#"Imported Excel Workbook" = Excel.Workbook(#"Receipts Recon Master xlsx_My folder path that is always constant"),
Sheet1_Sheet = #"Imported Excel Workbook"{[0]}[Data]
in
Sheet1_Sheet
Basically, I want the name in this step to be dynamic
#"Receipts Recon Master xlsx_MyFolderPAth" = #"Filtered Rows"{[Name="Receipts Recon Master.xlsx",#"Folder Path"=My folder path that is always constant}[Content],
Windows for business | Windows Server | User experience | PowerShell
Sign in to answer