Forum Discussion
DataFormat.Error: We couldn't parse the input provided as a DateTime value.
- 9 years ago
After playing with your text file for 15 mins, I have found that there are some extra space at the front of your date column. Can you please remove those extra characters.
Steps to follow afterwards:
1. Split the column by 11 characters. This will separate Date and Time
2. Split the Date column by "/" Delimiter
3. Change the data type of the newly created columns to Whole number
4. Bring the Day column first by dragging, Month column second and Year column last
5. Select all these three collumns and go to Add column Tab, Select Merge Columns and in Merge dialog, Select "/"Separator.
6. Change the data type of the merged column to Date.
So many steps .....
Steps to be followed to resolve the Date Format Error :
1. When a CSV file is loaded in Power BI Desktop by default it detects the 'date/time' field as 'text' so when we try to convert we get an error.
2. Next Right click on the Field/Column you want to convert into a Date Field and navigate to 'Change Type' .
3. Next Click on 'Using Locale' option under the 'Change Type' dropdown.
4. Change the 'Data type' to 'Date' in the dialog box of 'Using Locale' as by default it takes it as 'text'.
5. Click on the drop down of 'locale'.
6. Then Select an 'Option' from drop down for which your Date field 'Format' matches exactly and Click on 'OK' .
7. Above steps will resolve the issue and same solution goes well for Date/Time column conversion also.
- mch6 years agoNew Member
RaviTeja_M your hint solved my issue, thak you!
- Anonymous5 years agoNot applicable
Superb! Works perfectly
- Anonymous4 years agoNot applicable
this solution worked for me, thanks a lot for sharing your knowledge
- Pala4 years agoNew Member
Thank you! This solution worked for me 😀
- AbbasG3 years agoMemorable Member
RaviTeja_M this helped me solve the problem thank you.
- Rushikesh_20223 years agoFrequent Visitor
These steps were really helpful. thanks
- Anonymous3 years agoNot applicable
Thank you!
- PatChan1 year agoHelper I
This is awesome detailed solution!