-
Notifications
You must be signed in to change notification settings - Fork 0
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
KBC-1240 fix casting and nullability in Synapse CTAS queries #85
Conversation
Testy by dopadly cajk, zkusil sem tag v connection https://app.travis-ci.com/github/keboola/connection/jobs/549795525 |
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.
prosim jen dopln ten test, co udela query s ISNULL. A jestli bych te mohl poprosit priste o nejakej commit s realnym fixem a pak commit s tim prehazovanim kodu. Je v tom pak dost prace se vyznat
} else { | ||
// Columns with isnull are not null in CTAS | ||
$colSql = sprintf( | ||
'ISNULL(%s, \'\')', |
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.
pokud jsem to rozmotal spravne, tak tady ta vetev (a duvod celeho PR) neni otestovana v testech (vsechny destination column tam jsou nullable), tak to bych doplnil (nebo me vyved z omylu)
🤦 jo sorry už mě z těch Synapse usecases docela hrabe. Přidal sem testy. |
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.
haha, prej pridam testy... -> 55 zmen. Ale jsou to vesmes jen renamy a pak hlavni test (opet asi pripomenu to, ze rozdeleni commitu by pomohlo). Ale cajk :)
JIRA: https://keboola.atlassian.net/browse/KBC-2240
This PR is fixing issue when resulting table from CTAS had different nullability. When coalesce is used in CTAS Synapse will set column to nullable no matter what is set in source, if column is not null there has to be ISNULL used.