This is best Fabric, Power BI, SQL and AI community event. How do we know? The last event sold out! Save €200 with code FABCMTY200.
Register nowThe Fabric community is upgrading! Read all of the details including the timeline and what you can expect. Learn more
When trying to use sharepoint.contents to open a sharepoint folder in power query, we notice that for some users excel files are not recognized when we drill to the folder. But if we change mcode to sharepoint.file the exel files populate correctly. Any reason why sharepoint.contents does not work? We like sharepoint.contents better because it creates a more logical structure in power query. (working with a class of students - for most sharepoint.contents works fine but for a couple the excel files are not recognzied)
Hi @mopetkewi,
Since SharePoint.Files is returning the workbooks correctly, I would avoid changing the downstream Excel logic for now and test the SharePoint.Contents source itself.
One option that may be worth trying is the newer connector implementation:
SharePoint.Contents("https://tenant.sharepoint.com/sites/site", [ApiVersion = 15, Implementation = "2.0"])Microsoft documents both ApiVersion and Implementation = "2.0" as supported options for SharePoint.Contents. The latter switches the call to the newer SharePoint connector implementation.
I would compare this on one machine where the files appear and one where they do not. If the same site URL and credentials are being used but the result differs between students, I would also clear the SharePoint data source permissions in Power Query and reconnect with the same Organizational Account before testing again.
Since SharePoint.Files already sees the files, this looks more like an enumeration/navigation issue with SharePoint.Contents than an issue with the Excel files themselves.
Hi @mopetkewi,
Thank you for reaching out to Microsoft Fabric Community.
Since the affected users can access the same SharePoint site and SharePoint.Files() returns the excel files successfully, this does not look like a general permissions issue. SharePoint.Files() and SharePoint.Contents() retrieve the share point content differently, so try using SharePoint.Contents() with ApiVersion = 15.
If the issue persists, consider using SharePoint.Files() instead, as it correctly returns the Excel files for the affected users.
Thanks and regards,
Anjan Kumar Chippa
Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.
| User | Count |
|---|---|
| 3 | |
| 3 | |
| 3 | |
| 2 | |
| 2 |