Skip to content
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

Dolt does not allow the dropping of a column with check constraint #3147

Open
VinaiRachakonda opened this issue Apr 4, 2022 · 0 comments
Open
Labels
bug good first issue

Comments

@VinaiRachakonda
Copy link
Contributor

@VinaiRachakonda VinaiRachakonda commented Apr 4, 2022

Consider the following table

create table mytable (pk int primary key);
ALTER TABLE mytable ADD COLUMN col2 text NOT NULL;
ALTER TABLE mytable ADD CONSTRAINT constraint_check CHECK (col2 LIKE '%myregex%');
 ALTER TABLE mytable DROP COLUMN col2;

Dolt throws the error : can't alter column "col2" because it would invalidate check constraint "constraint_check"

MySQL allows this behavior

@VinaiRachakonda VinaiRachakonda added bug good first issue labels Apr 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug good first issue
Projects
None yet
Development

No branches or pull requests

1 participant