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

syscolumn table: results of select with where clause are affected by encoding/collation of the system

    XMLWordPrintable

Details

    • Bug
    • Status: Confirmed (View Workflow)
    • Major
    • Resolution: Unresolved
    • None
    • None
    • None
    • None

    Description

      Selects from calpontsys.syscolumn work incorrectly when system default encoding/collation is not ASCII

      That breaks callastinsertid(''); function, because it relies on selects from calpontsys.syscolumn

      Expected result:
      Request like
      select columnname, nextvalue from calpontsys.syscolumn where schema = 'test' and tablename = 'foo' and autoincrement='y';
      should return only 0 or 1 results, because only one autoincrement column per table is allowed.

      Actual result: (I've managed to reproduce it only on drone's runners hosts)

      MariaDB [test]> select columnname, autoincrement, nextvalue from calpontsys.syscolumn where schema = 'test' and tablename = 'foo' and autoincrement='y';
      ----------------------------------

      columnname autoincrement nextvalue

      ----------------------------------

      col1 n 1
      newcol y 201

      ----------------------------------
      2 rows in set (2.996 sec)

      MariaDB [test]> select columnname, autoincrement, nextvalue from calpontsys.syscolumn where schema = 'test' and tablename = 'foo' and autoincrement='n';
      ----------------------------------

      columnname autoincrement nextvalue

      ----------------------------------

      col1 n 1
      newcol y 201

      ----------------------------------
      2 rows in set (0.020 sec)

      MariaDB [test]> select columnname, autoincrement, nextvalue from calpontsys.syscolumn where schema = 'test' and autoincrement like 'y';
      ----------------------------------

      columnname autoincrement nextvalue

      ----------------------------------

      newcol y 201

      ----------------------------------
      1 row in set (1.216 sec)

      MariaDB [test]> select columnname, autoincrement, nextvalue from calpontsys.syscolumn where schema = 'test' and autoincrement like '%y%';
      ----------------------------------

      columnname autoincrement nextvalue

      ----------------------------------

      newcol y 201

      ----------------------------------
      1 row in set (1.967 sec)

      MariaDB [test]> select columnname, autoincrement, nextvalue from calpontsys.syscolumn where schema = 'test' and autoincrement = '%y%';
      Empty set (0.531 sec)

      MariaDB [test]> select columnname, autoincrement, nextvalue from calpontsys.syscolumn where schema = 'test' and autoincrement like 'y%';
      ----------------------------------

      columnname autoincrement nextvalue

      ----------------------------------

      newcol y 201

      ----------------------------------
      1 row in set (0.004 sec)

      MariaDB [test]> select columnname, autoincrement, nextvalue from calpontsys.syscolumn where schema = 'test' and tablename = 'foo' and autoincrement like 'y';
      ----------------------------------

      columnname autoincrement nextvalue

      ----------------------------------

      newcol y 201

      ----------------------------------
      1 row in set (0.008 sec)

      Attachments

        Issue Links

          Activity

            People

              leonid.fedorov Leonid Fedorov
              abukhalov Aleksei Bukhalov
              Votes:
              0 Vote for this issue
              Watchers:
              1 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.