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

SYSTEM VERSIONING columns not showing as GENERATED

    XMLWordPrintable

Details

    • Bug
    • Status: Closed (View Workflow)
    • Major
    • Resolution: Fixed
    • 10.3.8
    • 10.3.16, 10.4.6
    • Versioned Tables
    • None
    • Server version: 10.3.8-MariaDB-1:10.3.8+maria~stretch-log mariadb.org binary distribution

    Description

      1. Create a table
      2. Add SYSTEM VERSIONING as follows per documentation at https://mariadb.com/kb/en/library/system-versioned-tables/

      ALTER TABLE t ADD COLUMN ts TIMESTAMP(6) GENERATED ALWAYS AS ROW START,
                    ADD COLUMN te TIMESTAMP(6) GENERATED ALWAYS AS ROW END,
                    ADD PERIOD FOR SYSTEM_TIME(ts, te),
                    ADD SYSTEM VERSIONING;
      

      3. Execute a SHOW COLUMNS on table.

      MariaDB [test_database]> show columns from t;
      +-------+--------------+------+-----+---------+----------------+
      | Field | Type         | Null | Key | Default | Extra          |
      +-------+--------------+------+-----+---------+----------------+
      | col1  | bigint(20)   | NO   | PRI | NULL    | auto_increment |
      | ts    | timestamp(6) | NO   |     | NULL    |                |
      | te    | timestamp(6) | NO   | PRI | NULL    |                |
      +-------+--------------+------+-----+---------+----------------+
      

      `ts` and `te` should list GENERATED in the Extra field.

      Attachments

        Issue Links

          Activity

            People

              serg Sergei Golubchik
              darkain Vincent Milum Jr
              Votes:
              0 Vote for this issue
              Watchers:
              4 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.