Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
6 years ago
Solved

Adding data from Sharepoint ends with Error

Hi, I need a help with adding excel files from Sharepoint to PBI. I have sucessfully chosen desired file from a list on the sharepoint but then I am getting transformation error:

An error occurred in the ‘Transform File’ query. Expression.Error: The key didn't match any rows in the table.

Details:

    Key=

        Item=status change

        Kind=Sheet

    Table=[Table]

 

In Advance data editor I have these steps which were automatically created by PBI during load:

let
Source = SharePoint.Files("https://xxx.sharepoint.com/sites/Report/", [ApiVersion = 15]),
#"Filtered Hidden Files1" = Table.SelectRows(Source, each [Attributes]?[Hidden]? <> true),
#"Invoke Custom Function1" = Table.AddColumn(#"Filtered Hidden Files1", "Transform File", each #"Transform File"([Content])),
#"Renamed Columns1" = Table.RenameColumns(#"Invoke Custom Function1", {"Name", "Source.Name"}),
#"Removed Other Columns1" = Table.SelectColumns(#"Renamed Columns1", {"Source.Name", "Transform File"}),
#"Expanded Table Column1" = Table.ExpandTableColumn(#"Removed Other Columns1", "Transform File", Table.ColumnNames(#"Transform File"(#"Sample File")))
in
#"Expanded Table Column1"

 

Please any idea how to fix it?

5 Replies