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

mariadb-dump fails with illegal mix of collations

    XMLWordPrintable

Details

    Description

      CREATE TABLE t (f DATE, vcol BOOLEAN AS (MONTHNAME(f) = 'February') VIRTUAL) CHARSET=utf8mb4 COLLATE=utf8mb4_spanish2_ci;
      --exec $MYSQL_DUMP -uroot --port=$MASTER_MYPORT test
       
      DROP TABLE t;
      

      10.6 008145b968518f1ccf22558ee15fbc146f1b204b

      CURRENT_TEST: bug.collations1
      mariadb-dump: Couldn't execute 'show create table `t`': Illegal mix of collations (utf8mb4_general_ci,COERCIBLE) and (utf8mb4_spanish2_ci,COERCIBLE) for operation '=' (1267)
      mysqltest: At line 2: exec of '/share8t/bld/10.6-rel/client//mariadb-dump --defaults-file=/share8t/bld/10.6-rel/mysql-test/var/my.cnf --defaults-group-suffix=.1 -uroot --port=19060 test' failed, error: 512, status: 2, errno: 11
      

      If you let the test proceed and try the same dump again, the error on the 2nd invocation is different:

      CREATE TABLE t (f DATE, vcol BOOLEAN AS (MONTHNAME(f) = 'February') VIRTUAL) CHARSET=utf8mb4 COLLATE=utf8mb4_spanish2_ci;
      --error 0,2
      --exec $MYSQL_DUMP -uroot --port=$MASTER_MYPORT test
      --exec $MYSQL_DUMP -uroot --port=$MASTER_MYPORT test
       
      DROP TABLE t;
      

      mariadb-dump: Got error: 1267: "Illegal mix of collations (utf8mb4_general_ci,COERCIBLE) and (utf8mb4_spanish2_ci,COERCIBLE) for operation '='" when using LOCK TABLES
      mysqltest: At line 4: exec of '/share8t/bld/10.6-rel/client//mariadb-dump --defaults-file=/share8t/bld/10.6-rel/mysql-test/var/my.cnf --defaults-group-suffix=.1 -uroot --port=19060 test' failed, error: 512, status: 2, errno: 0
      

      Attachments

        Activity

          People

            bar Alexander Barkov
            elenst Elena Stepanova
            Votes:
            0 Vote for this issue
            Watchers:
            2 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.