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

Partition pruning with column list causes syntax error in 10.4

    XMLWordPrintable

Details

    Description

      --source include/have_partition.inc
      create table t (a int) partition by hash(a);
      insert into t partition (p0) (a) values (1);
      select * from t;
      drop table t;
      

      10.4 09b2d37a

      insert into t partition (p0) (a) values (1);
      bug.t2                                   [ fail ]
              Test ended at 2019-03-20 19:44:18
       
      CURRENT_TEST: bug.t2
      mysqltest: At line 3: query 'insert into t partition (p0) (a) values (1)' failed: 1064: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'a) values (1)' at line 1
      

      In 10.3 it works all right.

      Same for insert .. select instead of insert .. values:

      --source include/have_partition.inc
      create table t (a int) partition by hash(a);
      insert into t partition (p0) (a) select 1;
      select * from t;
      drop table t;
      

      mysqltest: At line 3: query 'insert into t partition (p0) (a) select 1' failed: 1064: You have an error in your SQL syntax; check the manual that corresponds to your MariaDB server version for the right syntax to use near 'a) select 1' at line 1
      

      Attachments

        Issue Links

          Activity

            People

              igor Igor Babaev
              elenst Elena Stepanova
              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.