Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
EithneDangan
Regular Visitor

Date Errors when loading Files from SharePoint folder into Power Query

Hello everyone.

 

I would love some help.  I am using powerquery to load files from a SharePoint folder.  Any files uploaded since March 17th (St. Patricks Day - Luck of the Irish!) are coming in with Errors for Date Created and Date Modified 

 

Error message: - 

DataFormat.Error: We couldn't parse the input provided as a DateTime value.
Details:
3/24/2021 4:00 PM

 

I have trawled through google searches and forums.  Any Help would be gratefully appreciated

e.g.  See screen shot below:

 

SharePoint PowerQuery Date JPG.jpg

 

6 REPLIES 6
wynhopkins
Most Valuable Professional
Most Valuable Professional

This is a bug being investigated by Microsoft

 

@EithneDangan  and I investigated further and changing the SharePoint.Files step to use SharePoint.Contents and drill down to the relevant folder avoided the issue highlighted by @HotChilli with US date formatting

Hope that helps someone else

 

Cheers

 

Wyn

MVP | Author of Power BI for the Excel Analyst | Speaker | Power BI & Excel Developer & Instructor | YouTube- 5 million views | Fan of Power Query & XLOOKUP | Purpose: Making life easier for people through applying and sharing knowledge.
HotChilli
Community Champion
Community Champion

I don't understand your response.

Read my answer again.

Look at what power query did to the first 3 dates. It switched the day and month.  It didn't throw an error because they are still valid dates (even when switched).

This is quite a common issue (especially when importing dates from a transatlantic source)

Thanks HotChilli

I have cleared folder and only have 1 file which I load dated March 27,2021.  File loads, but still getting the issue.  Apparently there was a Windows update.  I have reached out to some MVP's.  GET DATA from SHAREPOINT folder addeding an API 15 parameter at end of M-CODE for source.  It was suggested to remove this, which does remove date ERRORS but doesnt allow load.  I changed the API 15 to 14 and same result.  I have included details hereDate issues forum.jpg

Hi  @EithneDangan ,

 

Pls check whether there are some extra space at the front of your date column,see the similar thread below:

https://community.powerbi.com/t5/Desktop/DataFormat-Error-We-couldn-t-parse-the-input-provided-as-a/...

Or refer below can help:

https://community.powerbi.com/t5/Desktop/We-couldn-t-parse-the-input-provided-as-a-DateTime-value/td...

 

Best Regards,
Kelly

Did I answer your question? Mark my post as a solution!

HotChilli
Community Champion
Community Champion

It looks like a region settings/date format problem.  The date is being interpreted in the opposite format to the one you want (US or UK). 17 is bigger than 12 which would be a valid month so it throws the error.

So that's where you should start the investigation.

Thank you very much your response.  I appreciate every idea.  I had tried that.  All the files in the SharePoint folder are in the exact same date format.  When I navigate to the Sharepoint file directly from within Excel it shows all the files in identical format.  However when I load them file Get Data/From SharePoint Folder the first 3 in the list below load with Date Errors.  

 

 

FIles with Dates.png

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

60 days of Data Days Carousel

Data Days 2026

Join Fabric Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.