Forum Discussion
Locale settings should not affect CSV import
- 4 years ago
The output of the M code should not be affected by application's settings.
I disagree. The application settings govern how the input is interpreted. Under different interpretations, identical data means different things and the output should reflect proper meaning. Since a CSV file doesn't contain reliable locale metadata, there isn't a straightforward way for Power Query to magically know what interpretation you expect it to use unless you specify it in the code or in the application settings.
As far as I know, the CSV file does not include locale information. And I'm not sure how PQ would be able to infer that from CSV contents. However, you can tell PQ the locale of the incoming csv file in the third argument of the "Table.TransformColumnDataTypes" function. With that information, it can do the proper transformations.