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

Inconsistent handling of "ALGORITHM=INPLACE" with PERSISTENT generated columns.

Details

    • 10.0.24

    Description

      It is not possible to add a PERSISTENT virtual column using ALGORITHM=INPLACE but it is possible to drop it (together with an index on it) that way.

      And while the column is present in the table, it is not possible to add/drop any index using ALGORITHM=INPLACE (so if I understand it, "fast index creation" is not available).

      alter ONLINE table ... behaves the same.

      Thanks to danblack for extending the testcase and testing on 10.1.8 http://pastie.org/10517538

      Attachments

        Activity

          I've relaxed the restriction, but didn't remove it completely.

          In 10.0.24

          • one will be able to add or drop indexes inplace even if the table have persistent generated columns
          • one will be able to drop or add columns inplace even if the table have persistent generated columns
          • adding a persistent generated column still cannot be done inplace, because inplace alter is done internally inside the engine, and only the sql layer can evaluate the expression to generate values for the newly added virtual column.
          serg Sergei Golubchik added a comment - I've relaxed the restriction, but didn't remove it completely. In 10.0.24 one will be able to add or drop indexes inplace even if the table have persistent generated columns one will be able to drop or add columns inplace even if the table have persistent generated columns adding a persistent generated column still cannot be done inplace, because inplace alter is done internally inside the engine, and only the sql layer can evaluate the expression to generate values for the newly added virtual column.

          People

            serg Sergei Golubchik
            jkavalik Jiri Kavalik
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Git Integration

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