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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Error in Date column

new with powerBI,I get data fm excel file n theres an "error" in the date column..how to rectify this issue,any help will do,tks..
2 ACCEPTED SOLUTIONS
Jimmy801
Community Champion
Community Champion

Hello @Anonymous 

 

If in the Excel-file the date-field is formated as date, you should normaly get no errors. In your case this might not be the case. Therefore you need to check the date type (american, english) and not applying a Table.TransformColumnTypes but a Table.TransformColumns instead using a Date.From(_, culture) Function. But without any Query/data I'm not able to help you further.

 

If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too

Have fun

Jimmy

View solution in original post

edhans
Community Champion
Community Champion

You can approach this a few ways:

  1. Fix the dates in your source.
  2. Try converting the "date" to a real date. The Date.From or Date.FromText functions may help, and you can wrap them in a try/otherwise statement. So:

 

try Date.FromText([DateField]) otherwise null

 

That will try to convert the date-looking-thing in the DateField from text to a date. If it works, great. If not it returns null, which isn't an error.

If you need further help, please post sample data as text so we aren't guessing what your "dates" look like or what the errors are.



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting

View solution in original post

3 REPLIES 3
edhans
Community Champion
Community Champion

You can approach this a few ways:

  1. Fix the dates in your source.
  2. Try converting the "date" to a real date. The Date.From or Date.FromText functions may help, and you can wrap them in a try/otherwise statement. So:

 

try Date.FromText([DateField]) otherwise null

 

That will try to convert the date-looking-thing in the DateField from text to a date. If it works, great. If not it returns null, which isn't an error.

If you need further help, please post sample data as text so we aren't guessing what your "dates" look like or what the errors are.



Did I answer your question? Mark my post as a solution!
Did my answers help arrive at a solution? Give it a kudos by clicking the Thumbs Up!

DAX is for Analysis. Power Query is for Data Modeling


Proud to be a Super User!

MCSA: BI Reporting
Jimmy801
Community Champion
Community Champion

Hello @Anonymous 

 

If in the Excel-file the date-field is formated as date, you should normaly get no errors. In your case this might not be the case. Therefore you need to check the date type (american, english) and not applying a Table.TransformColumnTypes but a Table.TransformColumns instead using a Date.From(_, culture) Function. But without any Query/data I'm not able to help you further.

 

If this post helps or solves your problem, please mark it as solution (to help other users find useful content and to acknowledge the work of users that helped you)
Kudoes are nice too

Have fun

Jimmy

Anonymous
Not applicable

tks for the help..greatly appreciated

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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 Solution Authors