1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

ADD CONSTRAINT IF NOT EXISTS didn't work in SP

"if not exists" must be stored in a separate read-only property
This commit is contained in:
Sergei Golubchik
2022-11-03 19:17:25 +01:00
parent a5eff044cb
commit cce76fef38
5 changed files with 54 additions and 5 deletions

View File

@ -6928,10 +6928,8 @@ remove_key:
while ((check=it++))
{
if (!(check->flags & VCOL_CHECK_CONSTRAINT_IF_NOT_EXISTS) &&
check->name.length)
if (!check->if_not_exists && check->name.length)
continue;
check->flags= 0;
for (c= share->field_check_constraints;
c < share->table_check_constraints ; c++)
{