summaryrefslogtreecommitdiff
path: root/sql/mysql_priv.h
diff options
context:
space:
mode:
authorunknown <evgen@moonbone.local>2006-10-13 21:59:52 +0400
committerunknown <evgen@moonbone.local>2006-10-13 21:59:52 +0400
commit67770b7671652ee4fe89c82ffbe77a3a1c08ed78 (patch)
tree7bd36ea523de49e01ecb5afa66beded74a185380 /sql/mysql_priv.h
parentb6248f76ed201d524ccc9b33cae2d961a0724c5e (diff)
downloadmariadb-git-67770b7671652ee4fe89c82ffbe77a3a1c08ed78.tar.gz
Bug#14959: ALTER TABLE isn't able to rename a view
The mysql_alter_table() was able to rename only a table. The view/table renaming code is moved from the function rename_tables to the new function called do_rename(). The mysql_alter_table() function calls it when it needs to rename a view. mysql-test/t/rename.test: Added a test case for bug#14959: ALTER TABLE isn't able to rename a view mysql-test/r/rename.result: Added a test case for bug#14959: ALTER TABLE isn't able to rename a view sql/mysql_priv.h: Bug#14959: ALTER TABLE isn't able to rename a view Added the prototype of the do_rename() function. sql/sql_rename.cc: Bug#14959: ALTER TABLE isn't able to rename a view The view/table renaming code is moved from the function rename_tables to the new function called do_rename(). sql/sql_table.cc: Bug#14959: ALTER TABLE isn't able to rename a view Added handling of a view rename to the mysql_alter_table() function.
Diffstat (limited to 'sql/mysql_priv.h')
-rw-r--r--sql/mysql_priv.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/sql/mysql_priv.h b/sql/mysql_priv.h
index ff04022b110..1cee013852e 100644
--- a/sql/mysql_priv.h
+++ b/sql/mysql_priv.h
@@ -648,6 +648,9 @@ int quick_rm_table(enum db_type base,const char *db,
const char *table_name);
void close_cached_table(THD *thd, TABLE *table);
bool mysql_rename_tables(THD *thd, TABLE_LIST *table_list);
+bool do_rename(THD *thd, TABLE_LIST *ren_table, char *new_db,
+ char *new_table_name, char *new_table_alias,
+ bool skip_error);
bool mysql_change_db(THD *thd,const char *name,bool no_access_check);
void mysql_parse(THD *thd,char *inBuf,uint length);
bool mysql_test_parse_for_slave(THD *thd,char *inBuf,uint length);