1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

MDEV-24331 mysqldump fails with "Got error: 1356" if the database contains a view with a subquery

detect derived tables differently. TABLE_LIST::is_derived()
only works after mysql_derived_init()
This commit is contained in:
Sergei Golubchik
2020-12-11 19:35:38 +01:00
parent 79fd338e6c
commit 4fa44c584c
3 changed files with 52 additions and 1 deletions

View File

@ -6639,7 +6639,7 @@ check_access(THD *thd, ulong want_access, const char *db, ulong *save_priv,
bool check_single_table_access(THD *thd, ulong privilege, TABLE_LIST *tables,
bool no_errors)
{
if (tables->is_derived())
if (tables->derived)
return 0;
Switch_to_definer_security_ctx backup_sctx(thd, tables);