You import a CSV file into Power Query. After automatic type detection, the OrderDate column displays the value Error for many rows and dataset refresh fails with the message: DataFormat.Error: We couldn't parse the value "31/12/2024" as type Date. The file stores dates in the dd/MM/yyyy format, but the computer's regional settings are en-US. Which action in Power Query resolves the import error while keeping OrderDate as a Date column?
Change the OrderDate column type by selecting Use locale, choose Date as the data type, and select a locale that uses the dd/MM/yyyy pattern such as English (United Kingdom).
Change the OrderDate column type to Text so the values are not parsed as dates.
Rename the OrderDate column before the Changed Type step to prevent schema conflicts.
Use Replace Errors to change all Error values in OrderDate to null.
The errors occur because Power Query tried to interpret the text 31/12/2024 by using the en-US culture (MM/dd/yyyy). Changing the column type again with the Using locale option forces the engine to parse the text by using the culture that matches the source data (for example, English (United Kingdom)). When the correct locale is supplied, the values are converted successfully to the Date type and the refresh error disappears. Converting the column to Text avoids the error but loses the required Date type. Replacing errors with null masks the problem and still discards valid values. Renaming the column has no influence on how the underlying text is converted, so it does not fix the DataFormat.Error.
Ask Bash
Bash is our AI bot, trained to help you pass your exam. AI Generated Content may display inaccurate information, always double-check anything important.
What does 'Use locale' in Power Query do?
Open an interactive chat with Bash
What happens if the wrong locale is selected in Power Query?
Open an interactive chat with Bash
How does Power Query's automatic type detection work?
Open an interactive chat with Bash
Microsoft Power BI Data Analyst
Prepare the data
Your Score:
Report Issue
Bash, the Crucial Exams Chat Bot
AI Bot
Loading...
Loading...
Loading...
Pass with Confidence.
IT & Cybersecurity Package
You have hit the limits of our free tier, become a Premium Member today for unlimited access.
Military, Healthcare worker, Gov. employee or Teacher? See if you qualify for a Community Discount.
Monthly
$19.99
$19.99/mo
Billed monthly, Cancel any time.
3 Month Pass
$44.99
$14.99/mo
One time purchase of $44.99, Does not auto-renew.
MOST POPULAR
Annual Pass
$119.99
$9.99/mo
One time purchase of $119.99, Does not auto-renew.
BEST DEAL
Lifetime Pass
$189.99
One time purchase, Good for life.
What You Get
All IT & Cybersecurity Package plans include the following perks and exams .