1
0
mirror of https://github.com/MariaDB/server.git synced 2025-05-27 01:57:48 +03:00
Tatiana A. Nurnberg 1fc1f462b6 Bug#49487: crash with explain extended and group_concat in a derived table
When EXPLAIN EXTENDED tries to print column names, it checks whether the
referenced table is CONST (in which case, the column's value rather than
its name will be printed). If no proper table is reference (i.e. because
a derived table was used that has since gone out of scope), this will fail
spectacularly.

This ports an equivalent of the fix for Bug 43354.

mysql-test/r/func_gconcat.result:
  Show that EXPLAIN EXTENDED on a GROUP_CONCAT() on a derived table
  no longer crashes the server.
mysql-test/t/func_gconcat.test:
  Show that EXPLAIN EXTENDED on a GROUP_CONCAT() on a derived table
  no longer crashes the server.
sql/item_sum.cc:
  Do not de-ref what cannot be, that is, temp-tables that have gone away.
  This is of questionable utility anyway, since our deref has the sole
  purpose of checking whether the table is const (in which case, we'll
  substitute the column with its value in EXPLAIN EXTENDED - that is all).
2010-02-19 15:16:43 +00:00
..
2008-12-17 15:01:34 -05:00
2008-07-14 16:16:37 -04:00
2008-07-10 14:47:53 -04:00
2007-11-05 20:18:22 +01:00
2009-11-03 19:58:54 +03:00
2009-02-06 18:25:08 +01:00
2009-04-01 16:02:26 +05:00
2009-03-19 09:44:58 -04:00
2009-11-03 19:58:54 +03:00
2008-07-10 14:50:07 -04:00
2008-01-23 13:26:41 -07:00
2010-02-01 13:40:16 +02:00
2009-11-03 19:58:54 +03:00
2007-07-01 15:33:28 -07:00
2009-03-19 09:44:58 -04:00
2009-12-14 00:58:16 +01:00
2009-11-03 19:58:54 +03:00
2009-08-21 17:10:55 +03:00
2009-06-29 15:17:01 +02:00