Select on table with two colums cause empty result.

Bug #727091 reported by Marcin Grzymski
16
This bug affects 2 people
Affects Status Importance Assigned to Milestone
MySQL Server
Unknown
Unknown
mysql-dfsg-5.1 (Ubuntu)
Triaged
Low
Unassigned

Bug Description

Binary package hint: mysql-server-5.1

Table with two integer columns and separate indexes on each column can cause problems
during select with conditions on both columns.
Selecting with condition on one column works ok but multiple columns in same time
generate empty result.

Creating index on two columns fixes results from select.
Version 5.0 works fine in that case.

Looks like bug has been fixed in 5.1.54 + .
http://bugs.mysql.com/bug.php?id=60231

ProblemType: Bug
DistroRelease: Ubuntu 10.10
Package: mysql-server-5.1 5.1.49-1ubuntu8.1
ProcVersionSignature: Ubuntu 2.6.35-25.44-generic 2.6.35.10
Uname: Linux 2.6.35-25-generic x86_64
NonfreeKernelModules: nvidia
Architecture: amd64
Date: Tue Mar 1 10:42:40 2011
ProcEnviron:
 PATH=(custom, user)
 LANG=en_GB.utf8
 SHELL=/bin/bash
SourcePackage: mysql-5.1

Revision history for this message
Marcin Grzymski (m-grzymski) wrote :
Revision history for this message
Clint Byrum (clint-fewbar) wrote :

Marcin, thanks for taking the time to file this bug report and help us make Ubuntu better.

Given that you are the only one reporting this issue, I tried to repeat it using the test case from the mysql bug report.

I was unable to reproduce it, with MySQL 5.1 5.1.54-1ubuntu4 on natty, or 5.1.49-1ubuntu8.1 on maverick.

Marcin, I'm going to close this bug as Invalid. If you have further details that will help us reproduce the issue or further understand how your setup differs, feel free to re-open it as Status "New".

Changed in mysql-dfsg-5.1 (Ubuntu):
status: New → Invalid
Revision history for this message
Marcin Grzymski (m-grzymski) wrote : Re: [Bug 727091] Re: Select on table with two colums cause empty result.

W dniu 03.03.2011 11:23, Clint Byrum pisze:
> Marcin, thanks for taking the time to file this bug report and help us
> make Ubuntu better.
>
> Given that you are the only one reporting this issue, I tried to repeat
> it using the test case from the mysql bug report.
>
> I was unable to reproduce it, with MySQL 5.1 5.1.54-1ubuntu4 on natty,
> or 5.1.49-1ubuntu8.1 on maverick.
>
> Marcin, I'm going to close this bug as Invalid. If you have further
> details that will help us reproduce the issue or further understand how
> your setup differs, feel free to re-open it as Status "New".
>
> ** Changed in: mysql-dfsg-5.1 (Ubuntu)
> Status: New => Invalid
>
Thank you for response.

Could you double check if you recreated all steps.
I have checked that on ubuntu 10.10 maverick 32 / 64 bits and debian
squeeze 64 bits with mysql 5.1.49 - all systems have same result.
In 10.10 maverick desktop edition 32 bit with fresh install of mysql (no
config changes) with just one db - 'test'.
Debian one have no changes to config too.

Important bit is:

INSERT INTO `a_b` VALUES (12,4);

select * from a_b where a_id = 11 and b_id = 4;
Empty set (0.00 sec)

and how create index fix it:

create unique index index_a_b_on_both_id on a_b (a_id, b_id);

select * from a_b where a_id = 11 and b_id = 4;
+------+------+
| a_id | b_id |
+------+------+
| 11 | 4 |
+------+------+

Kind Regards
Marcin Grzymski

Changed in mysql-dfsg-5.1 (Ubuntu):
status: Invalid → New
Revision history for this message
James Page (james-page) wrote :

I was able to reproduce on Maverick (mysql-server 5.1.49-1ubuntu8.1) by following the steps in the upstream bug report.

Revision history for this message
James Page (james-page) wrote :

Log of issue from clean, up-to-date maverick install

James Page (james-page)
Changed in mysql-dfsg-5.1 (Ubuntu):
status: New → Confirmed
Revision history for this message
James Page (james-page) wrote :

Also checked in natty - not impacted by the same issue but this is reflected in the upstream bug report.

Changed in mysql-dfsg-5.1 (Ubuntu):
status: Confirmed → Triaged
importance: Undecided → Low
Revision history for this message
James Page (james-page) wrote :

Thanks for reporting this bug and any supporting documentation. Since this bug has enough information provided for a developer to begin work, I'm going to mark it as confirmed and let them handle it from here. Thanks for taking the time to make Ubuntu better!

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.