Bug #4807 NATURAL JOIN hangs connection, requires kill -9 to stop mysqld
Submitted: 29 Jul 2004 17:15 Modified: 2 Aug 2004 10:47
Reporter: Dean Ellis Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S2 (Serious)
Version:4.1.4 OS:Linux (Linux)
Assigned to: Sergei Golubchik CPU Architecture:Any

[29 Jul 2004 17:15] Dean Ellis
Description:
A NATURAL JOIN across three or more tables where one or more of them have no common columns with another table causes the connection to hang, requiring a kill -9 to stop mysqld.  4.0 is unaffected.

How to repeat:
DROP TABLE IF EXISTS t1, t2, t3;
CREATE TABLE t1 ( a int );
CREATE TABLE t2 ( b int );
CREATE TABLE t3 ( c int );
SELECT * FROM t1 NATURAL JOIN t2 NATURAL JOIN t3;
DROP TABLE t1, t2, t3;

Suggested fix:
n/a
[2 Aug 2004 10:47] Sergei Golubchik
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 bugfix, yourself. More information 
about accessing the source trees is available at
    http://www.mysql.com/doc/en/Installing_source_tree.html

Additional info:

fixed in 4.1.4