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

Wrong result - server does not return NULL values from default list partition after ALTER table

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed (View Workflow)
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 10.2
    • Fix Version/s: 10.2.2
    • Component/s: Partitioning
    • Labels:
      None
    • Sprint:
      10.2.2-3

      Description

      Output

      MariaDB [test]> create table t1 (i int) partition by list (i) ( partition p1 default);
      Query OK, 0 rows affected (0.62 sec)
       
      MariaDB [test]> insert into t1 values (null);
      Query OK, 1 row affected (0.08 sec)
       
      MariaDB [test]> select * from t1 where i is null;
      +------+
      | i    |
      +------+
      | NULL |
      +------+
      1 row in set (0.00 sec)
       
      MariaDB [test]> alter table t1 partition by list (i) ( partition p1 values in (1), partition p2 default);
      Query OK, 1 row affected (1.38 sec)
      Records: 1  Duplicates: 0  Warnings: 0
       
      MariaDB [test]> select * from t1 where i is null;
      Empty set (0.01 sec)
      

      Test case

      create table t1 (i int) partition by list (i) ( partition p1 default);
      insert into t1 values (null);
      select * from t1 where i is null;
      alter table t1 partition by list (i) ( partition p1 values in (1), partition p2 default);
      select * from t1 where i is null;
      

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              sanja Oleksandr Byelkin
              Reporter:
              elenst Elena Stepanova
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated:
                Resolved: