Uploaded image for project: 'MariaDB Server'
  1. MariaDB Server
  2. MDEV-3841 LevelDB storage engine
  3. MDEV-4085

LevelDB: Wrong result on range condition and aggregate function with two keys on a field

    Details

    • Type: Technical task
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:

      Description

      CREATE TABLE t1 (pk INT PRIMARY KEY, a INT, b CHAR(1), KEY(a), KEY(a,b)) 
        ENGINE=LevelDB;
      INSERT INTO t1 VALUES (1,10,'x'), (2,20,'y');
      
      EXPLAIN EXTENDED SELECT MAX(a) FROM t1 WHERE a < 100;
      id	select_type	table	type	possible_keys	key	key_len	ref	rows	filtered	Extra
      1	SIMPLE	NULL	NULL	NULL	NULL	NULL	NULL	NULL	NULL	No matching min/max row
      Warnings:
      Note	1003	/* select#1 */ select max(`test`.`t1`.`a`) AS `MAX(a)` from `test`.`t1` where (`test`.`t1`.`a` < 100)
      
      SELECT MAX(a) FROM t1 WHERE a < 100;
      MAX(a)
      NULL
      

      Test case:

      CREATE TABLE t1 (pk INT PRIMARY KEY, a INT, b CHAR(1), KEY(a), KEY(a,b)) 
        ENGINE=LevelDB;
      INSERT INTO t1 VALUES (1,10,'x'), (2,20,'y');
      SELECT MAX(a) FROM t1 WHERE a < 100;
      
      revision-id: psergey@askmonty.org-20130124165745-nm4yaxrsu8e4o2ll
      revno: 4511
      branch-nick: mysql-5.6-leveldb
      

        Gliffy Diagrams

          Attachments

            Activity

            There are no comments yet on this issue.

              People

              • Assignee:
                psergey Sergei Petrunia
                Reporter:
                elenst Elena Stepanova
              • Votes:
                0 Vote for this issue
                Watchers:
                1 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:

                  Time Tracking

                  Estimated:
                  Original Estimate - Not Specified
                  Not Specified
                  Remaining:
                  Remaining Estimate - 0 minutes
                  0m
                  Logged:
                  Time Spent - 30 minutes
                  30m