Bug #1146 2013 ERROR in select statement with in and union clauses
Submitted: 26 Aug 2003 23:24 Modified: 27 Aug 2003 4:57
Reporter: Siva Dirisala Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S3 (Non-critical)
Version:4.1.0-alpha OS:Linux (linux 2.4)
Assigned to: CPU Architecture:Any

[26 Aug 2003 23:24] Siva Dirisala
Description:
Get

ERROR 2013: Lost connection to MySQL server during query 

when executing a query like

select count(1) from temp where value2 in (select 1 from dual union all select 2 from dual);

How to repeat:

1. create table temp (value1 varchar(30),value2 integer) type=innodb;

2. populate with some data in the table.

3. Execute the above mentioned query which is killing the server.

If the in clause is changed to (1,2) it works fine. 
However, sometimes the in clause would depend on selecting data from tables.
[26 Aug 2003 23:28] Siva Dirisala
updated synopsis to be more specific.
[27 Aug 2003 4:57] Alexander Keremidarski
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

Does not crash with current 4.1 from bk tree (i.e. post-4.1.0)
This is probably same as one of previoulsy reported and fixed bugs with subqueries.