Bug #26469 Falcon: searches fail if decimal(6,6) column and index exists

Submitted: 18 Feb 2007 0:49 Modified: 20 Apr 2007 14:45
Reporter: Peter Gulutzan Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server: Falcon storage engine Severity:S2 (Serious)
Version:5.2.4-falcon-alpha-debug OS:Linux (SUSE 10.0 / 64-bit)
Assigned to: Jim Starkey CPU Architecture:Any

[18 Feb 2007 0:49] Peter Gulutzan
Description:
I create a table with a decimal(6,6) indexed column.
I insert ... 0.000001.
I search for 0.000001.
Nothing is found.

This doesn't happen with a decimal(5,5) column.
This doesn't happen with an unindexed column.

How to repeat:
mysql> create table t27 (s1 decimal(6,6), key(s1)) engine=falcon;
Query OK, 0 rows affected (0.01 sec)

mysql> insert into t27 values      (0.000001);
Query OK, 1 row affected (0.00 sec)

mysql> select * from t27 where s1 = 0.000001;
Empty set (0.00 sec)
[18 Feb 2007 2:17] Hakan Küçükyılmaz
Verified as described. Added test case falcon_bug_26469.test and pushed into mysql-5.1-falcon tree.

TEST                           RESULT         TIME (ms)
-------------------------------------------------------

falcon_bug_26469               [ fail ]

Errors are (from /home/hakan/work/mysql/mysql-5.1-falcon/mysql-test/var/log/mysqltest-time) :
mysqltest: Result content mismatch
(the last lines may be the most important ones)
Below are the diffs between actual and expected results:
-------------------------------------------------------
*** r/falcon_bug_26469.result   2007-02-18 05:15:16.000000000 +0300
--- r/falcon_bug_26469.reject   2007-02-18 05:15:19.000000000 +0300
***************
*** 5,9 ****
  INSERT INTO t1 VALUES (0.000001);
  SELECT count(*) FROM t1 WHERE a = 0.000001;
  count(*)
! 1
  DROP TABLE t1;
--- 5,9 ----
  INSERT INTO t1 VALUES (0.000001);
  SELECT count(*) FROM t1 WHERE a = 0.000001;
  count(*)
! 0
  DROP TABLE t1;
-------------------------------------------------------
Please follow the instructions outlined at
http://www.mysql.com/doc/en/Reporting_mysqltest_bugs.html
to find the reason to this problem and how to report this.

Regards, Hakan
[19 Apr 2007 15:57] Jim Starkey
BigInt and Value where using different algorithms to scale double
number resulting in a low bit error.  They now use the same code.
[19 Apr 2007 17:10] Hakan Küçükyılmaz
Passes now:

TEST                           RESULT         TIME (ms)
-------------------------------------------------------

falcon_bug_26469               [ pass ]            254
-------------------------------------------------------
Stopping All Servers
All 1 tests were successful.
The servers where restarted 1 times
Spent 0.254 seconds actually executing testcases
[19 Apr 2007 17:12] Bugs System
A patch for this bug has been committed. After review, it may
be pushed to the relevant source trees for release in the next
version. You can access the patch from:

  http://lists.mysql.com/commits/24910

ChangeSet@1.2623, 2007-04-19 19:11:44+02:00, hakank@lu0011.wdf.sap.corp +1 -0
  Test for Bug#26469 passes now.
[20 Apr 2007 14:45] MC Brown
A note has been added to the 5.2.4 changelog.
[10 Jul 2007 19:09] MC Brown
This bug report entry has been moved to the 6.0.0 Falcon changelog.

Portions of this website are copyright © 2001, 2002 The PHP Group

Page generated in 0.057 sec. using MySQL 8.4.7-u6-cloud

Timestamp references displayed by the system are UTC.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.