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
Now that we can mix and match DML and DDL statements, we're running into issues where the SQL review fails for valid statements. Consider the following SQL migration:
ALTER TABLE "time_schedule" ADD "oauthClientName" character varying;
UPDATE "time_schedule" SET "oauthClientName" = 'incident.io' WHERE "oauthClientId" IS NOT NULL;
We do get an error for the second statement:
Validate the executability of DML statements #208
"UPDATE "time_schedule" SET "oauthClientName" = 'incident.io' WHERE "oauthClientId" IS NOT NULL;" dry runs failed: ERROR: column "oauthClientName" of relation "time_schedule" does not exist (SQLSTATE 42703)
The statement is run in isolation when in fact any preceding DDL statements should also be run first.
Steps to reproduce
Create an issue in Bytebase that modifies the database schema and then uses the modified schema to update data.
Expected behavior
No errors should be reported by the SQL check
Provide the database you are using
Postgres
Provide the version control system you are using
Github
Additional context
No response
The text was updated successfully, but these errors were encountered:
Provide the Bytebase version you are using
2.14.1
Describe the bug
Now that we can mix and match DML and DDL statements, we're running into issues where the SQL review fails for valid statements. Consider the following SQL migration:
We do get an error for the second statement:
The statement is run in isolation when in fact any preceding DDL statements should also be run first.
Steps to reproduce
Create an issue in Bytebase that modifies the database schema and then uses the modified schema to update data.
Expected behavior
No errors should be reported by the SQL check
Provide the database you are using
Postgres
Provide the version control system you are using
Github
Additional context
No response
The text was updated successfully, but these errors were encountered: