You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Changes to SqlToS3Operator Breaking CSV formats #26567
Once #25083 was merged, when using CSV as the output format on the SqlToS3Operator, null strings started appearing as "None" in the actual CSV export. This will cause unintended behavior in most use cases for reading the CSV including uploading to databases.
Certain databases such as Snowflake allow for things like NULL_IF on import however there are times where you would want the actual string "None" to be in the field and there would be no way at that point to distinguish.
Before:
After:
What you think should happen instead
The strings should be empty as they did previously. I understand the implementation of the recent PR for parquet and propose that we add an additional condition to line 138 of the sql_to_s3.py file restricting that to only if the chosen output is parquet.
How to reproduce
Run the SqlToS3Operator with the default output format of CSV on any query that selects a column of type string that allows null. Look the outputted CSV in S3.
Anything else
Every time we select a nullable column with the SqlToS3Operator
Activity
josh-fell commentedon Sep 21, 2022
Feel free to open a PR!