Bug #39243 Maria: SELECT WHERE does not find row
Submitted: 4 Sep 2008 13:48 Modified: 9 Jan 2009 15:28
Reporter: Guilhem Bichot Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Maria storage engine Severity:S3 (Non-critical)
Version:5.1-maria, 6.0-bk OS:Linux
Assigned to: Michael Widenius CPU Architecture:Any

[4 Sep 2008 13:48] Guilhem Bichot
Description:
Run this with t1 being a Maria table:
create table t2 (p int primary key, i int, a char(10), key k1(i), key k2(a));
insert into t2 values (1, 1, 'qqqq'), (2, 1, 'pppp'),
                      (3, 1, 'yyyy'), (4, 3, 'zzzz');
insert into t2 values (2000, 3, 'yyyy');
select * from t2 where a='zzzz';
select * from t2;
The first SELECT returns no rows, though the second SELECT shows the 'zzzz' row.
This bug seems to occur several times when running:
./mtr --mem key_cache --mysqld=--default-storage-engine=maria
So after fixing the small testcase, please run the above mtr line.

How to repeat:
See description
[26 Sep 2008 8:18] Michael Widenius
Thank you for your bug report. This issue has been committed to our source repository of that product and will be incorporated into the next release.

If necessary, you can access the source repository and build the latest available version, including the bug fix. More information about accessing the source trees is available at

    http://dev.mysql.com/doc/en/installing-source.html
[13 Oct 2008 19:26] Guilhem Bichot
Patch was pushed in 5.1-maria, not yet in 6.0-maria
[26 Oct 2008 22:19] Bugs System
Pushed into 6.0.8-alpha  (revid:monty@mysql.com-20080926081635-hh6xco5ewlmt3obv) (version source revid:guilhem@mysql.com-20081020191322-i0e65e3k8044kkce) (pib:5)
[9 Jan 2009 15:28] MC Brown
Added a note to the 6.0.8 changelog: 

Maria could fail to find data in a table with an index on a char column