diff options
author | unknown <dlenev@mysql.com> | 2006-02-26 16:38:48 +0300 |
---|---|---|
committer | unknown <dlenev@mysql.com> | 2006-02-26 16:38:48 +0300 |
commit | 1c93eeaa16774f4c9c0e1a3be9376541b218f053 (patch) | |
tree | 4b1048c53e299ed44184fa45c4acce47e62f0c82 /sql/sql_trigger.h | |
parent | 258ad72c83154ef23bb4b9c0f492aa3e97b0bbed (diff) | |
parent | f8386dfa4821b79b6f88f8d9950ed370ba22e508 (diff) | |
download | mariadb-git-1c93eeaa16774f4c9c0e1a3be9376541b218f053.tar.gz |
Merge bk-internal.mysql.com:/home/bk/mysql-5.0-runtime
into mysql.com:/home/dlenev/src/mysql-5.0-bg13525
sql/sql_table.cc:
Auto merged
sql/sql_trigger.cc:
Auto merged
sql/sql_trigger.h:
Auto merged
sql/sql_yacc.yy:
Auto merged
mysql-test/r/trigger.result:
SCCS merged
mysql-test/t/trigger.test:
SCCS merged
Diffstat (limited to 'sql/sql_trigger.h')
-rw-r--r-- | sql/sql_trigger.h | 17 |
1 files changed, 16 insertions, 1 deletions
diff --git a/sql/sql_trigger.h b/sql/sql_trigger.h index 8992de63b37..b67c22e0588 100644 --- a/sql/sql_trigger.h +++ b/sql/sql_trigger.h @@ -47,6 +47,11 @@ class Table_triggers_list: public Sql_alloc */ List<LEX_STRING> names_list; /* + List of "ON table_name" parts in trigger definitions, used for + updating trigger definitions during RENAME TABLE. + */ + List<LEX_STRING> on_table_names_list; + /* Key representing triggers for this table in set of all stored routines used by statement. TODO: We won't need this member once triggers namespace will be @@ -97,7 +102,10 @@ public: static bool check_n_load(THD *thd, const char *db, const char *table_name, TABLE *table, bool names_only); static bool drop_all_triggers(THD *thd, char *db, char *table_name); - + static bool change_table_name(THD *thd, const char *db, + const char *old_table, + const char *new_db, + const char *new_table); bool has_delete_triggers() { return (bodies[TRG_EVENT_DELETE][TRG_ACTION_BEFORE] || @@ -117,6 +125,13 @@ public: private: bool prepare_record1_accessors(TABLE *table); + LEX_STRING* change_table_name_in_trignames(const char *db_name, + LEX_STRING *new_table_name, + LEX_STRING *stopper); + bool change_table_name_in_triggers(THD *thd, + const char *db_name, + LEX_STRING *old_table_name, + LEX_STRING *new_table_name); }; extern const LEX_STRING trg_action_time_type_names[]; |