-
Notifications
You must be signed in to change notification settings - Fork 50
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
error with white spaces & other wrong characters in column names #14
Comments
Hi,
It's easy enough to make |
I also tried to upload using the web interface in the BigQuery Console, with the "auto detect" checkbox selected, and I get the same error:
|
You're right. I mistake with csv. |
I suspect that they will just tell you to pre-process your JSON file to modify your invalid column names. The code to do that is fairly straightforward. For example, save the following as
convert.py:
|
Hi Iuiu, |
Closing with no activity for 4 months. Let me know if you have further questions. |
When the schema is created, column names with spaces are writen as they are.
Therefore, when uploading to bq generates the following error
<BigQuery error in load operation: Invalid field name "utm_medium-partners". Fields must contain only letters, numbers, and underscores, start with a letter or underscore, and be at most 128 characters long.>
Would be posible to substitute blank spaces and other wrong characters with '_' as the '--autodetect' option does?
For example:
'Column.example 1' is written as 'Column_example_1'
The text was updated successfully, but these errors were encountered: