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
importccl: fix MYSQLOUTFILE edge cases #26275
Conversation
opts roachpb.MySQLOutfileOptions | ||
conv rowConverter | ||
opts roachpb.MySQLOutfileOptions | ||
debugRow func(tree.Datums) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
is this used?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
was during debugging. removed.
} | ||
for query, res := range tc.query { | ||
sqlDB.CheckQueryResults(t, query, res) | ||
} | ||
}) | ||
} | ||
|
||
t.Run("mysqlout multpile", func(t *testing.T) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nit: multiple
Previously, the MYSQLOUTFILE file reader would convert its data to CSV and use the CSV workers to convert it to datums. This worked for most data, but was not able to correctly handle all NULL encodings. To fix this, decouple MYSQLOUTFILE from CSV so that it can parse datums in its own way and thus handle NULLs correctly. This does lose parallelization, but we can come up with ways to do that in the future. As a side effect, this fixes the listed bug, which occurred because the csvRecord field wasn't being correctly initialized since readFile was shadowing the CSV readFile. Fixes #26153 Release note (bug fix): correct NULL handling during IMPORT of MYSQLOUTFILE.
bors r+ |
Build succeeded |
No description provided.