Bug #8824 Subquery with now() breaks cluster
Submitted: 26 Feb 2005 22:14 Modified: 5 Apr 2005 0:25
Reporter: eric Email Updates:
Status: Closed Impact on me:
Category:MySQL Server Severity:S1 (Critical)
Version:4.1.10 and 5.0 bk src OS:Linux (SuSE 9.2)
Assigned to: Oleksandr Byelkin CPU Architecture:Any

[26 Feb 2005 22:14] eric
I have a cluster of three MySQL machines running 4.1.10.  Two of the machines are running both ndbd and mysqld, and the third runs ndb_mgmd.  There are a few databases which contain clustered tables, but they aren't used in this bug.  Running a query that uses now() in a subquery causes the API node to crash.

Not sure if this is common to all SuSE9.2 installs running 4.1.10, or if it requires a cluster to exist as well.  

How to repeat:
dbadmin@node1:/usr/local/mysql> mysql -u root -p
Enter password:
Welcome to the MySQL monitor.  Commands end with ; or \g.
Your MySQL connection id is 1 to server version: 4.1.10-max

Type 'help;' or '\h' for help. Type '\c' to clear the buffer.

mysql> select * from (select now() as foo) as bar;
ERROR 2013 (HY000): Lost connection to MySQL server during query
mysql> select * from (select now() as foo) as bar;
ERROR 2006 (HY000): MySQL server has gone away
No connection. Trying to reconnect...
Connection id:    1
Current database: *** NONE ***

ERROR 2013 (HY000): Lost connection to MySQL server during query
[26 Feb 2005 22:16] eric
Further testing shows that the alias on now() is not required.  Adjusting synopsis.
[1 Mar 2005 21:28] Tomas Ulin
tested quickly in 5.0 src tree without cluster, same problem

concluded it is not cluster specific, changing category to server
[23 Mar 2005 6:37] 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:

[30 Mar 2005 20:13] Oleksandr Byelkin
Thank you for bugreport. bugfix is pushed into source tree marked as 4.1.11.
[5 Apr 2005 0:25] Paul Dubois
Noted in 4.1.11 changelog.