Uploaded image for project: 'MariaDB ColumnStore'
  1. MariaDB ColumnStore
  2. MCOL-5662

ColumnStore wrongly thinks it doesn't support WAIT and NOWAIT

    XMLWordPrintable

Details

    • Task
    • Status: Open (View Workflow)
    • Major
    • Resolution: Unresolved
    • 23.10.0
    • None
    • None
    • None

    Description

      TL;DR: NOWAIT and WAIT clauses behave as documented with ColumnStore. So, for example, if a table is locked, LOCK 5 will wait up to 5 seconds for the lock to be released. But after that, instead of running the ALTER TABLE as required, ColumnStore returns an error.

      In connection 1, acquire a lock on a table:

      MariaDB [test]> START TRANSACTION;
      Query OK, 0 rows affected (0.000 sec)
       
      MariaDB [test]> INSERT INTO cs2 (a) VALUES (DEFAULT);
      Query OK, 1 row affected (0.092 sec)
      

      In connection 2, try ALTER TABLE NOWAIT and WAIT:

      MariaDB [test]> ALTER TABLE cs2 NOWAIT ADD COLUMN xxx INT;
      ERROR 1205 (HY000): Lock wait timeout exceeded; try restarting transaction
      MariaDB [test]> ALTER TABLE cs2 WAIT 3 ADD COLUMN xxx INT;
      ERROR 1205 (HY000): Lock wait timeout exceeded; try restarting transaction
      

      The second error appeared after 3 seconds. So when there is a lock it works percectly! But let's rollback the transaction, so that the table has no locks, and then try again:

      MariaDB [test]> ALTER TABLE cs2 WAIT 3 ADD COLUMN xxx INT;
      ERROR 1178 (42000): The storage engine for the table doesn't support The syntax or the data type(s) is not supported by Columnstore. Please check the Columnstore syntax guide for supported syntax or data types.
      

      Attachments

        Activity

          People

            Unassigned Unassigned
            f_razzoli Federico Razzoli
            Votes:
            1 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:

              Git Integration

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