summaryrefslogtreecommitdiff
path: root/innobase/dict
diff options
context:
space:
mode:
authorunknown <marko@hundin.mysql.fi>2004-04-02 16:25:48 +0300
committerunknown <marko@hundin.mysql.fi>2004-04-02 16:25:48 +0300
commita6d2408b539348ed7ad11ed649990e69e14b1ff6 (patch)
tree751da20f73c4984ede631acbed2ecfa9bcfe50f6 /innobase/dict
parentb73dc660a0cd6825721553b11002133ac0cf1f3f (diff)
downloadmariadb-git-a6d2408b539348ed7ad11ed649990e69e14b1ff6.tar.gz
InnoDB: ignore intra-database foreign key references between tables
when dropping database (Bug #3058) innobase/dict/dict0crea.c: Add a parameter to row_drop_table_for_mysql() innobase/dict/dict0dict.c: Make dict_tables_have_same_db() a global function innobase/include/dict0dict.h: Make dict_tables_have_same_db() a global function innobase/include/row0mysql.h: Add a parameter to row_drop_table_for_mysql() innobase/row/row0mysql.c: Add a parameter "drop_db" to row_drop_table_for_mysql() to skip foreign constraint checks on tables in same database innobase/trx/trx0roll.c: Add a parameter to row_drop_table_for_mysql() sql/ha_innodb.cc: Add a parameter "drop_db" to row_drop_table_for_mysql() innobase_drop_database(): allocate namebuf dynamically
Diffstat (limited to 'innobase/dict')
-rw-r--r--innobase/dict/dict0crea.c8
-rw-r--r--innobase/dict/dict0dict.c2
2 files changed, 5 insertions, 5 deletions
diff --git a/innobase/dict/dict0crea.c b/innobase/dict/dict0crea.c
index 967818a3784..87cdd4f5302 100644
--- a/innobase/dict/dict0crea.c
+++ b/innobase/dict/dict0crea.c
@@ -999,13 +999,13 @@ dict_create_or_check_foreign_constraint_tables(void)
if (table1) {
fprintf(stderr,
"InnoDB: dropping incompletely created SYS_FOREIGN table\n");
- row_drop_table_for_mysql((char *) "SYS_FOREIGN", trx);
+ row_drop_table_for_mysql((char*)"SYS_FOREIGN", trx, TRUE);
}
if (table2) {
fprintf(stderr,
"InnoDB: dropping incompletely created SYS_FOREIGN_COLS table\n");
- row_drop_table_for_mysql((char *) "SYS_FOREIGN_COLS", trx);
+ row_drop_table_for_mysql((char*)"SYS_FOREIGN_COLS", trx, TRUE);
}
fprintf(stderr,
@@ -1054,8 +1054,8 @@ dict_create_or_check_foreign_constraint_tables(void)
fprintf(stderr,
"InnoDB: dropping incompletely created SYS_FOREIGN tables\n");
- row_drop_table_for_mysql((char *) "SYS_FOREIGN", trx);
- row_drop_table_for_mysql((char *) "SYS_FOREIGN_COLS", trx);
+ row_drop_table_for_mysql((char*)"SYS_FOREIGN", trx, TRUE);
+ row_drop_table_for_mysql((char*)"SYS_FOREIGN_COLS", trx, TRUE);
error = DB_MUST_GET_MORE_FILE_SPACE;
}
diff --git a/innobase/dict/dict0dict.c b/innobase/dict/dict0dict.c
index 0efb9935800..c0810ad45dc 100644
--- a/innobase/dict/dict0dict.c
+++ b/innobase/dict/dict0dict.c
@@ -177,7 +177,7 @@ mutex_t dict_foreign_err_mutex; /* mutex protecting the foreign
/************************************************************************
Checks if the database name in two table names is the same. */
-static
+
ibool
dict_tables_have_same_db(
/*=====================*/