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
kp_wood13
Helper I
Helper I

SharePoint CSV - Scheduled Refresh Failing

I've got several Desktop created reports that I've published and setup scheduled refreshes on the datasets. They contain direct SQL queries as well as a query to a CSV file stored on SharePoint Online. Each report that references this CSV errors out on scheduled refresh but I can manually refresh without an issue. I've cleared and re-saved a fresh CSV. I've removed and re-added the query in PBI Desktop. Still get the error every day. Any suggestions? Currently using a service account on SharePoint to grant access.

 

 

{"error":{"code":"DM_GWPipeline_Gateway_MashupDataAccessError","pbi.error":{"code":"DM_GWPipeline_Gateway_MashupDataAccessError","parameters":{},"details":[{"code":"DM_ErrorDetailNameCode_UnderlyingErrorCode","detail":{"type":1,"value":"-2147467259"}},{"code":"DM_ErrorDetailNameCode_UnderlyingErrorMessage","detail":{"type":1,"value":"There weren't enough elements in the enumeration to complete the operation."}},{"code":"DM_ErrorDetailNameCode_UnderlyingHResult","detail":{"type":1,"value":"-2147467259"}},{"code":"Microsoft.Data.Mashup.ValueError.Detail","detail":{"type":1,"value":"#table({\"Content\", \"Name\", \"Extension\", \"Date accessed\", \"Date modified\", \"Date created\", \"Attributes\", \"Folder Path\"}, {})"}},{"code":"Microsoft.Data.Mashup.ValueError.Reason","detail":{"type":1,"value":"Expression.Error"}}],"exceptionCulprit":1}}} Table: Query3

1 ACCEPTED SOLUTION

They should behave the same as scheduled... does anything in this thread help? It's the same error code: https://community.fabric.microsoft.com/t5/Desktop/Expression-Error-There-weren-t-enough-elements-in-...

View solution in original post

5 REPLIES 5
christinepayton
Super User
Super User

Does the service account have access to the the site that the file is in? It needs read access at the site level, not just to the file. It looks like a permission issue to me (it can't find the thing it's looking for because it doesn't have access to it). 

I've confirmed it is a contributor on the site with ready/write access. As I mentioned, when I click the refresh icon in my datasets it works fine, it's only the scheduled refresh that fails. There are no other actions taking place at that time with other reports either.

There should be no difference between the scheduled refresh and the web service refresh. Desktop could be different if it's using different credentials there. You do need to enter the credentials in the datasource settings in the web app after publishing if you haven't done that yet (it's on the scheduling page). 

Yup, I've got the credentials entered, I've tried using my own as well as a service account with full access to the SharePoint site and still having the same issue. When I go into PBI Service I can manually refresh the dataset but the scheduled refreshes fail. I've also realigned all the affected reports to refresh at separate times so they don't step on each other.

They should behave the same as scheduled... does anything in this thread help? It's the same error code: https://community.fabric.microsoft.com/t5/Desktop/Expression-Error-There-weren-t-enough-elements-in-...

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