diff options
author | heikki@hundin.mysql.fi <> | 2003-05-04 23:24:23 +0300 |
---|---|---|
committer | heikki@hundin.mysql.fi <> | 2003-05-04 23:24:23 +0300 |
commit | aa92b8ecd10d42b70ee93e90822c35f25d00cf84 (patch) | |
tree | 69216396781f1a2d6400c0e70a00105c58d652a5 /innobase/dict | |
parent | 9dd21162bb63367519f3930aa53b75240af6ab8b (diff) | |
download | mariadb-git-aa92b8ecd10d42b70ee93e90822c35f25d00cf84.tar.gz |
row0ins.c, dict0dict.c, dict0dict.h, srv0srv.c:
Let SHOW INNODB STATUS print detailed info of the latest unique key violation, note that REPLACE and INSERT IGNORE mask the error from the user
Diffstat (limited to 'innobase/dict')
-rw-r--r-- | innobase/dict/dict0dict.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/innobase/dict/dict0dict.c b/innobase/dict/dict0dict.c index 74fe5cd5b70..c11a5f76d94 100644 --- a/innobase/dict/dict0dict.c +++ b/innobase/dict/dict0dict.c @@ -185,10 +185,12 @@ dict_foreign_free( /*==============*/ dict_foreign_t* foreign); /* in, own: foreign key struct */ -/* Buffer for storing detailed information about the latest foreig key -error */ +/* Buffers for storing detailed information about the latest foreign key +and unique key errors */ char* dict_foreign_err_buf = NULL; -mutex_t dict_foreign_err_mutex; /* mutex protecting the buffer */ +char* dict_unique_err_buf = NULL; +mutex_t dict_foreign_err_mutex; /* mutex protecting the foreign + and unique error buffers */ /************************************************************************ @@ -582,6 +584,8 @@ dict_init(void) dict_foreign_err_buf = mem_alloc(DICT_FOREIGN_ERR_BUF_LEN); dict_foreign_err_buf[0] = '\0'; + dict_unique_err_buf = mem_alloc(DICT_FOREIGN_ERR_BUF_LEN); + dict_unique_err_buf[0] = '\0'; mutex_create(&dict_foreign_err_mutex); mutex_set_level(&dict_foreign_err_mutex, SYNC_ANY_LATCH); } |