Bug #3167 HANDLER with PRIMARY causes server crash
Submitted: 14 Mar 2004 10:56 Modified: 14 Mar 2004 13:44
Reporter: Paul DuBois Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Server Severity:S2 (Serious)
Version:4.1.2 OS:
Assigned to: CPU Architecture:Any

[14 Mar 2004 10:56] Paul DuBois
Description:
This works in 4.0.19, 5.0.1, and 5.1.0,but causes a server crash for
the HANDLER ... READ statement with 4.1.2 (current 4.1 bk repository):

DROP TABLE IF EXISTS t;
CREATE TABLE t (i INT NOT NULL AUTO_INCREMENT PRIMARY KEY);
INSERT INTO t SET i = NULL;
HANDLER t OPEN;
HANDLER t READ `PRIMARY` FIRST;
HANDLER t CLOSE;

Note that this does *not* cause a crash in 4.1.1.  Perhaps this problem
is related to the fix for bug #856 [NEW]: Naming a key "Primary" causes
trouble?

http://bugs.mysql.com/?id=856

How to repeat:
See above.
[14 Mar 2004 13:17] Sergei Golubchik
Paul, I cannot repeat it - works as it should for me:

mysql> HANDLER t READ `PRIMARY` FIRST;
+---+
| i |
+---+
| 1 |
+---+
1 row in set (0.00 sec)

(and, just in case, yes, I have the very latest tree)
[14 Mar 2004 13:44] MySQL Verification Team
Also I tested on Windows and Suse 9.0 with the same Sergei's result.
[15 Mar 2004 9:30] Paul DuBois
Looks as though it is platform-specific.  The statements
work for me with the current 4.1 pull on Linux, but the READ
still crashes the server on Mac OS X (Panther). I'll try to provide
more info if you let me know what you want.