CSV File Numbers/Amounts Appear in Destination As STRING or VARCHAR
Issue
A CSV file contains decimal numbers that are comma-separated. These appear in the destination as a STRING
or VARCHAR
data type.
Environment
File connectors
Resolution
To resolve this issue, follow the steps below:
- Set the decimal separator as a comma by either:
- Finding and replacing commas in your CSV.
- Changing the decimal separator regional configuration language or locale so that a decimal point is used instead.
- Create a new connector for the new CSV file with the decimal separator.
NOTE: For the old connector, the data type will not narrow down from
STRING
toFLOAT
once it has already been created in destination.
Cause
The columns are being synced as strings because the decimal separator needs to be a decimal point, instead of a comma.