Bug #41997 Multi table delete no longer accepts a * in SELECT
Submitted: 9 Jan 2009 12:54 Modified: 10 Feb 2009 20:11
Reporter: Amit Saha Email Updates:
Status: Can't repeat Impact on me:
None 
Category:MySQL Server: Documentation Severity:S3 (Non-critical)
Version:6.0.8 OS:Linux
Assigned to: CPU Architecture:Any

[9 Jan 2009 12:54] Amit Saha
Description:
A Multi table delete statement like "DELETE     FROM t1.*, t2.*, t3 USING t1, t2, t3 WHERE t1.c1=t2.c2 AND t2.c1=t3.c2' "  is no longer accepted, even though the documentation suggests so.

How to repeat:
Please run the attached test case.
[9 Jan 2009 12:54] Amit Saha
Test Case

Attachment: de_multi_db_table_using.test (application/octet-stream, text), 22.06 KiB.

[9 Jan 2009 13:11] Jon Stephens
Did someone tell you that this change was intentional? If so, who?

If it's not an intentional change in behaviour, then it's a server bug.
[9 Jan 2009 13:15] Amit Saha
@Jon: I am not sure whether the change was intentional. I had to choose one at fault. I chose the documentation. It will need to be verified, though.
[9 Jan 2009 14:13] MySQL Verification Team
Thank you for the bug report. Looks like similar query is showed by the call stack of the bug: http://bugs.mysql.com/bug.php?id=41996:

00BAFBB6    mysqld.exe!_threadstartex()[threadex.c:241]
7C80B713    kernel32.dll!GetModuleFileNameA()
Trying to get some variables.
Some pointers may be invalid and cause the dump to abort...
thd->query at 0377A4C0=DELETE     d1.t1, d2.t2 FROM d1.t1, d2.t2, d3.t3 WHERE
d1.t1.c1=d2.t2.c2 AND d2.t2.c1=d3.t3.c2
thd->thread_id=1

if yes, then this bug is duplicate of the above one?. Thanks in advance.
[9 Jan 2009 14:19] MySQL Verification Team
Sorry I was looking another call stack I got:

thd: 0x370ad30
Attempting backtrace. You can use the following information to find out
where mysqld died. If you see no messages after this, something went
terribly wrong...
009BECD6    mysqld.exe!mach_read_from_4()[mach0data.ic:172]
00994209    mysqld.exe!btr_copy_externally_stored_field()[btr0cur.c:3759]
0099452E    mysqld.exe!btr_rec_copy_externally_stored_field()[btr0cur.c:3847]
009853D8    mysqld.exe!row_sel_store_mysql_rec()[row0sel.c:2640]
00986AFD    mysqld.exe!row_search_for_mysql()[row0sel.c:4192]
009469CB    mysqld.exe!ha_innobase::index_read()[ha_innodb.cc:4267]
0046A75C    mysqld.exe!handler::index_read_map()[handler.h:1767]
006DA2A3    mysqld.exe!join_read_always_key()[sql_select.cc:16831]
006D8B9F    mysqld.exe!sub_select()[sql_select.cc:16164]
006D92C0    mysqld.exe!evaluate_join_record()[sql_select.cc:16432]
006D8BF5    mysqld.exe!sub_select()[sql_select.cc:16169]
006D8111    mysqld.exe!do_select()[sql_select.cc:15728]
006BBDB0    mysqld.exe!JOIN::exec()[sql_select.cc:2866]
006BC458    mysqld.exe!mysql_select()[sql_select.cc:3049]
0067581D    mysqld.exe!mysql_execute_command()[sql_parse.cc:3291]
0067BE5D    mysqld.exe!mysql_parse()[sql_parse.cc:5735]
00671438    mysqld.exe!dispatch_command()[sql_parse.cc:1007]
00670CBF    mysqld.exe!do_command()[sql_parse.cc:690]
0078AA77    mysqld.exe!handle_one_connection()[sql_connect.cc:1145]
0086CDB8    mysqld.exe!pthread_start()[my_winthread.c:61]
00BAFBB6    mysqld.exe!_threadstartex()[threadex.c:241]
7C80B713    kernel32.dll!GetModuleFileNameA()
Trying to get some variables.
Some pointers may be invalid and cause the dump to abort...
thd->query at 0377A3E0=DELETE     FROM d1.t1, d2.t2 USING d1.t1, d2.t2, d3.t3 WHERE d1.t1.c1=d2.t2.c2 AND d2.t2.c1=d3.t3.c2
thd->thread_id=1
thd->killed=NOT_KILLED
The manual page at http://dev.mysql.com/doc/mysql/en/crashing.html contains
information that should help you find out what is causing the crash.

Anyway the above query provokes a crash.
[10 Feb 2009 0:00] Bugs System
No feedback was provided for this bug for over a month, so it is
being suspended automatically. If you are able to provide the
information that was originally requested, please do so and change
the status of the bug back to "Open".
[10 Feb 2009 20:11] MySQL Verification Team
I couldn't repeat anymore with current source server.
[11 Feb 2009 4:26] Amit Saha
I think, the bug is no longer reproducible. May be it has been fixed. I tried it with 6.0.9 alpha.