From 0a91dbcf53e021155e56c02ee50b4314ffad7ccd Mon Sep 17 00:00:00 2001 From: unknown Date: Fri, 15 Jun 2007 03:22:40 +0500 Subject: [PATCH 01/27] BUG#28971 - ALTER TABLE followed by UPDATE for a CSV table make server crash UPDATE against CSV table may cause server crash or update a table with wrong values. CSV can write only a whole row at once. That means it must read all columns, that it is not going to update, and write them along with updated columns. But only limited set of columns was read, those that were needed for the UPDATE query. With this fix all columns are read in case we're performing an UPDATE. mysql-test/r/csv.result: A test case for BUG#28971. mysql-test/t/csv.test: A test case for BUG#28971. Flush tables is here just to make crash more probable. If we remove it, fields will have old values from previous query and server won't crash. storage/csv/ha_tina.cc: CSV engine is not capable to update single column, because it can only write a row at once. Thus we must read all columns if a table is opened for update. --- mysql-test/r/csv.result | 8 ++++++++ mysql-test/t/csv.test | 11 +++++++++++ storage/csv/ha_tina.cc | 5 ++++- 3 files changed, 23 insertions(+), 1 deletion(-) diff --git a/mysql-test/r/csv.result b/mysql-test/r/csv.result index ede5d9a32fd..1196a264fd3 100644 --- a/mysql-test/r/csv.result +++ b/mysql-test/r/csv.result @@ -5240,3 +5240,11 @@ CREATE TABLE `bug21328` ( insert into bug21328 values (1,NULL,NULL); alter table bug21328 engine=myisam; drop table bug21328; +create table t1(a blob, b int) engine=csv; +insert into t1 values('a', 1); +flush tables; +update t1 set b=2; +select * from t1; +a b +a 2 +drop table t1; diff --git a/mysql-test/t/csv.test b/mysql-test/t/csv.test index 62482d576b2..922fbb0d3f1 100644 --- a/mysql-test/t/csv.test +++ b/mysql-test/t/csv.test @@ -1653,3 +1653,14 @@ CREATE TABLE `bug21328` ( insert into bug21328 values (1,NULL,NULL); alter table bug21328 engine=myisam; drop table bug21328; + +# +# BUG#28971 - ALTER TABLE followed by UPDATE for a CSV table make server +# crash +# +create table t1(a blob, b int) engine=csv; +insert into t1 values('a', 1); +flush tables; +update t1 set b=2; +select * from t1; +drop table t1; diff --git a/storage/csv/ha_tina.cc b/storage/csv/ha_tina.cc index 9eead7a059c..c0790d69888 100644 --- a/storage/csv/ha_tina.cc +++ b/storage/csv/ha_tina.cc @@ -590,6 +590,7 @@ int ha_tina::find_current_row(uchar *buf) int eoln_len; my_bitmap_map *org_bitmap; int error; + bool read_all; DBUG_ENTER("ha_tina::find_current_row"); /* @@ -601,6 +602,8 @@ int ha_tina::find_current_row(uchar *buf) local_saved_data_file_length, &eoln_len)) == 0) DBUG_RETURN(HA_ERR_END_OF_FILE); + /* We must read all columns in case a table is opened for update */ + read_all= !bitmap_is_clear_all(table->write_set); /* Avoid asserts in ::store() for columns that are not going to be updated */ org_bitmap= dbug_tmp_use_all_columns(table, table->write_set); error= HA_ERR_CRASHED_ON_USAGE; @@ -678,7 +681,7 @@ int ha_tina::find_current_row(uchar *buf) goto err; } - if (bitmap_is_set(table->read_set, (*field)->field_index)) + if (read_all || bitmap_is_set(table->read_set, (*field)->field_index)) (*field)->store(buffer.ptr(), buffer.length(), system_charset_info); } next_position= end_offset + eoln_len; From e148eb473222babd262eb7200621a1e1cd2b4938 Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 19 Jun 2007 15:34:21 +0500 Subject: [PATCH 02/27] mtr_report.pl: Ignore warning about file name having question marks. mysql-test/lib/mtr_report.pl: Ignore warning about file name having question marks. --- mysql-test/lib/mtr_report.pl | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/mysql-test/lib/mtr_report.pl b/mysql-test/lib/mtr_report.pl index 096840eb559..84d813ca918 100644 --- a/mysql-test/lib/mtr_report.pl +++ b/mysql-test/lib/mtr_report.pl @@ -359,6 +359,10 @@ sub mtr_report_stats ($) { /skip-name-resolve mode/ or /slave SQL thread aborted/ or /Slave: .*Duplicate entry/ or + # Special case for Bug #26402 in show_check.test + # Question marks are not valid file name parts + # on Windows platforms. Ignore this error message. + /\QCan't find file: '.\test\????????.frm'\E/ or # Special case, made as specific as possible, for: # Bug #28436: Incorrect position in SHOW BINLOG EVENTS causes # server coredump From aeddf24a2f100aaef22ec807fce3f11edb9be70b Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 20 Jun 2007 14:00:28 +0200 Subject: [PATCH 03/27] configure.in: Added --with-system-type= and --with-machine-type= options, to be able to override the one detected, for --version strings field.cc, field.h, listener.cc: C++ compatibility change for IBM VisualAge 6 and i5/OS configure.in: Added --with-system-type= and --with-machine-type= options, to be able to override the one detected, for --version strings server-tools/instance-manager/listener.cc: C++ compatibility change for IBM VisualAge 6 and i5/OS sql/field.cc: C++ compatibility change for IBM VisualAge 6 and i5/OS sql/field.h: C++ compatibility change for IBM VisualAge 6 and i5/OS --- configure.in | 16 ++++++++++++---- server-tools/instance-manager/listener.cc | 4 +++- sql/field.cc | 1 + sql/field.h | 2 +- 4 files changed, 17 insertions(+), 6 deletions(-) diff --git a/configure.in b/configure.in index e7e9aa58c9b..6cf8dbd4e47 100644 --- a/configure.in +++ b/configure.in @@ -100,14 +100,22 @@ AC_DEFINE_UNQUOTED([NDB_VERSION_STATUS], ["$NDB_VERSION_STATUS"], # Canonicalize the configuration name. -SYSTEM_TYPE="$host_vendor-$host_os" -MACHINE_TYPE="$host_cpu" + +# Check whether --with-system-type or --without-system-type was given. +AC_ARG_WITH(system-type, + [ --with-system-type Set the system type, like "sun-solaris10"], + [SYSTEM_TYPE="$withval"], + [SYSTEM_TYPE="$host_vendor-$host_os"]) +AC_ARG_WITH(machine-type, + [ --with-machine-type Set the machine type, like "powerpc"], + [MACHINE_TYPE="$withval"], + [MACHINE_TYPE="$host_cpu"]) AC_SUBST(SYSTEM_TYPE) AC_DEFINE_UNQUOTED([SYSTEM_TYPE], ["$SYSTEM_TYPE"], - [Name of system, eg solaris]) + [Name of system, eg sun-solaris]) AC_SUBST(MACHINE_TYPE) AC_DEFINE_UNQUOTED([MACHINE_TYPE], ["$MACHINE_TYPE"], - [Machine type name, eg sun10]) + [Machine type name, eg sparc]) # Detect intel x86 like processor BASE_MACHINE_TYPE=$MACHINE_TYPE diff --git a/server-tools/instance-manager/listener.cc b/server-tools/instance-manager/listener.cc index a055d98656c..a950ecf4ed3 100644 --- a/server-tools/instance-manager/listener.cc +++ b/server-tools/instance-manager/listener.cc @@ -67,7 +67,7 @@ public: ~Listener_thread(); void run(); private: - static const int LISTEN_BACK_LOG_SIZE= 5; /* standard backlog size */ + static const int LISTEN_BACK_LOG_SIZE; ulong total_connection_count; Thread_info thread_info; @@ -80,6 +80,8 @@ private: int create_unix_socket(struct sockaddr_un &unix_socket_address); }; +const int Listener_thread::LISTEN_BACK_LOG_SIZE = 5; /* standard backlog size */ + Listener_thread::Listener_thread(const Listener_thread_args &args) : Listener_thread_args(args.thread_registry, args.options, args.user_map, diff --git a/sql/field.cc b/sql/field.cc index c8c6014b92c..87f1a815e24 100644 --- a/sql/field.cc +++ b/sql/field.cc @@ -6267,6 +6267,7 @@ Field *Field_string::new_field(MEM_ROOT *root, struct st_table *new_table, is 2. ****************************************************************************/ +const uint Field_varstring::MAX_SIZE= UINT_MAX16; int Field_varstring::store(const char *from,uint length,CHARSET_INFO *cs) { diff --git a/sql/field.h b/sql/field.h index fb6534b7b55..fbf402ab5c3 100644 --- a/sql/field.h +++ b/sql/field.h @@ -1116,7 +1116,7 @@ public: The maximum space available in a Field_varstring, in bytes. See length_bytes. */ - static const uint MAX_SIZE= UINT_MAX16; + static const uint MAX_SIZE; /* Store number of bytes used to store length (1 or 2) */ uint32 length_bytes; Field_varstring(char *ptr_arg, From 9b8b0000cea134136d5a097629a792da593e35e0 Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 20 Jun 2007 19:22:27 +0300 Subject: [PATCH 04/27] Allow multiple calls to mysql_server_end() (Part of fix for Bug#25621 Error in my_thread_global_end(): 1 threads didn't exit) Give correct error message if InnoDB table is not found (This allows us to drop a an innodb table that is not in the InnoDB registery) BitKeeper/etc/ignore: added include/abi_check libmysql/libmysql.c: Allow multiple calls to mysql_server_end() (Part of fix for Bug#25621 Error in my_thread_global_end(): 1 threads didn't exit) mysql-test/r/innodb_mysql.result: Test case for drop of table that only has a .frm file mysql-test/t/innodb_mysql.test: Test case for drop of table that only has a .frm file sql/ha_innodb.cc: Give correct error message if InnoDB table is not found. (This allows us to drop a an innodb table that is not in the InnoDB registery) --- .bzrignore | 3 +++ libmysql/libmysql.c | 15 +++++++++++++++ mysql-test/r/innodb_mysql.result | 8 ++++++++ mysql-test/t/innodb_mysql.test | 14 ++++++++++++++ sql/ha_innodb.cc | 2 +- 5 files changed, 41 insertions(+), 1 deletion(-) diff --git a/.bzrignore b/.bzrignore index 8c632f8f890..e7a7a1c27dc 100644 --- a/.bzrignore +++ b/.bzrignore @@ -1341,3 +1341,6 @@ win/vs71cache.txt win/vs8cache.txt zlib/*.ds? zlib/*.vcproj +debian/control +debian/defs.mk +include/abi_check diff --git a/libmysql/libmysql.c b/libmysql/libmysql.c index e426d2c549e..121167763ed 100644 --- a/libmysql/libmysql.c +++ b/libmysql/libmysql.c @@ -168,8 +168,23 @@ int STDCALL mysql_server_init(int argc __attribute__((unused)), } +/* + Free all memory and resources used by the client library + + NOTES + When calling this there should not be any other threads using + the library. + + To make things simpler when used with windows dll's (which calls this + function automaticly), it's safe to call this function multiple times. +*/ + + void STDCALL mysql_server_end() { + if (!mysql_client_init) + return; + #ifdef EMBEDDED_LIBRARY end_embedded_server(); #endif diff --git a/mysql-test/r/innodb_mysql.result b/mysql-test/r/innodb_mysql.result index 34eb831e7db..4720c7c2e2e 100644 --- a/mysql-test/r/innodb_mysql.result +++ b/mysql-test/r/innodb_mysql.result @@ -625,4 +625,12 @@ t1 CREATE TABLE `t1` ( `a` int(11) default NULL ) ENGINE=InnoDB DEFAULT CHARSET=latin1 COMMENT='123' drop table t1; +create table t1 (a int) engine=innodb; +select * from t2; +ERROR 42S02: Table 'test.t2' doesn't exist +drop table t1; +drop table t2; +ERROR 42S02: Unknown table 't2' +create table t2 (a int); +drop table t2; End of 5.0 tests diff --git a/mysql-test/t/innodb_mysql.test b/mysql-test/t/innodb_mysql.test index e6d94fe1627..578a81f355e 100644 --- a/mysql-test/t/innodb_mysql.test +++ b/mysql-test/t/innodb_mysql.test @@ -605,4 +605,18 @@ alter table t1 comment '123'; show create table t1; drop table t1; +# +# Test bug when trying to drop data file which no InnoDB directory entry +# + +create table t1 (a int) engine=innodb; +copy_file $MYSQLTEST_VARDIR/master-data/test/t1.frm $MYSQLTEST_VARDIR/master-data/test/t2.frm; +--error 1146 +select * from t2; +drop table t1; +--error 1051 +drop table t2; +create table t2 (a int); +drop table t2; + --echo End of 5.0 tests diff --git a/sql/ha_innodb.cc b/sql/ha_innodb.cc index 455c0968050..a3676bd7e1b 100644 --- a/sql/ha_innodb.cc +++ b/sql/ha_innodb.cc @@ -504,7 +504,7 @@ convert_error_code_to_mysql( } else if (error == (int) DB_TABLE_NOT_FOUND) { - return(HA_ERR_KEY_NOT_FOUND); + return(HA_ERR_NO_SUCH_TABLE); } else if (error == (int) DB_TOO_BIG_RECORD) { From f8034d36ba5670e72374d61ca4901a71adbd6d9f Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 21 Jun 2007 08:58:39 +0200 Subject: [PATCH 05/27] Steal part of fix for bug#25621 from monty for 5.0.44. libmysql/libmysql.c: mysql_server_end() can be called multiple times. --- libmysql/libmysql.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/libmysql/libmysql.c b/libmysql/libmysql.c index e426d2c549e..121167763ed 100644 --- a/libmysql/libmysql.c +++ b/libmysql/libmysql.c @@ -168,8 +168,23 @@ int STDCALL mysql_server_init(int argc __attribute__((unused)), } +/* + Free all memory and resources used by the client library + + NOTES + When calling this there should not be any other threads using + the library. + + To make things simpler when used with windows dll's (which calls this + function automaticly), it's safe to call this function multiple times. +*/ + + void STDCALL mysql_server_end() { + if (!mysql_client_init) + return; + #ifdef EMBEDDED_LIBRARY end_embedded_server(); #endif From b3b8d5165d76de270532120dd8ce2a216308c0bd Mon Sep 17 00:00:00 2001 From: unknown Date: Sun, 24 Jun 2007 19:44:54 +0500 Subject: [PATCH 06/27] BUG#15787 - MySQL crashes when archive table exceeds 2GB Max compressed file size was calculated incorretly causing server crash on INSERT. With this patch we use proper max file size provided by zlib. Affects 5.0 only. sql/ha_archive.cc: When calculating max compressed file size, use the real offset size that is provided by zlib, instead of sizeof(z_off_t), which may be different from actual offset size. When we're about to write and the data file is almost full flush gzio buffer to get accurate real file size. mysql-test/r/archive-big.result: New BitKeeper file ``mysql-test/r/archive-big.result'' mysql-test/t/archive-big.test: New BitKeeper file ``mysql-test/t/archive-big.test'' --- mysql-test/r/archive-big.result | 19 +++++++++++++++++++ mysql-test/t/archive-big.test | 25 +++++++++++++++++++++++++ sql/ha_archive.cc | 3 ++- 3 files changed, 46 insertions(+), 1 deletion(-) create mode 100644 mysql-test/r/archive-big.result create mode 100644 mysql-test/t/archive-big.test diff --git a/mysql-test/r/archive-big.result b/mysql-test/r/archive-big.result new file mode 100644 index 00000000000..7dbdb490017 --- /dev/null +++ b/mysql-test/r/archive-big.result @@ -0,0 +1,19 @@ +CREATE TABLE t1(a BLOB) ENGINE=ARCHIVE; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +DROP TABLE t1; diff --git a/mysql-test/t/archive-big.test b/mysql-test/t/archive-big.test new file mode 100644 index 00000000000..414b689b180 --- /dev/null +++ b/mysql-test/t/archive-big.test @@ -0,0 +1,25 @@ +--source include/big_test.inc +--source include/have_arch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A*Ho$S]^Bl(n(h`0a%(:/t/\"X\"4$PP%]2u+fK&p3EEf]\"(@LAA`H%w\\E$w_VoT7Pnc\'1\\ca?Si<*V\\Q^jzQ^j\"Y\'M7ctIJt7KXZ>aXsdwRpb!l1DGuF8&L8kA1u-ov,eEdQHTQz=W&N=\'C`BdWg+2ZW*b:59^X\"5)eQDAXy\'Fm\"NLpx4-$hjb1b)9\'PEJ&vRpg5h;)TU37YD&+F_6,p&Yws^[2!J:%@Y\'L/CEo/2I^$-THJzVy.d=?aUd!fid;419i2U*P>$3rpbx]G.G])Gn\"ONw=^I1TP\\_L?88PkT@%/^uW35MiR>vg&uOe9%H\"fi_%/\\k,->2\"L@=P_m2FN8e#o7X@n;mA6,r/\'n*r4B3sw$9C&1c);.px3(ha1e9&M:r_bQPzF(.M#\\5+q-yOZW*`3pkKpzY+_,QoA0e=9G<69Y<[0omWM[dkmd4kKq#H,=2\"LA@];IBL:x\"/b.TFAS`l(o*s8Qsw#838^Z,b6!>UsnP&bJ*+9#:>hyO[\\CuOe9%FwQiEUaip\"DtJM(wO_rHM/=(HvH@G&$\"wabJ+1U@{u``EtB*FcHxP`w\\H3bx`Wsbq:bf_-UPog:\'M8kA:AtS#I.FXk8j=,`*D]1ppb!m5S*nw6=oC<@l-1Lnm[^J:{0kYY9LVNb,Jq(a>KCL9se&zhwH;0x>c_6*jfBS_hov,hUQt\"deSOpn[[CsHGkk\\l3Mmg>;MS?!\"&7\'Xk<\"1kXV)]*M/;y&.e@I1UA$)APP&'); +--enable_query_log +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +INSERT INTO t1 SELECT * FROM t1; +--error 0,1114 +INSERT INTO t1 SELECT * FROM t1; +DROP TABLE t1; diff --git a/sql/ha_archive.cc b/sql/ha_archive.cc index e2a2211259f..6e18f2e1e01 100644 --- a/sql/ha_archive.cc +++ b/sql/ha_archive.cc @@ -205,7 +205,7 @@ bool archive_db_init() else { zoffset_size= 2 << ((zlibCompileFlags() >> 6) & 3); - switch (sizeof(z_off_t)) { + switch (zoffset_size) { case 2: max_zfile_size= INT_MAX16; break; @@ -676,6 +676,7 @@ int ha_archive::real_write_row(byte *buf, gzFile writer) total_row_length+= ((Field_blob*) table->field[*ptr])->get_length(); if (share->approx_file_size > max_zfile_size - total_row_length) { + gzflush(writer, Z_SYNC_FLUSH); info(HA_STATUS_TIME); share->approx_file_size= (ulong) data_file_length; if (share->approx_file_size > max_zfile_size - total_row_length) From b2de7a6ee6fa37805d9066ed92ca831499902d12 Mon Sep 17 00:00:00 2001 From: unknown Date: Mon, 25 Jun 2007 14:42:35 +0500 Subject: [PATCH 07/27] BUG#28026 - Falcon: crash if partitions and select for update Assertion failure may happen with falcon + partition + select for update. This may affect other engines as well. Though assertion failure is fixed with this patch, falcon still deadlocks when running falcon_bug_28026.test. sql/ha_partition.cc: In case rnd_next fails, we must call ha_rnd_end. This is done conditionally (NO_CURRENT_PART_ID != m_part_spec.start_part) in ha_partition::ha_rnd_end. Thus we may not reset m_part_spec.start_part in case rnd is not ended. --- sql/ha_partition.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sql/ha_partition.cc b/sql/ha_partition.cc index 0c4f3cf708f..37e42f7a850 100644 --- a/sql/ha_partition.cc +++ b/sql/ha_partition.cc @@ -3117,7 +3117,7 @@ int ha_partition::rnd_next(uchar *buf) continue; // Probably MyISAM if (result != HA_ERR_END_OF_FILE) - break; // Return error + goto end_dont_reset_start_part; // Return error /* End current partition */ late_extra_no_cache(part_id); @@ -3143,6 +3143,7 @@ int ha_partition::rnd_next(uchar *buf) end: m_part_spec.start_part= NO_CURRENT_PART_ID; +end_dont_reset_start_part: table->status= STATUS_NOT_FOUND; DBUG_RETURN(result); } From ae398d995a925e8bc2fe096f4c6fe55618a58543 Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 26 Jun 2007 13:15:43 +0200 Subject: [PATCH 08/27] Bug #29245: Bad Merge Caused Error Codes Conflict between 5.0/5.1 Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/backup.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/events_bugs.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/events_trans.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/ndb_dd_basic.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/ndb_dd_ddl.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/ndb_gis.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/ndb_row_format.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/rpl_extraCol_innodb.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/rpl_extraCol_myisam.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/rpl_incident.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/rpl_ndb_extraCol.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/rpl_row_tabledefs_2myisam.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/rpl_row_tabledefs_3innodb.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/rpl_sp.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/select.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/show_check.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/sp.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/sp_gis.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/sp_trans.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/type_timestamp.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/warnings.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/r/xml.result: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/t/grant.test: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 mysql-test/t/partition_grant.test: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 sql/mysql_priv.h: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 sql/share/errmsg.txt: Fix some error messages so that all error codes are equivalent in 5.0 and 5.1 --- mysql-test/r/backup.result | 2 +- mysql-test/r/events_bugs.result | 16 ++--- mysql-test/r/events_trans.result | 2 +- mysql-test/r/ndb_dd_basic.result | 6 +- mysql-test/r/ndb_dd_ddl.result | 2 +- mysql-test/r/ndb_gis.result | 4 +- mysql-test/r/ndb_row_format.result | 2 +- mysql-test/r/rpl_extraCol_innodb.result | 28 ++++---- mysql-test/r/rpl_extraCol_myisam.result | 28 ++++---- mysql-test/r/rpl_incident.result | 4 +- mysql-test/r/rpl_ndb_extraCol.result | 28 ++++---- mysql-test/r/rpl_row_tabledefs_2myisam.result | 16 ++--- mysql-test/r/rpl_row_tabledefs_3innodb.result | 16 ++--- mysql-test/r/rpl_sp.result | 2 +- mysql-test/r/select.result | 2 +- mysql-test/r/show_check.result | 2 +- mysql-test/r/sp.result | 8 +-- mysql-test/r/sp_gis.result | 4 +- mysql-test/r/sp_trans.result | 2 +- mysql-test/r/type_timestamp.result | 14 ++-- mysql-test/r/warnings.result | 2 +- mysql-test/r/xml.result | 18 ++--- mysql-test/t/grant.test | 2 +- mysql-test/t/partition_grant.test | 4 +- sql/mysql_priv.h | 2 +- sql/share/errmsg.txt | 68 +++++++++++-------- 26 files changed, 146 insertions(+), 138 deletions(-) diff --git a/mysql-test/r/backup.result b/mysql-test/r/backup.result index 154b577e61f..4de599f3af7 100644 --- a/mysql-test/r/backup.result +++ b/mysql-test/r/backup.result @@ -36,7 +36,7 @@ restore table t1 from '../bogus'; Table Op Msg_type Msg_text t1 restore error Failed copying .frm file Warnings: -Warning 1543 The syntax 'RESTORE TABLE' is deprecated and will be removed in MySQL 5.2. Please use MySQL Administrator (mysqldump, mysql) instead +Warning 1287 The syntax 'RESTORE TABLE' is deprecated and will be removed in MySQL 5.2. Please use MySQL Administrator (mysqldump, mysql) instead Error 29 File 'MYSQLTEST_VARDIR/bogus/t1.frm' not found (Errcode: X) restore table t1 from '../tmp'; Table Op Msg_type Msg_text diff --git a/mysql-test/r/events_bugs.result b/mysql-test/r/events_bugs.result index fae530f556b..541502607c1 100644 --- a/mysql-test/r/events_bugs.result +++ b/mysql-test/r/events_bugs.result @@ -31,7 +31,7 @@ create event e_55 on schedule at 10000101000000 do drop table t; ERROR HY000: Incorrect AT value: '10000101000000' create event e_55 on schedule at 20000101000000 do drop table t; Warnings: -Note 1584 Event execution time is in the past and ON COMPLETION NOT PRESERVE is set. Event has not been created +Note 1585 Event execution time is in the past and ON COMPLETION NOT PRESERVE is set. Event has not been created show events; Db Name Definer Time zone Type Execute at Interval value Interval field Starts Ends Status Originator create event e_55 on schedule at 20200101000000 starts 10000101000000 do drop table t; @@ -457,22 +457,22 @@ CREATE EVENT e4 ON SCHEDULE EVERY 1 HOUR STARTS '1999-01-01 00:00:00' DO SELECT 1; Warnings: -Note 1584 Event execution time is in the past and ON COMPLETION NOT PRESERVE is set. Event has not been created +Note 1585 Event execution time is in the past and ON COMPLETION NOT PRESERVE is set. Event has not been created CREATE EVENT e4 ON SCHEDULE EVERY 1 HOUR STARTS '1999-01-01 00:00:00' ENDS '1999-01-02 00:00:00' DISABLE DO SELECT 1; Warnings: -Note 1584 Event execution time is in the past and ON COMPLETION NOT PRESERVE is set. Event has not been created +Note 1585 Event execution time is in the past and ON COMPLETION NOT PRESERVE is set. Event has not been created CREATE EVENT e4 ON SCHEDULE AT '1999-01-01 00:00:00' DO SELECT 1; Warnings: -Note 1584 Event execution time is in the past and ON COMPLETION NOT PRESERVE is set. Event has not been created +Note 1585 Event execution time is in the past and ON COMPLETION NOT PRESERVE is set. Event has not been created CREATE EVENT e4 ON SCHEDULE AT '1999-01-01 00:00:00' DISABLE DO SELECT 1; Warnings: -Note 1584 Event execution time is in the past and ON COMPLETION NOT PRESERVE is set. Event has not been created +Note 1585 Event execution time is in the past and ON COMPLETION NOT PRESERVE is set. Event has not been created SHOW EVENTS; Db Name Definer Time zone Type Execute at Interval value Interval field Starts Ends Status Originator events_test e1 root@localhost +05:00 RECURRING NULL 1 DAY 2006-01-01 00:00:00 NULL ENABLED 1 @@ -482,19 +482,19 @@ The following should succeed giving a warning. ALTER EVENT e1 ON SCHEDULE EVERY 1 HOUR STARTS '1999-01-01 00:00:00' ENDS '1999-01-02 00:00:00' ON COMPLETION PRESERVE; Warnings: -Note 1533 Event execution time is in the past. Event has been disabled +Note 1541 Event execution time is in the past. Event has been disabled CREATE EVENT e4 ON SCHEDULE EVERY 1 HOUR STARTS '1999-01-01 00:00:00' ENDS '1999-01-02 00:00:00' ON COMPLETION PRESERVE DO SELECT 1; Warnings: -Note 1533 Event execution time is in the past. Event has been disabled +Note 1541 Event execution time is in the past. Event has been disabled CREATE EVENT e5 ON SCHEDULE AT '1999-01-01 00:00:00' ON COMPLETION PRESERVE DO SELECT 1; Warnings: -Note 1533 Event execution time is in the past. Event has been disabled +Note 1541 Event execution time is in the past. Event has been disabled The following should succeed without warnings. ALTER EVENT e2 ON SCHEDULE EVERY 1 HOUR STARTS '1999-01-01 00:00:00'; ALTER EVENT e3 ON SCHEDULE EVERY 1 HOUR STARTS '1999-01-01 00:00:00' diff --git a/mysql-test/r/events_trans.result b/mysql-test/r/events_trans.result index a9829db0c61..1f87bcea68e 100644 --- a/mysql-test/r/events_trans.result +++ b/mysql-test/r/events_trans.result @@ -63,7 +63,7 @@ begin work; insert into t1 (a) values ("OK: create event if not exists"); create event if not exists e1 on schedule every 2 day do select 2; Warnings: -Note 1526 Event 'e1' already exists +Note 1534 Event 'e1' already exists rollback work; select * from t1; a diff --git a/mysql-test/r/ndb_dd_basic.result b/mysql-test/r/ndb_dd_basic.result index 7aeb156869b..bc1762ce407 100644 --- a/mysql-test/r/ndb_dd_basic.result +++ b/mysql-test/r/ndb_dd_basic.result @@ -5,20 +5,20 @@ INITIAL_SIZE 16M UNDO_BUFFER_SIZE = 1M ENGINE=MYISAM; Warnings: -Error 1466 Table storage engine 'MyISAM' does not support the create option 'TABLESPACE or LOGFILE GROUP' +Error 1475 Table storage engine 'MyISAM' does not support the create option 'TABLESPACE or LOGFILE GROUP' ALTER LOGFILE GROUP lg1 ADD UNDOFILE 'undofile02.dat' INITIAL_SIZE = 4M ENGINE=XYZ; Warnings: Warning 1286 Unknown table engine 'XYZ' -Error 1466 Table storage engine 'MyISAM' does not support the create option 'TABLESPACE or LOGFILE GROUP' +Error 1475 Table storage engine 'MyISAM' does not support the create option 'TABLESPACE or LOGFILE GROUP' CREATE TABLESPACE ts1 ADD DATAFILE 'datafile.dat' USE LOGFILE GROUP lg1 INITIAL_SIZE 12M; Warnings: -Error 1466 Table storage engine 'MyISAM' does not support the create option 'TABLESPACE or LOGFILE GROUP' +Error 1475 Table storage engine 'MyISAM' does not support the create option 'TABLESPACE or LOGFILE GROUP' set storage_engine=ndb; CREATE LOGFILE GROUP lg1 ADD UNDOFILE 'undofile.dat' diff --git a/mysql-test/r/ndb_dd_ddl.result b/mysql-test/r/ndb_dd_ddl.result index 67857d39ab6..55f1f56fd0c 100644 --- a/mysql-test/r/ndb_dd_ddl.result +++ b/mysql-test/r/ndb_dd_ddl.result @@ -16,7 +16,7 @@ ERROR HY000: Failed to create LOGFILE GROUP SHOW WARNINGS; Level Code Message Error 1296 Got error 1514 'Currently there is a limit of one logfile group' from NDB -Error 1516 Failed to create LOGFILE GROUP +Error 1525 Failed to create LOGFILE GROUP CREATE LOGFILE GROUP lg1 ADD UNDOFILE 'undofile.dat' INITIAL_SIZE 1M diff --git a/mysql-test/r/ndb_gis.result b/mysql-test/r/ndb_gis.result index 3af7b71d72d..54f1fc23489 100644 --- a/mysql-test/r/ndb_gis.result +++ b/mysql-test/r/ndb_gis.result @@ -463,7 +463,7 @@ drop table t1; End of 4.1 tests CREATE TABLE t1 (name VARCHAR(100), square GEOMETRY); Warnings: -Error 1466 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK' +Error 1475 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK' INSERT INTO t1 VALUES("center", GeomFromText('POLYGON (( 0 0, 0 2, 2 2, 2 0, 0 0))')); INSERT INTO t1 VALUES("small", GeomFromText('POLYGON (( 0 0, 0 1, 1 1, 1 0, 0 0))')); INSERT INTO t1 VALUES("big", GeomFromText('POLYGON (( 0 0, 0 3, 3 3, 3 0, 0 0))')); @@ -1013,7 +1013,7 @@ drop table t1; End of 4.1 tests CREATE TABLE t1 (name VARCHAR(100), square GEOMETRY); Warnings: -Error 1466 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK' +Error 1475 Table storage engine 'ndbcluster' does not support the create option 'Binlog of table with BLOB attribute and no PK' INSERT INTO t1 VALUES("center", GeomFromText('POLYGON (( 0 0, 0 2, 2 2, 2 0, 0 0))')); INSERT INTO t1 VALUES("small", GeomFromText('POLYGON (( 0 0, 0 1, 1 1, 1 0, 0 0))')); INSERT INTO t1 VALUES("big", GeomFromText('POLYGON (( 0 0, 0 3, 3 3, 3 0, 0 0))')); diff --git a/mysql-test/r/ndb_row_format.result b/mysql-test/r/ndb_row_format.result index ae165d87c5c..37c239986f6 100644 --- a/mysql-test/r/ndb_row_format.result +++ b/mysql-test/r/ndb_row_format.result @@ -8,7 +8,7 @@ ENGINE=NDB; ERROR HY000: Can't create table 'test.t1' (errno: 138) SHOW WARNINGS; Level Code Message -Error 1466 Table storage engine 'ndbcluster' does not support the create option 'Row format FIXED incompatible with variable sized attribute' +Error 1475 Table storage engine 'ndbcluster' does not support the create option 'Row format FIXED incompatible with variable sized attribute' Error 1005 Can't create table 'test.t1' (errno: 138) CREATE TABLE t1 ( a INT KEY, diff --git a/mysql-test/r/rpl_extraCol_innodb.result b/mysql-test/r/rpl_extraCol_innodb.result index cfce12b594e..c3159987b30 100644 --- a/mysql-test/r/rpl_extraCol_innodb.result +++ b/mysql-test/r/rpl_extraCol_innodb.result @@ -72,7 +72,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 252, test.t3 has type 3 Skip_Counter 0 Exec_Master_Log_Pos # @@ -90,7 +90,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 252, test.t3 has type 3 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -134,7 +134,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 246, test.t4 has type 3 Skip_Counter 0 Exec_Master_Log_Pos # @@ -152,7 +152,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 246, test.t4 has type 3 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -196,7 +196,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 5 type mismatch - received type 4, test.t5 has type 246 Skip_Counter 0 Exec_Master_Log_Pos # @@ -214,7 +214,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 5 type mismatch - received type 4, test.t5 has type 246 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -257,7 +257,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 3 type mismatch - received type 16, test.t6 has type 3 Skip_Counter 0 Exec_Master_Log_Pos # @@ -275,7 +275,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 3 type mismatch - received type 16, test.t6 has type 3 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=3; *** Drop t6 *** @@ -369,7 +369,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 254, test.t10 has type 5 Skip_Counter 0 Exec_Master_Log_Pos # @@ -387,7 +387,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 254, test.t10 has type 5 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -430,7 +430,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 15, test.t11 has type 252 Skip_Counter 0 Exec_Master_Log_Pos # @@ -448,7 +448,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 15, test.t11 has type 252 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -755,7 +755,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 8, test.t17 has type 2 Skip_Counter 0 Exec_Master_Log_Pos # @@ -773,7 +773,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 8, test.t17 has type 2 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; diff --git a/mysql-test/r/rpl_extraCol_myisam.result b/mysql-test/r/rpl_extraCol_myisam.result index b250911368c..9d6c3ed5d33 100644 --- a/mysql-test/r/rpl_extraCol_myisam.result +++ b/mysql-test/r/rpl_extraCol_myisam.result @@ -72,7 +72,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 252, test.t3 has type 3 Skip_Counter 0 Exec_Master_Log_Pos # @@ -90,7 +90,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 252, test.t3 has type 3 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -134,7 +134,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 246, test.t4 has type 3 Skip_Counter 0 Exec_Master_Log_Pos # @@ -152,7 +152,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 246, test.t4 has type 3 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -196,7 +196,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 5 type mismatch - received type 4, test.t5 has type 246 Skip_Counter 0 Exec_Master_Log_Pos # @@ -214,7 +214,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 5 type mismatch - received type 4, test.t5 has type 246 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -257,7 +257,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 3 type mismatch - received type 16, test.t6 has type 3 Skip_Counter 0 Exec_Master_Log_Pos # @@ -275,7 +275,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 3 type mismatch - received type 16, test.t6 has type 3 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=3; *** Drop t6 *** @@ -369,7 +369,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 254, test.t10 has type 5 Skip_Counter 0 Exec_Master_Log_Pos # @@ -387,7 +387,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 254, test.t10 has type 5 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -430,7 +430,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 15, test.t11 has type 252 Skip_Counter 0 Exec_Master_Log_Pos # @@ -448,7 +448,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 15, test.t11 has type 252 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -755,7 +755,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 8, test.t17 has type 2 Skip_Counter 0 Exec_Master_Log_Pos # @@ -773,7 +773,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 8, test.t17 has type 2 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; diff --git a/mysql-test/r/rpl_incident.result b/mysql-test/r/rpl_incident.result index 9d82798b5f4..84fd9c0ee4f 100644 --- a/mysql-test/r/rpl_incident.result +++ b/mysql-test/r/rpl_incident.result @@ -44,7 +44,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1586 +Last_Errno 1587 Last_Error The incident LOST_EVENTS occured on the master. Message: Skip_Counter 0 Exec_Master_Log_Pos # @@ -62,7 +62,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1586 +Last_SQL_Errno 1587 Last_SQL_Error The incident LOST_EVENTS occured on the master. Message: SET GLOBAL SQL_SLAVE_SKIP_COUNTER=1; START SLAVE; diff --git a/mysql-test/r/rpl_ndb_extraCol.result b/mysql-test/r/rpl_ndb_extraCol.result index 5afc9c1db77..edb4dfbf392 100644 --- a/mysql-test/r/rpl_ndb_extraCol.result +++ b/mysql-test/r/rpl_ndb_extraCol.result @@ -72,7 +72,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 252, test.t3 has type 3 Skip_Counter 0 Exec_Master_Log_Pos # @@ -90,7 +90,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 252, test.t3 has type 3 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -134,7 +134,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 246, test.t4 has type 3 Skip_Counter 0 Exec_Master_Log_Pos # @@ -152,7 +152,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 246, test.t4 has type 3 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -196,7 +196,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 5 type mismatch - received type 4, test.t5 has type 246 Skip_Counter 0 Exec_Master_Log_Pos # @@ -214,7 +214,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 5 type mismatch - received type 4, test.t5 has type 246 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -257,7 +257,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 3 type mismatch - received type 16, test.t6 has type 3 Skip_Counter 0 Exec_Master_Log_Pos # @@ -275,7 +275,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 3 type mismatch - received type 16, test.t6 has type 3 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=3; *** Drop t6 *** @@ -369,7 +369,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 254, test.t10 has type 5 Skip_Counter 0 Exec_Master_Log_Pos # @@ -387,7 +387,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 254, test.t10 has type 5 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -430,7 +430,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 15, test.t11 has type 252 Skip_Counter 0 Exec_Master_Log_Pos # @@ -448,7 +448,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 15, test.t11 has type 252 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -756,7 +756,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 8, test.t17 has type 2 Skip_Counter 0 Exec_Master_Log_Pos # @@ -774,7 +774,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 8, test.t17 has type 2 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; diff --git a/mysql-test/r/rpl_row_tabledefs_2myisam.result b/mysql-test/r/rpl_row_tabledefs_2myisam.result index d8ff1907e28..eb0c1cdc81d 100644 --- a/mysql-test/r/rpl_row_tabledefs_2myisam.result +++ b/mysql-test/r/rpl_row_tabledefs_2myisam.result @@ -165,7 +165,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Table width mismatch - received 2 columns, test.t2 has 1 columns Skip_Counter 0 Exec_Master_Log_Pos # @@ -183,7 +183,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Table width mismatch - received 2 columns, test.t2 has 1 columns SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -208,7 +208,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 3, test.t4 has type 4 Skip_Counter 0 Exec_Master_Log_Pos # @@ -226,7 +226,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 3, test.t4 has type 4 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -251,7 +251,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 1 type mismatch - received type 3, test.t5 has type 4 Skip_Counter 0 Exec_Master_Log_Pos # @@ -269,7 +269,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 1 type mismatch - received type 3, test.t5 has type 4 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -294,7 +294,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 3, test.t6 has type 4 Skip_Counter 0 Exec_Master_Log_Pos # @@ -312,7 +312,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 3, test.t6 has type 4 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; diff --git a/mysql-test/r/rpl_row_tabledefs_3innodb.result b/mysql-test/r/rpl_row_tabledefs_3innodb.result index 17c591327c2..287ab072e3d 100644 --- a/mysql-test/r/rpl_row_tabledefs_3innodb.result +++ b/mysql-test/r/rpl_row_tabledefs_3innodb.result @@ -165,7 +165,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Table width mismatch - received 2 columns, test.t2 has 1 columns Skip_Counter 0 Exec_Master_Log_Pos # @@ -183,7 +183,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Table width mismatch - received 2 columns, test.t2 has 1 columns SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -208,7 +208,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 3, test.t4 has type 4 Skip_Counter 0 Exec_Master_Log_Pos # @@ -226,7 +226,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 0 type mismatch - received type 3, test.t4 has type 4 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -251,7 +251,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 1 type mismatch - received type 3, test.t5 has type 4 Skip_Counter 0 Exec_Master_Log_Pos # @@ -269,7 +269,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 1 type mismatch - received type 3, test.t5 has type 4 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; @@ -294,7 +294,7 @@ Replicate_Do_Table Replicate_Ignore_Table Replicate_Wild_Do_Table Replicate_Wild_Ignore_Table -Last_Errno 1523 +Last_Errno 1532 Last_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 3, test.t6 has type 4 Skip_Counter 0 Exec_Master_Log_Pos # @@ -312,7 +312,7 @@ Seconds_Behind_Master # Master_SSL_Verify_Server_Cert No Last_IO_Errno 0 Last_IO_Error -Last_SQL_Errno 1523 +Last_SQL_Errno 1532 Last_SQL_Error Table definition on master and slave does not match: Column 2 type mismatch - received type 3, test.t6 has type 4 SET GLOBAL SQL_SLAVE_SKIP_COUNTER=2; START SLAVE; diff --git a/mysql-test/r/rpl_sp.result b/mysql-test/r/rpl_sp.result index 208c46c5fab..323926e2a9e 100644 --- a/mysql-test/r/rpl_sp.result +++ b/mysql-test/r/rpl_sp.result @@ -181,7 +181,7 @@ end| ERROR HY000: You do not have the SUPER privilege and binary logging is enabled (you *might* want to use the less safe log_bin_trust_function_creators variable) set global log_bin_trust_routine_creators=1; Warnings: -Warning 1543 The syntax 'log_bin_trust_routine_creators' is deprecated and will be removed in MySQL 5.2. Please use 'log_bin_trust_function_creators' instead +Warning 1287 The syntax 'log_bin_trust_routine_creators' is deprecated and will be removed in MySQL 5.2. Please use 'log_bin_trust_function_creators' instead set global log_bin_trust_function_creators=0; set global log_bin_trust_function_creators=1; set global log_bin_trust_function_creators=1; diff --git a/mysql-test/r/select.result b/mysql-test/r/select.result index 92ceca2162f..a148d1029df 100644 --- a/mysql-test/r/select.result +++ b/mysql-test/r/select.result @@ -3492,7 +3492,7 @@ SELECT 0.9888889889 * 1.011111411911; 0.9998769417899202067879 prepare stmt from 'select 1 as " a "'; Warnings: -Warning 1548 Leading spaces are removed from name ' a ' +Warning 1466 Leading spaces are removed from name ' a ' execute stmt; a 1 diff --git a/mysql-test/r/show_check.result b/mysql-test/r/show_check.result index 66cd929ee05..c07aadff042 100644 --- a/mysql-test/r/show_check.result +++ b/mysql-test/r/show_check.result @@ -712,7 +712,7 @@ drop database mysqltest; show full plugin; show warnings; Level Code Message -Warning 1543 The syntax 'SHOW PLUGIN' is deprecated and will be removed in MySQL 5.2. Please use 'SHOW PLUGINS' instead +Warning 1287 The syntax 'SHOW PLUGIN' is deprecated and will be removed in MySQL 5.2. Please use 'SHOW PLUGINS' instead show plugin; show plugins; create database `mysqlttest\1`; diff --git a/mysql-test/r/sp.result b/mysql-test/r/sp.result index 98d73f7536c..558daec5c30 100644 --- a/mysql-test/r/sp.result +++ b/mysql-test/r/sp.result @@ -5665,7 +5665,7 @@ drop function if exists pi; create function pi() returns varchar(50) return "pie, my favorite desert."; Warnings: -Note 1581 This function 'pi' has the same name as a native function +Note 1582 This function 'pi' has the same name as a native function SET @save_sql_mode=@@sql_mode; SET SQL_MODE='IGNORE_SPACE'; select pi(), pi (); @@ -5714,15 +5714,15 @@ use test; create function `database`() returns varchar(50) return "Stored function database"; Warnings: -Note 1581 This function 'database' has the same name as a native function +Note 1582 This function 'database' has the same name as a native function create function `current_user`() returns varchar(50) return "Stored function current_user"; Warnings: -Note 1581 This function 'current_user' has the same name as a native function +Note 1582 This function 'current_user' has the same name as a native function create function md5(x varchar(50)) returns varchar(50) return "Stored function md5"; Warnings: -Note 1581 This function 'md5' has the same name as a native function +Note 1582 This function 'md5' has the same name as a native function SET SQL_MODE='IGNORE_SPACE'; select database(), database (); database() database () diff --git a/mysql-test/r/sp_gis.result b/mysql-test/r/sp_gis.result index fddf2a6bc18..b4fe0872d64 100644 --- a/mysql-test/r/sp_gis.result +++ b/mysql-test/r/sp_gis.result @@ -7,11 +7,11 @@ return 1; create function x() returns int return 2; Warnings: -Note 1581 This function 'x' has the same name as a native function +Note 1582 This function 'x' has the same name as a native function create function y() returns int return 3; Warnings: -Note 1581 This function 'y' has the same name as a native function +Note 1582 This function 'y' has the same name as a native function select a(); a() 1 diff --git a/mysql-test/r/sp_trans.result b/mysql-test/r/sp_trans.result index a0d687e565b..abd454ac907 100644 --- a/mysql-test/r/sp_trans.result +++ b/mysql-test/r/sp_trans.result @@ -535,7 +535,7 @@ use db_bug7787| CREATE PROCEDURE p1() SHOW INNODB STATUS; | Warnings: -Warning 1543 The syntax 'SHOW INNODB STATUS' is deprecated and will be removed in MySQL 5.2. Please use 'SHOW ENGINE INNODB STATUS' instead +Warning 1287 The syntax 'SHOW INNODB STATUS' is deprecated and will be removed in MySQL 5.2. Please use 'SHOW ENGINE INNODB STATUS' instead GRANT EXECUTE ON PROCEDURE p1 TO user_bug7787@localhost| DROP DATABASE db_bug7787| drop user user_bug7787@localhost| diff --git a/mysql-test/r/type_timestamp.result b/mysql-test/r/type_timestamp.result index c075a199dae..7caf7e78fe9 100644 --- a/mysql-test/r/type_timestamp.result +++ b/mysql-test/r/type_timestamp.result @@ -101,13 +101,13 @@ create table t1 (t2 timestamp(2), t4 timestamp(4), t6 timestamp(6), t8 timestamp(8), t10 timestamp(10), t12 timestamp(12), t14 timestamp(14)); Warnings: -Warning 1543 The syntax 'TIMESTAMP(2)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead -Warning 1543 The syntax 'TIMESTAMP(4)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead -Warning 1543 The syntax 'TIMESTAMP(6)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead -Warning 1543 The syntax 'TIMESTAMP(8)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead -Warning 1543 The syntax 'TIMESTAMP(10)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead -Warning 1543 The syntax 'TIMESTAMP(12)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead -Warning 1543 The syntax 'TIMESTAMP(14)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead +Warning 1287 The syntax 'TIMESTAMP(2)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead +Warning 1287 The syntax 'TIMESTAMP(4)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead +Warning 1287 The syntax 'TIMESTAMP(6)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead +Warning 1287 The syntax 'TIMESTAMP(8)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead +Warning 1287 The syntax 'TIMESTAMP(10)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead +Warning 1287 The syntax 'TIMESTAMP(12)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead +Warning 1287 The syntax 'TIMESTAMP(14)' is deprecated and will be removed in MySQL 5.2. Please use 'TIMESTAMP' instead insert t1 values (0,0,0,0,0,0,0), ("1997-12-31 23:47:59", "1997-12-31 23:47:59", "1997-12-31 23:47:59", "1997-12-31 23:47:59", "1997-12-31 23:47:59", "1997-12-31 23:47:59", diff --git a/mysql-test/r/warnings.result b/mysql-test/r/warnings.result index 01b1c77887f..2929328a9b1 100644 --- a/mysql-test/r/warnings.result +++ b/mysql-test/r/warnings.result @@ -168,7 +168,7 @@ max_error_count 10 drop table t1; set table_type=MYISAM; Warnings: -Warning 1543 The syntax 'table_type' is deprecated and will be removed in MySQL 5.2. Please use 'storage_engine' instead +Warning 1287 The syntax 'table_type' is deprecated and will be removed in MySQL 5.2. Please use 'storage_engine' instead create table t1 (a int); insert into t1 (a) values (1), (2), (3), (4), (5), (6), (7), (8), (9), (10); update t1 set a='abc'; diff --git a/mysql-test/r/xml.result b/mysql-test/r/xml.result index f71b8cadabb..95ad19a886f 100644 --- a/mysql-test/r/xml.result +++ b/mysql-test/r/xml.result @@ -647,32 +647,32 @@ select extractValue('a','/a'); extractValue('a','/a') NULL Warnings: -Warning 1513 Incorrect XML value: 'parse error at line 1 pos 5: unexpected END-OF-INPUT' +Warning 1522 Incorrect XML value: 'parse error at line 1 pos 5: unexpected END-OF-INPUT' select extractValue('a<','/a'); extractValue('a<','/a') NULL Warnings: -Warning 1513 Incorrect XML value: 'parse error at line 1 pos 6: END-OF-INPUT unexpected (ident or '/' wanted)' +Warning 1522 Incorrect XML value: 'parse error at line 1 pos 6: END-OF-INPUT unexpected (ident or '/' wanted)' select extractValue('aaaa' wanted)' +Warning 1522 Incorrect XML value: 'parse error at line 1 pos 8: END-OF-INPUT unexpected ('>' wanted)' select extractValue('a','/a'); extractValue('a','/a') NULL Warnings: -Warning 1513 Incorrect XML value: 'parse error at line 1 pos 12: '' unexpected (END-OF-INPUT wanted)' +Warning 1522 Incorrect XML value: 'parse error at line 1 pos 12: '' unexpected (END-OF-INPUT wanted)' select extractValue('a','/a'); extractValue('a','/a') NULL Warnings: -Warning 1513 Incorrect XML value: 'parse error at line 1 pos 7: '>' unexpected (ident or string wanted)' +Warning 1522 Incorrect XML value: 'parse error at line 1 pos 7: '>' unexpected (ident or string wanted)' select extractValue('1','position()'); ERROR HY000: XPATH syntax error: '' select extractValue('1','last()'); @@ -723,17 +723,17 @@ select extractValue('<01>10:39:15<02>140','//* extractValue('<01>10:39:15<02>140','//*') NULL Warnings: -Warning 1513 Incorrect XML value: 'parse error at line 1 pos 13: unknown token unexpected (ident or '/' wanted)' +Warning 1522 Incorrect XML value: 'parse error at line 1 pos 13: unknown token unexpected (ident or '/' wanted)' select extractValue('<.>test','//*'); extractValue('<.>test','//*') NULL Warnings: -Warning 1513 Incorrect XML value: 'parse error at line 1 pos 2: unknown token unexpected (ident or '/' wanted)' +Warning 1522 Incorrect XML value: 'parse error at line 1 pos 2: unknown token unexpected (ident or '/' wanted)' select extractValue('<->test','//*'); extractValue('<->test','//*') NULL Warnings: -Warning 1513 Incorrect XML value: 'parse error at line 1 pos 2: unknown token unexpected (ident or '/' wanted)' +Warning 1522 Incorrect XML value: 'parse error at line 1 pos 2: unknown token unexpected (ident or '/' wanted)' select extractValue('<:>test','//*'); extractValue('<:>test','//*') test diff --git a/mysql-test/t/grant.test b/mysql-test/t/grant.test index 17c5f1bbe8f..e33712e1ebf 100644 --- a/mysql-test/t/grant.test +++ b/mysql-test/t/grant.test @@ -1271,6 +1271,6 @@ grant select on test.* to юзер_юзер@localhost; --exec $MYSQL --default-character-set=utf8 --user=юзер_юзер -e "select user()" revoke all on test.* from юзер_юзер@localhost; drop user юзер_юзер@localhost; ---error 1573 +--error ER_WRONG_STRING_LENGTH grant select on test.* to очень_длинный_юзер@localhost; set names default; diff --git a/mysql-test/t/partition_grant.test b/mysql-test/t/partition_grant.test index 0d30ad01c7a..cf944e507fd 100644 --- a/mysql-test/t/partition_grant.test +++ b/mysql-test/t/partition_grant.test @@ -63,13 +63,13 @@ insert into t1 values (1); grant alter on mysqltest_1.* to mysqltest_1@localhost; connect (conn4,localhost,mysqltest_1,,mysqltest_1); connection conn4; ---error 1514 +--error ER_NO_PARTITION_FOR_GIVEN_VALUE alter table t1 partition by list (s1) (partition p1 values in (2)); connection default; grant select, alter on mysqltest_1.* to mysqltest_1@localhost; disconnect conn4; connect (conn5,localhost,mysqltest_1,,mysqltest_1); ---error 1514 +--error ER_NO_PARTITION_FOR_GIVEN_VALUE alter table t1 partition by list (s1) (partition p1 values in (2)); disconnect conn5; connection default; diff --git a/sql/mysql_priv.h b/sql/mysql_priv.h index 5a50b03282f..e6455a82c33 100644 --- a/sql/mysql_priv.h +++ b/sql/mysql_priv.h @@ -98,7 +98,7 @@ char* query_table_status(THD *thd,const char *db,const char *table_name); DBUG_ASSERT(strncmp(Ver, MYSQL_SERVER_VERSION, sizeof(Ver)-1) > 0); \ if (((uchar*)Thd) != NULL) \ push_warning_printf(((THD *)Thd), MYSQL_ERROR::WARN_LEVEL_WARN, \ - ER_WARN_DEPRECATED_SYNTAX, ER(ER_WARN_DEPRECATED_SYNTAX), \ + ER_WARN_DEPRECATED_SYNTAX, ER(ER_WARN_DEPRECATED_SYNTAX_WITH_VER), \ (Old), (Ver), (New)); \ else \ sql_print_warning("The syntax '%s' is deprecated and will be removed " \ diff --git a/sql/share/errmsg.txt b/sql/share/errmsg.txt index 1dde977800b..37176a04c32 100644 --- a/sql/share/errmsg.txt +++ b/sql/share/errmsg.txt @@ -1478,6 +1478,8 @@ ER_DUP_KEYNAME 42000 S1009 spa "Nombre de clave duplicado '%-.192s'" swe "Nyckelnamn '%-.192s' finns flera gånger" ukr "äÕÂÌÀÀÞÅ ¦Í'Ñ ËÌÀÞÁ '%-.192s'" +# When using this error code, please use ER(ER_DUP_ENTRY_WITH_KEY_NAME) +# for the message string. See, for example, code in handler.cc. ER_DUP_ENTRY 23000 S1009 cze "Zdvojen-Bý klíè '%-.192s' (èíslo klíèe %d)" dan "Ens værdier '%-.192s' for indeks %d" @@ -5022,7 +5024,9 @@ ER_UNKNOWN_STORAGE_ENGINE 42000 ger "Unbekannte Speicher-Engine '%s'" por "Motor de tabela desconhecido '%s'" spa "Desconocido motor de tabla '%s'" -ER_UNUSED_1 +# When using this error code, use ER(ER_WARN_DEPRECATED_SYNTAX_WITH_VER) +# for the message string. See, for example, code in mysql_priv.h. +ER_WARN_DEPRECATED_SYNTAX eng "'%s' is deprecated; use '%s' instead" ger "'%s' ist veraltet. Bitte benutzen Sie '%s'" por "'%s' é desatualizado. Use '%s' em seu lugar" @@ -5606,8 +5610,6 @@ ER_SP_RECURSION_LIMIT ER_SP_PROC_TABLE_CORRUPT eng "Failed to load routine %-.192s. The table mysql.proc is missing, corrupt, or contains bad data (internal code %d)" ger "Routine %-.192s konnte nicht geladen werden. Die Tabelle mysql.proc fehlt, ist beschädigt, oder enthält fehlerhaften Daten (interner Code: %d)" -ER_FOREIGN_SERVER_EXISTS - eng "The foreign server, %s, you are trying to create already exists." ER_SP_WRONG_NAME 42000 eng "Incorrect routine name '%-.192s'" ger "Ungültiger Routinenname '%-.192s'" @@ -5629,6 +5631,34 @@ ER_NON_GROUPING_FIELD_USED 42000 ER_TABLE_CANT_HANDLE_SPKEYS eng "The used table type doesn't support SPATIAL indexes" ger "Der verwendete Tabellentyp unterstützt keine SPATIAL-Indizes" +ER_NO_TRIGGERS_ON_SYSTEM_SCHEMA + eng "Triggers can not be created on system tables" + ger "Trigger können nicht auf Systemtabellen erzeugt werden" +ER_REMOVED_SPACES + eng "Leading spaces are removed from name '%s'" + ger "Führende Leerzeichen werden aus dem Namen '%s' entfernt" +ER_AUTOINC_READ_FAILED + eng "Failed to read auto-increment value from storage engine" + ger "Lesen des Autoincrement-Werts von der Speicher-Engine fehlgeschlagen" +ER_USERNAME + eng "user name" + ger "Benutzername" +ER_HOSTNAME + eng "host name" + ger "Hostname" +ER_WRONG_STRING_LENGTH + eng "String '%-.70s' is too long for %s (should be no longer than %d)" + ger "String '%-.70s' ist zu lang für %s (sollte nicht länger sein als %d)" +ER_NON_INSERTABLE_TABLE + eng "The target table %-.100s of the %s is not insertable-into" + ger "Die Zieltabelle %-.100s von %s ist nicht einfügbar" +ER_ADMIN_WRONG_MRG_TABLE + eng "Table '%-.64s' is differently defined or of non-MyISAM type or doesn't exist" +ER_FOREIGN_SERVER_EXISTS + eng "The foreign server, %s, you are trying to create already exists." +ER_FOREIGN_SERVER_DOESNT_EXIST + eng "The foreign server name you are trying to reference does not exist. Data source error: %-.64s" + ger "Die externe Verbindung, auf die Sie zugreifen wollen, existiert nicht. Datenquellenfehlermeldung: %-.64s" ER_ILLEGAL_HA_CREATE_OPTION eng "Table storage engine '%-.64s' does not support the create option '%.64s'" ger "Speicher-Engine '%-.64s' der Tabelle unterstützt die Option '%.64s' nicht" @@ -5848,9 +5878,6 @@ ER_BINLOG_ROW_WRONG_TABLE_DEF ER_BINLOG_ROW_RBR_TO_SBR eng "Slave running with --log-slave-updates must use row-based binary logging to be able to replicate row-based binary log events" ger "Slave, die mit --log-slave-updates laufen, müssen zeilenbasiertes Loggen verwenden, um zeilenbasierte Binärlog-Ereignisse loggen zu können" -ER_FOREIGN_SERVER_DOESNT_EXIST - eng "The foreign server name you are trying to reference does not exist. Data source error: %-.64s" - ger "Die externe Verbindung, auf die Sie zugreifen wollen, existiert nicht. Datenquellenfehlermeldung: %-.64s" ER_EVENT_ALREADY_EXISTS eng "Event '%-.192s' already exists" ger "Event '%-.192s' existiert bereits" @@ -5901,7 +5928,9 @@ ER_EVENT_DATA_TOO_LONG ER_DROP_INDEX_FK eng "Cannot drop index '%-.192s': needed in a foreign key constraint" ger "Kann Index '%-.192s' nicht löschen: wird für einen Fremdschlüssel benötigt" -ER_WARN_DEPRECATED_SYNTAX +# When using this error message, use the ER_WARN_DEPRECATED_SYNTAX error +# code. See, for example, code in mysql_priv.h. +ER_WARN_DEPRECATED_SYNTAX_WITH_VER eng "The syntax '%s' is deprecated and will be removed in MySQL %s. Please use %s instead" ger "Die Syntax '%s' ist veraltet und wird in MySQL %s entfernt. Bitte benutzen Sie statt dessen %s" ER_CANT_WRITE_LOCK_LOG_TABLE @@ -5916,9 +5945,6 @@ ER_FOREIGN_DUPLICATE_KEY 23000 S1009 ER_COL_COUNT_DOESNT_MATCH_PLEASE_UPDATE eng "Column count of mysql.%s is wrong. Expected %d, found %d. Created with MySQL %d, now running %d. Please use mysql_upgrade to fix this error." ger "Spaltenanzahl von mysql.%s falsch. %d erwartet, aber %d erhalten. Erzeugt mit MySQL %d, jetzt unter %d. Bitte benutzen Sie mysql_upgrade, um den Fehler zu beheben" -ER_REMOVED_SPACES - eng "Leading spaces are removed from name '%s'" - ger "Führende Leerzeichen werden aus dem Namen '%s' entfernt" ER_TEMP_TABLE_PREVENTS_SWITCH_OUT_OF_RBR eng "Cannot switch out of the row-based binary log format when the session has open temporary tables" ger "Kann nicht aus dem zeilenbasierten Binärlog-Format herauswechseln, wenn die Sitzung offene temporäre Tabellen hat" @@ -5975,9 +6001,6 @@ ER_BASE64_DECODE_ERROR eng "Decoding of base64 string failed" swe "Avkodning av base64 sträng misslyckades" ger "Der Server hat keine zeilenbasierte Replikation" -ER_NO_TRIGGERS_ON_SYSTEM_SCHEMA - eng "Triggers can not be created on system tables" - ger "Trigger können nicht auf Systemtabellen erzeugt werden" ER_EVENT_RECURSION_FORBIDDEN eng "Recursion of EVENT DDL statements is forbidden when body is present" ger "Rekursivität von EVENT-DDL-Anweisungen ist unzulässig wenn ein Hauptteil (Body) existiert" @@ -5987,27 +6010,12 @@ ER_EVENTS_DB_ERROR ER_ONLY_INTEGERS_ALLOWED eng "Only integers allowed as number here" ger "An dieser Stelle sind nur Ganzzahlen zulässig" -ER_AUTOINC_READ_FAILED - eng "Failed to read auto-increment value from storage engine" - ger "Lesen des Autoincrement-Werts von der Speicher-Engine fehlgeschlagen" -ER_USERNAME - eng "user name" - ger "Benutzername" -ER_HOSTNAME - eng "host name" - ger "Hostname" -ER_WRONG_STRING_LENGTH - eng "String '%-.70s' is too long for %s (should be no longer than %d)" - ger "String '%-.70s' ist zu lang für %s (sollte nicht länger sein als %d)" ER_UNSUPORTED_LOG_ENGINE eng "This storage engine cannot be used for log tables"" ger "Diese Speicher-Engine kann für Logtabellen nicht verwendet werden" ER_BAD_LOG_STATEMENT eng "You cannot '%s' a log table if logging is enabled" ger "Sie können eine Logtabelle nicht '%s', wenn Loggen angeschaltet ist" -ER_NON_INSERTABLE_TABLE - eng "The target table %-.100s of the %s is not insertable-into" - ger "Die Zieltabelle %-.100s von %s ist nicht einfügbar" ER_CANT_RENAME_LOG_TABLE eng "Cannot rename '%s'. When logging enabled, rename to/from log table must rename two tables: the log table to an archive table and another table back to '%s'" ger "Kann '%s' nicht umbenennen. Wenn Loggen angeschaltet ist, müssen beim Umbenennen zu/von einer Logtabelle zwei Tabellen angegeben werden: die Logtabelle zu einer Archivtabelle und eine weitere Tabelle zurück zu '%s'" @@ -6023,6 +6031,8 @@ ER_WRONG_PARAMETERS_TO_STORED_FCT 42000 ER_NATIVE_FCT_NAME_COLLISION eng "This function '%-.192s' has the same name as a native function" ger "Die Funktion '%-.192s' hat denselben Namen wie eine native Funktion" +# When using this error message, use the ER_DUP_ENTRY error code. See, for +# example, code in handler.cc. ER_DUP_ENTRY_WITH_KEY_NAME 23000 S1009 cze "Zvojen-Bý klíè '%-.64s' (èíslo klíèe '%-.192s')" dan "Ens værdier '%-.64s' for indeks '%-.192s'" @@ -6059,8 +6069,6 @@ ER_SLAVE_INCIDENT eng "The incident %s occured on the master. Message: %-.64s" ER_NO_PARTITION_FOR_GIVEN_VALUE_SILENT eng "Table has no partition for some existing values" -ER_ADMIN_WRONG_MRG_TABLE - eng "Table '%-.64s' is differently defined or of non-MyISAM type or doesn't exist" ER_BINLOG_UNSAFE_STATEMENT eng "Statement is not safe to log in statement format." swe "Detta är inte säkert att logga i statement-format." From a38b1ae7c9e7b237acb4daf63edc4d2406478e57 Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 27 Jun 2007 13:19:34 +0500 Subject: [PATCH 09/27] BUG#29207 - archive table reported as corrupt by check table (P1) CHECK TABLE against ARCHIVE table may falsely report table corruption, or cause server crash. Fixed by using proper buffer for CHECK TABLE. Affects both 5.0 and 5.1. mysql-test/r/archive.result: A test case for BUG#28916. mysql-test/t/archive.test: A test case for BUG#28916. sql/ha_archive.cc: We call Field::get_length() from get_row(). Field::get_length() assumes that the row was read into table->record[0] buffer, which is not the case when we check a table. As a result we get wrongly initialized blob length. Use table->record[0] as record buffer for check table instead. --- mysql-test/r/archive.result | 7 +++++++ mysql-test/t/archive.test | 9 +++++++++ sql/ha_archive.cc | 19 +++---------------- 3 files changed, 19 insertions(+), 16 deletions(-) diff --git a/mysql-test/r/archive.result b/mysql-test/r/archive.result index d89cecedcdd..b6a313ddf1a 100644 --- a/mysql-test/r/archive.result +++ b/mysql-test/r/archive.result @@ -12364,3 +12364,10 @@ select * from t1; i 1 drop table t1; +create table t1(a longblob) engine=archive; +insert into t1 set a=''; +insert into t1 set a='a'; +check table t1 extended; +Table Op Msg_type Msg_text +test.t1 check status OK +drop table t1; diff --git a/mysql-test/t/archive.test b/mysql-test/t/archive.test index 0ffbfab3d4f..61033fca3f7 100644 --- a/mysql-test/t/archive.test +++ b/mysql-test/t/archive.test @@ -1374,3 +1374,12 @@ insert into t1 values (1); repair table t1 use_frm; select * from t1; drop table t1; + +# +# BUG#29207 - archive table reported as corrupt by check table +# +create table t1(a longblob) engine=archive; +insert into t1 set a=''; +insert into t1 set a='a'; +check table t1 extended; +drop table t1; diff --git a/sql/ha_archive.cc b/sql/ha_archive.cc index 6e18f2e1e01..0c558bf2515 100644 --- a/sql/ha_archive.cc +++ b/sql/ha_archive.cc @@ -1205,7 +1205,6 @@ bool ha_archive::is_crashed() const int ha_archive::check(THD* thd, HA_CHECK_OPT* check_opt) { int rc= 0; - byte *buf; const char *old_proc_info=thd->proc_info; ha_rows count= share->rows_recorded; DBUG_ENTER("ha_archive::check"); @@ -1214,25 +1213,13 @@ int ha_archive::check(THD* thd, HA_CHECK_OPT* check_opt) /* Flush any waiting data */ gzflush(share->archive_write, Z_SYNC_FLUSH); - /* - First we create a buffer that we can use for reading rows, and can pass - to get_row(). - */ - if (!(buf= (byte*) my_malloc(table->s->reclength, MYF(MY_WME)))) - rc= HA_ERR_OUT_OF_MEM; - /* Now we will rewind the archive file so that we are positioned at the start of the file. */ - if (!rc) - read_data_header(archive); - - if (!rc) - while (!(rc= get_row(archive, buf))) - count--; - - my_free((char*)buf, MYF(0)); + read_data_header(archive); + while (!(rc= get_row(archive, table->record[0]))) + count--; thd->proc_info= old_proc_info; From 030d98d3971aaabbbeb37ed641629944a97186f5 Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 27 Jun 2007 18:10:19 +0500 Subject: [PATCH 10/27] BUG#29299 - repeatable myisam fulltext index corruption Fulltext index may get corrupt by certain gbk characters. The problem was that when skipping leading non-true-word-characters, we assumed that these characters are always 1 byte long. This is not the case with gbk character set, since non-true-word-characters may be 2 bytes long. Affects 5.0 only. myisam/ft_parser.c: Leading non-true-word-characters may also be multi-byte (e.g. in gbk character set). mysql-test/r/fulltext2.result: A test case for BUG#29299. mysql-test/t/fulltext2.test: A test case for BUG#29299. --- myisam/ft_parser.c | 6 ++++-- mysql-test/r/fulltext2.result | 12 ++++++++++++ mysql-test/t/fulltext2.test | 12 ++++++++++++ 3 files changed, 28 insertions(+), 2 deletions(-) diff --git a/myisam/ft_parser.c b/myisam/ft_parser.c index 6c79f9249cf..6d68542e4e2 100644 --- a/myisam/ft_parser.c +++ b/myisam/ft_parser.c @@ -111,7 +111,7 @@ byte ft_get_word(CHARSET_INFO *cs, byte **start, byte *end, while (docquot) @@ -120,6 +120,7 @@ byte ft_get_word(CHARSET_INFO *cs, byte **start, byte *end, *start=doc+1; return 3; /* FTB_RBR */ } + mbl= my_mbcharlen(cs, *(uchar *)doc); if (!param->quot) { if (*doc == FTB_LBR || *doc == FTB_RBR || *doc == FTB_LQUOT) @@ -187,10 +188,11 @@ byte ft_simple_get_word(CHARSET_INFO *cs, byte **start, const byte *end, do { - for (;; doc++) + for (;; doc+= mbl) { if (doc >= end) DBUG_RETURN(0); if (true_word_char(cs, *doc)) break; + mbl= my_mbcharlen(cs, *(uchar *)doc); } mwc= length= 0; diff --git a/mysql-test/r/fulltext2.result b/mysql-test/r/fulltext2.result index f6a4b20bc22..f6bb4e4965a 100644 --- a/mysql-test/r/fulltext2.result +++ b/mysql-test/r/fulltext2.result @@ -241,3 +241,15 @@ select * from t1 where match a against('ab c' in boolean mode); a drop table t1; set names latin1; +CREATE TABLE t1(a VARCHAR(255) CHARACTER SET gbk, FULLTEXT(a)); +SET NAMES utf8; +INSERT INTO t1 VALUES(0xF043616161),(0xBEF361616197C22061616161); +SELECT HEX(a) FROM t1 WHERE MATCH(a) AGAINST(0x97C22061616161 IN BOOLEAN MODE); +HEX(a) +BEF361616197C22061616161 +DELETE FROM t1 LIMIT 1; +CHECK TABLE t1; +Table Op Msg_type Msg_text +test.t1 check status OK +SET NAMES latin1; +DROP TABLE t1; diff --git a/mysql-test/t/fulltext2.test b/mysql-test/t/fulltext2.test index fd97f795534..99209dc8543 100644 --- a/mysql-test/t/fulltext2.test +++ b/mysql-test/t/fulltext2.test @@ -220,4 +220,16 @@ select * from t1 where match a against('ab c' in boolean mode); drop table t1; set names latin1; +# +# BUG#29299 - repeatable myisam fulltext index corruption +# +CREATE TABLE t1(a VARCHAR(255) CHARACTER SET gbk, FULLTEXT(a)); +SET NAMES utf8; +INSERT INTO t1 VALUES(0xF043616161),(0xBEF361616197C22061616161); +SELECT HEX(a) FROM t1 WHERE MATCH(a) AGAINST(0x97C22061616161 IN BOOLEAN MODE); +DELETE FROM t1 LIMIT 1; +CHECK TABLE t1; +SET NAMES latin1; +DROP TABLE t1; + # End of 4.1 tests From 0e5e884b118baeea9d47520acc5da2caa905dca8 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 28 Jun 2007 00:23:14 -0700 Subject: [PATCH 11/27] Bug#29019 "REPLACE/INSERT IGNORE/UPDATE IGNORE doesn't work" Federated does not record neccessary HA_EXTRA flags in order to support REPLACE/INSERT IGNORE/UPDATE IGNORE. Implement ::extra() to capture flags neccessary for functionality. New function append_ident() to better escape identifiers consistantly. mysql-test/r/federated.result: test for bug29019 mysql-test/t/federated.test: test for bug29019 sql/ha_federated.cc: Bug29019 Federated does not record neccessary HA_EXTRA flags in order to support REPLACE/INSERT IGNORE/UPDATE IGNORE. Implement ::extra() to capture flags neccessary for functionality. New function append_ident() to better escape identifiers consistantly. sql/ha_federated.h: bug29019 add 2 member values to ha_federated class ignore_duplicates and replace_duplicates. add 1 member method to ha_federated class extra() --- mysql-test/r/federated.result | 24 ++++ mysql-test/t/federated.test | 27 +++++ sql/ha_federated.cc | 211 +++++++++++++++++++++++----------- sql/ha_federated.h | 2 + 4 files changed, 200 insertions(+), 64 deletions(-) diff --git a/mysql-test/r/federated.result b/mysql-test/r/federated.result index cecffbb1471..52304de7609 100644 --- a/mysql-test/r/federated.result +++ b/mysql-test/r/federated.result @@ -1843,6 +1843,30 @@ C3A4C3B6C3BCC39F D18DD184D184D0B5D0BAD182D0B8D0B2D0BDD183D18E drop table federated.t1; drop table federated.t1; +create table federated.t1 (a int primary key, b varchar(64)) +DEFAULT CHARSET=utf8; +create table federated.t1 (a int primary key, b varchar(64)) +ENGINE=FEDERATED +connection='mysql://root@127.0.0.1:SLAVE_PORT/federated/t1' + DEFAULT CHARSET=utf8; +insert ignore into federated.t1 values (1,"Larry"), (2,"Curly"), (1,"Moe"); +select * from federated.t1; +a b +1 Larry +2 Curly +truncate federated.t1; +replace into federated.t1 values (1,"Larry"), (2,"Curly"), (1,"Moe"); +select * from federated.t1; +a b +1 Moe +2 Curly +update ignore federated.t1 set a=a+1; +select * from federated.t1; +a b +1 Moe +3 Curly +drop table federated.t1; +drop table federated.t1; DROP TABLE IF EXISTS federated.t1; DROP DATABASE IF EXISTS federated; DROP TABLE IF EXISTS federated.t1; diff --git a/mysql-test/t/federated.test b/mysql-test/t/federated.test index 894cd513914..bdd6076064a 100644 --- a/mysql-test/t/federated.test +++ b/mysql-test/t/federated.test @@ -1576,4 +1576,31 @@ connection slave; drop table federated.t1; +# +# BUG#21019 Federated Engine does not support REPLACE/INSERT IGNORE/UPDATE IGNORE +# +connection slave; +create table federated.t1 (a int primary key, b varchar(64)) + DEFAULT CHARSET=utf8; +connection master; +--replace_result $SLAVE_MYPORT SLAVE_PORT +eval create table federated.t1 (a int primary key, b varchar(64)) + ENGINE=FEDERATED + connection='mysql://root@127.0.0.1:$SLAVE_MYPORT/federated/t1' + DEFAULT CHARSET=utf8; + +insert ignore into federated.t1 values (1,"Larry"), (2,"Curly"), (1,"Moe"); +select * from federated.t1; + +truncate federated.t1; +replace into federated.t1 values (1,"Larry"), (2,"Curly"), (1,"Moe"); +select * from federated.t1; + +update ignore federated.t1 set a=a+1; +select * from federated.t1; + +drop table federated.t1; +connection slave; +drop table federated.t1; + source include/federated_cleanup.inc; diff --git a/sql/ha_federated.cc b/sql/ha_federated.cc index dd4dd725be4..9412db4b6a6 100644 --- a/sql/ha_federated.cc +++ b/sql/ha_federated.cc @@ -348,6 +348,10 @@ pthread_mutex_t federated_mutex; // This is the mutex we use to // init the hash static int federated_init= FALSE; // Variable for checking the // init state of hash +static char ident_quote_char= '`'; // Character for quoting + // identifiers +static char value_quote_char= '\''; // Character for quoting + // literals /* Federated storage engine handlerton */ @@ -440,6 +444,58 @@ bool federated_db_end() return FALSE; } + +/** + @brief Append identifiers to the string. + + @param[in,out] string The target string. + @param[in] name Identifier name + @param[in] length Length of identifier name in bytes + @param[in] quote_char Quote char to use for quoting identifier. + + @return Operation Status + @retval FALSE OK + @retval TRUE There was an error appending to the string. + + @note This function is based upon the append_identifier() function + in sql_show.cc except that quoting always occurs. +*/ + +static bool append_ident(String *string, const char *name, uint length, + const char quote_char) +{ + bool result; + uint clen; + const char *name_end; + DBUG_ENTER("append_ident"); + + if (quote_char) + { + string->reserve(length * 2 + 2); + if ((result= string->append("e_char, 1, system_charset_info))) + goto err; + + for (name_end= name+length; name < name_end; name+= clen) + { + uchar c= *(uchar *) name; + if (!(clen= my_mbcharlen(system_charset_info, c))) + clen= 1; + if (clen == 1 && c == (uchar) quote_char && + (result= string->append("e_char, 1, system_charset_info))) + goto err; + if ((result= string->append(name, clen, string->charset()))) + goto err; + } + result= string->append("e_char, 1, system_charset_info); + } + else + result= string->append(name, length, system_charset_info); + +err: + DBUG_RETURN(result); +} + + /* Check (in create) whether the tables exists, and that it can be connected to @@ -458,7 +514,6 @@ bool federated_db_end() static int check_foreign_data_source(FEDERATED_SHARE *share, bool table_create_flag) { - char escaped_table_name[NAME_LEN*2]; char query_buffer[FEDERATED_QUERY_BUFFER_SIZE]; char error_buffer[FEDERATED_QUERY_BUFFER_SIZE]; uint error_code; @@ -499,7 +554,6 @@ static int check_foreign_data_source(FEDERATED_SHARE *share, } else { - int escaped_table_name_length= 0; /* Since we do not support transactions at this version, we can let the client API silently reconnect. For future versions, we will need more @@ -517,14 +571,8 @@ static int check_foreign_data_source(FEDERATED_SHARE *share, query.append(FEDERATED_SELECT); query.append(FEDERATED_STAR); query.append(FEDERATED_FROM); - query.append(FEDERATED_BTICK); - escaped_table_name_length= - escape_string_for_mysql(&my_charset_bin, (char*)escaped_table_name, - sizeof(escaped_table_name), - share->table_name, - share->table_name_length); - query.append(escaped_table_name, escaped_table_name_length); - query.append(FEDERATED_BTICK); + append_ident(&query, share->table_name, share->table_name_length, + ident_quote_char); query.append(FEDERATED_WHERE); query.append(FEDERATED_FALSE); @@ -784,9 +832,8 @@ uint ha_federated::convert_row_to_internal_format(byte *record, static bool emit_key_part_name(String *to, KEY_PART_INFO *part) { DBUG_ENTER("emit_key_part_name"); - if (to->append(FEDERATED_BTICK) || - to->append(part->field->field_name) || - to->append(FEDERATED_BTICK)) + if (append_ident(to, part->field->field_name, + strlen(part->field->field_name), ident_quote_char)) DBUG_RETURN(1); // Out of memory DBUG_RETURN(0); } @@ -1309,31 +1356,28 @@ static FEDERATED_SHARE *get_share(const char *table_name, TABLE *table) query.append(FEDERATED_SELECT); for (field= table->field; *field; field++) { - query.append(FEDERATED_BTICK); - query.append((*field)->field_name); - query.append(FEDERATED_BTICK); + append_ident(&query, (*field)->field_name, + strlen((*field)->field_name), ident_quote_char); query.append(FEDERATED_COMMA); } query.length(query.length()- strlen(FEDERATED_COMMA)); query.append(FEDERATED_FROM); - query.append(FEDERATED_BTICK); + + tmp_share.table_name_length= strlen(tmp_share.table_name); + append_ident(&query, tmp_share.table_name, + tmp_share.table_name_length, ident_quote_char); if (!(share= (FEDERATED_SHARE *) my_multi_malloc(MYF(MY_WME), &share, sizeof(*share), - &select_query, - query.length()+table->s->connect_string.length+1, + &select_query, query.length()+1, NullS))) goto error; memcpy(share, &tmp_share, sizeof(tmp_share)); + memcpy(select_query, query.ptr(), query.length()+1); - share->table_name_length= strlen(share->table_name); - /* TODO: share->table_name to LEX_STRING object */ - query.append(share->table_name, share->table_name_length); - query.append(FEDERATED_BTICK); share->select_query= select_query; - strmov(share->select_query, query.ptr()); share->use_count= 0; DBUG_PRINT("info", ("share->select_query %s", share->select_query)); @@ -1467,6 +1511,8 @@ int ha_federated::open(const char *name, int mode, uint test_if_locked) table->s->reclength); DBUG_PRINT("info", ("ref_length: %u", ref_length)); + reset(); + DBUG_RETURN(0); } @@ -1579,10 +1625,14 @@ int ha_federated::write_row(byte *buf) /* start both our field and field values strings */ - insert_string.append(FEDERATED_INSERT); - insert_string.append(FEDERATED_BTICK); - insert_string.append(share->table_name, share->table_name_length); - insert_string.append(FEDERATED_BTICK); + if (replace_duplicates) + insert_string.append(STRING_WITH_LEN("REPLACE INTO ")); + else if (ignore_duplicates) + insert_string.append(STRING_WITH_LEN("INSERT IGNORE INTO ")); + else + insert_string.append(STRING_WITH_LEN("INSERT INTO ")); + append_ident(&insert_string, share->table_name, + share->table_name_length, ident_quote_char); insert_string.append(FEDERATED_OPENPAREN); values_string.append(FEDERATED_VALUES); @@ -1599,14 +1649,15 @@ int ha_federated::write_row(byte *buf) else { (*field)->val_str(&insert_field_value_string); - values_string.append('\''); + values_string.append(value_quote_char); insert_field_value_string.print(&values_string); - values_string.append('\''); + values_string.append(value_quote_char); insert_field_value_string.length(0); } /* append the field name */ - insert_string.append((*field)->field_name); + append_ident(&insert_string, (*field)->field_name, + strlen((*field)->field_name), ident_quote_char); /* append the value */ values_string.append(insert_field_value_string); @@ -1688,9 +1739,8 @@ int ha_federated::optimize(THD* thd, HA_CHECK_OPT* check_opt) query.set_charset(system_charset_info); query.append(FEDERATED_OPTIMIZE); - query.append(FEDERATED_BTICK); - query.append(share->table_name, share->table_name_length); - query.append(FEDERATED_BTICK); + append_ident(&query, share->table_name, share->table_name_length, + ident_quote_char); if (mysql_real_query(mysql, query.ptr(), query.length())) { @@ -1711,9 +1761,8 @@ int ha_federated::repair(THD* thd, HA_CHECK_OPT* check_opt) query.set_charset(system_charset_info); query.append(FEDERATED_REPAIR); - query.append(FEDERATED_BTICK); - query.append(share->table_name, share->table_name_length); - query.append(FEDERATED_BTICK); + append_ident(&query, share->table_name, share->table_name_length, + ident_quote_char); if (check_opt->flags & T_QUICK) query.append(FEDERATED_QUICK); if (check_opt->flags & T_EXTEND) @@ -1788,10 +1837,12 @@ int ha_federated::update_row(const byte *old_data, byte *new_data) update_string.length(0); where_string.length(0); - update_string.append(FEDERATED_UPDATE); - update_string.append(FEDERATED_BTICK); - update_string.append(share->table_name); - update_string.append(FEDERATED_BTICK); + if (ignore_duplicates) + update_string.append(STRING_WITH_LEN("UPDATE IGNORE ")); + else + update_string.append(STRING_WITH_LEN("UPDATE ")); + append_ident(&update_string, share->table_name, + share->table_name_length, ident_quote_char); update_string.append(FEDERATED_SET); /* @@ -1806,8 +1857,11 @@ int ha_federated::update_row(const byte *old_data, byte *new_data) for (Field **field= table->field; *field; field++) { - where_string.append((*field)->field_name); - update_string.append((*field)->field_name); + uint field_name_length= strlen((*field)->field_name); + append_ident(&where_string, (*field)->field_name, field_name_length, + ident_quote_char); + append_ident(&update_string, (*field)->field_name, field_name_length, + ident_quote_char); update_string.append(FEDERATED_EQ); if ((*field)->is_null()) @@ -1816,9 +1870,9 @@ int ha_federated::update_row(const byte *old_data, byte *new_data) { /* otherwise = */ (*field)->val_str(&field_value); - update_string.append('\''); + update_string.append(value_quote_char); field_value.print(&update_string); - update_string.append('\''); + update_string.append(value_quote_char); field_value.length(0); } @@ -1829,9 +1883,9 @@ int ha_federated::update_row(const byte *old_data, byte *new_data) where_string.append(FEDERATED_EQ); (*field)->val_str(&field_value, (char*) (old_data + (*field)->offset())); - where_string.append('\''); + where_string.append(value_quote_char); field_value.print(&where_string); - where_string.append('\''); + where_string.append(value_quote_char); field_value.length(0); } @@ -1888,16 +1942,16 @@ int ha_federated::delete_row(const byte *buf) delete_string.length(0); delete_string.append(FEDERATED_DELETE); delete_string.append(FEDERATED_FROM); - delete_string.append(FEDERATED_BTICK); - delete_string.append(share->table_name); - delete_string.append(FEDERATED_BTICK); + append_ident(&delete_string, share->table_name, + share->table_name_length, ident_quote_char); delete_string.append(FEDERATED_WHERE); for (Field **field= table->field; *field; field++) { Field *cur_field= *field; data_string.length(0); - delete_string.append(cur_field->field_name); + append_ident(&delete_string, (*field)->field_name, + strlen((*field)->field_name), ident_quote_char); if (cur_field->is_null()) { @@ -1907,9 +1961,9 @@ int ha_federated::delete_row(const byte *buf) { delete_string.append(FEDERATED_EQ); cur_field->val_str(&data_string); - delete_string.append('\''); + delete_string.append(value_quote_char); data_string.print(&delete_string); - delete_string.append('\''); + delete_string.append(value_quote_char); } delete_string.append(FEDERATED_AND); @@ -2411,14 +2465,8 @@ int ha_federated::info(uint flag) { status_query_string.length(0); status_query_string.append(FEDERATED_INFO); - status_query_string.append(FEDERATED_SQUOTE); - - escape_string_for_mysql(&my_charset_bin, (char *)escaped_table_name, - sizeof(escaped_table_name), - share->table_name, - share->table_name_length); - status_query_string.append(escaped_table_name); - status_query_string.append(FEDERATED_SQUOTE); + append_ident(&status_query_string, share->table_name, + share->table_name_length, value_quote_char); if (mysql_real_query(mysql, status_query_string.ptr(), status_query_string.length())) @@ -2484,6 +2532,42 @@ error: } +/** + @brief Handles extra signals from MySQL server + + @param[in] operation Hint for storage engine + + @return Operation Status + @retval 0 OK + */ +int ha_federated::extra(ha_extra_function operation) +{ + DBUG_ENTER("ha_federated::extra"); + switch (operation) { + case HA_EXTRA_IGNORE_DUP_KEY: + ignore_duplicates= TRUE; + break; + case HA_EXTRA_NO_IGNORE_DUP_KEY: + ignore_duplicates= FALSE; + break; + case HA_EXTRA_WRITE_CAN_REPLACE: + replace_duplicates= TRUE; + break; + case HA_EXTRA_WRITE_CANNOT_REPLACE: + replace_duplicates= FALSE; + break; + case HA_EXTRA_RESET: + ignore_duplicates= FALSE; + replace_duplicates= FALSE; + break; + default: + /* do nothing */ + DBUG_PRINT("info",("unhandled operation: %d", (uint) operation)); + } + DBUG_RETURN(0); +} + + /* Used to delete all rows in a table. Both for cases of truncate and for cases where the optimizer realizes that all rows will be @@ -2506,9 +2590,8 @@ int ha_federated::delete_all_rows() query.set_charset(system_charset_info); query.append(FEDERATED_TRUNCATE); - query.append(FEDERATED_BTICK); - query.append(share->table_name); - query.append(FEDERATED_BTICK); + append_ident(&query, share->table_name, share->table_name_length, + ident_quote_char); /* TRUNCATE won't return anything in mysql_affected_rows diff --git a/sql/ha_federated.h b/sql/ha_federated.h index 09c934cb493..11a7547880a 100644 --- a/sql/ha_federated.h +++ b/sql/ha_federated.h @@ -157,6 +157,7 @@ class ha_federated: public handler MYSQL_ROW_OFFSET current_position; // Current position used by ::position() int remote_error_number; char remote_error_buf[FEDERATED_QUERY_BUFFER_SIZE]; + bool ignore_duplicates, replace_duplicates; private: /* @@ -284,6 +285,7 @@ public: int rnd_pos(byte *buf, byte *pos); //required void position(const byte *record); //required int info(uint); //required + int extra(ha_extra_function operation); void update_auto_increment(void); int repair(THD* thd, HA_CHECK_OPT* check_opt); From c69012d3e71a9bbf13228ae491f7ac27690f7bf8 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 28 Jun 2007 14:04:20 +0500 Subject: [PATCH 12/27] BUG#29207 - archive table reported as corrupt by check table After merge fix. mysql-test/r/archive.result: After merge fix. --- mysql-test/r/archive.result | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/mysql-test/r/archive.result b/mysql-test/r/archive.result index 59462e848d2..36b013703d8 100644 --- a/mysql-test/r/archive.result +++ b/mysql-test/r/archive.result @@ -12675,3 +12675,10 @@ select * from t1; i 1 drop table t1; +create table t1(a longblob) engine=archive; +insert into t1 set a=''; +insert into t1 set a='a'; +check table t1 extended; +Table Op Msg_type Msg_text +test.t1 check status OK +drop table t1; From 94beb7cd8db07e816ecced8112945d9df9db67e4 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 28 Jun 2007 13:36:26 -0700 Subject: [PATCH 13/27] Bug#25511 "Federated INSERT failures" Federated does not correctly handle "INSERT...ON DUPLICATE KEY UPDATE" However, implementing such support is not reasonably possible without increasing complexity of the storage engine: checking that constraints on remote server match local server and parsing error messages. This patch causes 'ON DUPLICATE KEY' to fail with ER_DUP_KEY message if a conflict occurs and not to fail silently. include/my_base.h: bug25511 new storage engine hint: HA_EXTRA_INSERT_WITH_UPDATE mysql-test/r/federated.result: test for bug25511 mysql-test/t/federated.test: test for bug25511 sql/ha_federated.cc: bug25511 implement support for handling HA_EXTRA_INSERT_WITH_UPDATE hint sql/ha_federated.h: bug25511 new property: insert_dup_update sql/sql_insert.cc: bug25511 implement support for HA_EXTRA_INSERT_WITH_UPDATE When checking duplicates flag, if it is DUP_UPDATE, send hint to the storage engine. --- include/my_base.h | 8 +++++++- mysql-test/r/federated.result | 15 +++++++++++++++ mysql-test/t/federated.test | 26 ++++++++++++++++++++++++++ sql/ha_federated.cc | 10 +++++++++- sql/ha_federated.h | 1 + sql/sql_insert.cc | 8 ++++++++ 6 files changed, 66 insertions(+), 2 deletions(-) diff --git a/include/my_base.h b/include/my_base.h index d07a4de8e6a..a26217f8050 100644 --- a/include/my_base.h +++ b/include/my_base.h @@ -168,7 +168,13 @@ enum ha_extra_function { These flags are reset by the handler::extra(HA_EXTRA_RESET) call. */ HA_EXTRA_DELETE_CANNOT_BATCH, - HA_EXTRA_UPDATE_CANNOT_BATCH + HA_EXTRA_UPDATE_CANNOT_BATCH, + /* + Inform handler that write_row() should immediately report constraint + violations because a INSERT...ON DUPLICATE KEY UPDATE is in being + performed. + */ + HA_EXTRA_INSERT_WITH_UPDATE }; /* The following is parameter to ha_panic() */ diff --git a/mysql-test/r/federated.result b/mysql-test/r/federated.result index 52304de7609..4bef92319fb 100644 --- a/mysql-test/r/federated.result +++ b/mysql-test/r/federated.result @@ -1867,6 +1867,21 @@ a b 3 Curly drop table federated.t1; drop table federated.t1; +create table federated.t1 (a int primary key, b varchar(64)) +DEFAULT CHARSET=utf8; +create table federated.t1 (a int primary key, b varchar(64)) +ENGINE=FEDERATED +connection='mysql://root@127.0.0.1:SLAVE_PORT/federated/t1' + DEFAULT CHARSET=utf8; +insert into federated.t1 values (1,"Larry"), (2,"Curly"), (1,"Moe") +on duplicate key update a=a+100; +ERROR 23000: Can't write; duplicate key in table 't1' +select * from federated.t1; +a b +1 Larry +2 Curly +drop table federated.t1; +drop table federated.t1; DROP TABLE IF EXISTS federated.t1; DROP DATABASE IF EXISTS federated; DROP TABLE IF EXISTS federated.t1; diff --git a/mysql-test/t/federated.test b/mysql-test/t/federated.test index bdd6076064a..bedb6b36d61 100644 --- a/mysql-test/t/federated.test +++ b/mysql-test/t/federated.test @@ -1603,4 +1603,30 @@ drop table federated.t1; connection slave; drop table federated.t1; +# +# BUG#25511 Federated Insert failures. +# +# When the user performs a INSERT...ON DUPLICATE KEY UPDATE, we want +# it to fail if a duplicate key exists instead of ignoring it. +# +connection slave; +create table federated.t1 (a int primary key, b varchar(64)) + DEFAULT CHARSET=utf8; +connection master; +--replace_result $SLAVE_MYPORT SLAVE_PORT +eval create table federated.t1 (a int primary key, b varchar(64)) + ENGINE=FEDERATED + connection='mysql://root@127.0.0.1:$SLAVE_MYPORT/federated/t1' + DEFAULT CHARSET=utf8; + +--error ER_DUP_KEY +insert into federated.t1 values (1,"Larry"), (2,"Curly"), (1,"Moe") +on duplicate key update a=a+100; +select * from federated.t1; + +drop table federated.t1; +connection slave; +drop table federated.t1; + + source include/federated_cleanup.inc; diff --git a/sql/ha_federated.cc b/sql/ha_federated.cc index 9412db4b6a6..e691831bbc9 100644 --- a/sql/ha_federated.cc +++ b/sql/ha_federated.cc @@ -1627,7 +1627,7 @@ int ha_federated::write_row(byte *buf) */ if (replace_duplicates) insert_string.append(STRING_WITH_LEN("REPLACE INTO ")); - else if (ignore_duplicates) + else if (ignore_duplicates && !insert_dup_update) insert_string.append(STRING_WITH_LEN("INSERT IGNORE INTO ")); else insert_string.append(STRING_WITH_LEN("INSERT INTO ")); @@ -2548,6 +2548,7 @@ int ha_federated::extra(ha_extra_function operation) ignore_duplicates= TRUE; break; case HA_EXTRA_NO_IGNORE_DUP_KEY: + insert_dup_update= FALSE; ignore_duplicates= FALSE; break; case HA_EXTRA_WRITE_CAN_REPLACE: @@ -2556,7 +2557,11 @@ int ha_federated::extra(ha_extra_function operation) case HA_EXTRA_WRITE_CANNOT_REPLACE: replace_duplicates= FALSE; break; + case HA_EXTRA_INSERT_WITH_UPDATE: + insert_dup_update= TRUE; + break; case HA_EXTRA_RESET: + insert_dup_update= FALSE; ignore_duplicates= FALSE; replace_duplicates= FALSE; break; @@ -2699,6 +2704,9 @@ int ha_federated::stash_remote_error() DBUG_ENTER("ha_federated::stash_remote_error()"); remote_error_number= mysql_errno(mysql); strmake(remote_error_buf, mysql_error(mysql), sizeof(remote_error_buf)-1); + if (remote_error_number == ER_DUP_ENTRY || + remote_error_number == ER_DUP_KEY) + DBUG_RETURN(HA_ERR_FOUND_DUPP_KEY); DBUG_RETURN(HA_FEDERATED_ERROR_WITH_REMOTE_SYSTEM); } diff --git a/sql/ha_federated.h b/sql/ha_federated.h index 11a7547880a..28c89561b2c 100644 --- a/sql/ha_federated.h +++ b/sql/ha_federated.h @@ -158,6 +158,7 @@ class ha_federated: public handler int remote_error_number; char remote_error_buf[FEDERATED_QUERY_BUFFER_SIZE]; bool ignore_duplicates, replace_duplicates; + bool insert_dup_update; private: /* diff --git a/sql/sql_insert.cc b/sql/sql_insert.cc index 228fc8860ae..3bfd84b324b 100644 --- a/sql/sql_insert.cc +++ b/sql/sql_insert.cc @@ -715,6 +715,8 @@ bool mysql_insert(THD *thd,TABLE_LIST *table_list, */ table->file->extra(HA_EXTRA_RETRIEVE_ALL_COLS); } + if (duplic == DUP_UPDATE) + table->file->extra(HA_EXTRA_INSERT_WITH_UPDATE); /* let's *try* to start bulk inserts. It won't necessary start them as values_list.elements should be greater than @@ -2434,6 +2436,8 @@ bool Delayed_insert::handle_inserts(void) table->file->extra(HA_EXTRA_WRITE_CAN_REPLACE); using_opt_replace= 1; } + if (info.handle_duplicates == DUP_UPDATE) + table->file->extra(HA_EXTRA_INSERT_WITH_UPDATE); thd.clear_error(); // reset error for binlog if (write_record(&thd, table, &info)) { @@ -2761,6 +2765,8 @@ select_insert::prepare(List &values, SELECT_LEX_UNIT *u) table->file->extra(HA_EXTRA_WRITE_CAN_REPLACE); table->file->extra(HA_EXTRA_RETRIEVE_ALL_COLS); } + if (info.handle_duplicates == DUP_UPDATE) + table->file->extra(HA_EXTRA_INSERT_WITH_UPDATE); thd->no_trans_update.stmt= FALSE; thd->abort_on_warning= (!info.ignore && (thd->variables.sql_mode & @@ -3218,6 +3224,8 @@ select_create::prepare(List &values, SELECT_LEX_UNIT *u) table->file->extra(HA_EXTRA_WRITE_CAN_REPLACE); table->file->extra(HA_EXTRA_RETRIEVE_ALL_COLS); } + if (info.handle_duplicates == DUP_UPDATE) + table->file->extra(HA_EXTRA_INSERT_WITH_UPDATE); if (!thd->prelocked_mode) table->file->start_bulk_insert((ha_rows) 0); thd->no_trans_update.stmt= FALSE; From dba70720a7a3d6ae7e8504cb5414124f5c5d5c60 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 28 Jun 2007 16:03:01 -0700 Subject: [PATCH 14/27] Bug#25513 "Federared Transactions Failure" Bug occurs when the user performs an operation which inserts more than one row into the federated table and the federated table references a remote table stored within a transactional storage engine. When the insert operation for any one row in the statement fails due to constraint violation, the federated engine is unable to perform statement rollback and so the remote table contains a partial commit. The user would expect a statement to perform the same so a statement rollback is expected. This bug was fixed by implementing bulk-insert handling into the federated storage engine. This will relieve the bug for most common situations by enabling the generation of a multi-row insert into the remote table and thus permitting the remote table to perform statement rollback when neccessary. The multi-row insert is limited to the maximum packet size between servers and should the size overflow, more than one insert statement will be sent and this bug will reappear. Multi-row insert is disabled when an "INSERT...ON DUPLICATE KEY UPDATE" is being performed. The bulk-insert handling will offer a significant performance boost when inserting a large number of small rows. This patch builds on Bug29019 and Bug25511 sql/ha_federated.cc: bug25513 new member methods: start_bulk_insert() - initializes memory for bulk insert end_bulk_insert() - sends any remaining bulk insert and frees memory append_stmt_insert() - create the INSERT statement sql/ha_federated.h: bug25513 new member value: bulk_insert new member methods: start_bulk_insert(), end_bulk_insert(), append_stmt_insert() make member methods private: read_next(), index_read_idx_with_result_set() mysql-test/r/federated_innodb.result: New BitKeeper file ``mysql-test/r/federated_innodb.result'' mysql-test/t/federated_innodb-slave.opt: New BitKeeper file ``mysql-test/t/federated_innodb-slave.opt'' mysql-test/t/federated_innodb.test: New BitKeeper file ``mysql-test/t/federated_innodb.test'' --- mysql-test/r/federated_innodb.result | 34 ++++ mysql-test/t/federated_innodb-slave.opt | 1 + mysql-test/t/federated_innodb.test | 34 ++++ sql/ha_federated.cc | 232 +++++++++++++++++++++--- sql/ha_federated.h | 20 +- 5 files changed, 283 insertions(+), 38 deletions(-) create mode 100644 mysql-test/r/federated_innodb.result create mode 100644 mysql-test/t/federated_innodb-slave.opt create mode 100644 mysql-test/t/federated_innodb.test diff --git a/mysql-test/r/federated_innodb.result b/mysql-test/r/federated_innodb.result new file mode 100644 index 00000000000..70ba3acb279 --- /dev/null +++ b/mysql-test/r/federated_innodb.result @@ -0,0 +1,34 @@ +stop slave; +drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; +reset master; +reset slave; +drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9; +start slave; +stop slave; +DROP DATABASE IF EXISTS federated; +CREATE DATABASE federated; +DROP DATABASE IF EXISTS federated; +CREATE DATABASE federated; +create table federated.t1 (a int primary key, b varchar(64)) +engine=myisam; +create table federated.t1 (a int primary key, b varchar(64)) +engine=federated +connection='mysql://root@127.0.0.1:SLAVE_PORT/federated/t1'; +insert into federated.t1 values (1,"Larry"), (2,"Curly"), (1,"Moe"); +ERROR 23000: Can't write; duplicate key in table 't1' +select * from federated.t1; +a b +1 Larry +2 Curly +truncate federated.t1; +alter table federated.t1 engine=innodb; +insert into federated.t1 values (1,"Larry"), (2,"Curly"), (1,"Moe"); +ERROR 23000: Can't write; duplicate key in table 't1' +select * from federated.t1; +a b +drop table federated.t1; +drop table federated.t1; +DROP TABLE IF EXISTS federated.t1; +DROP DATABASE IF EXISTS federated; +DROP TABLE IF EXISTS federated.t1; +DROP DATABASE IF EXISTS federated; diff --git a/mysql-test/t/federated_innodb-slave.opt b/mysql-test/t/federated_innodb-slave.opt new file mode 100644 index 00000000000..627becdbfb5 --- /dev/null +++ b/mysql-test/t/federated_innodb-slave.opt @@ -0,0 +1 @@ +--innodb diff --git a/mysql-test/t/federated_innodb.test b/mysql-test/t/federated_innodb.test new file mode 100644 index 00000000000..772e37a2929 --- /dev/null +++ b/mysql-test/t/federated_innodb.test @@ -0,0 +1,34 @@ +source include/federated.inc; +source include/have_innodb.inc; + +# +# Bug#25513 Federated transaction failures +# +connection slave; +create table federated.t1 (a int primary key, b varchar(64)) + engine=myisam; +connection master; +--replace_result $SLAVE_MYPORT SLAVE_PORT +eval create table federated.t1 (a int primary key, b varchar(64)) + engine=federated + connection='mysql://root@127.0.0.1:$SLAVE_MYPORT/federated/t1'; + +--error ER_DUP_KEY +insert into federated.t1 values (1,"Larry"), (2,"Curly"), (1,"Moe"); +select * from federated.t1; + +connection slave; +truncate federated.t1; +alter table federated.t1 engine=innodb; +connection master; + +--error ER_DUP_KEY +insert into federated.t1 values (1,"Larry"), (2,"Curly"), (1,"Moe"); +select * from federated.t1; + +drop table federated.t1; +connection slave; +drop table federated.t1; + + +source include/federated_cleanup.inc; diff --git a/sql/ha_federated.cc b/sql/ha_federated.cc index e691831bbc9..8551db6be16 100644 --- a/sql/ha_federated.cc +++ b/sql/ha_federated.cc @@ -352,6 +352,7 @@ static char ident_quote_char= '`'; // Character for quoting // identifiers static char value_quote_char= '\''; // Character for quoting // literals +static const int bulk_padding= 64; // bytes "overhead" in packet /* Federated storage engine handlerton */ @@ -773,7 +774,9 @@ error: ha_federated::ha_federated(TABLE *table_arg) :handler(&federated_hton, table_arg), mysql(0), stored_result(0) -{} +{ + bzero(&bulk_insert, sizeof(bulk_insert)); +} /* @@ -1584,6 +1587,83 @@ inline uint field_in_record_is_null(TABLE *table, DBUG_RETURN(0); } + +/** + @brief Construct the INSERT statement. + + @details This method will construct the INSERT statement and appends it to + the supplied query string buffer. + + @return + @retval FALSE No error + @retval TRUE Failure +*/ + +bool ha_federated::append_stmt_insert(String *query) +{ + char insert_buffer[FEDERATED_QUERY_BUFFER_SIZE]; + Field **field; + uint tmp_length; + + /* The main insert query string */ + String insert_string(insert_buffer, sizeof(insert_buffer), &my_charset_bin); + DBUG_ENTER("ha_federated::append_stmt_insert"); + + insert_string.length(0); + + if (replace_duplicates) + insert_string.append(STRING_WITH_LEN("REPLACE INTO ")); + else if (ignore_duplicates && !insert_dup_update) + insert_string.append(STRING_WITH_LEN("INSERT IGNORE INTO ")); + else + insert_string.append(STRING_WITH_LEN("INSERT INTO ")); + append_ident(&insert_string, share->table_name, share->table_name_length, + ident_quote_char); + insert_string.append(FEDERATED_OPENPAREN); + tmp_length= insert_string.length() - strlen(FEDERATED_COMMA); + + /* + loop through the field pointer array, add any fields to both the values + list and the fields list that match the current query id + */ + for (field= table->field; *field; field++) + { + /* append the field name */ + append_ident(&insert_string, (*field)->field_name, + strlen((*field)->field_name), ident_quote_char); + + /* append commas between both fields and fieldnames */ + /* + unfortunately, we can't use the logic + if *(fields + 1) to make the following + appends conditional because we may not append + if the next field doesn't match the condition: + (((*field)->query_id && (*field)->query_id == current_query_id) + */ + insert_string.append(FEDERATED_COMMA); + } + + /* + remove trailing comma + */ + insert_string.length(insert_string.length() - strlen(FEDERATED_COMMA)); + + /* + if there were no fields, we don't want to add a closing paren + AND, we don't want to chop off the last char '(' + insert will be "INSERT INTO t1 VALUES ();" + */ + if (insert_string.length() > tmp_length) + { + insert_string.append(FEDERATED_CLOSEPAREN); + } + + insert_string.append(FEDERATED_VALUES); + + DBUG_RETURN(query->append(insert_string)); +} + + /* write_row() inserts a row. No extra() hint is given currently if a bulk load is happeneding. buf() is a byte array of data. You can use the field @@ -1600,13 +1680,14 @@ inline uint field_in_record_is_null(TABLE *table, int ha_federated::write_row(byte *buf) { - char insert_buffer[FEDERATED_QUERY_BUFFER_SIZE]; char values_buffer[FEDERATED_QUERY_BUFFER_SIZE]; char insert_field_value_buffer[STRING_BUFFER_USUAL_SIZE]; Field **field; + uint tmp_length; + int error= 0; + bool use_bulk_insert; + bool auto_increment_update_required= table->next_number_field; - /* The main insert query string */ - String insert_string(insert_buffer, sizeof(insert_buffer), &my_charset_bin); /* The string containing the values to be added to the insert */ String values_string(values_buffer, sizeof(values_buffer), &my_charset_bin); /* The actual value of the field, to be added to the values_string */ @@ -1614,7 +1695,6 @@ int ha_federated::write_row(byte *buf) sizeof(insert_field_value_buffer), &my_charset_bin); values_string.length(0); - insert_string.length(0); insert_field_value_string.length(0); DBUG_ENTER("ha_federated::write_row"); @@ -1624,19 +1704,19 @@ int ha_federated::write_row(byte *buf) /* start both our field and field values strings + We must disable multi-row insert for "INSERT...ON DUPLICATE KEY UPDATE" + Ignore duplicates is always true when insert_dup_update is true. + When replace_duplicates == TRUE, we can safely enable multi-row insert. + When performing multi-row insert, we only collect the columns values for + the row. The start of the statement is only created when the first + row is copied in to the bulk_insert string. */ - if (replace_duplicates) - insert_string.append(STRING_WITH_LEN("REPLACE INTO ")); - else if (ignore_duplicates && !insert_dup_update) - insert_string.append(STRING_WITH_LEN("INSERT IGNORE INTO ")); - else - insert_string.append(STRING_WITH_LEN("INSERT INTO ")); - append_ident(&insert_string, share->table_name, - share->table_name_length, ident_quote_char); - insert_string.append(FEDERATED_OPENPAREN); + if (!(use_bulk_insert= bulk_insert.str && + (!insert_dup_update || replace_duplicates))) + append_stmt_insert(&values_string); - values_string.append(FEDERATED_VALUES); values_string.append(FEDERATED_OPENPAREN); + tmp_length= values_string.length(); /* loop through the field pointer array, add any fields to both the values @@ -1655,9 +1735,6 @@ int ha_federated::write_row(byte *buf) insert_field_value_string.length(0); } - /* append the field name */ - append_ident(&insert_string, (*field)->field_name, - strlen((*field)->field_name), ident_quote_char); /* append the value */ values_string.append(insert_field_value_string); @@ -1671,32 +1748,61 @@ int ha_federated::write_row(byte *buf) if the next field doesn't match the condition: (((*field)->query_id && (*field)->query_id == current_query_id) */ - insert_string.append(FEDERATED_COMMA); values_string.append(FEDERATED_COMMA); } - /* - remove trailing comma - */ - insert_string.length(insert_string.length() - strlen(FEDERATED_COMMA)); /* if there were no fields, we don't want to add a closing paren AND, we don't want to chop off the last char '(' insert will be "INSERT INTO t1 VALUES ();" */ - if (table->s->fields) + if (values_string.length() > tmp_length) { /* chops off leading commas */ values_string.length(values_string.length() - strlen(FEDERATED_COMMA)); - insert_string.append(FEDERATED_CLOSEPAREN); } /* we always want to append this, even if there aren't any fields */ values_string.append(FEDERATED_CLOSEPAREN); - /* add the values */ - insert_string.append(values_string); + if (use_bulk_insert) + { + /* + Send the current bulk insert out if appending the current row would + cause the statement to overflow the packet size, otherwise set + auto_increment_update_required to FALSE as no query was executed. + */ + if (bulk_insert.length + values_string.length() + bulk_padding > + mysql->net.max_packet_size && bulk_insert.length) + { + error= mysql_real_query(mysql, bulk_insert.str, bulk_insert.length); + bulk_insert.length= 0; + } + else + auto_increment_update_required= FALSE; + + if (bulk_insert.length == 0) + { + char insert_buffer[FEDERATED_QUERY_BUFFER_SIZE]; + String insert_string(insert_buffer, sizeof(insert_buffer), + &my_charset_bin); + insert_string.length(0); + append_stmt_insert(&insert_string); + dynstr_append_mem(&bulk_insert, insert_string.ptr(), + insert_string.length()); + } + else + dynstr_append_mem(&bulk_insert, ",", 1); - if (mysql_real_query(mysql, insert_string.ptr(), insert_string.length())) + dynstr_append_mem(&bulk_insert, values_string.ptr(), + values_string.length()); + } + else + { + error= mysql_real_query(mysql, values_string.ptr(), + values_string.length()); + } + + if (error) { DBUG_RETURN(stash_remote_error()); } @@ -1704,12 +1810,79 @@ int ha_federated::write_row(byte *buf) If the table we've just written a record to contains an auto_increment field, then store the last_insert_id() value from the foreign server */ - if (table->next_number_field) + if (auto_increment_update_required) update_auto_increment(); DBUG_RETURN(0); } + +/** + @brief Prepares the storage engine for bulk inserts. + + @param[in] rows estimated number of rows in bulk insert + or 0 if unknown. + + @details Initializes memory structures required for bulk insert. +*/ + +void ha_federated::start_bulk_insert(ha_rows rows) +{ + uint page_size; + DBUG_ENTER("ha_federated::start_bulk_insert"); + + dynstr_free(&bulk_insert); + + /** + We don't bother with bulk-insert semantics when the estimated rows == 1 + The rows value will be 0 if the server does not know how many rows + would be inserted. This can occur when performing INSERT...SELECT + */ + + if (rows == 1) + DBUG_VOID_RETURN; + + page_size= (uint) my_getpagesize(); + + if (init_dynamic_string(&bulk_insert, NULL, page_size, page_size)) + DBUG_VOID_RETURN; + + bulk_insert.length= 0; + DBUG_VOID_RETURN; +} + + +/** + @brief End bulk insert. + + @details This method will send any remaining rows to the remote server. + Finally, it will deinitialize the bulk insert data structure. + + @return Operation status + @retval 0 No error + @retval != 0 Error occured at remote server. Also sets my_errno. +*/ + +int ha_federated::end_bulk_insert() +{ + int error= 0; + DBUG_ENTER("ha_federated::end_bulk_insert"); + + if (bulk_insert.str && bulk_insert.length) + { + if (mysql_real_query(mysql, bulk_insert.str, bulk_insert.length)) + error= stash_remote_error(); + else + if (table->next_number_field) + update_auto_increment(); + } + + dynstr_free(&bulk_insert); + + DBUG_RETURN(my_errno= error); +} + + /* ha_federated::update_auto_increment @@ -2451,7 +2624,6 @@ int ha_federated::info(uint flag) { char error_buffer[FEDERATED_QUERY_BUFFER_SIZE]; char status_buf[FEDERATED_QUERY_BUFFER_SIZE]; - char escaped_table_name[FEDERATED_QUERY_BUFFER_SIZE]; int error; uint error_code; MYSQL_RES *result= 0; diff --git a/sql/ha_federated.h b/sql/ha_federated.h index 28c89561b2c..b5e1c217eb5 100644 --- a/sql/ha_federated.h +++ b/sql/ha_federated.h @@ -159,6 +159,7 @@ class ha_federated: public handler char remote_error_buf[FEDERATED_QUERY_BUFFER_SIZE]; bool ignore_duplicates, replace_duplicates; bool insert_dup_update; + DYNAMIC_STRING bulk_insert; private: /* @@ -173,6 +174,14 @@ private: bool records_in_range); int stash_remote_error(); + bool append_stmt_insert(String *query); + + int read_next(byte *buf, MYSQL_RES *result); + int index_read_idx_with_result_set(byte *buf, uint index, + const byte *key, + uint key_len, + ha_rkey_function find_flag, + MYSQL_RES **result); public: ha_federated(TABLE *table_arg); ~ha_federated() @@ -258,6 +267,8 @@ public: int open(const char *name, int mode, uint test_if_locked); // required int close(void); // required + void start_bulk_insert(ha_rows rows); + int end_bulk_insert(); int write_row(byte *buf); int update_row(const byte *old_data, byte *new_data); int delete_row(const byte *buf); @@ -301,14 +312,7 @@ public: THR_LOCK_DATA **store_lock(THD *thd, THR_LOCK_DATA **to, enum thr_lock_type lock_type); //required - virtual bool get_error_message(int error, String *buf); - - int read_next(byte *buf, MYSQL_RES *result); - int index_read_idx_with_result_set(byte *buf, uint index, - const byte *key, - uint key_len, - ha_rkey_function find_flag, - MYSQL_RES **result); + bool get_error_message(int error, String *buf); }; bool federated_db_init(void); From b4fe5e4408dad197509976857bb7826d8c447ce0 Mon Sep 17 00:00:00 2001 From: unknown Date: Fri, 29 Jun 2007 13:55:16 -0700 Subject: [PATCH 15/27] add and amend comments for clarity include/my_base.h: amend comment for clarity sql/ha_federated.cc: add comment --- include/my_base.h | 5 ++--- sql/ha_federated.cc | 4 ++++ 2 files changed, 6 insertions(+), 3 deletions(-) diff --git a/include/my_base.h b/include/my_base.h index a26217f8050..4ce7a87105d 100644 --- a/include/my_base.h +++ b/include/my_base.h @@ -170,9 +170,8 @@ enum ha_extra_function { HA_EXTRA_DELETE_CANNOT_BATCH, HA_EXTRA_UPDATE_CANNOT_BATCH, /* - Inform handler that write_row() should immediately report constraint - violations because a INSERT...ON DUPLICATE KEY UPDATE is in being - performed. + Inform handler that an "INSERT...ON DUPLICATE KEY UPDATE" will be + executed. This condition is unset by HA_EXTRA_NO_IGNORE_DUP_KEY. */ HA_EXTRA_INSERT_WITH_UPDATE }; diff --git a/sql/ha_federated.cc b/sql/ha_federated.cc index e691831bbc9..8db091669c3 100644 --- a/sql/ha_federated.cc +++ b/sql/ha_federated.cc @@ -2555,6 +2555,10 @@ int ha_federated::extra(ha_extra_function operation) replace_duplicates= TRUE; break; case HA_EXTRA_WRITE_CANNOT_REPLACE: + /* + We use this flag to ensure that we do not create an "INSERT IGNORE" + statement when inserting new rows into the remote table. + */ replace_duplicates= FALSE; break; case HA_EXTRA_INSERT_WITH_UPDATE: From c268fd77c01bc8023ef6d3a25dc6a584c62eea94 Mon Sep 17 00:00:00 2001 From: unknown Date: Fri, 29 Jun 2007 15:14:08 -0700 Subject: [PATCH 16/27] fix Visual Studio build - strictness of compiler could not cast pointer into a BOOL type. --- sql/ha_federated.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sql/ha_federated.cc b/sql/ha_federated.cc index b981af7d8cf..3cf9c2a8b99 100644 --- a/sql/ha_federated.cc +++ b/sql/ha_federated.cc @@ -1686,7 +1686,7 @@ int ha_federated::write_row(byte *buf) uint tmp_length; int error= 0; bool use_bulk_insert; - bool auto_increment_update_required= table->next_number_field; + bool auto_increment_update_required= (table->next_number_field != NULL); /* The string containing the values to be added to the insert */ String values_string(values_buffer, sizeof(values_buffer), &my_charset_bin); From b83c28b2ae07410fedb923b1753ca50bbf2cf5cb Mon Sep 17 00:00:00 2001 From: unknown Date: Sat, 30 Jun 2007 18:17:20 +0200 Subject: [PATCH 17/27] Post-merge fixes. sql/ha_partition.cc: Post-merge fixes. The new function HA_EXTRA_INSERT_WITH_UPDATE needs to be handled in ha_partition::extra(). storage/federated/ha_federated.cc: Post-merge fixes. Removed leftover characters. Added a missing brace. Fixed and improved parenthesis handling in ha_federated::append_stmt_insert(). Moved code from HA_EXTRA_RESET to ha_federated::reset(). storage/federated/ha_federated.h: Post-merge fixes. Changed byte to uchar. Added declaration for ha_federated::reset(). --- sql/ha_partition.cc | 9 +++++ storage/federated/ha_federated.cc | 56 +++++++++++++++++++------------ storage/federated/ha_federated.h | 7 ++-- 3 files changed, 48 insertions(+), 24 deletions(-) diff --git a/sql/ha_partition.cc b/sql/ha_partition.cc index 37e42f7a850..b6a27c8df28 100644 --- a/sql/ha_partition.cc +++ b/sql/ha_partition.cc @@ -4714,6 +4714,12 @@ void ha_partition::get_dynamic_partition_info(PARTITION_INFO *stat_info, HA_EXTRA_KEY_CACHE: HA_EXTRA_NO_KEY_CACHE: This parameters are no longer used and could be removed. + + 7) Parameters only used by federated tables for query processing + ---------------------------------------------------------------- + HA_EXTRA_INSERT_WITH_UPDATE: + Inform handler that an "INSERT...ON DUPLICATE KEY UPDATE" will be + executed. This condition is unset by HA_EXTRA_NO_IGNORE_DUP_KEY. */ int ha_partition::extra(enum ha_extra_function operation) @@ -4795,6 +4801,9 @@ int ha_partition::extra(enum ha_extra_function operation) */ break; } + /* Category 7), used by federated handlers */ + case HA_EXTRA_INSERT_WITH_UPDATE: + DBUG_RETURN(loop_extra(operation)); default: { /* Temporary crash to discover what is wrong */ diff --git a/storage/federated/ha_federated.cc b/storage/federated/ha_federated.cc index 18460ad4cfc..635a6fa79e0 100644 --- a/storage/federated/ha_federated.cc +++ b/storage/federated/ha_federated.cc @@ -608,7 +608,7 @@ static int check_foreign_data_source(FEDERATED_SHARE *share, query.append(STRING_WITH_LEN("SELECT * FROM ")); append_ident(&query, share->table_name, share->table_name_length, ident_quote_char); - query.append(STRING_WITH_LEN(" WHERE 1=0"); + query.append(STRING_WITH_LEN(" WHERE 1=0")); if (mysql_real_query(mysql, query.ptr(), query.length())) { @@ -1572,7 +1572,7 @@ static FEDERATED_SHARE *get_share(const char *table_name, TABLE *table) /* chops off trailing comma */ query.length(query.length() - sizeof_trailing_comma); - query.append(STRING_WITH_LEN(" FROM `")); + query.append(STRING_WITH_LEN(" FROM ")); append_ident(&query, tmp_share.table_name, tmp_share.table_name_length, ident_quote_char); @@ -1809,6 +1809,7 @@ bool ha_federated::append_stmt_insert(String *query) char insert_buffer[FEDERATED_QUERY_BUFFER_SIZE]; Field **field; uint tmp_length; + bool added_field= FALSE; /* The main insert query string */ String insert_string(insert_buffer, sizeof(insert_buffer), &my_charset_bin); @@ -1824,8 +1825,8 @@ bool ha_federated::append_stmt_insert(String *query) insert_string.append(STRING_WITH_LEN("INSERT INTO ")); append_ident(&insert_string, share->table_name, share->table_name_length, ident_quote_char); - insert_string.append(FEDERATED_OPENPAREN); - tmp_length= insert_string.length() - strlen(STRING_WITH_LEN(", ")); + tmp_length= insert_string.length(); + insert_string.append(STRING_WITH_LEN(" (")); /* loop through the field pointer array, add any fields to both the values @@ -1846,22 +1847,20 @@ bool ha_federated::append_stmt_insert(String *query) next field is in the write set */ insert_string.append(STRING_WITH_LEN(", ")); + added_field= TRUE; } } - /* - remove trailing comma - */ - insert_string.length(insert_string.length() - sizeof_trailing_comma); - - /* - if there were no fields, we don't want to add a closing paren - AND, we don't want to chop off the last char '(' - insert will be "INSERT INTO t1 VALUES ();" - */ - if (insert_string.length() > tmp_length) + if (added_field) { - insert_string.append(STRING_WITH_LEN(") "); + /* Remove trailing comma. */ + insert_string.length(insert_string.length() - sizeof_trailing_comma); + insert_string.append(STRING_WITH_LEN(") ")); + } + else + { + /* If there were no fields, we don't want to add a closing paren. */ + insert_string.length(tmp_length); } insert_string.append(STRING_WITH_LEN(" VALUES ")); @@ -2371,6 +2370,7 @@ int ha_federated::delete_row(const uchar *buf) delete_string.append(value_quote_char); } delete_string.append(STRING_WITH_LEN(" AND ")); + } } // Remove trailing AND @@ -2974,11 +2974,6 @@ int ha_federated::extra(ha_extra_function operation) case HA_EXTRA_INSERT_WITH_UPDATE: insert_dup_update= TRUE; break; - case HA_EXTRA_RESET: - insert_dup_update= FALSE; - ignore_duplicates= FALSE; - replace_duplicates= FALSE; - break; default: /* do nothing */ DBUG_PRINT("info",("unhandled operation: %d", (uint) operation)); @@ -2987,6 +2982,25 @@ int ha_federated::extra(ha_extra_function operation) } +/** + @brief Reset state of file to after 'open'. + + @detail This function is called after every statement for all tables + used by that statement. + + @return Operation status + @retval 0 OK +*/ + +int ha_federated::reset(void) +{ + insert_dup_update= FALSE; + ignore_duplicates= FALSE; + replace_duplicates= FALSE; + return 0; +} + + /* Used to delete all rows in a table. Both for cases of truncate and for cases where the optimizer realizes that all rows will be diff --git a/storage/federated/ha_federated.h b/storage/federated/ha_federated.h index 399451888e2..3443194817b 100644 --- a/storage/federated/ha_federated.h +++ b/storage/federated/ha_federated.h @@ -107,9 +107,9 @@ private: bool append_stmt_insert(String *query); - int read_next(byte *buf, MYSQL_RES *result); - int index_read_idx_with_result_set(byte *buf, uint index, - const byte *key, + int read_next(uchar *buf, MYSQL_RES *result); + int index_read_idx_with_result_set(uchar *buf, uint index, + const uchar *key, uint key_len, ha_rkey_function find_flag, MYSQL_RES **result); @@ -251,5 +251,6 @@ public: int connection_rollback(); int connection_autocommit(bool state); int execute_simple_query(const char *query, int len); + int reset(void); }; From 1cd1f7d06fdd6099d8e3378aed1f42bdfbd8c415 Mon Sep 17 00:00:00 2001 From: unknown Date: Sun, 1 Jul 2007 11:56:01 +0200 Subject: [PATCH 18/27] Post.merge fixes Fixed warnings Fixed error numbers mysql-test/extra/rpl_tests/rpl_loaddata.test: Fixed warnings mysql-test/r/ndb_single_user.result: Post-merge fixes Changed error numbers mysql-test/t/bigint.test: Fixed warnings mysql-test/t/ndb_single_user.test: Post-merge fixes Changed error numbers --- mysql-test/extra/rpl_tests/rpl_loaddata.test | 4 ++-- mysql-test/r/ndb_single_user.result | 10 +++++----- mysql-test/t/bigint.test | 2 +- mysql-test/t/ndb_single_user.test | 2 +- 4 files changed, 9 insertions(+), 9 deletions(-) diff --git a/mysql-test/extra/rpl_tests/rpl_loaddata.test b/mysql-test/extra/rpl_tests/rpl_loaddata.test index acd8fd48234..bb6afd73034 100644 --- a/mysql-test/extra/rpl_tests/rpl_loaddata.test +++ b/mysql-test/extra/rpl_tests/rpl_loaddata.test @@ -164,8 +164,8 @@ CREATE TABLE t1 (word CHAR(20) NOT NULL PRIMARY KEY) ENGINE=INNODB; --error ER_DUP_ENTRY LOAD DATA INFILE "../std_data_ln/words.dat" INTO TABLE t1; ---disable warnings +--disable_warnings DROP TABLE IF EXISTS t1; ---enable warnings +--enable_warnings # End of 4.1 tests diff --git a/mysql-test/r/ndb_single_user.result b/mysql-test/r/ndb_single_user.result index 54ae99b2f4f..f916422a509 100644 --- a/mysql-test/r/ndb_single_user.result +++ b/mysql-test/r/ndb_single_user.result @@ -11,7 +11,7 @@ ERROR HY000: Failed to create LOGFILE GROUP show warnings; Level Code Message Error 1296 Got error 299 'Operation not allowed or aborted due to single user mode' from NDB -Error 1516 Failed to create LOGFILE GROUP +Error 1525 Failed to create LOGFILE GROUP create table t1 (a int key, b int unique, c int) engine ndb; CREATE LOGFILE GROUP lg1 ADD UNDOFILE 'undofile.dat' @@ -27,14 +27,14 @@ ERROR HY000: Failed to create TABLESPACE show warnings; Level Code Message Error 1296 Got error 299 'Operation not allowed or aborted due to single user mode' from NDB -Error 1516 Failed to create TABLESPACE +Error 1525 Failed to create TABLESPACE DROP LOGFILE GROUP lg1 ENGINE =NDB; ERROR HY000: Failed to drop LOGFILE GROUP show warnings; Level Code Message Error 1296 Got error 299 'Operation not allowed or aborted due to single user mode' from NDB -Error 1517 Failed to drop LOGFILE GROUP +Error 1526 Failed to drop LOGFILE GROUP CREATE TABLESPACE ts1 ADD DATAFILE 'datafile.dat' USE LOGFILE GROUP lg1 @@ -47,7 +47,7 @@ ERROR HY000: Failed to alter: DROP DATAFILE show warnings; Level Code Message Error 1296 Got error 299 'Operation not allowed or aborted due to single user mode' from NDB -Error 1521 Failed to alter: DROP DATAFILE +Error 1530 Failed to alter: DROP DATAFILE ALTER TABLESPACE ts1 DROP DATAFILE 'datafile.dat' ENGINE NDB; @@ -57,7 +57,7 @@ ERROR HY000: Failed to drop TABLESPACE show warnings; Level Code Message Error 1296 Got error 299 'Operation not allowed or aborted due to single user mode' from NDB -Error 1517 Failed to drop TABLESPACE +Error 1526 Failed to drop TABLESPACE DROP TABLESPACE ts1 ENGINE NDB; DROP LOGFILE GROUP lg1 diff --git a/mysql-test/t/bigint.test b/mysql-test/t/bigint.test index 9b4fc3f39b0..da10f4efa61 100644 --- a/mysql-test/t/bigint.test +++ b/mysql-test/t/bigint.test @@ -307,7 +307,7 @@ select -(9223372036854775808); select -((9223372036854775808)); select -(-(9223372036854775808)); --disable_metadata ---endble_ps_protocol +--enable_ps_protocol select --9223372036854775808, ---9223372036854775808, ----9223372036854775808; select -(-9223372036854775808), -(-(-9223372036854775808)); diff --git a/mysql-test/t/ndb_single_user.test b/mysql-test/t/ndb_single_user.test index 5d2ee0a3a8d..eb7ebe8a971 100644 --- a/mysql-test/t/ndb_single_user.test +++ b/mysql-test/t/ndb_single_user.test @@ -27,7 +27,7 @@ drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9,t10; create table t1 (a int key, b int unique, c int) engine ndb; # Bug #27712 Single user mode. Creating logfile group and tablespace is allowed # - before bug fix these would succeed ---error 1516 +--error ER_CREATE_FILEGROUP_FAILED CREATE LOGFILE GROUP lg1 ADD UNDOFILE 'undofile.dat' INITIAL_SIZE 16M From 63e03007ebda036691aa8c430c894b5cc9306b38 Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 3 Jul 2007 03:56:03 -0700 Subject: [PATCH 19/27] fix bad merge --- mysql-test/r/fulltext2.result | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/mysql-test/r/fulltext2.result b/mysql-test/r/fulltext2.result index 783d9acd8ac..e9bee6f697e 100644 --- a/mysql-test/r/fulltext2.result +++ b/mysql-test/r/fulltext2.result @@ -241,14 +241,6 @@ select * from t1 where match a against('ab c' in boolean mode); a drop table t1; set names latin1; -SET NAMES utf8; -CREATE TABLE t1(a VARCHAR(255), FULLTEXT(a)) ENGINE=MyISAM DEFAULT CHARSET=utf8; -INSERT INTO t1 VALUES('„MySQL“'); -SELECT a FROM t1 WHERE MATCH a AGAINST('“MySQL„' IN BOOLEAN MODE); -a -„MySQL“ -DROP TABLE t1; -SET NAMES latin1; CREATE TABLE t1(a VARCHAR(255) CHARACTER SET gbk, FULLTEXT(a)); SET NAMES utf8; INSERT INTO t1 VALUES(0xF043616161),(0xBEF361616197C22061616161); @@ -261,3 +253,11 @@ Table Op Msg_type Msg_text test.t1 check status OK SET NAMES latin1; DROP TABLE t1; +SET NAMES utf8; +CREATE TABLE t1(a VARCHAR(255), FULLTEXT(a)) ENGINE=MyISAM DEFAULT CHARSET=utf8; +INSERT INTO t1 VALUES('„MySQL“'); +SELECT a FROM t1 WHERE MATCH a AGAINST('“MySQL„' IN BOOLEAN MODE); +a +„MySQL“ +DROP TABLE t1; +SET NAMES latin1; From 1490e79da2448e712ed9d7be53f4b1c1e13ffc1d Mon Sep 17 00:00:00 2001 From: unknown Date: Tue, 3 Jul 2007 08:11:38 -0700 Subject: [PATCH 20/27] move test for bug29299 into seperate file as it requires charset gbk fixes test breakage on sles10-ia64-a which omits charset. mysql-test/r/fulltext2.result: move test for bug29299 into seperate file as it requires charset gbk mysql-test/t/fulltext2.test: move test for bug29299 into seperate file as it requires charset gbk mysql-test/r/fulltext3.result: move test for bug29299 into seperate file as it requires charset gbk mysql-test/t/fulltext3.test: move test for bug29299 into seperate file as it requires charset gbk --- mysql-test/r/fulltext2.result | 12 ------------ mysql-test/r/fulltext3.result | 13 +++++++++++++ mysql-test/t/fulltext2.test | 12 ------------ mysql-test/t/fulltext3.test | 24 ++++++++++++++++++++++++ 4 files changed, 37 insertions(+), 24 deletions(-) create mode 100644 mysql-test/r/fulltext3.result create mode 100644 mysql-test/t/fulltext3.test diff --git a/mysql-test/r/fulltext2.result b/mysql-test/r/fulltext2.result index e9bee6f697e..7e3e25370d3 100644 --- a/mysql-test/r/fulltext2.result +++ b/mysql-test/r/fulltext2.result @@ -241,18 +241,6 @@ select * from t1 where match a against('ab c' in boolean mode); a drop table t1; set names latin1; -CREATE TABLE t1(a VARCHAR(255) CHARACTER SET gbk, FULLTEXT(a)); -SET NAMES utf8; -INSERT INTO t1 VALUES(0xF043616161),(0xBEF361616197C22061616161); -SELECT HEX(a) FROM t1 WHERE MATCH(a) AGAINST(0x97C22061616161 IN BOOLEAN MODE); -HEX(a) -BEF361616197C22061616161 -DELETE FROM t1 LIMIT 1; -CHECK TABLE t1; -Table Op Msg_type Msg_text -test.t1 check status OK -SET NAMES latin1; -DROP TABLE t1; SET NAMES utf8; CREATE TABLE t1(a VARCHAR(255), FULLTEXT(a)) ENGINE=MyISAM DEFAULT CHARSET=utf8; INSERT INTO t1 VALUES('„MySQL“'); diff --git a/mysql-test/r/fulltext3.result b/mysql-test/r/fulltext3.result new file mode 100644 index 00000000000..019d5f472ed --- /dev/null +++ b/mysql-test/r/fulltext3.result @@ -0,0 +1,13 @@ +DROP TABLE IF EXISTS t1; +CREATE TABLE t1(a VARCHAR(255) CHARACTER SET gbk, FULLTEXT(a)); +SET NAMES utf8; +INSERT INTO t1 VALUES(0xF043616161),(0xBEF361616197C22061616161); +SELECT HEX(a) FROM t1 WHERE MATCH(a) AGAINST(0x97C22061616161 IN BOOLEAN MODE); +HEX(a) +BEF361616197C22061616161 +DELETE FROM t1 LIMIT 1; +CHECK TABLE t1; +Table Op Msg_type Msg_text +test.t1 check status OK +SET NAMES latin1; +DROP TABLE t1; diff --git a/mysql-test/t/fulltext2.test b/mysql-test/t/fulltext2.test index cb2e839c41f..88967a5dd04 100644 --- a/mysql-test/t/fulltext2.test +++ b/mysql-test/t/fulltext2.test @@ -220,18 +220,6 @@ select * from t1 where match a against('ab c' in boolean mode); drop table t1; set names latin1; -# -# BUG#29299 - repeatable myisam fulltext index corruption -# -CREATE TABLE t1(a VARCHAR(255) CHARACTER SET gbk, FULLTEXT(a)); -SET NAMES utf8; -INSERT INTO t1 VALUES(0xF043616161),(0xBEF361616197C22061616161); -SELECT HEX(a) FROM t1 WHERE MATCH(a) AGAINST(0x97C22061616161 IN BOOLEAN MODE); -DELETE FROM t1 LIMIT 1; -CHECK TABLE t1; -SET NAMES latin1; -DROP TABLE t1; - # End of 4.1 tests # diff --git a/mysql-test/t/fulltext3.test b/mysql-test/t/fulltext3.test new file mode 100644 index 00000000000..5ca068c066b --- /dev/null +++ b/mysql-test/t/fulltext3.test @@ -0,0 +1,24 @@ +--source include/have_gbk.inc +# +# test of new fulltext search features +# + +--disable_warnings +DROP TABLE IF EXISTS t1; +--enable_warnings + + +# +# BUG#29299 - repeatable myisam fulltext index corruption +# +CREATE TABLE t1(a VARCHAR(255) CHARACTER SET gbk, FULLTEXT(a)); +SET NAMES utf8; +INSERT INTO t1 VALUES(0xF043616161),(0xBEF361616197C22061616161); +SELECT HEX(a) FROM t1 WHERE MATCH(a) AGAINST(0x97C22061616161 IN BOOLEAN MODE); +DELETE FROM t1 LIMIT 1; +CHECK TABLE t1; +SET NAMES latin1; +DROP TABLE t1; + +# End of 4.1 tests + From 435df1859fc503c884cdec9eaceb7f5f102af70d Mon Sep 17 00:00:00 2001 From: unknown Date: Wed, 4 Jul 2007 21:55:26 +0200 Subject: [PATCH 21/27] Bug#26827 - table->read_set is set incorrectly, causing update of a different column For efficiency some storage engines do not read a complete record for update, but only the columns required for selecting the rows. When updating a row of a partitioned table, modifying a column that is part of the partition or subpartition expression, then the row may need to move from one [sub]partition to another one. This is done by inserting the new row into the target [sub]partition and deleting the old row from the originating one. For the insert we need a complete record. If an above mentioned engine was used for a partitioned table, we did not have a complete record in update_row(). The implicitly executed write_row() got an incomplete record. This is solved by instructing the engine to read a complete record if one of the columns of the partition or subpartiton is to be updated. No testcase. This can be reproduced with Falcon only. The engines contained in standard 5.1 do always return complete records on update. sql/ha_partition.cc: Bug#26827 - table->read_set is set incorrectly, causing update of a different column Setting partition field bits in read_set if a writing operation is going on. This replaces the old function include_partition_fields_in_used_fields(). Setting all bits in read_set if write_set contains a column used in a partition or subpartition expression. Removed include_partition_fields_in_used_fields(). sql/ha_partition.h: Bug#26827 - table->read_set is set incorrectly, causing update of a different column Removed declaration of include_partition_fields_in_used_fields(). sql/partition_info.h: Bug#26827 - table->read_set is set incorrectly, causing update of a different column Added a bitmap to partition_info for a quick check of columns used in a partition or subpartition expression. sql/sql_partition.cc: Bug#26827 - table->read_set is set incorrectly, causing update of a different column Initializing the new bitmap with all columns used in a partition or subpartition expression. --- sql/ha_partition.cc | 69 ++++++++++++++++++++++++-------------------- sql/ha_partition.h | 1 - sql/partition_info.h | 7 +++++ sql/sql_partition.cc | 35 ++++++++++++++++++++-- 4 files changed, 77 insertions(+), 35 deletions(-) diff --git a/sql/ha_partition.cc b/sql/ha_partition.cc index 31f59c662d4..e4924e8e8f2 100644 --- a/sql/ha_partition.cc +++ b/sql/ha_partition.cc @@ -2961,8 +2961,34 @@ int ha_partition::rnd_init(bool scan) uint32 part_id; DBUG_ENTER("ha_partition::rnd_init"); - include_partition_fields_in_used_fields(); - + /* + For operations that may need to change data, we may need to extend + read_set. + */ + if (m_lock_type == F_WRLCK) + { + /* + If write_set contains any of the fields used in partition and + subpartition expression, we need to set all bits in read_set because + the row may need to be inserted in a different [sub]partition. In + other words update_row() can be converted into write_row(), which + requires a complete record. + */ + if (bitmap_is_overlapping(&m_part_info->full_part_field_set, + table->write_set)) + bitmap_set_all(table->read_set); + else + { + /* + Some handlers only read fields as specified by the bitmap for the + read set. For partitioned handlers we always require that the + fields of the partition functions are read such that we can + calculate the partition id to place updated and deleted records. + */ + bitmap_union(table->read_set, &m_part_info->full_part_field_set); + } + } + /* Now we see what the index of our first important partition is */ DBUG_PRINT("info", ("m_part_info->used_partitions: 0x%lx", (long) m_part_info->used_partitions.bitmap)); @@ -3276,7 +3302,15 @@ int ha_partition::index_init(uint inx, bool sorted) m_start_key.length= 0; m_ordered= sorted; m_curr_key_info= table->key_info+inx; - include_partition_fields_in_used_fields(); + /* + Some handlers only read fields as specified by the bitmap for the + read set. For partitioned handlers we always require that the + fields of the partition functions are read such that we can + calculate the partition id to place updated and deleted records. + But this is required for operations that may need to change data only. + */ + if (m_lock_type == F_WRLCK) + bitmap_union(table->read_set, &m_part_info->full_part_field_set); file= m_file; do { @@ -4145,35 +4179,6 @@ int ha_partition::handle_ordered_prev(uchar *buf) } -/* - Set fields in partition functions in read set for underlying handlers - - SYNOPSIS - include_partition_fields_in_used_fields() - - RETURN VALUE - NONE - - DESCRIPTION - Some handlers only read fields as specified by the bitmap for the - read set. For partitioned handlers we always require that the - fields of the partition functions are read such that we can - calculate the partition id to place updated and deleted records. -*/ - -void ha_partition::include_partition_fields_in_used_fields() -{ - Field **ptr= m_part_field_array; - DBUG_ENTER("ha_partition::include_partition_fields_in_used_fields"); - - do - { - bitmap_set_bit(table->read_set, (*ptr)->field_index); - } while (*(++ptr)); - DBUG_VOID_RETURN; -} - - /**************************************************************************** MODULE information calls ****************************************************************************/ diff --git a/sql/ha_partition.h b/sql/ha_partition.h index a168007ea04..895f001fa6a 100644 --- a/sql/ha_partition.h +++ b/sql/ha_partition.h @@ -449,7 +449,6 @@ private: int handle_ordered_next(uchar * buf, bool next_same); int handle_ordered_prev(uchar * buf); void return_top_record(uchar * buf); - void include_partition_fields_in_used_fields(); public: /* ------------------------------------------------------------------------- diff --git a/sql/partition_info.h b/sql/partition_info.h index ce2f2a7b358..10edea074c0 100644 --- a/sql/partition_info.h +++ b/sql/partition_info.h @@ -81,6 +81,13 @@ public: */ Field **full_part_field_array; Field **full_part_charset_field_array; + /* + Set of all fields used in partition and subpartition expression. + Required for testing of partition fields in write_set when + updating. We need to set all bits in read_set because the row may + need to be inserted in a different [sub]partition. + */ + MY_BITMAP full_part_field_set; /* When we have a field that requires transformation before calling the diff --git a/sql/sql_partition.cc b/sql/sql_partition.cc index ad3cf2d3e7a..a44af968d9f 100644 --- a/sql/sql_partition.cc +++ b/sql/sql_partition.cc @@ -523,6 +523,7 @@ static bool set_up_field_array(TABLE *table, SYNOPSIS create_full_part_field_array() + thd Thread handle table TABLE object for which partition fields are set-up part_info Reference to partitioning data structure @@ -537,11 +538,12 @@ static bool set_up_field_array(TABLE *table, This function is called from fix_partition_func */ -static bool create_full_part_field_array(TABLE *table, +static bool create_full_part_field_array(THD *thd, TABLE *table, partition_info *part_info) { bool result= FALSE; Field **ptr; + my_bitmap_map *bitmap_buf; DBUG_ENTER("create_full_part_field_array"); if (!part_info->is_sub_partitioned()) @@ -578,6 +580,35 @@ static bool create_full_part_field_array(TABLE *table, part_info->full_part_field_array= field_array; part_info->no_full_part_fields= no_part_fields; } + + /* + Initialize the set of all fields used in partition and subpartition + expression. Required for testing of partition fields in write_set + when updating. We need to set all bits in read_set because the row + may need to be inserted in a different [sub]partition. + */ + if (!(bitmap_buf= (my_bitmap_map*) + thd->alloc(bitmap_buffer_size(table->s->fields)))) + { + mem_alloc_error(bitmap_buffer_size(table->s->fields)); + result= TRUE; + goto end; + } + if (bitmap_init(&part_info->full_part_field_set, bitmap_buf, + table->s->fields, FALSE)) + { + mem_alloc_error(table->s->fields); + result= TRUE; + goto end; + } + /* + full_part_field_array may be NULL if storage engine supports native + partitioning. + */ + if ((ptr= part_info->full_part_field_array)) + while (*ptr) + bitmap_set_bit(&part_info->full_part_field_set, (*ptr++)->field_index); + end: DBUG_RETURN(result); } @@ -1636,7 +1667,7 @@ bool fix_partition_func(THD *thd, TABLE *table, my_error(ER_PARTITION_FUNCTION_IS_NOT_ALLOWED, MYF(0)); goto end; } - if (unlikely(create_full_part_field_array(table, part_info))) + if (unlikely(create_full_part_field_array(thd, table, part_info))) goto end; if (unlikely(check_primary_key(table))) goto end; From b7bf9725852640bf843a5bd5fc83d6a0556406de Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 5 Jul 2007 11:45:14 +0500 Subject: [PATCH 22/27] BUG#27564 - Valgrind: UDF does not cleanup correctly Dropping an user defined function may cause server crash in case this function is still in use by another thread. The problem was that our hash implementation didn't update hash link list properly when hash_update() was called. mysys/hash.c: The following requirement wasn't met by hash_update() function causing corruption of hash links list: After a record was unlinked from the old chain during update, it holds random position. By the chance this position is equal to position for the first element in the new chain. That means updated record is the only record in the new chain. --- mysys/hash.c | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) diff --git a/mysys/hash.c b/mysys/hash.c index 75135a470c9..1ba80dc6fd3 100644 --- a/mysys/hash.c +++ b/mysys/hash.c @@ -572,6 +572,25 @@ my_bool hash_update(HASH *hash,byte *record,byte *old_key,uint old_key_length) previous->next=pos->next; /* unlink pos */ /* Move data to correct position */ + if (new_index == empty) + { + /* + At this point record is unlinked from the old chain, thus it holds + random position. By the chance this position is equal to position + for the first element in the new chain. That means updated record + is the only record in the new chain. + */ + if (empty != idx) + { + /* + Record was moved while unlinking it from the old chain. + Copy data to a new position. + */ + data[empty]= org_link; + } + data[empty].next= NO_RECORD; + DBUG_RETURN(0); + } pos=data+new_index; new_pos_index=hash_rec_mask(hash,pos,blength,records); if (new_index != new_pos_index) From e4ee2c5c08dc8d96f1519c1305416a4f17f1fcc0 Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 5 Jul 2007 12:48:11 +0500 Subject: [PATCH 23/27] BUG#27564 - Valgrind: UDF does not cleanup correctly Enabling rpl_udf test. mysql-test/t/disabled.def: Enabling rpl_udf test. --- mysql-test/t/disabled.def | 1 - 1 file changed, 1 deletion(-) diff --git a/mysql-test/t/disabled.def b/mysql-test/t/disabled.def index 32de2077e81..8a6a91fc169 100644 --- a/mysql-test/t/disabled.def +++ b/mysql-test/t/disabled.def @@ -51,6 +51,5 @@ ndb_partition_error2 : HF is not sure if the test can work as internded on all im_options_set : Bug#20294: Instance manager tests fail randomly im_options_unset : Bug#20294: Instance manager tests fail randomly mysql_upgrade : Bug#28560 test links to /usr/local/mysql/lib libraries, causes non-determinism and failures on ABI breakage -rpl_udf : Bug#28993 rpl_udf test causes server crash and valgrind warning in pushbuild rpl_ndb_circular : Bug#29233 rpl_ndb_circular fails randomly ndb_dd_sql_features : Bug#29102 ndb_dd_sql_features fails in pushbuild From 26af0b96a8d7edb8987ff604f415b3814ee47ece Mon Sep 17 00:00:00 2001 From: unknown Date: Thu, 5 Jul 2007 11:31:03 +0200 Subject: [PATCH 24/27] Bug#26827 - table->read_set is set incorrectly, causing update of a different column Post-pushbuild fix. bitmap_set_bit() is an inline function in DEBUG builds and a macro in non-DEBUG builds. The latter evaluates its 'bit' argument twice. So one must not use increment/decrement operators on this argument. Moved increment of pointer out of bitmap_set_bit() call. include/my_bitmap.h: Bug#26827 - table->read_set is set incorrectly, causing update of a different column Added a warning comment. sql/sql_partition.cc: Bug#26827 - table->read_set is set incorrectly, causing update of a different column Moved increment of pointer out of bitmap_set_bit() call. --- include/my_bitmap.h | 11 +++++++++++ sql/sql_partition.cc | 4 ++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/include/my_bitmap.h b/include/my_bitmap.h index 488c41ffb22..0b12172946a 100644 --- a/include/my_bitmap.h +++ b/include/my_bitmap.h @@ -103,6 +103,17 @@ extern void bitmap_lock_invert(MY_BITMAP *map); &= ~ (1 << ((BIT) & 7))) #define _bitmap_is_set(MAP, BIT) (uint) (((uchar*)(MAP)->bitmap)[(BIT) / 8] \ & (1 << ((BIT) & 7))) +/* + WARNING! + + The below symbols are inline functions in DEBUG builds and macros in + non-DEBUG builds. The latter evaluate their 'bit' argument twice. + + NEVER use an increment/decrement operator with the 'bit' argument. + It would work with DEBUG builds, but fails later in production builds! + + FORBIDDEN: bitmap_set_bit($my_bitmap, (field++)->field_index); +*/ #ifndef DBUG_OFF static inline void bitmap_set_bit(MY_BITMAP *map,uint bit) diff --git a/sql/sql_partition.cc b/sql/sql_partition.cc index a44af968d9f..191859e0ed4 100644 --- a/sql/sql_partition.cc +++ b/sql/sql_partition.cc @@ -606,8 +606,8 @@ static bool create_full_part_field_array(THD *thd, TABLE *table, partitioning. */ if ((ptr= part_info->full_part_field_array)) - while (*ptr) - bitmap_set_bit(&part_info->full_part_field_set, (*ptr++)->field_index); + for (; *ptr; ptr++) + bitmap_set_bit(&part_info->full_part_field_set, (*ptr)->field_index); end: DBUG_RETURN(result); From a077186b7076fa61ab9a10be06cfc9fa3dbe5f34 Mon Sep 17 00:00:00 2001 From: unknown Date: Fri, 6 Jul 2007 11:35:10 -0700 Subject: [PATCH 25/27] fix test for bug29299 --- mysql-test/r/fulltext2.result | 12 ------------ mysql-test/r/fulltext3.result | 13 +++++++++++++ mysql-test/t/fulltext2.test | 12 ------------ mysql-test/t/fulltext3.test | 24 ++++++++++++++++++++++++ 4 files changed, 37 insertions(+), 24 deletions(-) create mode 100644 mysql-test/r/fulltext3.result create mode 100644 mysql-test/t/fulltext3.test diff --git a/mysql-test/r/fulltext2.result b/mysql-test/r/fulltext2.result index f6bb4e4965a..f6a4b20bc22 100644 --- a/mysql-test/r/fulltext2.result +++ b/mysql-test/r/fulltext2.result @@ -241,15 +241,3 @@ select * from t1 where match a against('ab c' in boolean mode); a drop table t1; set names latin1; -CREATE TABLE t1(a VARCHAR(255) CHARACTER SET gbk, FULLTEXT(a)); -SET NAMES utf8; -INSERT INTO t1 VALUES(0xF043616161),(0xBEF361616197C22061616161); -SELECT HEX(a) FROM t1 WHERE MATCH(a) AGAINST(0x97C22061616161 IN BOOLEAN MODE); -HEX(a) -BEF361616197C22061616161 -DELETE FROM t1 LIMIT 1; -CHECK TABLE t1; -Table Op Msg_type Msg_text -test.t1 check status OK -SET NAMES latin1; -DROP TABLE t1; diff --git a/mysql-test/r/fulltext3.result b/mysql-test/r/fulltext3.result new file mode 100644 index 00000000000..019d5f472ed --- /dev/null +++ b/mysql-test/r/fulltext3.result @@ -0,0 +1,13 @@ +DROP TABLE IF EXISTS t1; +CREATE TABLE t1(a VARCHAR(255) CHARACTER SET gbk, FULLTEXT(a)); +SET NAMES utf8; +INSERT INTO t1 VALUES(0xF043616161),(0xBEF361616197C22061616161); +SELECT HEX(a) FROM t1 WHERE MATCH(a) AGAINST(0x97C22061616161 IN BOOLEAN MODE); +HEX(a) +BEF361616197C22061616161 +DELETE FROM t1 LIMIT 1; +CHECK TABLE t1; +Table Op Msg_type Msg_text +test.t1 check status OK +SET NAMES latin1; +DROP TABLE t1; diff --git a/mysql-test/t/fulltext2.test b/mysql-test/t/fulltext2.test index 99209dc8543..fd97f795534 100644 --- a/mysql-test/t/fulltext2.test +++ b/mysql-test/t/fulltext2.test @@ -220,16 +220,4 @@ select * from t1 where match a against('ab c' in boolean mode); drop table t1; set names latin1; -# -# BUG#29299 - repeatable myisam fulltext index corruption -# -CREATE TABLE t1(a VARCHAR(255) CHARACTER SET gbk, FULLTEXT(a)); -SET NAMES utf8; -INSERT INTO t1 VALUES(0xF043616161),(0xBEF361616197C22061616161); -SELECT HEX(a) FROM t1 WHERE MATCH(a) AGAINST(0x97C22061616161 IN BOOLEAN MODE); -DELETE FROM t1 LIMIT 1; -CHECK TABLE t1; -SET NAMES latin1; -DROP TABLE t1; - # End of 4.1 tests diff --git a/mysql-test/t/fulltext3.test b/mysql-test/t/fulltext3.test new file mode 100644 index 00000000000..a57fd48daaa --- /dev/null +++ b/mysql-test/t/fulltext3.test @@ -0,0 +1,24 @@ +--source include/have_gbk.inc +# +# test of new fulltext search features +# + +--disable_warnings +DROP TABLE IF EXISTS t1; +--enable_warnings + + +# +# BUG#29299 - repeatable myisam fulltext index corruption +# +CREATE TABLE t1(a VARCHAR(255) CHARACTER SET gbk, FULLTEXT(a)); +SET NAMES utf8; +INSERT INTO t1 VALUES(0xF043616161),(0xBEF361616197C22061616161); +SELECT HEX(a) FROM t1 WHERE MATCH(a) AGAINST(0x97C22061616161 IN BOOLEAN MODE); +DELETE FROM t1 LIMIT 1; +CHECK TABLE t1; +SET NAMES latin1; +DROP TABLE t1; + +# End of 5.0 tests + From 87e1a302c3bbd0f956883321358da8d1dec0591e Mon Sep 17 00:00:00 2001 From: unknown Date: Sat, 7 Jul 2007 07:46:17 +0200 Subject: [PATCH 26/27] Bug #29543 GCov information not written in case of crash. For GCov builds, if the server crashes, the normal exit handler for writing coverage information is not executed due to the abnormal termination. Fix this by explicitly calling the __gcov_flush function in our crash handler. --- BUILD/compile-pentium-gcov | 5 +++-- sql/stacktrace.c | 9 +++++++++ 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/BUILD/compile-pentium-gcov b/BUILD/compile-pentium-gcov index 26475824570..0d561d5b147 100755 --- a/BUILD/compile-pentium-gcov +++ b/BUILD/compile-pentium-gcov @@ -13,8 +13,9 @@ export LDFLAGS="-fprofile-arcs -ftest-coverage" # The -fprofile-arcs and -ftest-coverage options cause GCC to instrument the # code with profiling information used by gcov. -# the -DDISABLE_TAO_ASM is needed to avoid build failures in Yassl. -extra_flags="$pentium_cflags -fprofile-arcs -ftest-coverage -DDISABLE_TAO_ASM $debug_cflags $max_cflags -DMYSQL_SERVER_SUFFIX=-gcov" +# The -DDISABLE_TAO_ASM is needed to avoid build failures in Yassl. +# The -DHAVE_gcov enables code to write out coverage info even when crashing. +extra_flags="$pentium_cflags -fprofile-arcs -ftest-coverage -DDISABLE_TAO_ASM $debug_cflags $max_cflags -DMYSQL_SERVER_SUFFIX=-gcov -DHAVE_gcov" c_warnings="$c_warnings $debug_extra_warnings" cxx_warnings="$cxx_warnings $debug_extra_warnings" extra_configs="$pentium_configs $debug_configs --disable-shared $static_link" diff --git a/sql/stacktrace.c b/sql/stacktrace.c index d8e9b7fd883..c947beafac3 100644 --- a/sql/stacktrace.c +++ b/sql/stacktrace.c @@ -241,6 +241,15 @@ void write_core(int sig) void write_core(int sig) { signal(sig, SIG_DFL); +#ifdef HAVE_gcov + /* + For GCOV build, crashing will prevent the writing of code coverage + information from this process, causing gcov output to be incomplete. + So we force the writing of coverage information here before terminating. + */ + extern void __gcov_flush(void); + __gcov_flush(); +#endif pthread_kill(pthread_self(), sig); #if defined(P_MYID) && !defined(SCO) /* On Solaris, the above kill is not enough */ From fe00f78d809e3249e170bfce25fb4bc5030fdf71 Mon Sep 17 00:00:00 2001 From: unknown Date: Sat, 7 Jul 2007 09:28:35 -0700 Subject: [PATCH 27/27] disable federated_innodb test until bug29522 is fixed --- mysql-test/t/disabled.def | 1 + 1 file changed, 1 insertion(+) diff --git a/mysql-test/t/disabled.def b/mysql-test/t/disabled.def index 827598d0585..cca73c38831 100644 --- a/mysql-test/t/disabled.def +++ b/mysql-test/t/disabled.def @@ -53,3 +53,4 @@ im_options_set : Bug#20294: Instance manager tests fail randomly im_options_unset : Bug#20294: Instance manager tests fail randomly mysql_upgrade : Bug#28560 test links to /usr/local/mysql/lib libraries, causes non-determinism and failures on ABI breakage ndb_dd_sql_features : Bug#29102 ndb_dd_sql_features fails in pushbuild +federated_innodb : Bug#29522 failed assertion in binlog_close_connection()