Bug #4801 SERVER CRASH after with VIEWS + SELECT * FROM DUAL
Submitted: 29 Jul 2004 11:34 Modified: 24 Aug 2004 8:57
Reporter: Georg Richter Email Updates:
Status: Closed Impact on me:
None 
Category:MySQL Server Severity:S3 (Non-critical)
Version:5.0.1 OS:
Assigned to: Oleksandr Byelkin CPU Architecture:Any

[29 Jul 2004 11:34] Georg Richter
Description:
When trying to create a VIEW with SELECT * FROM DUAL server crashes in next statement (packets 
out of order). Same happens when using a prepared statement. 

How to repeat:
[11:32] root@test> select version(); 
+-----------------------+ 
| version()             | 
+-----------------------+ 
| 5.0.1-alpha-debug-log | 
+-----------------------+ 
1 row in set (0.00 sec) 
 
[11:28] root@test> CREATE VIEW v02 AS SELECT * FROM DUAL; 
ERROR 1096 (HY000): No tables used 
5.0.1-alpha-debug-log 
[11:28] root@test> SHOW TABLES; 
Packets out of order (Found: 2, expected 1) 
ERROR 2013 (HY000): Lost connection to MySQL server during query 
5.0.1-alpha-debug-log 
 
with prepared statements: 
 
... 
strcpy(query, "SELECT * FROM DUAL"); 
mysql_stmt_prepare(stmt, query, strlen(query)); 
.... 
crash!
[23 Aug 2004 1:51] Peter Gulutzan
It doesn't have to be "select * from dual". 
If I say "create view v as select *" the effect is similar.
[23 Aug 2004 11:40] Oleksandr Byelkin
ChangeSet 
  1.1725 04/08/23 12:38:55 bell@sanja.is.com.ua +3 -0 
  fixed error processing of prepare in VIEW creation (BUG#4801)
[24 Aug 2004 8:57] Oleksandr Byelkin
Thank you  for bugreport. Bugfix is pushed in our source repository