Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-13508

ALTER TABLE that renames columns and CHECK constraints

    XMLWordPrintable

Details

    Description

      If a column is renamed, CHECK constraint isn't changed to use the new column name. But UNIQUE constraint is.

      create table t1 (a int, b int, check(a>b));
      alter table t1 change column a b int, change column b a int;
      show create table t1;
      

      Compare with

      create table t1 (a int, b int, unique(a,b));
      alter table t1 change column a b int, change column b a int;
      show create table t1;
      

      Attachments

        Issue Links

          Activity

            People

              monty Michael Widenius
              serg Sergei Golubchik
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved:

                Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0d
                  0d
                  Logged:
                  Time Spent - 5h
                  5h

                  Git Integration

                    Error rendering 'com.xiplink.jira.git.jira_git_plugin:git-issue-webpanel'. Please contact your Jira administrators.