summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/not_embedded_server.result5
-rw-r--r--mysql-test/r/ps_grant.result1
-rw-r--r--mysql-test/t/alias.test2
-rw-r--r--mysql-test/t/alter_table.test2
-rw-r--r--mysql-test/t/analyse.test2
-rw-r--r--mysql-test/t/analyze.test21
-rw-r--r--mysql-test/t/ansi.test2
-rw-r--r--mysql-test/t/archive.test2
-rw-r--r--mysql-test/t/auto_increment.test2
-rw-r--r--mysql-test/t/backup.test2
-rw-r--r--mysql-test/t/bdb-alter-table-1.test2
-rw-r--r--mysql-test/t/bdb-alter-table-2.test2
-rw-r--r--mysql-test/t/bdb-crash.test2
-rw-r--r--mysql-test/t/bdb-deadlock.test2
-rw-r--r--mysql-test/t/bdb-deadlock.tminus2
-rw-r--r--mysql-test/t/bdb.test2
-rw-r--r--mysql-test/t/bdb_cache.test2
-rw-r--r--mysql-test/t/bench_count_distinct.test2
-rw-r--r--mysql-test/t/bigint.test2
-rw-r--r--mysql-test/t/binary.test2
-rw-r--r--mysql-test/t/blackhole.test2
-rw-r--r--mysql-test/t/bool.test2
-rw-r--r--mysql-test/t/bulk_replace.test1
-rw-r--r--mysql-test/t/case.test3
-rw-r--r--mysql-test/t/cast.test3
-rw-r--r--mysql-test/t/check.test2
-rw-r--r--mysql-test/t/comments.test2
-rw-r--r--mysql-test/t/compare.test2
-rw-r--r--mysql-test/t/connect.test2
-rw-r--r--mysql-test/t/consistent_snapshot.test2
-rw-r--r--mysql-test/t/constraints.test2
-rw-r--r--mysql-test/t/count_distinct.test2
-rw-r--r--mysql-test/t/count_distinct2.test1
-rw-r--r--mysql-test/t/count_distinct3.test2
-rw-r--r--mysql-test/t/create.test2
-rw-r--r--mysql-test/t/create_select_tmp.test2
-rw-r--r--mysql-test/t/csv.test2
-rw-r--r--mysql-test/t/ctype_big5.test2
-rw-r--r--mysql-test/t/ctype_collate.test2
-rw-r--r--mysql-test/t/ctype_cp1250_ch.test2
-rw-r--r--mysql-test/t/ctype_cp1251.test2
-rw-r--r--mysql-test/t/ctype_create.test2
-rw-r--r--mysql-test/t/ctype_gbk.test2
-rw-r--r--mysql-test/t/ctype_latin1.test2
-rw-r--r--mysql-test/t/ctype_latin1_de.test2
-rw-r--r--mysql-test/t/ctype_latin2.test2
-rw-r--r--mysql-test/t/ctype_many.test2
-rw-r--r--mysql-test/t/ctype_mb.test2
-rw-r--r--mysql-test/t/ctype_recoding.test2
-rw-r--r--mysql-test/t/ctype_sjis.test2
-rw-r--r--mysql-test/t/ctype_tis620.test2
-rw-r--r--mysql-test/t/ctype_uca.test2
-rw-r--r--mysql-test/t/ctype_ucs.test2
-rw-r--r--mysql-test/t/ctype_ucs_binlog.test2
-rw-r--r--mysql-test/t/ctype_ujis.test2
-rw-r--r--mysql-test/t/ctype_utf8.test2
-rw-r--r--mysql-test/t/date_formats.test2
-rw-r--r--mysql-test/t/delayed.test2
-rw-r--r--mysql-test/t/delete.test2
-rw-r--r--mysql-test/t/derived.test2
-rw-r--r--mysql-test/t/dirty_close.test2
-rw-r--r--mysql-test/t/distinct.test2
-rw-r--r--mysql-test/t/drop.test2
-rw-r--r--mysql-test/t/drop_temp_table.test2
-rw-r--r--mysql-test/t/empty_table.test2
-rw-r--r--mysql-test/t/endspace.test2
-rw-r--r--mysql-test/t/errors.test2
-rw-r--r--mysql-test/t/exampledb.test2
-rw-r--r--mysql-test/t/explain.test2
-rw-r--r--mysql-test/t/flush.test2
-rw-r--r--mysql-test/t/flush_block_commit.test2
-rw-r--r--mysql-test/t/flush_table.test2
-rw-r--r--mysql-test/t/foreign_key.test2
-rw-r--r--mysql-test/t/fulltext.test2
-rw-r--r--mysql-test/t/fulltext2.test1
-rw-r--r--mysql-test/t/fulltext_cache.test2
-rw-r--r--mysql-test/t/fulltext_distinct.test2
-rw-r--r--mysql-test/t/fulltext_left_join.test1
-rw-r--r--mysql-test/t/fulltext_multi.test2
-rw-r--r--mysql-test/t/fulltext_order_by.test1
-rw-r--r--mysql-test/t/fulltext_update.test2
-rw-r--r--mysql-test/t/fulltext_var.test1
-rw-r--r--mysql-test/t/func_compress.test1
-rw-r--r--mysql-test/t/func_concat.test1
-rw-r--r--mysql-test/t/func_crypt.test2
-rw-r--r--mysql-test/t/func_date_add.test2
-rw-r--r--mysql-test/t/func_default.test2
-rw-r--r--mysql-test/t/func_des_encrypt.test2
-rw-r--r--mysql-test/t/func_encrypt.test2
-rw-r--r--mysql-test/t/func_encrypt_nossl.test1
-rw-r--r--mysql-test/t/func_equal.test2
-rw-r--r--mysql-test/t/func_gconcat.test2
-rw-r--r--mysql-test/t/func_group.test64
-rw-r--r--mysql-test/t/func_if.test2
-rw-r--r--mysql-test/t/func_in.test2
-rw-r--r--mysql-test/t/func_isnull.test2
-rw-r--r--mysql-test/t/func_like.test1
-rw-r--r--mysql-test/t/func_math.test2
-rw-r--r--mysql-test/t/func_misc.test8
-rw-r--r--mysql-test/t/func_op.test2
-rw-r--r--mysql-test/t/func_regexp.test2
-rw-r--r--mysql-test/t/func_sapdb.test2
-rw-r--r--mysql-test/t/func_set.test1
-rw-r--r--mysql-test/t/func_str.test2
-rw-r--r--mysql-test/t/func_system.test2
-rw-r--r--mysql-test/t/func_test.test2
-rw-r--r--mysql-test/t/func_time.test3
-rw-r--r--mysql-test/t/func_timestamp.test2
-rw-r--r--mysql-test/t/gcc296.test2
-rw-r--r--mysql-test/t/gis-rtree.test2
-rw-r--r--mysql-test/t/gis.test2
-rw-r--r--mysql-test/t/grant.test2
-rw-r--r--mysql-test/t/grant2.test2
-rw-r--r--mysql-test/t/grant_cache.test2
-rw-r--r--mysql-test/t/group_by.test2
-rw-r--r--mysql-test/t/handler.test2
-rw-r--r--mysql-test/t/having.test2
-rw-r--r--mysql-test/t/heap.test2
-rw-r--r--mysql-test/t/heap_auto_increment.test2
-rw-r--r--mysql-test/t/heap_btree.test2
-rw-r--r--mysql-test/t/heap_hash.test2
-rw-r--r--mysql-test/t/help.test2
-rw-r--r--mysql-test/t/init_connect.test2
-rw-r--r--mysql-test/t/init_file.test2
-rw-r--r--mysql-test/t/innodb-deadlock.test2
-rw-r--r--mysql-test/t/innodb-lock.test2
-rw-r--r--mysql-test/t/innodb-replace.test1
-rw-r--r--mysql-test/t/innodb.test3
-rw-r--r--mysql-test/t/innodb_cache.test1
-rw-r--r--mysql-test/t/innodb_handler.test1
-rw-r--r--mysql-test/t/insert.test6
-rw-r--r--mysql-test/t/insert_select-binlog.test1
-rw-r--r--mysql-test/t/insert_select.test2
-rw-r--r--mysql-test/t/insert_update.test2
-rw-r--r--mysql-test/t/join.test2
-rw-r--r--mysql-test/t/join_crash.test2
-rw-r--r--mysql-test/t/join_outer.test5
-rw-r--r--mysql-test/t/key.test2
-rw-r--r--mysql-test/t/key_cache.test2
-rw-r--r--mysql-test/t/key_diff.test2
-rw-r--r--mysql-test/t/key_primary.test2
-rw-r--r--mysql-test/t/keywords.test2
-rw-r--r--mysql-test/t/kill.test2
-rw-r--r--mysql-test/t/limit.test2
-rw-r--r--mysql-test/t/loaddata.test2
-rw-r--r--mysql-test/t/lock.test2
-rw-r--r--mysql-test/t/lock_multi.test3
-rw-r--r--mysql-test/t/lock_tables_lost_commit.test2
-rw-r--r--mysql-test/t/lowercase_table.test1
-rw-r--r--mysql-test/t/lowercase_table2.test2
-rw-r--r--mysql-test/t/lowercase_table3.test2
-rw-r--r--mysql-test/t/lowercase_table_grant.test2
-rw-r--r--mysql-test/t/lowercase_table_qcache.test2
-rw-r--r--mysql-test/t/merge.test1
-rw-r--r--mysql-test/t/metadata.test2
-rw-r--r--mysql-test/t/mix_innodb_myisam_binlog.test2
-rw-r--r--mysql-test/t/multi_statement.test2
-rw-r--r--mysql-test/t/multi_update.test2
-rw-r--r--mysql-test/t/myisam-blob.test2
-rw-r--r--mysql-test/t/myisam.test1
-rw-r--r--mysql-test/t/mysql_client_test.test2
-rw-r--r--mysql-test/t/mysql_protocols.test1
-rw-r--r--mysql-test/t/mysqlbinlog.test1
-rw-r--r--mysql-test/t/mysqlbinlog2.test2
-rw-r--r--mysql-test/t/mysqldump.test86
-rw-r--r--mysql-test/t/mysqltest.test3
-rw-r--r--mysql-test/t/ndb_alter_table.test2
-rw-r--r--mysql-test/t/ndb_autodiscover.test2
-rw-r--r--mysql-test/t/ndb_autodiscover2.test1
-rw-r--r--mysql-test/t/ndb_basic.test1
-rw-r--r--mysql-test/t/ndb_blob.test2
-rw-r--r--mysql-test/t/ndb_cache.test2
-rw-r--r--mysql-test/t/ndb_charset.test2
-rw-r--r--mysql-test/t/ndb_config.test2
-rw-r--r--mysql-test/t/ndb_database.test2
-rw-r--r--mysql-test/t/ndb_grant.later2
-rw-r--r--mysql-test/t/ndb_index.test3
-rw-r--r--mysql-test/t/ndb_index_ordered.test2
-rw-r--r--mysql-test/t/ndb_index_unique.test2
-rw-r--r--mysql-test/t/ndb_insert.test2
-rw-r--r--mysql-test/t/ndb_limit.test2
-rw-r--r--mysql-test/t/ndb_lock.test1
-rw-r--r--mysql-test/t/ndb_minmax.test4
-rw-r--r--mysql-test/t/ndb_multi.test2
-rw-r--r--mysql-test/t/ndb_replace.test2
-rw-r--r--mysql-test/t/ndb_restore.test2
-rw-r--r--mysql-test/t/ndb_subquery.test5
-rw-r--r--mysql-test/t/ndb_transaction.test2
-rw-r--r--mysql-test/t/ndb_truncate.test2
-rw-r--r--mysql-test/t/ndb_types.test2
-rw-r--r--mysql-test/t/ndb_update.test2
-rw-r--r--mysql-test/t/negation_elimination.test2
-rw-r--r--mysql-test/t/not_embedded_server.test18
-rw-r--r--mysql-test/t/null.test2
-rw-r--r--mysql-test/t/null_key.test2
-rw-r--r--mysql-test/t/odbc.test2
-rw-r--r--mysql-test/t/olap.test2
-rw-r--r--mysql-test/t/openssl_1.test2
-rw-r--r--mysql-test/t/order_by.test2
-rw-r--r--mysql-test/t/order_fill_sortbuf.test2
-rw-r--r--mysql-test/t/outfile.test2
-rw-r--r--mysql-test/t/overflow.test2
-rw-r--r--mysql-test/t/packet.test2
-rw-r--r--mysql-test/t/preload.test2
-rw-r--r--mysql-test/t/ps.test2
-rw-r--r--mysql-test/t/ps_10nestset.test2
-rw-r--r--mysql-test/t/ps_11bugs.test1
-rw-r--r--mysql-test/t/ps_1general.test2
-rw-r--r--mysql-test/t/ps_2myisam.test2
-rw-r--r--mysql-test/t/ps_3innodb.test2
-rw-r--r--mysql-test/t/ps_4heap.test2
-rw-r--r--mysql-test/t/ps_5merge.test2
-rw-r--r--mysql-test/t/ps_6bdb.test2
-rw-r--r--mysql-test/t/ps_7ndb.test2
-rw-r--r--mysql-test/t/ps_grant.test15
-rw-r--r--mysql-test/t/query_cache.test2
-rw-r--r--mysql-test/t/query_cache_merge.test2
-rw-r--r--mysql-test/t/raid.test2
-rw-r--r--mysql-test/t/range.test2
-rw-r--r--mysql-test/t/rename.test2
-rw-r--r--mysql-test/t/repair.test2
-rw-r--r--mysql-test/t/replace.test2
-rw-r--r--mysql-test/t/rollback.test2
-rw-r--r--mysql-test/t/row.test2
-rw-r--r--mysql-test/t/rpl000001.test2
-rw-r--r--mysql-test/t/rpl000002.test2
-rw-r--r--mysql-test/t/rpl000004.test2
-rw-r--r--mysql-test/t/rpl000005.test2
-rw-r--r--mysql-test/t/rpl000006.test2
-rw-r--r--mysql-test/t/rpl000008.test2
-rw-r--r--mysql-test/t/rpl000009.test2
-rw-r--r--mysql-test/t/rpl000010.test1
-rw-r--r--mysql-test/t/rpl000011.test2
-rw-r--r--mysql-test/t/rpl000012.test2
-rw-r--r--mysql-test/t/rpl000013.test2
-rw-r--r--mysql-test/t/rpl000015.test2
-rw-r--r--mysql-test/t/rpl000017.test2
-rw-r--r--mysql-test/t/rpl000018.test2
-rw-r--r--mysql-test/t/rpl_EE_error.test2
-rw-r--r--mysql-test/t/rpl_alter.test2
-rw-r--r--mysql-test/t/rpl_chain_temp_table.test2
-rw-r--r--mysql-test/t/rpl_change_master.test2
-rw-r--r--mysql-test/t/rpl_charset.test2
-rw-r--r--mysql-test/t/rpl_commit_after_flush.test2
-rw-r--r--mysql-test/t/rpl_create_database.test2
-rw-r--r--mysql-test/t/rpl_ddl.test2
-rw-r--r--mysql-test/t/rpl_deadlock.test2
-rw-r--r--mysql-test/t/rpl_delete_all.test2
-rw-r--r--mysql-test/t/rpl_do_grant.test2
-rw-r--r--mysql-test/t/rpl_drop.test2
-rw-r--r--mysql-test/t/rpl_drop_temp.test1
-rw-r--r--mysql-test/t/rpl_empty_master_crash.test2
-rw-r--r--mysql-test/t/rpl_error_ignored_table.test2
-rw-r--r--mysql-test/t/rpl_failed_optimize.test2
-rw-r--r--mysql-test/t/rpl_failsafe.test2
-rw-r--r--mysql-test/t/rpl_flush_log_loop.test2
-rw-r--r--mysql-test/t/rpl_flush_tables.test2
-rw-r--r--mysql-test/t/rpl_free_items.test2
-rw-r--r--mysql-test/t/rpl_get_lock.test2
-rw-r--r--mysql-test/t/rpl_heap.test2
-rw-r--r--mysql-test/t/rpl_ignore_grant.test2
-rw-r--r--mysql-test/t/rpl_init_slave.test2
-rw-r--r--mysql-test/t/rpl_innodb.test2
-rw-r--r--mysql-test/t/rpl_insert_id.test4
-rw-r--r--mysql-test/t/rpl_insert_ignore.test2
-rw-r--r--mysql-test/t/rpl_loaddata.test2
-rw-r--r--mysql-test/t/rpl_loaddata_rule_m.test2
-rw-r--r--mysql-test/t/rpl_loaddata_rule_s.test2
-rw-r--r--mysql-test/t/rpl_loaddatalocal.test2
-rw-r--r--mysql-test/t/rpl_log.test2
-rw-r--r--mysql-test/t/rpl_log_pos.test2
-rw-r--r--mysql-test/t/rpl_many_optimize.test2
-rw-r--r--mysql-test/t/rpl_master_pos_wait.test2
-rw-r--r--mysql-test/t/rpl_max_relay_size.test2
-rw-r--r--mysql-test/t/rpl_misc_functions.test2
-rw-r--r--mysql-test/t/rpl_multi_delete.test2
-rw-r--r--mysql-test/t/rpl_multi_delete2.test2
-rw-r--r--mysql-test/t/rpl_multi_query.test2
-rw-r--r--mysql-test/t/rpl_multi_update.test2
-rw-r--r--mysql-test/t/rpl_multi_update2.test2
-rw-r--r--mysql-test/t/rpl_multi_update3.test2
-rw-r--r--mysql-test/t/rpl_mystery22.test1
-rw-r--r--mysql-test/t/rpl_openssl.test2
-rw-r--r--mysql-test/t/rpl_optimize.test2
-rw-r--r--mysql-test/t/rpl_ps.test1
-rw-r--r--mysql-test/t/rpl_redirect.test2
-rw-r--r--mysql-test/t/rpl_relayrotate.test2
-rw-r--r--mysql-test/t/rpl_relayspace.test2
-rw-r--r--mysql-test/t/rpl_replicate_do.test1
-rw-r--r--mysql-test/t/rpl_reset_slave.test2
-rw-r--r--mysql-test/t/rpl_rewrite_db.test1
-rw-r--r--mysql-test/t/rpl_rotate_logs.test1
-rw-r--r--mysql-test/t/rpl_server_id1.test2
-rw-r--r--mysql-test/t/rpl_server_id2.test2
-rw-r--r--mysql-test/t/rpl_set_charset.test2
-rw-r--r--mysql-test/t/rpl_skip_error.test2
-rw-r--r--mysql-test/t/rpl_sporadic_master.test2
-rw-r--r--mysql-test/t/rpl_start_stop_slave.test2
-rw-r--r--mysql-test/t/rpl_temporary.test2
-rw-r--r--mysql-test/t/rpl_timezone.test2
-rw-r--r--mysql-test/t/rpl_until.test2
-rw-r--r--mysql-test/t/rpl_user_variables.test2
-rw-r--r--mysql-test/t/rpl_variables.test2
-rw-r--r--mysql-test/t/select.test2
-rw-r--r--mysql-test/t/select_found.test2
-rw-r--r--mysql-test/t/select_safe.test2
-rw-r--r--mysql-test/t/show_check.test2
-rw-r--r--mysql-test/t/skip_name_resolve.test2
-rw-r--r--mysql-test/t/sql_mode.test2
-rw-r--r--mysql-test/t/status.test2
-rw-r--r--mysql-test/t/subselect.test2
-rw-r--r--mysql-test/t/subselect2.test3
-rw-r--r--mysql-test/t/subselect_gis.test2
-rw-r--r--mysql-test/t/subselect_innodb.test2
-rw-r--r--mysql-test/t/symlink.test2
-rw-r--r--mysql-test/t/synchronization.test2
-rw-r--r--mysql-test/t/system_mysql_db.test2
-rw-r--r--mysql-test/t/system_mysql_db_fix.test2
-rw-r--r--mysql-test/t/system_mysql_db_refs.test2
-rw-r--r--mysql-test/t/tablelock.test2
-rw-r--r--mysql-test/t/temp_table.test2
-rw-r--r--mysql-test/t/timezone.test2
-rw-r--r--mysql-test/t/timezone2.test2
-rw-r--r--mysql-test/t/timezone3.test2
-rw-r--r--mysql-test/t/timezone_grant.test1
-rw-r--r--mysql-test/t/truncate.test2
-rw-r--r--mysql-test/t/type_blob.test2
-rw-r--r--mysql-test/t/type_date.test2
-rw-r--r--mysql-test/t/type_datetime.test2
-rw-r--r--mysql-test/t/type_decimal.test4
-rw-r--r--mysql-test/t/type_enum.test2
-rw-r--r--mysql-test/t/type_float.test2
-rw-r--r--mysql-test/t/type_nchar.test1
-rw-r--r--mysql-test/t/type_ranges.test2
-rw-r--r--mysql-test/t/type_set.test2
-rw-r--r--mysql-test/t/type_time.test2
-rw-r--r--mysql-test/t/type_timestamp.test1
-rw-r--r--mysql-test/t/type_uint.test2
-rw-r--r--mysql-test/t/type_year.test2
-rw-r--r--mysql-test/t/union.test2
-rw-r--r--mysql-test/t/update.test2
-rw-r--r--mysql-test/t/user_var-binlog.test2
-rw-r--r--mysql-test/t/user_var.test2
-rw-r--r--mysql-test/t/varbinary.test2
-rw-r--r--mysql-test/t/variables.test2
-rw-r--r--mysql-test/t/warnings.test2
346 files changed, 768 insertions, 116 deletions
diff --git a/mysql-test/r/not_embedded_server.result b/mysql-test/r/not_embedded_server.result
new file mode 100644
index 00000000000..082ebe72ba4
--- /dev/null
+++ b/mysql-test/r/not_embedded_server.result
@@ -0,0 +1,5 @@
+prepare stmt1 from ' show full processlist ';
+execute stmt1;
+Id User Host db Command Time State Info
+number root localhost test Execute time NULL show full processlist
+deallocate prepare stmt1;
diff --git a/mysql-test/r/ps_grant.result b/mysql-test/r/ps_grant.result
index 651ac171e5d..fa963f944b5 100644
--- a/mysql-test/r/ps_grant.result
+++ b/mysql-test/r/ps_grant.result
@@ -54,6 +54,7 @@ my_col
4
execute s_t9 ;
ERROR 42S02: Table 'mysqltest.t9' doesn't exist
+deallocate prepare s_t9;
revoke all privileges on mysqltest.t1 from second_user@localhost
identified by 'looser' ;
show grants for second_user@localhost ;
diff --git a/mysql-test/t/alias.test b/mysql-test/t/alias.test
index cfa8ec7f18a..2746409c7e5 100644
--- a/mysql-test/t/alias.test
+++ b/mysql-test/t/alias.test
@@ -86,3 +86,5 @@ UPDATE t1 SET t1.xstatus_vor = Greatest(t1.xstatus_vor,1) WHERE t1.aufnr =
ASC LIMIT 1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/alter_table.test b/mysql-test/t/alter_table.test
index c3ba2c8a7a4..a237b21f403 100644
--- a/mysql-test/t/alter_table.test
+++ b/mysql-test/t/alter_table.test
@@ -360,3 +360,5 @@ create table t1 ( a timestamp );
--error 1089
alter table t1 add unique ( a(1) );
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/analyse.test b/mysql-test/t/analyse.test
index f5523f83226..2003feee163 100644
--- a/mysql-test/t/analyse.test
+++ b/mysql-test/t/analyse.test
@@ -48,6 +48,8 @@ insert into t1 values ('abc'),('abc\'def\\hij\"klm\0opq'),('\''),('\"'),('\\'),(
select * from t1 procedure analyse();
drop table t1;
+# End of 4.1 tests
+
#decimal-related test
create table t1 (df decimal(5,1));
diff --git a/mysql-test/t/analyze.test b/mysql-test/t/analyze.test
index faf30279c68..3c3b3933bc3 100644
--- a/mysql-test/t/analyze.test
+++ b/mysql-test/t/analyze.test
@@ -1,16 +1,18 @@
#
# Bug #10901 Analyze Table on new table destroys table
# This is minimal test case to get error
-# The problem was that analyze table wrote the shared state to the file and this
-# didn't include the inserts while locked. A check was needed to ensure that
-# state information was not updated when executing analyze table for a locked table.
-# The analyze table had to be within locks and check table had to be after unlocking
-# since then it brings the wrong state from disk rather than from the currently
-# correct internal state. The insert is needed since it changes the file state,
-# number of records.
-# The fix is to synchronise the state of the shared state and the current state before
-# calling mi_state_info_write
+# The problem was that analyze table wrote the shared state to the
+# file and this didn't include the inserts while locked. A check was
+# needed to ensure that state information was not updated when
+# executing analyze table for a locked table. The analyze table had
+# to be within locks and check table had to be after unlocking since
+# then it brings the wrong state from disk rather than from the
+# currently correct internal state. The insert is needed since it
+# changes the file state, number of records. The fix is to
+# synchronise the state of the shared state and the current state
+# before calling mi_state_info_write
#
+
create table t1 (a bigint);
lock tables t1 write;
insert into t1 values(0);
@@ -37,3 +39,4 @@ check table t1;
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/ansi.test b/mysql-test/t/ansi.test
index 9d235df5b46..444bf982b8a 100644
--- a/mysql-test/t/ansi.test
+++ b/mysql-test/t/ansi.test
@@ -25,3 +25,5 @@ SELECT id FROM t1 GROUP BY id2;
drop table t1;
SET @@SQL_MODE="";
+
+# End of 4.1 tests
diff --git a/mysql-test/t/archive.test b/mysql-test/t/archive.test
index a42a42b2a4e..d756bf765be 100644
--- a/mysql-test/t/archive.test
+++ b/mysql-test/t/archive.test
@@ -1333,3 +1333,5 @@ INSERT DELAYED INTO t2 VALUES (4,011403,37,'intercepted','audiology','tinily',''
# Cleanup, test is over
#
drop table t1, t2, t4;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/auto_increment.test b/mysql-test/t/auto_increment.test
index afc4c722051..b20fe80303d 100644
--- a/mysql-test/t/auto_increment.test
+++ b/mysql-test/t/auto_increment.test
@@ -219,6 +219,8 @@ INSERT INTO t1 (b) VALUES ('bbbb');
CHECK TABLE t1;
DROP TABLE IF EXISTS t1;
+# End of 4.1 tests
+
#
# Bug #11080 & #11005 Multi-row REPLACE fails on a duplicate key error
#
diff --git a/mysql-test/t/backup.test b/mysql-test/t/backup.test
index 8b3a46724ab..3034129ad4b 100644
--- a/mysql-test/t/backup.test
+++ b/mysql-test/t/backup.test
@@ -52,3 +52,5 @@ unlock tables;
connection con1;
reap;
drop table t5;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/bdb-alter-table-1.test b/mysql-test/t/bdb-alter-table-1.test
index 18b6c70758f..9cb469a8df6 100644
--- a/mysql-test/t/bdb-alter-table-1.test
+++ b/mysql-test/t/bdb-alter-table-1.test
@@ -14,3 +14,5 @@ select * from t1;
alter table t1 drop column test;
# Now we do a reboot and continue with the next test
+
+# End of 4.1 tests
diff --git a/mysql-test/t/bdb-alter-table-2.test b/mysql-test/t/bdb-alter-table-2.test
index a474efe42e1..15b8938a11d 100644
--- a/mysql-test/t/bdb-alter-table-2.test
+++ b/mysql-test/t/bdb-alter-table-2.test
@@ -6,3 +6,5 @@
-- source include/have_bdb.inc
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/bdb-crash.test b/mysql-test/t/bdb-crash.test
index 3cd78821000..75f4d04d5df 100644
--- a/mysql-test/t/bdb-crash.test
+++ b/mysql-test/t/bdb-crash.test
@@ -47,3 +47,5 @@ set autocommit=0;
insert into t1 values(1);
analyze table t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/bdb-deadlock.test b/mysql-test/t/bdb-deadlock.test
index 5e6ca666cc2..88243cfc860 100644
--- a/mysql-test/t/bdb-deadlock.test
+++ b/mysql-test/t/bdb-deadlock.test
@@ -55,3 +55,5 @@ select * from t2;
commit;
drop table t1,t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/bdb-deadlock.tminus b/mysql-test/t/bdb-deadlock.tminus
index d86403fcffc..3918a8ffe9d 100644
--- a/mysql-test/t/bdb-deadlock.tminus
+++ b/mysql-test/t/bdb-deadlock.tminus
@@ -55,3 +55,5 @@ select * from t2;
commit;
drop table t1,t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/bdb.test b/mysql-test/t/bdb.test
index f4895318818..c1abe011be4 100644
--- a/mysql-test/t/bdb.test
+++ b/mysql-test/t/bdb.test
@@ -937,6 +937,8 @@ SELECT id FROM t1 WHERE (list_id = 1) AND (term = "lettera");
SELECT id FROM t1 WHERE (list_id = 1) AND (term = "letterd");
DROP TABLE t1;
+# End of 4.1 tests
+
#
# alter temp table
#
diff --git a/mysql-test/t/bdb_cache.test b/mysql-test/t/bdb_cache.test
index 401456711ac..85328920d71 100644
--- a/mysql-test/t/bdb_cache.test
+++ b/mysql-test/t/bdb_cache.test
@@ -49,3 +49,5 @@ show status like "Qcache_hits";
commit;
show status like "Qcache_queries_in_cache";
drop table if exists t1, t2, t3;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/bench_count_distinct.test b/mysql-test/t/bench_count_distinct.test
index 3ffb95a69c2..131208f1fa1 100644
--- a/mysql-test/t/bench_count_distinct.test
+++ b/mysql-test/t/bench_count_distinct.test
@@ -18,3 +18,5 @@ enable_query_log;
select count(distinct n) from t1;
explain extended select count(distinct n) from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/bigint.test b/mysql-test/t/bigint.test
index 99c8a13d0b5..5c06ef89676 100644
--- a/mysql-test/t/bigint.test
+++ b/mysql-test/t/bigint.test
@@ -104,6 +104,8 @@ t2.value64=t1.value64;
drop table t1, t2;
+# End of 4.1 tests
+
#
# Test of CREATE ... SELECT and unsigned integers
#
diff --git a/mysql-test/t/binary.test b/mysql-test/t/binary.test
index 54ad8e92237..02773b32302 100644
--- a/mysql-test/t/binary.test
+++ b/mysql-test/t/binary.test
@@ -87,3 +87,5 @@ drop table t1;
create table t1 (a binary);
show create table t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/blackhole.test b/mysql-test/t/blackhole.test
index d1fcfc971a9..257770d311c 100644
--- a/mysql-test/t/blackhole.test
+++ b/mysql-test/t/blackhole.test
@@ -125,3 +125,5 @@ let $VERSION=`select version()`;
show binlog events;
drop table t1,t2,t3;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/bool.test b/mysql-test/t/bool.test
index 53230dd5fa3..34c51c648d3 100644
--- a/mysql-test/t/bool.test
+++ b/mysql-test/t/bool.test
@@ -58,3 +58,5 @@ select ifnull(A, 'N') as A, ifnull(B, 'N') as B, ifnull(not A, 'N') as nA, ifnul
select ifnull(A=1, 'N') as A, ifnull(B=1, 'N') as B, ifnull(not (A=1), 'N') as nA, ifnull(not (B=1), 'N') as nB, ifnull((A=1) and (B=1), 'N') as AB, ifnull(not ((A=1) and (B=1)), 'N') as `n(AB)`, ifnull((not (A=1) or not (B=1)), 'N') as nAonB, ifnull((A=1) or (B=1), 'N') as AoB, ifnull(not((A=1) or (B=1)), 'N') as `n(AoB)`, ifnull(not (A=1) and not (B=1), 'N') as nAnB from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/bulk_replace.test b/mysql-test/t/bulk_replace.test
index 755d34083f8..4e567c43104 100644
--- a/mysql-test/t/bulk_replace.test
+++ b/mysql-test/t/bulk_replace.test
@@ -11,3 +11,4 @@ select * from t1;
check table t1;
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/case.test b/mysql-test/t/case.test
index e942333d5fe..555e34d5cf2 100644
--- a/mysql-test/t/case.test
+++ b/mysql-test/t/case.test
@@ -122,6 +122,9 @@ SELECT 'case+union+test'
UNION
SELECT CASE '1' WHEN '2' THEN 'BUG' ELSE 'nobug' END;
+# End of 4.1 tests
+
+
#
# Tests for bug #9939: conversion of the arguments for COALESCE and IFNULL
#
diff --git a/mysql-test/t/cast.test b/mysql-test/t/cast.test
index 356b69daf38..2049c17580e 100644
--- a/mysql-test/t/cast.test
+++ b/mysql-test/t/cast.test
@@ -156,6 +156,9 @@ select cast(concat('184467440','73709551615') as signed);
select cast(repeat('1',20) as unsigned);
select cast(repeat('1',20) as signed);
+# End of 4.1 tests
+
+
#decimal-related additions
select cast('1.2' as decimal(3,2));
select 1e18 * cast('1.2' as decimal(3,2));
diff --git a/mysql-test/t/check.test b/mysql-test/t/check.test
index c502655818d..8d9d70bd29a 100644
--- a/mysql-test/t/check.test
+++ b/mysql-test/t/check.test
@@ -22,6 +22,8 @@ connection con1;
reap;
drop table t1;
+# End of 4.1 tests
+
#
# Bug #9897 Views: 'Check Table' crashes MySQL, with a view and a table
# in the statement
diff --git a/mysql-test/t/comments.test b/mysql-test/t/comments.test
index 087df60f3f5..52273ec9523 100644
--- a/mysql-test/t/comments.test
+++ b/mysql-test/t/comments.test
@@ -17,3 +17,5 @@ select 1 --2
select 1 # The rest of the row will be ignored
;
/* line with only comment */;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/compare.test b/mysql-test/t/compare.test
index bc20786227b..a42ba5ac88a 100644
--- a/mysql-test/t/compare.test
+++ b/mysql-test/t/compare.test
@@ -35,3 +35,5 @@ DROP TABLE t1;
SELECT CHAR(31) = '', '' = CHAR(31);
# Extra test
SELECT CHAR(30) = '', '' = CHAR(30);
+
+# End of 4.1 tests
diff --git a/mysql-test/t/connect.test b/mysql-test/t/connect.test
index 5d2d53a2a90..64b170970ca 100644
--- a/mysql-test/t/connect.test
+++ b/mysql-test/t/connect.test
@@ -76,3 +76,5 @@ show tables;
delete from mysql.user where user=_binary"test";
flush privileges;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/consistent_snapshot.test b/mysql-test/t/consistent_snapshot.test
index 7afdae36325..8da8e9ce660 100644
--- a/mysql-test/t/consistent_snapshot.test
+++ b/mysql-test/t/consistent_snapshot.test
@@ -39,3 +39,5 @@ select * from t1; # if consistent snapshot was not set, as expected, we
commit;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/constraints.test b/mysql-test/t/constraints.test
index dbc34a0dff1..ed268ab5846 100644
--- a/mysql-test/t/constraints.test
+++ b/mysql-test/t/constraints.test
@@ -27,3 +27,5 @@ alter table t1 add constraint unique key_1(a);
alter table t1 add constraint constraint_2 unique key_2(a);
show create table t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/count_distinct.test b/mysql-test/t/count_distinct.test
index be67026e268..e63bdabdb95 100644
--- a/mysql-test/t/count_distinct.test
+++ b/mysql-test/t/count_distinct.test
@@ -55,6 +55,8 @@ create table t1 (f int);
select count(distinct f) from t1;
drop table t1;
+# End of 4.1 tests
+
#
# Bug #6515
#
diff --git a/mysql-test/t/count_distinct2.test b/mysql-test/t/count_distinct2.test
index 2b982e3e620..8dcb2a70065 100644
--- a/mysql-test/t/count_distinct2.test
+++ b/mysql-test/t/count_distinct2.test
@@ -79,3 +79,4 @@ select count(distinct s) from t1;
show status like 'Created_tmp_disk_tables';
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/count_distinct3.test b/mysql-test/t/count_distinct3.test
index 9d2bb0d139a..52a4f271dac 100644
--- a/mysql-test/t/count_distinct3.test
+++ b/mysql-test/t/count_distinct3.test
@@ -56,3 +56,5 @@ SELECT COUNT(DISTINCT id) FROM t1 GROUP BY grp;
DROP TABLE t1;
set @@read_buffer_size=default;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/create.test b/mysql-test/t/create.test
index 5b334d1d31e..4e86a51e131 100644
--- a/mysql-test/t/create.test
+++ b/mysql-test/t/create.test
@@ -514,3 +514,5 @@ create table test.t1 like x;
--disable_warnings
drop table if exists test.t1;
--enable_warnings
+
+# End of 4.1 tests
diff --git a/mysql-test/t/create_select_tmp.test b/mysql-test/t/create_select_tmp.test
index d81a3799d98..2e4c0f22997 100644
--- a/mysql-test/t/create_select_tmp.test
+++ b/mysql-test/t/create_select_tmp.test
@@ -27,3 +27,5 @@ select * from t2;
CREATE TEMPORARY TABLE t2 ( PRIMARY KEY (a) ) ENGINE=MYISAM SELECT a FROM t1;
--error 1146;
select * from t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/csv.test b/mysql-test/t/csv.test
index 591fab3961a..2ac46d75f9a 100644
--- a/mysql-test/t/csv.test
+++ b/mysql-test/t/csv.test
@@ -1313,3 +1313,5 @@ INSERT INTO t1 VALUES (9410,9412);
select period from t1;
drop table if exists t1,t2,t3,t4;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_big5.test b/mysql-test/t/ctype_big5.test
index da31a8f3245..e4fb1d2a32b 100644
--- a/mysql-test/t/ctype_big5.test
+++ b/mysql-test/t/ctype_big5.test
@@ -27,3 +27,5 @@ CREATE TABLE t1 (a text) character set big5;
INSERT INTO t1 VALUES ('ùØ');
SELECT * FROM t1;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_collate.test b/mysql-test/t/ctype_collate.test
index b65067a36cf..e59693680bf 100644
--- a/mysql-test/t/ctype_collate.test
+++ b/mysql-test/t/ctype_collate.test
@@ -206,3 +206,5 @@ EXPLAIN SELECT * FROM t1 WHERE s1 LIKE 'a' COLLATE latin1_german1_ci;
EXPLAIN SELECT * FROM t1 WHERE s2 LIKE 'a' COLLATE latin1_german1_ci;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_cp1250_ch.test b/mysql-test/t/ctype_cp1250_ch.test
index 814da628fb7..ea4b35a44a3 100644
--- a/mysql-test/t/ctype_cp1250_ch.test
+++ b/mysql-test/t/ctype_cp1250_ch.test
@@ -22,3 +22,5 @@ INSERT INTO t1 VALUES ('2005-01-1');
SELECT * FROM t1 WHERE popisek = '2005-01-1';
SELECT * FROM t1 WHERE popisek LIKE '2005-01-1';
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_cp1251.test b/mysql-test/t/ctype_cp1251.test
index 76873e6fa0e..1aafe7b7266 100644
--- a/mysql-test/t/ctype_cp1251.test
+++ b/mysql-test/t/ctype_cp1251.test
@@ -46,3 +46,5 @@ insert into t1 (a) values ('air'),
select * from t1 where a like 'we_%';
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_create.test b/mysql-test/t/ctype_create.test
index e97017ab416..e88004bbb8c 100644
--- a/mysql-test/t/ctype_create.test
+++ b/mysql-test/t/ctype_create.test
@@ -98,3 +98,5 @@ show create database mysqltest2;
drop database mysqltest2;
--error 1046
ALTER DATABASE DEFAULT CHARACTER SET latin2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_gbk.test b/mysql-test/t/ctype_gbk.test
index 82a2e61879e..2210891454e 100644
--- a/mysql-test/t/ctype_gbk.test
+++ b/mysql-test/t/ctype_gbk.test
@@ -28,3 +28,5 @@ CREATE TABLE t1 (a text) character set gbk;
INSERT INTO t1 VALUES (0xA3A0),(0xA1A1);
SELECT hex(a) FROM t1 ORDER BY a;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_latin1.test b/mysql-test/t/ctype_latin1.test
index 6006ee4c527..1b83373da29 100644
--- a/mysql-test/t/ctype_latin1.test
+++ b/mysql-test/t/ctype_latin1.test
@@ -75,3 +75,5 @@ SET collation_connection='latin1_bin';
--error 1064
CREATE TABLE „a (a int);
SELECT '„a' as str;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_latin1_de.test b/mysql-test/t/ctype_latin1_de.test
index 88eb840a787..d6a11a22857 100644
--- a/mysql-test/t/ctype_latin1_de.test
+++ b/mysql-test/t/ctype_latin1_de.test
@@ -133,6 +133,8 @@ ALTER TABLE t1 ADD KEY ifword(col1);
SELECT * FROM t1 WHERE col1='ß' ORDER BY col1, BINARY col1;
DROP TABLE t1;
+# End of 4.1 tests
+
#
# Bug#9509
#
diff --git a/mysql-test/t/ctype_latin2.test b/mysql-test/t/ctype_latin2.test
index cc232adeaec..676b472e7b8 100644
--- a/mysql-test/t/ctype_latin2.test
+++ b/mysql-test/t/ctype_latin2.test
@@ -48,3 +48,5 @@ a, lower(a) l, upper(a) u from t1 order by ha;
#
SELECT group_concat(a collate latin2_croatian_ci order by binary a) from t1 group by a collate latin2_croatian_ci;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_many.test b/mysql-test/t/ctype_many.test
index 454e2c63cbb..22e844c6868 100644
--- a/mysql-test/t/ctype_many.test
+++ b/mysql-test/t/ctype_many.test
@@ -209,3 +209,5 @@ SET CHARACTER SET 'binary';
SELECT * FROM t1;
SELECT min(comment),count(*) FROM t1 GROUP BY ucs2_f;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_mb.test b/mysql-test/t/ctype_mb.test
index b0ccab8e345..6e369e3fa0b 100644
--- a/mysql-test/t/ctype_mb.test
+++ b/mysql-test/t/ctype_mb.test
@@ -24,3 +24,5 @@ ALTER TABLE t1 CHANGE a a CHAR(4) CHARACTER SET utf8;
SHOW CREATE TABLE t1;
SHOW KEYS FROM t1;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_recoding.test b/mysql-test/t/ctype_recoding.test
index 0e5e954c720..9949ef88da4 100644
--- a/mysql-test/t/ctype_recoding.test
+++ b/mysql-test/t/ctype_recoding.test
@@ -179,3 +179,5 @@ select rpad(c1,3,'ö'), rpad('ö',3,c1) from t1;
# TODO
#select case c1 when 'ß' then 'ß' when 'ö' then 'ö' else 'c' end from t1;
#select export_set(5,c1,'ö'), export_set(5,'ö',c1) from t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_sjis.test b/mysql-test/t/ctype_sjis.test
index 9b53d448374..252f0a0b6c8 100644
--- a/mysql-test/t/ctype_sjis.test
+++ b/mysql-test/t/ctype_sjis.test
@@ -77,3 +77,5 @@ SET collation_connection='sjis_bin';
--character_set sjis
SET NAMES sjis;
SELECT HEX('²“‘@\Œ\') FROM DUAL;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_tis620.test b/mysql-test/t/ctype_tis620.test
index 87047db9b54..d649828eda3 100644
--- a/mysql-test/t/ctype_tis620.test
+++ b/mysql-test/t/ctype_tis620.test
@@ -157,3 +157,5 @@ SET collation_connection='tis620_thai_ci';
-- source include/ctype_filesort.inc
SET collation_connection='tis620_bin';
-- source include/ctype_filesort.inc
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_uca.test b/mysql-test/t/ctype_uca.test
index e5c2acc8b4e..098ea33c6b2 100644
--- a/mysql-test/t/ctype_uca.test
+++ b/mysql-test/t/ctype_uca.test
@@ -456,6 +456,8 @@ drop table t1;
SET collation_connection='utf8_unicode_ci';
-- source include/ctype_filesort.inc
+# End of 4.1 tests
+
#
# Check UPPER/LOWER changeing length
#
diff --git a/mysql-test/t/ctype_ucs.test b/mysql-test/t/ctype_ucs.test
index d032c1249df..668edb3fafe 100644
--- a/mysql-test/t/ctype_ucs.test
+++ b/mysql-test/t/ctype_ucs.test
@@ -419,6 +419,8 @@ insert into t1 values (0x005b);
select hex(a) from t1;
drop table t1;
+# End of 4.1 tests
+
#
# Conversion from an UCS2 string to a decimal column
#
diff --git a/mysql-test/t/ctype_ucs_binlog.test b/mysql-test/t/ctype_ucs_binlog.test
index 226f128c1c2..1ce55edd469 100644
--- a/mysql-test/t/ctype_ucs_binlog.test
+++ b/mysql-test/t/ctype_ucs_binlog.test
@@ -17,4 +17,4 @@ show binlog events from 98;
--exec $MYSQL_BINLOG --short-form $MYSQL_TEST_DIR/var/log/master-bin.000001
drop table t2;
-
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_ujis.test b/mysql-test/t/ctype_ujis.test
index 8657d5eaa86..88386500c9f 100644
--- a/mysql-test/t/ctype_ujis.test
+++ b/mysql-test/t/ctype_ujis.test
@@ -1149,3 +1149,5 @@ SET collation_connection='ujis_japanese_ci';
SET collation_connection='ujis_bin';
-- source include/ctype_filesort.inc
-- source include/ctype_innodb_like.inc
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ctype_utf8.test b/mysql-test/t/ctype_utf8.test
index b361b056332..ce259f465d9 100644
--- a/mysql-test/t/ctype_utf8.test
+++ b/mysql-test/t/ctype_utf8.test
@@ -843,6 +843,8 @@ insert into t1 values (_utf8 0x5b);
select hex(a) from t1;
drop table t1;
+# End of 4.1 tests
+
#
# Test for bug #11484: wrong results for a DISTINCT varchar column in uft8.
#
diff --git a/mysql-test/t/date_formats.test b/mysql-test/t/date_formats.test
index e8bd8965b96..f76f51fd12d 100644
--- a/mysql-test/t/date_formats.test
+++ b/mysql-test/t/date_formats.test
@@ -260,3 +260,5 @@ select str_to_date("2003-01-02 10:11:12.0012ABCD", "%Y-%m-%d %H:%i:%S.%f") as f1
select str_to_date("2003-04-05 g", "%Y-%m-%d") as f1,
str_to_date("2003-04-05 10:11:12.101010234567", "%Y-%m-%d %H:%i:%S.%f") as f2;
--enable_ps_protocol
+
+# End of 4.1 tests
diff --git a/mysql-test/t/delayed.test b/mysql-test/t/delayed.test
index 513de990165..3030ac20304 100644
--- a/mysql-test/t/delayed.test
+++ b/mysql-test/t/delayed.test
@@ -36,3 +36,5 @@ insert delayed into t1 values (3,"this will give an","error");
show status like 'not_flushed_delayed_rows';
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/delete.test b/mysql-test/t/delete.test
index 265089adfa2..4284bd2a06d 100644
--- a/mysql-test/t/delete.test
+++ b/mysql-test/t/delete.test
@@ -153,6 +153,8 @@ DELETE FROM t1 WHERE t1.a > 0 ORDER BY t1.a LIMIT 1;
SELECT * FROM t1;
DROP TABLE t1;
+# End of 4.1 tests
+
#
# Test of multi-delete where we are not scanning the first table
#
diff --git a/mysql-test/t/derived.test b/mysql-test/t/derived.test
index 1e3ffd5160b..8d51b4666e7 100644
--- a/mysql-test/t/derived.test
+++ b/mysql-test/t/derived.test
@@ -248,3 +248,5 @@ insert into t3 values(3),(3);
select * from t1 union distinct select * from t2 union all select * from t3;
select * from (select * from t1 union distinct select * from t2 union all select * from t3) X;
drop table t1, t2, t3;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/dirty_close.test b/mysql-test/t/dirty_close.test
index f965df8cfea..f1c2c88ae83 100644
--- a/mysql-test/t/dirty_close.test
+++ b/mysql-test/t/dirty_close.test
@@ -12,3 +12,5 @@ create table t1 (n int);
insert into t1 values (1),(2),(3);
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/distinct.test b/mysql-test/t/distinct.test
index 057c9bd9239..562926d160c 100644
--- a/mysql-test/t/distinct.test
+++ b/mysql-test/t/distinct.test
@@ -340,3 +340,5 @@ create table t1 (id int, dsc varchar(50));
insert into t1 values (1, "line number one"), (2, "line number two"), (3, "line number three");
select distinct id, IFNULL(dsc, '-') from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/drop.test b/mysql-test/t/drop.test
index 5e123ca0de8..2cd7866caf5 100644
--- a/mysql-test/t/drop.test
+++ b/mysql-test/t/drop.test
@@ -79,3 +79,5 @@ unlock tables;
create table t1(n int);
show tables;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/drop_temp_table.test b/mysql-test/t/drop_temp_table.test
index dbe7959acb2..38c13e3e5e4 100644
--- a/mysql-test/t/drop_temp_table.test
+++ b/mysql-test/t/drop_temp_table.test
@@ -23,3 +23,5 @@ let $VERSION=`select version()`;
--replace_column 2 # 5 #
show binlog events;
drop database `drop-temp+table-test`;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/empty_table.test b/mysql-test/t/empty_table.test
index db0a8e6a247..e8e532832f4 100644
--- a/mysql-test/t/empty_table.test
+++ b/mysql-test/t/empty_table.test
@@ -11,3 +11,5 @@ select count(*) from t1;
select * from t1;
select * from t1 limit 0;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/endspace.test b/mysql-test/t/endspace.test
index 3d27c44c3b9..c4d53450910 100644
--- a/mysql-test/t/endspace.test
+++ b/mysql-test/t/endspace.test
@@ -94,3 +94,5 @@ select text1, length(text1) from t1 where text1='teststring' or text1 like 'test
select text1, length(text1) from t1 where text1='teststring' or text1 >= 'teststring\t';
select concat('|', text1, '|') from t1 order by text1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/errors.test b/mysql-test/t/errors.test
index b558c90b0c6..93668ffdd3d 100644
--- a/mysql-test/t/errors.test
+++ b/mysql-test/t/errors.test
@@ -29,3 +29,5 @@ select 1 from t1 order by t1.b;
--error 1054
select count(*),b from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/exampledb.test b/mysql-test/t/exampledb.test
index c60a9d7f930..946d25325dc 100644
--- a/mysql-test/t/exampledb.test
+++ b/mysql-test/t/exampledb.test
@@ -14,3 +14,5 @@ CREATE TABLE t1 (
) ENGINE=example;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/explain.test b/mysql-test/t/explain.test
index 050939e5ad2..2a3a23c5f96 100644
--- a/mysql-test/t/explain.test
+++ b/mysql-test/t/explain.test
@@ -41,3 +41,5 @@ insert into ÔÁÂ (ËÏÌ0) values (2);
explain select ËÏÌ0 from ÔÁÂ where ËÏÌ0=1;
drop table ÔÁÂ;
set names latin1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/flush.test b/mysql-test/t/flush.test
index 62af9d4932b..f2bfa45ba59 100644
--- a/mysql-test/t/flush.test
+++ b/mysql-test/t/flush.test
@@ -69,3 +69,5 @@ connection con2;
insert into t1 values (345);
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/flush_block_commit.test b/mysql-test/t/flush_block_commit.test
index 29ef7b8a0b9..ebb48242a4d 100644
--- a/mysql-test/t/flush_block_commit.test
+++ b/mysql-test/t/flush_block_commit.test
@@ -77,6 +77,8 @@ show create database test;
drop table t1;
+# End of 4.1 tests
+
# FLUSH TABLES WITH READ LOCK should block writes to binlog too
connection con1;
create table t1 (a int) engine=innodb;
diff --git a/mysql-test/t/flush_table.test b/mysql-test/t/flush_table.test
index afb30d21da7..0330582bc34 100644
--- a/mysql-test/t/flush_table.test
+++ b/mysql-test/t/flush_table.test
@@ -72,3 +72,5 @@ handler t1 read next limit 1;
handler t1 read next limit 1;
handler t1 close;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/foreign_key.test b/mysql-test/t/foreign_key.test
index 8c35fd65f74..0a3708e6dc8 100644
--- a/mysql-test/t/foreign_key.test
+++ b/mysql-test/t/foreign_key.test
@@ -21,3 +21,5 @@ create table t1 (
create index a on t1 (a);
create unique index b on t1 (a,b);
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/fulltext.test b/mysql-test/t/fulltext.test
index 3c4d5dc93da..b0b70d40e5c 100644
--- a/mysql-test/t/fulltext.test
+++ b/mysql-test/t/fulltext.test
@@ -338,3 +338,5 @@ SET NAMES latin1;
INSERT INTO t1 VALUES('Mit freundlichem Grüß aus Osnabrück');
SELECT COUNT(*) FROM t1 WHERE MATCH(t) AGAINST ('"osnabrück"' IN BOOLEAN MODE);
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/fulltext2.test b/mysql-test/t/fulltext2.test
index 1d3a5307412..bcd39b9ea04 100644
--- a/mysql-test/t/fulltext2.test
+++ b/mysql-test/t/fulltext2.test
@@ -182,3 +182,4 @@ select count(*) from t1 where match a against ('aaazzz' in boolean mode);
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/fulltext_cache.test b/mysql-test/t/fulltext_cache.test
index b01f0d18b76..ea05f699506 100644
--- a/mysql-test/t/fulltext_cache.test
+++ b/mysql-test/t/fulltext_cache.test
@@ -42,3 +42,5 @@ SELECT t1.q, t2.item, t2.id, MATCH t2.item AGAINST ('sushi' IN BOOLEAN MODE)
as x FROM t2, t1 WHERE (t2.id2 = t1.id) ORDER BY x DESC,t2.id;
drop table t1, t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/fulltext_distinct.test b/mysql-test/t/fulltext_distinct.test
index 1f4cb8cd7bc..bf773c36844 100644
--- a/mysql-test/t/fulltext_distinct.test
+++ b/mysql-test/t/fulltext_distinct.test
@@ -42,3 +42,5 @@ WHERE MATCH (t1.value) AGAINST ('baz333' IN BOOLEAN MODE)
AND t1.id = t2.id_t1;
DROP TABLE t1, t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/fulltext_left_join.test b/mysql-test/t/fulltext_left_join.test
index 96751ef8678..3bb1f0b7309 100644
--- a/mysql-test/t/fulltext_left_join.test
+++ b/mysql-test/t/fulltext_left_join.test
@@ -45,3 +45,4 @@ select * from t1 left join t2 on (venue_id = entity_id and match(name) against('
select * from t1 left join t2 on (venue_id = entity_id and match(name) against('aberdeen')) where dt = '2003-05-23 19:30:00';
drop table t1,t2;
+# End of 4.1 tests
diff --git a/mysql-test/t/fulltext_multi.test b/mysql-test/t/fulltext_multi.test
index 3a622a551bc..fe64fe88599 100644
--- a/mysql-test/t/fulltext_multi.test
+++ b/mysql-test/t/fulltext_multi.test
@@ -21,3 +21,5 @@ SELECT a, round(MATCH b AGAINST ('lala lkjh'),5) FROM t1;
SELECT a, round(MATCH c AGAINST ('lala lkjh'),5) FROM t1;
SELECT a, round(MATCH b,c AGAINST ('lala lkjh'),5) FROM t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/fulltext_order_by.test b/mysql-test/t/fulltext_order_by.test
index 3101242613a..a0bd7954674 100644
--- a/mysql-test/t/fulltext_order_by.test
+++ b/mysql-test/t/fulltext_order_by.test
@@ -137,3 +137,4 @@ order by
drop table t1,t2,t3;
+# End of 4.1 tests
diff --git a/mysql-test/t/fulltext_update.test b/mysql-test/t/fulltext_update.test
index a1d133ba3fe..14eb0de58a5 100644
--- a/mysql-test/t/fulltext_update.test
+++ b/mysql-test/t/fulltext_update.test
@@ -25,3 +25,5 @@ update test set url='test', shortdesc='ggg', longdesc='mmm',
description='ddd', name='nam' where gnr=2;
check table test;
drop table test;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/fulltext_var.test b/mysql-test/t/fulltext_var.test
index 8cc8acf60a6..6b0b8aa463b 100644
--- a/mysql-test/t/fulltext_var.test
+++ b/mysql-test/t/fulltext_var.test
@@ -25,3 +25,4 @@ set global ft_boolean_syntax='@ -><()~*:""@|';
set global ft_boolean_syntax='+ -><()~*:""@!|';
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/func_compress.test b/mysql-test/t/func_compress.test
index 9c32313e967..a78017ddb2f 100644
--- a/mysql-test/t/func_compress.test
+++ b/mysql-test/t/func_compress.test
@@ -47,3 +47,4 @@ set @@max_allowed_packet=1048576*100;
--replace_result "''" XXX "'1'" XXX
eval select compress(repeat('aaaaaaaaaa', IF('$LOW_MEMORY', 10, 10000000))) is null;
+# End of 4.1 tests
diff --git a/mysql-test/t/func_concat.test b/mysql-test/t/func_concat.test
index 4f13ce7513c..37fc0e105b8 100644
--- a/mysql-test/t/func_concat.test
+++ b/mysql-test/t/func_concat.test
@@ -52,3 +52,4 @@ select 'a' union select concat('a', -0.0);
--replace_result a-0.0000 a0.0000
select 'a' union select concat('a', -0.0000);
+# End of 4.1 tests
diff --git a/mysql-test/t/func_crypt.test b/mysql-test/t/func_crypt.test
index f352a98e3cd..5e0283feb28 100644
--- a/mysql-test/t/func_crypt.test
+++ b/mysql-test/t/func_crypt.test
@@ -48,3 +48,5 @@ select old_password('idkfa');
select old_password(' i d k f a ');
explain extended select password('idkfa '), old_password('idkfa');
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_date_add.test b/mysql-test/t/func_date_add.test
index 29c13793b78..b768e4fec61 100644
--- a/mysql-test/t/func_date_add.test
+++ b/mysql-test/t/func_date_add.test
@@ -40,3 +40,5 @@ having mts < DATE_SUB(NOW(),INTERVAL 3 MONTH);
select visitor_id,max(ts) as mts from t1 group by visitor_id
having DATE_ADD(mts,INTERVAL 3 MONTH) < NOW();
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_default.test b/mysql-test/t/func_default.test
index af7ebcf588b..7bebd4b4b72 100644
--- a/mysql-test/t/func_default.test
+++ b/mysql-test/t/func_default.test
@@ -18,6 +18,8 @@ explain select * from t1 where str <> default(str);
drop table t1;
+# End of 4.1 tests
+
#
# Bug #11314 (HAVING DEFAULT() hangs)
#
diff --git a/mysql-test/t/func_des_encrypt.test b/mysql-test/t/func_des_encrypt.test
index 201a0051c58..5d102bd02eb 100644
--- a/mysql-test/t/func_des_encrypt.test
+++ b/mysql-test/t/func_des_encrypt.test
@@ -7,3 +7,5 @@
# Bug #11643: des_encrypt() causes server to die
#
select des_encrypt('hello');
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_encrypt.test b/mysql-test/t/func_encrypt.test
index 52aca7f9dcb..a7364fa43da 100644
--- a/mysql-test/t/func_encrypt.test
+++ b/mysql-test/t/func_encrypt.test
@@ -86,3 +86,5 @@ select hex(des_decrypt(des_encrypt("hello",4),'password2'));
select hex(des_decrypt(des_encrypt("hello","hidden")));
explain extended select des_decrypt(des_encrypt("hello",4),'password2'), des_decrypt(des_encrypt("hello","hidden"));
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_encrypt_nossl.test b/mysql-test/t/func_encrypt_nossl.test
index 95c104ce046..11866db1da7 100644
--- a/mysql-test/t/func_encrypt_nossl.test
+++ b/mysql-test/t/func_encrypt_nossl.test
@@ -35,3 +35,4 @@ select hex("hello");
select hex(des_decrypt(des_encrypt("hello",4),'password2'));
select hex(des_decrypt(des_encrypt("hello","hidden")));
+# End of 4.1 tests
diff --git a/mysql-test/t/func_equal.test b/mysql-test/t/func_equal.test
index f446e277c92..4c88ed170a1 100644
--- a/mysql-test/t/func_equal.test
+++ b/mysql-test/t/func_equal.test
@@ -33,3 +33,5 @@ select * from t1 where id <=>id;
select * from t1 where value <=> value;
select * from t1 where id <=> value or value<=>id;
drop table t1,t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_gconcat.test b/mysql-test/t/func_gconcat.test
index d17e789f503..185a2fe1e78 100644
--- a/mysql-test/t/func_gconcat.test
+++ b/mysql-test/t/func_gconcat.test
@@ -310,6 +310,8 @@ select a, group_concat(b order by b) from t1 group by a with rollup;
select a, group_concat(distinct b order by b) from t1 group by a with rollup;
drop table t1;
+# End of 4.1 tests
+
#
# Bug #6475
#
diff --git a/mysql-test/t/func_group.test b/mysql-test/t/func_group.test
index 459a40cfe87..fb9470c16dd 100644
--- a/mysql-test/t/func_group.test
+++ b/mysql-test/t/func_group.test
@@ -509,7 +509,41 @@ create table t2 select f2 from (select now() f2 from t1) a;
show columns from t2;
drop table t2, t1;
+#
+# Bug 8893: wrong result for min/max optimization with 2 indexes
+#
+
+CREATE TABLE t1(
+ id int PRIMARY KEY,
+ a int,
+ b int,
+ INDEX i_b_id(a,b,id),
+ INDEX i_id(a,id)
+);
+INSERT INTO t1 VALUES
+ (1,1,4), (2,2,1), (3,1,3), (4,2,1), (5,1,1);
+SELECT MAX(id) FROM t1 WHERE id < 3 AND a=2 AND b=6;
+DROP TABLE t1;
+
+# change the order of the last two index definitions
+
+CREATE TABLE t1(
+ id int PRIMARY KEY,
+ a int,
+ b int,
+ INDEX i_id(a,id),
+ INDEX i_b_id(a,b,id)
+);
+INSERT INTO t1 VALUES
+ (1,1,4), (2,2,1), (3,1,3), (4,2,1), (5,1,1);
+SELECT MAX(id) FROM t1 WHERE id < 3 AND a=2 AND b=6;
+DROP TABLE t1;
+
+# End of 4.1 tests
+
+#
# decimal-related tests
+#
create table t2 (ff double);
insert into t2 values (2.2);
select cast(sum(distinct ff) as decimal(5,2)) from t2;
@@ -566,36 +600,6 @@ select col1,sum(col1),max(col1),min(col1) from t1 group by col1;
DROP TABLE t1;
#
-# Bug 8893: wrong result for min/max optimization with 2 indexes
-#
-
-CREATE TABLE t1(
- id int PRIMARY KEY,
- a int,
- b int,
- INDEX i_b_id(a,b,id),
- INDEX i_id(a,id)
-);
-INSERT INTO t1 VALUES
- (1,1,4), (2,2,1), (3,1,3), (4,2,1), (5,1,1);
-SELECT MAX(id) FROM t1 WHERE id < 3 AND a=2 AND b=6;
-DROP TABLE t1;
-
-# change the order of the last two index definitions
-
-CREATE TABLE t1(
- id int PRIMARY KEY,
- a int,
- b int,
- INDEX i_id(a,id),
- INDEX i_b_id(a,b,id)
-);
-INSERT INTO t1 VALUES
- (1,1,4), (2,2,1), (3,1,3), (4,2,1), (5,1,1);
-SELECT MAX(id) FROM t1 WHERE id < 3 AND a=2 AND b=6;
-DROP TABLE t1;
-
-#
# Test that new VARCHAR correctly works with COUNT(DISTINCT)
#
diff --git a/mysql-test/t/func_if.test b/mysql-test/t/func_if.test
index 03590dea8d1..4e0f426c10b 100644
--- a/mysql-test/t/func_if.test
+++ b/mysql-test/t/func_if.test
@@ -87,3 +87,5 @@ SELECT a, NULLIF(a,'') FROM t1;
SELECT a, NULLIF(a,'') FROM t1 WHERE NULLIF(a,'') IS NULL;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_in.test b/mysql-test/t/func_in.test
index 3a6b6653098..7bf737402ef 100644
--- a/mysql-test/t/func_in.test
+++ b/mysql-test/t/func_in.test
@@ -102,6 +102,8 @@ insert into t1 values ('aa'), ('bb');
select * from t1 where a in (NULL, 'aa');
drop table t1;
+# End of 4.1 tests
+
#
# Bug #11885: WHERE condition with NOT IN (one element)
#
diff --git a/mysql-test/t/func_isnull.test b/mysql-test/t/func_isnull.test
index 506efada0eb..6218efb882f 100644
--- a/mysql-test/t/func_isnull.test
+++ b/mysql-test/t/func_isnull.test
@@ -11,3 +11,5 @@ insert into t1 values (0,"2002-05-01"),(0,"2002-05-01"),(0,"2002-05-01");
flush tables;
select * from t1 where isnull(to_days(mydate));
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_like.test b/mysql-test/t/func_like.test
index 4ca2f28fa6e..684d7032038 100644
--- a/mysql-test/t/func_like.test
+++ b/mysql-test/t/func_like.test
@@ -96,3 +96,4 @@ DROP TABLE t1;
#
select _cp866'aaaaaaaaa' like _cp866'%aaaa%' collate cp866_bin;
+# End of 4.1 tests
diff --git a/mysql-test/t/func_math.test b/mysql-test/t/func_math.test
index da4b8335e07..bc3a1cd239c 100644
--- a/mysql-test/t/func_math.test
+++ b/mysql-test/t/func_math.test
@@ -68,6 +68,8 @@ explain extended select degrees(pi()),radians(360);
--error 1054
select rand(rand);
+# End of 4.1 tests
+
#
# Bug #8459 (FORMAT returns incorrect result)
#
diff --git a/mysql-test/t/func_misc.test b/mysql-test/t/func_misc.test
index 78ff0907b39..5079e2605ce 100644
--- a/mysql-test/t/func_misc.test
+++ b/mysql-test/t/func_misc.test
@@ -38,11 +38,11 @@ select a from t1 where mid(a+0,6,3) = ( mid(20040106123400,6,3) );
drop table t1;
+# End of 4.1 tests
+
+#
# Test for BUG#9535
+#
create table t1 as select uuid(), length(uuid());
show create table t1;
drop table t1;
-
-
-
-
diff --git a/mysql-test/t/func_op.test b/mysql-test/t/func_op.test
index 33a2884b424..24266150e4c 100644
--- a/mysql-test/t/func_op.test
+++ b/mysql-test/t/func_op.test
@@ -16,3 +16,5 @@ select 1 | -1, 1 ^ -1, 1 & -1;
select 0 | -1, 0 ^ -1, 0 & -1;
select -1 >> 0, -1 << 0;
select -1 >> 1, -1 << 1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_regexp.test b/mysql-test/t/func_regexp.test
index 1a771d466fa..23070c71fe9 100644
--- a/mysql-test/t/func_regexp.test
+++ b/mysql-test/t/func_regexp.test
@@ -73,3 +73,5 @@ set @a="^R.*";
execute stmt1 using @a;
deallocate prepare stmt1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_sapdb.test b/mysql-test/t/func_sapdb.test
index bb9159eefbe..6189712b5fe 100644
--- a/mysql-test/t/func_sapdb.test
+++ b/mysql-test/t/func_sapdb.test
@@ -128,3 +128,5 @@ select date_add("1997-12-31",INTERVAL "10.09" SECOND_MICROSECOND) as a;
--disable_ps_protocol
select str_to_date("2003-01-02 10:11:12.0012", "%Y-%m-%d %H:%i:%S.%f");
--enable_ps_protocol
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_set.test b/mysql-test/t/func_set.test
index 0c79dec7cc2..710b9b90a05 100644
--- a/mysql-test/t/func_set.test
+++ b/mysql-test/t/func_set.test
@@ -54,3 +54,4 @@ select find_in_set(binary 'a', 'A,B,C');
#
select find_in_set('1','3,1,');
+# End of 4.1 tests
diff --git a/mysql-test/t/func_str.test b/mysql-test/t/func_str.test
index b7cf9c8c4a0..c66f3eaa294 100644
--- a/mysql-test/t/func_str.test
+++ b/mysql-test/t/func_str.test
@@ -624,3 +624,5 @@ select lpad(i, 7, ' ') as t from t1;
select rpad(i, 7, ' ') as t from t1;
--disable_metadata
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_system.test b/mysql-test/t/func_system.test
index bbfef25bcfe..d7e215f5d48 100644
--- a/mysql-test/t/func_system.test
+++ b/mysql-test/t/func_system.test
@@ -41,3 +41,5 @@ select * from t1 where a=user();
insert into t1 values ('a');
select left(concat(a,version()),1) from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/func_test.test b/mysql-test/t/func_test.test
index 732cdc12cae..424c0d1456b 100644
--- a/mysql-test/t/func_test.test
+++ b/mysql-test/t/func_test.test
@@ -108,6 +108,8 @@ select 5.1 mod 3, 5.1 mod -3, -5.1 mod 3, -5.1 mod -3;
select 5 mod 3, 5 mod -3, -5 mod 3, -5 mod -3;
+# End of 4.1 tests
+
#
# Bug#6726: NOT BETWEEN parse failure
#
diff --git a/mysql-test/t/func_time.test b/mysql-test/t/func_time.test
index 66ff460fc61..0538e6111b9 100644
--- a/mysql-test/t/func_time.test
+++ b/mysql-test/t/func_time.test
@@ -334,6 +334,9 @@ INSERT INTO t1 VALUES (NOW());
SELECT count(*) FROM t1 WHERE d>FROM_DAYS(TO_DAYS(@TMP)) AND d<=FROM_DAYS(TO_DAYS(@TMP)+1);
DROP TABLE t1;
+
+# End of 4.1 tests
+
explain extended select timestampdiff(SQL_TSI_WEEK, '2001-02-01', '2001-05-01') as a1,
timestampdiff(SQL_TSI_FRAC_SECOND, '2001-02-01 12:59:59.120000', '2001-05-01 12:58:58.119999') as a2;
diff --git a/mysql-test/t/func_timestamp.test b/mysql-test/t/func_timestamp.test
index 8583c16073d..e1bb7e878ee 100644
--- a/mysql-test/t/func_timestamp.test
+++ b/mysql-test/t/func_timestamp.test
@@ -13,3 +13,5 @@ SELECT CONCAT(Jahr,'-',Monat,'-',Tag,' ',Zeit) AS Date,
UNIX_TIMESTAMP(CONCAT(Jahr,'-',Monat,'-',Tag,' ',Zeit)) AS Unix
FROM t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/gcc296.test b/mysql-test/t/gcc296.test
index ebca4dbc897..bfcd56ff396 100644
--- a/mysql-test/t/gcc296.test
+++ b/mysql-test/t/gcc296.test
@@ -18,3 +18,5 @@ INSERT INTO t1 VALUES ('0104000000','xxx','XXX');
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/gis-rtree.test b/mysql-test/t/gis-rtree.test
index 522f7a6f637..52fe6add3b8 100644
--- a/mysql-test/t/gis-rtree.test
+++ b/mysql-test/t/gis-rtree.test
@@ -171,3 +171,5 @@ CREATE TABLE t2 (geom GEOMETRY NOT NULL, SPATIAL KEY gk(geom));
--error 1416
INSERT INTO t2 SELECT GeomFromText(st) FROM t1;
drop table t1, t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/gis.test b/mysql-test/t/gis.test
index b7071019e9d..661616c0a6c 100644
--- a/mysql-test/t/gis.test
+++ b/mysql-test/t/gis.test
@@ -371,3 +371,5 @@ insert into t1 values ("qwerty");
insert into t1 values (pointfromtext('point(1,1)'));
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/grant.test b/mysql-test/t/grant.test
index bb21873a0c4..05094b29589 100644
--- a/mysql-test/t/grant.test
+++ b/mysql-test/t/grant.test
@@ -479,3 +479,5 @@ insert into tables_priv values ('','test_db','mysqltest_1','test_table','test_gr
flush privileges;
delete from tables_priv where host = '' and user = 'mysqltest_1';
flush privileges;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/grant2.test b/mysql-test/t/grant2.test
index 07bd6d53c4e..c6b8bfe2916 100644
--- a/mysql-test/t/grant2.test
+++ b/mysql-test/t/grant2.test
@@ -312,3 +312,5 @@ connection default;
REVOKE ALL ON mysqltest_1.t1 FROM mysqltest_1@'127.0.0.0/255.0.0.0';
drop table mysqltest_1.t1;
drop database mysqltest_1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/grant_cache.test b/mysql-test/t/grant_cache.test
index f4423a68717..7e17a03ec21 100644
--- a/mysql-test/t/grant_cache.test
+++ b/mysql-test/t/grant_cache.test
@@ -149,3 +149,5 @@ drop table test.t1,mysqltest.t1,mysqltest.t2;
drop database mysqltest;
set GLOBAL query_cache_size=default;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/group_by.test b/mysql-test/t/group_by.test
index 6f1880ae8fb..bfbdd098426 100644
--- a/mysql-test/t/group_by.test
+++ b/mysql-test/t/group_by.test
@@ -592,6 +592,8 @@ SELECT n+1 AS n FROM t1 GROUP BY n;
--enable_ps_protocol
DROP TABLE t1;
+# End of 4.1 tests
+
#
# Bug#11211: Ambiguous column reference in GROUP BY.
#
diff --git a/mysql-test/t/handler.test b/mysql-test/t/handler.test
index 3de8e8ae784..eb970e7a710 100644
--- a/mysql-test/t/handler.test
+++ b/mysql-test/t/handler.test
@@ -346,3 +346,5 @@ drop table t2;
drop table t3;
drop table t4;
drop table t5;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/having.test b/mysql-test/t/having.test
index 3221b0d4624..fb223d2a9af 100644
--- a/mysql-test/t/having.test
+++ b/mysql-test/t/having.test
@@ -123,6 +123,7 @@ group by a.id, a.description
having (a.description is not null) and (c=0);
drop table t1,t2,t3;
+# End of 4.1 tests
#
# Tests for WL#1972 CORRECT EVALUATION OF COLUMN REFERENCES IN THE HAVING CLAUSE
@@ -233,7 +234,6 @@ where t1.col2 in
group by col_t1
having col_t1 <= 20;
-
#
# nested HAVING clauses
#
diff --git a/mysql-test/t/heap.test b/mysql-test/t/heap.test
index 75ef5a73cb0..6a9ff5c8284 100644
--- a/mysql-test/t/heap.test
+++ b/mysql-test/t/heap.test
@@ -435,3 +435,5 @@ insert into t1 values ("abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcd
--error 1062
insert into t1 values ("abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz");
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/heap_auto_increment.test b/mysql-test/t/heap_auto_increment.test
index 9d0fefa4d52..016bc946209 100644
--- a/mysql-test/t/heap_auto_increment.test
+++ b/mysql-test/t/heap_auto_increment.test
@@ -31,3 +31,5 @@ insert into t1 values (NULL, "hey");
select * from t1;
select _rowid,t1._rowid,skey,sval from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/heap_btree.test b/mysql-test/t/heap_btree.test
index 6fec2ac1703..5e493c2643b 100644
--- a/mysql-test/t/heap_btree.test
+++ b/mysql-test/t/heap_btree.test
@@ -163,3 +163,5 @@ INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
DELETE from t1 where a < 100;
SELECT * from t1;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/heap_hash.test b/mysql-test/t/heap_hash.test
index 21ac69ef3a1..28a75a5ee11 100644
--- a/mysql-test/t/heap_hash.test
+++ b/mysql-test/t/heap_hash.test
@@ -259,3 +259,5 @@ insert into t1 values (1),(2),(3),(4),(5);
select a from t1 where a in (1,3);
explain select a from t1 where a in (1,3);
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/help.test b/mysql-test/t/help.test
index 3f3e99e1556..ff431fb4ebd 100644
--- a/mysql-test/t/help.test
+++ b/mysql-test/t/help.test
@@ -113,3 +113,5 @@ delete from mysql.help_relation where help_keyword_id=@keyword1_id and help_topi
delete from mysql.help_relation where help_keyword_id=@keyword2_id and help_topic_id=@topic1_id;
delete from mysql.help_relation where help_keyword_id=@keyword3_id and help_topic_id=@topic3_id;
delete from mysql.help_relation where help_keyword_id=@keyword3_id and help_topic_id=@topic4_id;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/init_connect.test b/mysql-test/t/init_connect.test
index d9682eb8122..2e3c67a7d38 100644
--- a/mysql-test/t/init_connect.test
+++ b/mysql-test/t/init_connect.test
@@ -32,3 +32,5 @@ connection con5;
select @a;
connection con0;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/init_file.test b/mysql-test/t/init_file.test
index 604d0a01794..de6aca455bd 100644
--- a/mysql-test/t/init_file.test
+++ b/mysql-test/t/init_file.test
@@ -5,3 +5,5 @@
# See mysql-test/std_data/init_file.dat and
# mysql-test/t/init_file-master.opt for the actual test
#
+
+# End of 4.1 tests
diff --git a/mysql-test/t/innodb-deadlock.test b/mysql-test/t/innodb-deadlock.test
index 7a7f657f35d..9d15a23da3c 100644
--- a/mysql-test/t/innodb-deadlock.test
+++ b/mysql-test/t/innodb-deadlock.test
@@ -113,3 +113,5 @@ select * from t1;
commit;
drop table t1, t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/innodb-lock.test b/mysql-test/t/innodb-lock.test
index 887a664e262..dd7f4319892 100644
--- a/mysql-test/t/innodb-lock.test
+++ b/mysql-test/t/innodb-lock.test
@@ -100,3 +100,5 @@ reap;
commit;
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/innodb-replace.test b/mysql-test/t/innodb-replace.test
index 516f058a68e..51b70f34b65 100644
--- a/mysql-test/t/innodb-replace.test
+++ b/mysql-test/t/innodb-replace.test
@@ -19,3 +19,4 @@ replace delayed into t1 (c1, c2) values ( "text1","12"),( "text2","13"),( "text
select * from t1;
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/innodb.test b/mysql-test/t/innodb.test
index 2d0e2a4dd65..05f47f36e42 100644
--- a/mysql-test/t/innodb.test
+++ b/mysql-test/t/innodb.test
@@ -1230,6 +1230,8 @@ SELECT * FROM (SELECT t1.*,GROUP_CONCAT(t2.b_id SEPARATOR ',') as b_list FROM (t
DROP TABLE t2;
DROP TABLE t1;
+# End of 4.1 tests
+
#
# range optimizer problem
#
@@ -1368,7 +1370,6 @@ insert into t1 (val) values ('1'),('2');
select * from t1;
drop table t1;
-
#
# Test that update does not change internal auto-increment value
#
diff --git a/mysql-test/t/innodb_cache.test b/mysql-test/t/innodb_cache.test
index 101dde37f89..a811d660bd7 100644
--- a/mysql-test/t/innodb_cache.test
+++ b/mysql-test/t/innodb_cache.test
@@ -80,3 +80,4 @@ commit;
select t1.* from t1, t2, t3 where t3.state & 1 = 0 and t3.t1_id = t1.id and t3.t2_id = t2.id and t1.id = 1 order by t1.a asc;
drop table t3,t2,t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/innodb_handler.test b/mysql-test/t/innodb_handler.test
index 65728519e7b..18cec97af0d 100644
--- a/mysql-test/t/innodb_handler.test
+++ b/mysql-test/t/innodb_handler.test
@@ -93,3 +93,4 @@ HANDLER t1 READ `primary` = (1, 1000);
HANDLER t1 READ `primary` PREV;
DROP TABLE t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/insert.test b/mysql-test/t/insert.test
index e977de94871..51d936f5b4f 100644
--- a/mysql-test/t/insert.test
+++ b/mysql-test/t/insert.test
@@ -151,6 +151,12 @@ insert into t1 values(null,@value,@value,@value,@value,@value,@value,@value,@val
drop table t1;
--enable_ps_protocol
+# End of 4.1 tests
+
+#
+# Test automatic result buffering with INSERT INTO t1 ... SELECT ... FROM t1
+#
+
create table t1(id1 int not null auto_increment primary key, t char(12));
create table t2(id2 int not null, t char(12));
create table t3(id3 int not null, t char(12), index(id3));
diff --git a/mysql-test/t/insert_select-binlog.test b/mysql-test/t/insert_select-binlog.test
index 9bb1ec274ef..d4041f86ab5 100644
--- a/mysql-test/t/insert_select-binlog.test
+++ b/mysql-test/t/insert_select-binlog.test
@@ -32,3 +32,4 @@ let $VERSION=`select version()`;
show binlog events;
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/insert_select.test b/mysql-test/t/insert_select.test
index 92e8c7f1231..4a463c1d52e 100644
--- a/mysql-test/t/insert_select.test
+++ b/mysql-test/t/insert_select.test
@@ -201,3 +201,5 @@ insert into t1 select t2.a from t2 on duplicate key update t2.a= a + t2.b;
--error 1109
insert into t1 select t2.a from t2 group by t2.a on duplicate key update a= t1.a + t2.b;
drop table t1,t2,t3;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/insert_update.test b/mysql-test/t/insert_update.test
index 64a76aafa5e..5948f92d4e0 100644
--- a/mysql-test/t/insert_update.test
+++ b/mysql-test/t/insert_update.test
@@ -100,3 +100,5 @@ insert into t1 select a from t1 on duplicate key update a=a+1 ;
--error 1052
insert ignore into t1 select a from t1 on duplicate key update a=t1.a+1 ;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/join.test b/mysql-test/t/join.test
index 1d18e020543..2715f30b6cf 100644
--- a/mysql-test/t/join.test
+++ b/mysql-test/t/join.test
@@ -325,3 +325,5 @@ select * from t1,t2 right join t3 on (t2.i=t3.i) order by t1.i,t2.i,t3.i;
select t1.i,t2.i,t3.i from t2 natural right join t3,t1 order by t1.i,t2.i,t3.i;
select t1.i,t2.i,t3.i from t2 right join t3 on (t2.i=t3.i),t1 order by t1.i,t2.i,t3.i;
drop table t1,t2,t3;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/join_crash.test b/mysql-test/t/join_crash.test
index 2d2222ad67a..68fd9226e41 100644
--- a/mysql-test/t/join_crash.test
+++ b/mysql-test/t/join_crash.test
@@ -124,3 +124,5 @@ from
client_name asc,
project_name asc;
DROP TABLE t1,t2,t3,t4;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/join_outer.test b/mysql-test/t/join_outer.test
index 7dd35f164d5..f48ae985e56 100644
--- a/mysql-test/t/join_outer.test
+++ b/mysql-test/t/join_outer.test
@@ -662,6 +662,8 @@ select group_concat(t1.b,t2.c) from t1 inner join t2 using(a) group by t1.a;
drop table t1, t2;
set group_concat_max_len=default;
+# End of 4.1 tests
+
#
# BUG#10162 - ON is merged with WHERE, left join is convered to a regular join
#
@@ -706,8 +708,5 @@ CREATE TABLE t1 (c11 int);
CREATE TABLE t2 (c21 int);
INSERT INTO t1 VALUES (30), (40), (50);
INSERT INTO t2 VALUES (300), (400), (500);
-
SELECT * FROM t1 LEFT JOIN t2 ON (c11=c21 AND c21=30) WHERE c11=40;
-
DROP TABLE t1, t2;
-
diff --git a/mysql-test/t/key.test b/mysql-test/t/key.test
index 96407a3d1bc..91bd1ada8a4 100644
--- a/mysql-test/t/key.test
+++ b/mysql-test/t/key.test
@@ -353,3 +353,5 @@ drop table t1;
create table t1 (a int not null primary key, b varchar(20) not null, c varchar(20) not null, unique(b(10),c(10)));
desc t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/key_cache.test b/mysql-test/t/key_cache.test
index 5ff26b315e2..5d0f904a716 100644
--- a/mysql-test/t/key_cache.test
+++ b/mysql-test/t/key_cache.test
@@ -167,3 +167,5 @@ set GLOBAL key_cache_block_size=2048;
check table t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/key_diff.test b/mysql-test/t/key_diff.test
index b4e4339ae33..b490c613c61 100644
--- a/mysql-test/t/key_diff.test
+++ b/mysql-test/t/key_diff.test
@@ -20,3 +20,5 @@ explain select t1.*,t2.* from t1,t1 as t2 where t1.A=t2.B;
select t1.*,t2.* from t1,t1 as t2 where t1.A=t2.B order by binary t1.a,t2.a;
select * from t1 where a='a';
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/key_primary.test b/mysql-test/t/key_primary.test
index 816365c517c..1ca2059b871 100644
--- a/mysql-test/t/key_primary.test
+++ b/mysql-test/t/key_primary.test
@@ -16,3 +16,5 @@ select * from t1 where t1 like "a_\%";
describe select * from t1 where t1="ABC";
describe select * from t1 where t1="ABCD";
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/keywords.test b/mysql-test/t/keywords.test
index 3392bfa1b3b..de0159a950e 100644
--- a/mysql-test/t/keywords.test
+++ b/mysql-test/t/keywords.test
@@ -17,3 +17,5 @@ create table events(binlog int);
insert into events values(1);
select events.binlog from events;
drop table events;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/kill.test b/mysql-test/t/kill.test
index 37e11e14df5..09ad3f59c10 100644
--- a/mysql-test/t/kill.test
+++ b/mysql-test/t/kill.test
@@ -39,6 +39,8 @@ connection con2;
select 4;
drop table t1;
+# End of 4.1 tests
+
#
# test of blocking of sending ERROR after OK or EOF
#
diff --git a/mysql-test/t/limit.test b/mysql-test/t/limit.test
index 3dc56295375..6df865278f6 100644
--- a/mysql-test/t/limit.test
+++ b/mysql-test/t/limit.test
@@ -59,3 +59,5 @@ insert into t1 values (1);
select 1 as a from t1 union all select 1 from dual limit 1;
(select 1 as a from t1) union all (select 1 from dual) limit 1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/loaddata.test b/mysql-test/t/loaddata.test
index 14ef749c802..fe6828916a3 100644
--- a/mysql-test/t/loaddata.test
+++ b/mysql-test/t/loaddata.test
@@ -31,6 +31,8 @@ load data infile '../../std_data/loaddata4.dat' into table t1 fields terminated
select * from t1;
drop table t1;
+# End of 4.1 tests
+
#
# Let us test extended LOAD DATA features
#
diff --git a/mysql-test/t/lock.test b/mysql-test/t/lock.test
index 127cbb54a88..4815c1a30b7 100644
--- a/mysql-test/t/lock.test
+++ b/mysql-test/t/lock.test
@@ -73,3 +73,5 @@ delete from t2 using t1,t2 where t1.a=t2.a;
--error 1099
delete t2 from t1,t2 where t1.a=t2.a;
drop table t1,t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/lock_multi.test b/mysql-test/t/lock_multi.test
index 43cff90332b..0d2266fc2ae 100644
--- a/mysql-test/t/lock_multi.test
+++ b/mysql-test/t/lock_multi.test
@@ -95,10 +95,11 @@ reap;
connection locker;
drop table t1;
+# End of 4.1 tests
#
# BUG#9998 - MySQL client hangs on USE "database"
-
+#
create table t1(a int);
lock tables t1 write;
connection reader;
diff --git a/mysql-test/t/lock_tables_lost_commit.test b/mysql-test/t/lock_tables_lost_commit.test
index 8c1ad97c0cc..d31b4b7dfb5 100644
--- a/mysql-test/t/lock_tables_lost_commit.test
+++ b/mysql-test/t/lock_tables_lost_commit.test
@@ -20,3 +20,5 @@ connection con2;
# binlog-ignore-db
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/lowercase_table.test b/mysql-test/t/lowercase_table.test
index 9332c47cb2f..e6f681e4f90 100644
--- a/mysql-test/t/lowercase_table.test
+++ b/mysql-test/t/lowercase_table.test
@@ -94,3 +94,4 @@ use com1;
--error 1049
use prn;
+# End of 4.1 tests
diff --git a/mysql-test/t/lowercase_table2.test b/mysql-test/t/lowercase_table2.test
index f5cf292482e..c02ae8f5073 100644
--- a/mysql-test/t/lowercase_table2.test
+++ b/mysql-test/t/lowercase_table2.test
@@ -137,3 +137,5 @@ create table t2aA (col1 int);
create table t1Aa (col1 int);
select t1Aa.col1 from t1aA,t2Aa where t1Aa.col1 = t2aA.col1;
drop table t2aA, t1Aa;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/lowercase_table3.test b/mysql-test/t/lowercase_table3.test
index 9841059a26b..7d34ba649cf 100644
--- a/mysql-test/t/lowercase_table3.test
+++ b/mysql-test/t/lowercase_table3.test
@@ -35,3 +35,5 @@ CREATE TABLE t1 (a int) ENGINE=INNODB;
--error 1146
SELECT * from T1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/lowercase_table_grant.test b/mysql-test/t/lowercase_table_grant.test
index 3d6adb477a3..7449231fca5 100644
--- a/mysql-test/t/lowercase_table_grant.test
+++ b/mysql-test/t/lowercase_table_grant.test
@@ -26,3 +26,5 @@ flush privileges;
drop user mysqltest_1@localhost;
drop database MYSQLtest;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/lowercase_table_qcache.test b/mysql-test/t/lowercase_table_qcache.test
index 5077a41402a..e63ad3b2c16 100644
--- a/mysql-test/t/lowercase_table_qcache.test
+++ b/mysql-test/t/lowercase_table_qcache.test
@@ -27,3 +27,5 @@ enable_result_log;
show status like "Qcache_queries_in_cache";
set GLOBAL query_cache_size=0;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/merge.test b/mysql-test/t/merge.test
index 165c16823a2..7d708243a10 100644
--- a/mysql-test/t/merge.test
+++ b/mysql-test/t/merge.test
@@ -320,3 +320,4 @@ INSERT INTO t2 (b) VALUES (1) ON DUPLICATE KEY UPDATE b=3;
SELECT b FROM t2;
DROP TABLE t1, t2;
+# End of 4.1 tests
diff --git a/mysql-test/t/metadata.test b/mysql-test/t/metadata.test
index ebd58ef4ebb..b4edd15f5ef 100644
--- a/mysql-test/t/metadata.test
+++ b/mysql-test/t/metadata.test
@@ -48,3 +48,5 @@ select * from (select 1 union select 1) aaa;
drop table t1;
--disable_metadata
+
+# End of 4.1 tests
diff --git a/mysql-test/t/mix_innodb_myisam_binlog.test b/mysql-test/t/mix_innodb_myisam_binlog.test
index 0641acb552f..2e804f4c986 100644
--- a/mysql-test/t/mix_innodb_myisam_binlog.test
+++ b/mysql-test/t/mix_innodb_myisam_binlog.test
@@ -229,3 +229,5 @@ select (@after-@before) >= 2;
# cleanup
drop table t1,t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/multi_statement.test b/mysql-test/t/multi_statement.test
index 2abec332878..eb8d867f3f0 100644
--- a/mysql-test/t/multi_statement.test
+++ b/mysql-test/t/multi_statement.test
@@ -29,3 +29,5 @@ show status like 'Slow_queries'||||
drop table t1||||
delimiter ;||||
+
+# End of 4.1 tests
diff --git a/mysql-test/t/multi_update.test b/mysql-test/t/multi_update.test
index 0ca42e86204..5e3be6d45eb 100644
--- a/mysql-test/t/multi_update.test
+++ b/mysql-test/t/multi_update.test
@@ -452,6 +452,8 @@ insert into t2 values(1,null);
delete t2, t1 from t2 left join t1 on (t2.aclid=t1.aclid) where t2.refid='1';
drop table t1, t2;
+# End of 4.1 tests
+
#
# Test for bug #1980.
#
diff --git a/mysql-test/t/myisam-blob.test b/mysql-test/t/myisam-blob.test
index 7af8c661c02..ac1b45b8c6c 100644
--- a/mysql-test/t/myisam-blob.test
+++ b/mysql-test/t/myisam-blob.test
@@ -39,3 +39,5 @@ INSERT INTO t1 (data) VALUES (NULL);
UPDATE t1 set data=repeat('a',18*1024*1024);
select length(data) from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/myisam.test b/mysql-test/t/myisam.test
index fccc7642eb0..d949e39b05b 100644
--- a/mysql-test/t/myisam.test
+++ b/mysql-test/t/myisam.test
@@ -675,3 +675,4 @@ show keys from t1;
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/mysql_client_test.test b/mysql-test/t/mysql_client_test.test
index 3639fc2e262..ccf5e0bf66a 100644
--- a/mysql-test/t/mysql_client_test.test
+++ b/mysql-test/t/mysql_client_test.test
@@ -8,3 +8,5 @@
--disable_result_log
--exec echo $MYSQL_CLIENT_TEST
--exec $MYSQL_CLIENT_TEST
+
+# End of 4.1 tests
diff --git a/mysql-test/t/mysql_protocols.test b/mysql-test/t/mysql_protocols.test
index 6e2d4f20429..0253c2b5d17 100644
--- a/mysql-test/t/mysql_protocols.test
+++ b/mysql-test/t/mysql_protocols.test
@@ -10,3 +10,4 @@
--exec echo "select ' ok' as 'MEMORY'" | $MYSQL --protocol=MEMORY 2>&1 || true
--exec echo "select ' ok' as 'NullS'" | $MYSQL --protocol=NullS 2>&1 || true
+# End of 4.1 tests
diff --git a/mysql-test/t/mysqlbinlog.test b/mysql-test/t/mysqlbinlog.test
index 49b8237d99f..e5bd8c554cb 100644
--- a/mysql-test/t/mysqlbinlog.test
+++ b/mysql-test/t/mysqlbinlog.test
@@ -110,3 +110,4 @@ select "--- reading stdin --" as "";
# clean up
drop table t1, t2;
+# End of 4.1 tests
diff --git a/mysql-test/t/mysqlbinlog2.test b/mysql-test/t/mysqlbinlog2.test
index 6e2eda07695..a2f1aba05b0 100644
--- a/mysql-test/t/mysqlbinlog2.test
+++ b/mysql-test/t/mysqlbinlog2.test
@@ -157,3 +157,5 @@ select "--- to-last-log --" as "";
select "--- end of test --" as "";
--enable_query_log
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/mysqldump.test b/mysql-test/t/mysqldump.test
index 81000c17d98..16d1148ef1d 100644
--- a/mysql-test/t/mysqldump.test
+++ b/mysql-test/t/mysqldump.test
@@ -4,7 +4,6 @@
--disable_warnings
DROP TABLE IF EXISTS t1, `"t"1`, t1aa, t2, t2aa;
drop database if exists mysqldump_test_db;
-drop database if exists db1;
drop view if exists v1, v2, v3;
--enable_warnings
@@ -135,15 +134,6 @@ insert into t1 values (1),(2),(3);
drop table t1;
#
-# dump of view
-#
-create table t1(a int);
-create view v1 as select * from t1;
---exec $MYSQL_DUMP --skip-comments test
-drop view v1;
-drop table t1;
-
-#
# Bug #6101: create database problem
#
@@ -198,15 +188,6 @@ INSERT INTO `t1` VALUES (0x602010000280100005E71A);
DROP TABLE t1;
#
-# Bug #9756
-#
-
-CREATE TABLE t1 (a char(10));
-INSERT INTO t1 VALUES ('\'');
---exec $MYSQL_DUMP --skip-comments test t1
-DROP TABLE t1;
-
-#
# Test for --insert-ignore
#
@@ -564,29 +545,6 @@ CREATE TABLE t1 (a int);
INSERT INTO t1 VALUES (1),(2),(3);
--exec $MYSQL_DUMP --add-drop-database --skip-comments --databases test
DROP TABLE t1;
-
-#
-# Bug #10213 mysqldump crashes when dumping VIEWs(on MacOS X)
-#
-
-create database db1;
-use db1;
-
-CREATE TABLE t2 (
- a varchar(30) default NULL,
- KEY a (a(5))
-);
-
-INSERT INTO t2 VALUES ('alfred');
-INSERT INTO t2 VALUES ('angie');
-INSERT INTO t2 VALUES ('bingo');
-INSERT INTO t2 VALUES ('waffle');
-INSERT INTO t2 VALUES ('lemon');
-create view v2 as select * from t2 where a like 'a%' with check option;
---exec $MYSQL_DUMP --skip-comments db1
-drop table t2;
-drop view v2;
-drop database db1;
#
# Bug #9558 mysqldump --no-data db t1 t2 format still dumps data
#
@@ -678,6 +636,50 @@ insert into t2 (a, b) values (NULL, NULL),(10, NULL),(NULL, "twenty"),(30, "thir
--exec $MYSQL_DUMP --skip-comments --xml --no-create-info test
drop table t1, t2;
+# End of 4.1 tests
+
+#
+# dump of view
+#
+create table t1(a int);
+create view v1 as select * from t1;
+--exec $MYSQL_DUMP --skip-comments test
+drop view v1;
+drop table t1;
+
+#
+# Bug #10213 mysqldump crashes when dumping VIEWs(on MacOS X)
+#
+
+create database mysqldump_test_db;
+use mysqldump_test_db;
+
+CREATE TABLE t2 (
+ a varchar(30) default NULL,
+ KEY a (a(5))
+);
+
+INSERT INTO t2 VALUES ('alfred');
+INSERT INTO t2 VALUES ('angie');
+INSERT INTO t2 VALUES ('bingo');
+INSERT INTO t2 VALUES ('waffle');
+INSERT INTO t2 VALUES ('lemon');
+create view v2 as select * from t2 where a like 'a%' with check option;
+--exec $MYSQL_DUMP --skip-comments mysqldump_test_db
+drop table t2;
+drop view v2;
+drop database mysqldump_test_db;
+use test;
+
+#
+# Bug #9756
+#
+
+CREATE TABLE t1 (a char(10));
+INSERT INTO t1 VALUES ('\'');
+--exec $MYSQL_DUMP --skip-comments test t1
+DROP TABLE t1;
+
#
# Bug #10927 mysqldump: Can't reload dump with view that consist of other view
#
diff --git a/mysql-test/t/mysqltest.test b/mysql-test/t/mysqltest.test
index 14b8c1d1127..29588419642 100644
--- a/mysql-test/t/mysqltest.test
+++ b/mysql-test/t/mysqltest.test
@@ -287,6 +287,7 @@ select 3 from t1 ;
#
#select 3 from t1 ;
+# End of 4.1 tests
#
# Bug #10251: Identifiers containing quotes not handled correctly
@@ -296,8 +297,6 @@ select 1 as `a'b`, 2 as `a"b`;
# Test escaping of quotes
select 'aaa\\','aa''a',"aa""a";
-
-
#
# Check of include/show_msg.inc and include/show_msg80.inc
#
diff --git a/mysql-test/t/ndb_alter_table.test b/mysql-test/t/ndb_alter_table.test
index 2e5e2293b5c..bfc278d709b 100644
--- a/mysql-test/t/ndb_alter_table.test
+++ b/mysql-test/t/ndb_alter_table.test
@@ -179,3 +179,5 @@ drop table t1;
#truncate table t2;
#select count(*) from t2;
#drop table t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_autodiscover.test b/mysql-test/t/ndb_autodiscover.test
index c2068329d41..6bbb1c2f2f2 100644
--- a/mysql-test/t/ndb_autodiscover.test
+++ b/mysql-test/t/ndb_autodiscover.test
@@ -544,3 +544,5 @@ create table t10 (
insert into t10 values (1, 'kalle');
--exec $NDB_TOOLS_DIR/ndb_drop_table --no-defaults -d test `$NDB_TOOLS_DIR/ndb_show_tables --no-defaults | grep BLOB` >> $NDB_TOOLS_OUTPUT 2>&1 || true
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_autodiscover2.test b/mysql-test/t/ndb_autodiscover2.test
index 76baa31a2a9..f12d3d31fdd 100644
--- a/mysql-test/t/ndb_autodiscover2.test
+++ b/mysql-test/t/ndb_autodiscover2.test
@@ -18,3 +18,4 @@ drop table t9;
select * from t10;
drop table t10;
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_basic.test b/mysql-test/t/ndb_basic.test
index c0d5b14c2ea..1c78a4b8744 100644
--- a/mysql-test/t/ndb_basic.test
+++ b/mysql-test/t/ndb_basic.test
@@ -606,6 +606,7 @@ select * from t1 order by counter;
drop table t1;
+# End of 4.1 tests
#
# Test long table name
diff --git a/mysql-test/t/ndb_blob.test b/mysql-test/t/ndb_blob.test
index b265809b75f..a12ebee2f0d 100644
--- a/mysql-test/t/ndb_blob.test
+++ b/mysql-test/t/ndb_blob.test
@@ -404,3 +404,5 @@ Proper fix: Set inline bytes to multiple of mbmaxlen and
validate it (after the 8 byte length).');
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_cache.test b/mysql-test/t/ndb_cache.test
index b61422a58fb..9c299b61c24 100644
--- a/mysql-test/t/ndb_cache.test
+++ b/mysql-test/t/ndb_cache.test
@@ -119,4 +119,4 @@ show status like "Qcache_queries_in_cache";
SET GLOBAL query_cache_size=0;
-
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_charset.test b/mysql-test/t/ndb_charset.test
index becbe9a4d06..fb43e1831f3 100644
--- a/mysql-test/t/ndb_charset.test
+++ b/mysql-test/t/ndb_charset.test
@@ -246,3 +246,5 @@ replace into t1 values ('jonas % ');
replace into t1 values ('jonas % ');
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_config.test b/mysql-test/t/ndb_config.test
index ea78a32b1ba..66287bf6d29 100644
--- a/mysql-test/t/ndb_config.test
+++ b/mysql-test/t/ndb_config.test
@@ -5,3 +5,5 @@
--exec $NDB_TOOLS_DIR/ndb_config --no-defaults --query=nodeid,host,DataMemory,IndexMemory --type=ndbd 2> /dev/null
--exec $NDB_TOOLS_DIR/ndb_config --no-defaults -r \\n -f " " --query=nodeid,host,DataMemory,IndexMemory --type=ndbd 2> /dev/null
--exec $NDB_TOOLS_DIR/ndb_config --no-defaults --query=nodeid --type=ndbd --host=localhost 2> /dev/null
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_database.test b/mysql-test/t/ndb_database.test
index 1264c3fa73b..2e924ba2dcc 100644
--- a/mysql-test/t/ndb_database.test
+++ b/mysql-test/t/ndb_database.test
@@ -48,3 +48,5 @@ show tables;
drop table if exists t1;
drop database if exists mysqltest;
--enable_warnings
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_grant.later b/mysql-test/t/ndb_grant.later
index b4885d2c5fc..5431d94e1f8 100644
--- a/mysql-test/t/ndb_grant.later
+++ b/mysql-test/t/ndb_grant.later
@@ -381,3 +381,5 @@ alter table time_zone_transition_type engine=myisam;
alter table user engine=myisam;
use test;
flush privileges;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_index.test b/mysql-test/t/ndb_index.test
index 93085dea587..272f30e3e6f 100644
--- a/mysql-test/t/ndb_index.test
+++ b/mysql-test/t/ndb_index.test
@@ -126,5 +126,6 @@ select port, accessnode, pop, accesstype from t1 where pop='pop98' and accessno
select port, accessnode, pop, accesstype from t1 where pop='pop98' and accessnode='node78' and port='port67' and customer_id='kllopmn';
select port, accessnode, pop, accesstype from t1 where pop='pop98' and accessnode='node78' and port='port67' and customer_id='foo';
-
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_index_ordered.test b/mysql-test/t/ndb_index_ordered.test
index 9c9d5d5a84f..9b70919ab2a 100644
--- a/mysql-test/t/ndb_index_ordered.test
+++ b/mysql-test/t/ndb_index_ordered.test
@@ -348,3 +348,5 @@ connection con1;
select a from t1 where b = 2;
show tables;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_index_unique.test b/mysql-test/t/ndb_index_unique.test
index d6de013c1e2..2185276c2c6 100644
--- a/mysql-test/t/ndb_index_unique.test
+++ b/mysql-test/t/ndb_index_unique.test
@@ -308,3 +308,5 @@ INSERT INTO t1 (month, year, code) VALUES (5,2004,'12');
select * from t1 where code = '12' and month = 4 and year = 2004 ;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_insert.test b/mysql-test/t/ndb_insert.test
index 68f3817e134..92bc51bcf4f 100644
--- a/mysql-test/t/ndb_insert.test
+++ b/mysql-test/t/ndb_insert.test
@@ -616,3 +616,5 @@ INSERT IGNORE INTO t1 VALUES (1);
INSERT IGNORE INTO t1 VALUES (1);
SELECT * FROM t1;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_limit.test b/mysql-test/t/ndb_limit.test
index 0df3b2f7566..01613606d66 100644
--- a/mysql-test/t/ndb_limit.test
+++ b/mysql-test/t/ndb_limit.test
@@ -81,3 +81,5 @@ SELECT DATE_FORMAT(day, '%Y%m%d') as date, DATE_FORMAT(day, '%d-%m-%Y')
as date_formatted FROM t2 GROUP BY day ORDER BY day DESC LIMIT 2;
drop table t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_lock.test b/mysql-test/t/ndb_lock.test
index b93abbd564b..6945f91ee39 100644
--- a/mysql-test/t/ndb_lock.test
+++ b/mysql-test/t/ndb_lock.test
@@ -69,3 +69,4 @@ insert into t1 values (1,1,1);
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_minmax.test b/mysql-test/t/ndb_minmax.test
index 97ea84f98ef..a3ac677cd2a 100644
--- a/mysql-test/t/ndb_minmax.test
+++ b/mysql-test/t/ndb_minmax.test
@@ -62,6 +62,4 @@ select MAX(c) from t2;
select * from t2 order by a;
drop table t2;
-
-
-
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_multi.test b/mysql-test/t/ndb_multi.test
index 85950c72cf9..760150c6f6a 100644
--- a/mysql-test/t/ndb_multi.test
+++ b/mysql-test/t/ndb_multi.test
@@ -68,4 +68,4 @@ drop table t1, t2, t3, t4;
connection server2;
drop table t1, t3, t4;
-
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_replace.test b/mysql-test/t/ndb_replace.test
index 1c06a9a6633..b97a0322a6a 100644
--- a/mysql-test/t/ndb_replace.test
+++ b/mysql-test/t/ndb_replace.test
@@ -26,3 +26,5 @@ insert into t1 (gesuchnr,benutzer_id) values (1,1);
replace into t1 (gesuchnr,benutzer_id) values (1,1);
select * from t1 order by gesuchnr;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_restore.test b/mysql-test/t/ndb_restore.test
index 0173fabd46f..049b07d5a8b 100644
--- a/mysql-test/t/ndb_restore.test
+++ b/mysql-test/t/ndb_restore.test
@@ -215,3 +215,5 @@ drop table if exists t1_c,t2_c,t3_c,t4_c,t5_c,t6_c,t7_c,t8_c,t9_c;
#
--exec $NDB_TOOLS_DIR/ndb_select_all --no-defaults -d sys -D , SYSTAB_0 | grep 520093696
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_subquery.test b/mysql-test/t/ndb_subquery.test
index 095fdbcfa13..93c45c521a0 100644
--- a/mysql-test/t/ndb_subquery.test
+++ b/mysql-test/t/ndb_subquery.test
@@ -38,8 +38,11 @@ drop table t2;
# bug#5367
##########
-###
+# End of 4.1 tests
+
+#
# bug#11205
+#
create table t1 (p int not null primary key, u int not null) engine=ndb;
insert into t1 values (1,1),(2,2),(3,3);
diff --git a/mysql-test/t/ndb_transaction.test b/mysql-test/t/ndb_transaction.test
index ae02059786d..d3ebadb1a78 100644
--- a/mysql-test/t/ndb_transaction.test
+++ b/mysql-test/t/ndb_transaction.test
@@ -295,4 +295,4 @@ select count(*) from t2;
drop table test.t1, t2;
drop database mysqltest;
-
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_truncate.test b/mysql-test/t/ndb_truncate.test
index 7c0f79bcc59..73af70d0d0f 100644
--- a/mysql-test/t/ndb_truncate.test
+++ b/mysql-test/t/ndb_truncate.test
@@ -32,3 +32,5 @@ truncate table t2;
select count(*) from t2;
drop table t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_types.test b/mysql-test/t/ndb_types.test
index d4bf4133807..3446a409b2a 100644
--- a/mysql-test/t/ndb_types.test
+++ b/mysql-test/t/ndb_types.test
@@ -81,3 +81,5 @@ from t1;
select time_stamp>@now from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ndb_update.test b/mysql-test/t/ndb_update.test
index 5453e41f937..45e3add4639 100644
--- a/mysql-test/t/ndb_update.test
+++ b/mysql-test/t/ndb_update.test
@@ -32,3 +32,5 @@ select * from t1 order by pk1;
--disable_warnings
DROP TABLE IF EXISTS t1;
--enable_warnings
+
+# End of 4.1 tests
diff --git a/mysql-test/t/negation_elimination.test b/mysql-test/t/negation_elimination.test
index c50a9678edb..0e0d8891e1f 100644
--- a/mysql-test/t/negation_elimination.test
+++ b/mysql-test/t/negation_elimination.test
@@ -70,3 +70,5 @@ select a, not(not(a)) from t1;
explain extended select a, not(not(a)), not(a <= 2 and not(a)), not(a not like "1"), not (a not in (1,2)), not(a != 2) from t1 where not(not(a)) having not(not(a));
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/not_embedded_server.test b/mysql-test/t/not_embedded_server.test
new file mode 100644
index 00000000000..83ec03d6706
--- /dev/null
+++ b/mysql-test/t/not_embedded_server.test
@@ -0,0 +1,18 @@
+#
+# Here we collect tests that doesn't work with the embedded server
+#
+
+-- source include/not_embedded.inc
+
+#
+# Show full process list with prepare
+# To not show other connections, this must be the first test and we must
+# have a server restart before this one
+#
+
+prepare stmt1 from ' show full processlist ';
+--replace_column 1 number 6 time 3 localhost
+execute stmt1;
+deallocate prepare stmt1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/null.test b/mysql-test/t/null.test
index 4cd20979319..183308880ed 100644
--- a/mysql-test/t/null.test
+++ b/mysql-test/t/null.test
@@ -189,3 +189,5 @@ select
# Restore charset to the default value.
set names latin1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/null_key.test b/mysql-test/t/null_key.test
index d7f6a634d1e..318e1fa6b9b 100644
--- a/mysql-test/t/null_key.test
+++ b/mysql-test/t/null_key.test
@@ -193,3 +193,5 @@ select * from t1 where id2 is null or id2 > 0;
delete from t1 where id <=> NULL;
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/odbc.test b/mysql-test/t/odbc.test
index 9aac5948359..d4b6fc35e74 100644
--- a/mysql-test/t/odbc.test
+++ b/mysql-test/t/odbc.test
@@ -20,3 +20,5 @@ select * from t1 where a is null and b=2;
select * from t1 where a is null;
explain select * from t1 where b is null;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/olap.test b/mysql-test/t/olap.test
index f3017978588..2e09bc5b3a3 100644
--- a/mysql-test/t/olap.test
+++ b/mysql-test/t/olap.test
@@ -276,3 +276,5 @@ INSERT INTO t1 VALUES (1, 2);
SELECT a, b, a AS c, COUNT(*) AS count FROM t1 GROUP BY a, b, c WITH ROLLUP;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/openssl_1.test b/mysql-test/t/openssl_1.test
index 2262395d586..96c92615430 100644
--- a/mysql-test/t/openssl_1.test
+++ b/mysql-test/t/openssl_1.test
@@ -43,3 +43,5 @@ delete from mysql.user where user='ssl_user%';
delete from mysql.db where user='ssl_user%';
flush privileges;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/order_by.test b/mysql-test/t/order_by.test
index 36eee6e43b7..e3b26a3e47f 100644
--- a/mysql-test/t/order_by.test
+++ b/mysql-test/t/order_by.test
@@ -549,3 +549,5 @@ INSERT INTO t1 VALUES (2), (1), (1), (2), (1);
SELECT a FROM t1 ORDER BY a;
(SELECT a FROM t1) ORDER BY a;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/order_fill_sortbuf.test b/mysql-test/t/order_fill_sortbuf.test
index 37620ebe331..f13cf8cf350 100644
--- a/mysql-test/t/order_fill_sortbuf.test
+++ b/mysql-test/t/order_fill_sortbuf.test
@@ -22,3 +22,5 @@ enable_query_log;
create table t2 select id2 from t1 order by id3;
select count(*) from t2;
drop table t1,t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/outfile.test b/mysql-test/t/outfile.test
index 4b12f9e4e50..a74bebe1460 100644
--- a/mysql-test/t/outfile.test
+++ b/mysql-test/t/outfile.test
@@ -63,3 +63,5 @@ EXPLAIN
FIELDS TERMINATED BY ',' OPTIONALLY ENCLOSED BY '"' LINES TERMINATED BY '\r\n'
FROM t1;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/overflow.test b/mysql-test/t/overflow.test
index 17e443d51f8..c930707413b 100644
--- a/mysql-test/t/overflow.test
+++ b/mysql-test/t/overflow.test
@@ -2,3 +2,5 @@ connect (con1,localhost,boo,,);
connection con1;
-- error 1064,1102,1280
drop database AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/packet.test b/mysql-test/t/packet.test
index c7f10d75d74..04122b42b44 100644
--- a/mysql-test/t/packet.test
+++ b/mysql-test/t/packet.test
@@ -31,3 +31,5 @@ set global net_buffer_length=default;
set net_buffer_length=default;
SELECT length("aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa") as len;
select length(repeat('a',2000));
+
+# End of 4.1 tests
diff --git a/mysql-test/t/preload.test b/mysql-test/t/preload.test
index 7a049d06a86..1b7f3c5b9eb 100644
--- a/mysql-test/t/preload.test
+++ b/mysql-test/t/preload.test
@@ -98,3 +98,5 @@ load index into cache t3 key (b), t2 key (c) ;
show status like "key_read%";
drop table t1, t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ps.test b/mysql-test/t/ps.test
index de92c67518e..b4c04e4432a 100644
--- a/mysql-test/t/ps.test
+++ b/mysql-test/t/ps.test
@@ -828,3 +828,5 @@ execute stmt;
set @@tx_isolation=default;
execute stmt;
deallocate prepare stmt;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ps_10nestset.test b/mysql-test/t/ps_10nestset.test
index 53e84f7a47d..46a88653da3 100644
--- a/mysql-test/t/ps_10nestset.test
+++ b/mysql-test/t/ps_10nestset.test
@@ -69,3 +69,5 @@ execute st_round using @arg_round, @arg_round;
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ps_11bugs.test b/mysql-test/t/ps_11bugs.test
index 5945b140645..e214afeaaf3 100644
--- a/mysql-test/t/ps_11bugs.test
+++ b/mysql-test/t/ps_11bugs.test
@@ -129,3 +129,4 @@ drop table t1, t2;
# end of bug#1676
+# End of 4.1 tests
diff --git a/mysql-test/t/ps_1general.test b/mysql-test/t/ps_1general.test
index ab133e4c347..6abfd8f28a7 100644
--- a/mysql-test/t/ps_1general.test
+++ b/mysql-test/t/ps_1general.test
@@ -930,3 +930,5 @@ drop table t5, t9;
# Thank you for reading these rules of thumb.
#
# Matthias
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ps_2myisam.test b/mysql-test/t/ps_2myisam.test
index 534703efc14..0a335bd02a3 100644
--- a/mysql-test/t/ps_2myisam.test
+++ b/mysql-test/t/ps_2myisam.test
@@ -40,3 +40,5 @@ drop table t2 ;
-- source include/ps_conv.inc
drop table t1, t9;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ps_3innodb.test b/mysql-test/t/ps_3innodb.test
index f83b61914a2..e25a8b1f469 100644
--- a/mysql-test/t/ps_3innodb.test
+++ b/mysql-test/t/ps_3innodb.test
@@ -22,3 +22,5 @@ let $type= 'InnoDB' ;
-- source include/ps_conv.inc
drop table t1, t9;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ps_4heap.test b/mysql-test/t/ps_4heap.test
index 3ce3bea8265..f16d4599a74 100644
--- a/mysql-test/t/ps_4heap.test
+++ b/mysql-test/t/ps_4heap.test
@@ -47,3 +47,5 @@ eval create table t9
-- source include/ps_conv.inc
drop table t1, t9;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ps_5merge.test b/mysql-test/t/ps_5merge.test
index 7e94ede41d1..e6ce9bf42d3 100644
--- a/mysql-test/t/ps_5merge.test
+++ b/mysql-test/t/ps_5merge.test
@@ -82,3 +82,5 @@ INSERT_METHOD=LAST;
drop table t1, t1_1, t1_2,
t9_1, t9_2, t9;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ps_6bdb.test b/mysql-test/t/ps_6bdb.test
index 5db3349279e..49dd7aa924b 100644
--- a/mysql-test/t/ps_6bdb.test
+++ b/mysql-test/t/ps_6bdb.test
@@ -21,3 +21,5 @@ let $type= 'BDB' ;
-- source include/ps_conv.inc
drop table t1, t9;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ps_7ndb.test b/mysql-test/t/ps_7ndb.test
index b558f2f3c21..e3f65ec2c4e 100644
--- a/mysql-test/t/ps_7ndb.test
+++ b/mysql-test/t/ps_7ndb.test
@@ -21,3 +21,5 @@ let $type= 'NDB' ;
-- source include/ps_conv.inc
drop table t1, t9;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/ps_grant.test b/mysql-test/t/ps_grant.test
index 0b33a2dadde..81c842de459 100644
--- a/mysql-test/t/ps_grant.test
+++ b/mysql-test/t/ps_grant.test
@@ -1,7 +1,6 @@
# Can't test grants with embedded server
-- source include/not_embedded.inc
-
let $type= 'MYISAM' ;
################ GRANT/REVOKE/DROP affecting a parallel session ################
@@ -80,6 +79,7 @@ execute s_t1 ;
######## Question 2: The table t9 does not exist. ########
--error 1146
execute s_t9 ;
+deallocate prepare s_t9;
#### revoke the access rights to t1
@@ -112,8 +112,11 @@ show grants for second_user@localhost ;
drop database mysqltest;
+# End of 4.1 tests
-## grant/revoke + drop user
+#
+# grant/revoke + drop user
+#
--error 1295
prepare stmt3 from ' grant all on test.t1 to drop_user@localhost
identified by ''looser'' ';
@@ -126,11 +129,3 @@ revoke all privileges on test.t1 from drop_user@localhost ;
--error 1295
prepare stmt3 from ' drop user drop_user@localhost ';
drop user drop_user@localhost;
-
-# This test must be the last one, otherwise it may produce extra
-# rows in the processlist under high load.
-# Tested here simply so it is not tested with embedded server
-prepare stmt4 from ' show full processlist ';
---replace_column 1 number 6 time 3 localhost
-execute stmt4;
-deallocate prepare stmt4;
diff --git a/mysql-test/t/query_cache.test b/mysql-test/t/query_cache.test
index 0b0758db5b1..8bff2b4608b 100644
--- a/mysql-test/t/query_cache.test
+++ b/mysql-test/t/query_cache.test
@@ -876,3 +876,5 @@ show status like "Qcache_hits";
drop procedure f1;
drop table t1;
set GLOBAL query_cache_size=0;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/query_cache_merge.test b/mysql-test/t/query_cache_merge.test
index fef3f18df60..36b8662f088 100644
--- a/mysql-test/t/query_cache_merge.test
+++ b/mysql-test/t/query_cache_merge.test
@@ -36,3 +36,5 @@ show status like "Qcache_queries_in_cache";
drop table t1,t2,t3,t4,t5,t6,t7,t8,t9,t10,t11,t12,t13,t14,t15,t16,t17,t18,t19,t20,t21,t22,t23,t24,t25,t26,t27,t28,t29,t30,t31,t32,t33,t34,t35,t36,t37,t38,t39,t40,t41,t42,t43,t44,t45,t46,t47,t48,t49,t50,t51,t52,t53,t54,t55,t56,t57,t58,t59,t60,t61,t62,t63,t64,t65,t66,t67,t68,t69,t70,t71,t72,t73,t74,t75,t76,t77,t78,t79,t80,t81,t82,t83,t84,t85,t86,t87,t88,t89,t90,t91,t92,t93,t94,t95,t96,t97,t98,t99,t100,t101,t102,t103,t104,t105,t106,t107,t108,t109,t110,t111,t112,t113,t114,t115,t116,t117,t118,t119,t120,t121,t122,t123,t124,t125,t126,t127,t128,t129,t130,t131,t132,t133,t134,t135,t136,t137,t138,t139,t140,t141,t142,t143,t144,t145,t146,t147,t148,t149,t150,t151,t152,t153,t154,t155,t156,t157,t158,t159,t160,t161,t162,t163,t164,t165,t166,t167,t168,t169,t170,t171,t172,t173,t174,t175,t176,t177,t178,t179,t180,t181,t182,t183,t184,t185,t186,t187,t188,t189,t190,t191,t192,t193,t194,t195,t196,t197,t198,t199,t200,t201,t202,t203,t204,t205,t206,t207,t208,t209,t210,t211,t212,t213,t214,t215,t216,t217,t218,t219,t220,t221,t222,t223,t224,t225,t226,t227,t228,t229,t230,t231,t232,t233,t234,t235,t236,t237,t238,t239,t240,t241,t242,t243,t244,t245,t246,t247,t248,t249,t250,t251,t252,t253,t254,t255,t256,t257,t00;
SET @@global.query_cache_size=0;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/raid.test b/mysql-test/t/raid.test
index 14a55db0c34..3ca5adaaaea 100644
--- a/mysql-test/t/raid.test
+++ b/mysql-test/t/raid.test
@@ -220,3 +220,5 @@ ALTER TABLE t1 RENAME t2;
ALTER TABLE t2 CHANGE COLUMN c c VARCHAR(251) NOT NULL;
select count(*) from t2;
DROP TABLE t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/range.test b/mysql-test/t/range.test
index 065cef659b8..12dda022cb9 100644
--- a/mysql-test/t/range.test
+++ b/mysql-test/t/range.test
@@ -490,6 +490,8 @@ SELECT count(*) FROM t1 WHERE CLIENT='000' AND (ARG1 != ' 1' OR ARG1 != ' 2');
SELECT count(*) FROM t1 WHERE CLIENT='000' AND (ARG1 != ' 2' OR ARG1 != ' 1');
drop table t1;
+# End of 4.1 tests
+
#
# Test for optimization request #10561: to use keys for
# NOT IN (c1,...,cn) and NOT BETWEEN c1 AND c2
diff --git a/mysql-test/t/rename.test b/mysql-test/t/rename.test
index 6fa208f37ec..5caecef176e 100644
--- a/mysql-test/t/rename.test
+++ b/mysql-test/t/rename.test
@@ -65,3 +65,5 @@ sleep 1;
show tables;
drop table t2, t4;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/repair.test b/mysql-test/t/repair.test
index ef7043febbc..5e39e0b6a50 100644
--- a/mysql-test/t/repair.test
+++ b/mysql-test/t/repair.test
@@ -33,3 +33,5 @@ system echo 1 > $MYSQL_TEST_DIR/var/master-data/test/t1.MYI ;
repair table t1;
repair table t1 use_frm;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/replace.test b/mysql-test/t/replace.test
index 2b3775f4f67..10703eaafb8 100644
--- a/mysql-test/t/replace.test
+++ b/mysql-test/t/replace.test
@@ -33,3 +33,5 @@ replace into t1 values (126,"first updated");
replace into t1 values (63,default);
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rollback.test b/mysql-test/t/rollback.test
index 3cb1ea3024b..3b8ad901907 100644
--- a/mysql-test/t/rollback.test
+++ b/mysql-test/t/rollback.test
@@ -21,3 +21,5 @@ select * from t1;
select @@warning_count;
show warnings;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/row.test b/mysql-test/t/row.test
index afcaaef6811..4becef1c2b7 100644
--- a/mysql-test/t/row.test
+++ b/mysql-test/t/row.test
@@ -84,3 +84,5 @@ select a, MAX(b), (1, MAX(b)) = (1, 4) from t1 group by a;
drop table t1;
SELECT ROW(2,10) <=> ROW(3,4);
SELECT ROW(NULL,10) <=> ROW(3,NULL);
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000001.test b/mysql-test/t/rpl000001.test
index e9a87529706..13dba142d54 100644
--- a/mysql-test/t/rpl000001.test
+++ b/mysql-test/t/rpl000001.test
@@ -126,3 +126,5 @@ drop table t1;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000002.test b/mysql-test/t/rpl000002.test
index 4fbb6a595a4..bafd8a30159 100644
--- a/mysql-test/t/rpl000002.test
+++ b/mysql-test/t/rpl000002.test
@@ -37,3 +37,5 @@ show create table t5;
connection master;
drop table t2,t3,t5;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000004.test b/mysql-test/t/rpl000004.test
index 8fc2977faab..f2a02bd4dd6 100644
--- a/mysql-test/t/rpl000004.test
+++ b/mysql-test/t/rpl000004.test
@@ -21,3 +21,5 @@ connection slave;
sync_with_master;
create table t1(n int);
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000005.test b/mysql-test/t/rpl000005.test
index b94695c72e1..e81ad739402 100644
--- a/mysql-test/t/rpl000005.test
+++ b/mysql-test/t/rpl000005.test
@@ -20,3 +20,5 @@ drop table t1;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000006.test b/mysql-test/t/rpl000006.test
index 898ef309f50..334ed575835 100644
--- a/mysql-test/t/rpl000006.test
+++ b/mysql-test/t/rpl000006.test
@@ -43,3 +43,5 @@ drop table t1;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000008.test b/mysql-test/t/rpl000008.test
index ea782b99d28..fe030f90411 100644
--- a/mysql-test/t/rpl000008.test
+++ b/mysql-test/t/rpl000008.test
@@ -34,3 +34,5 @@ save_master_pos;
connection slave;
sync_with_master;
drop table mysqltest_foo,mysqltest_bar,t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000009.test b/mysql-test/t/rpl000009.test
index 59451bc888d..a51a64979fa 100644
--- a/mysql-test/t/rpl000009.test
+++ b/mysql-test/t/rpl000009.test
@@ -170,3 +170,5 @@ sync_with_master;
# These has to be droped on slave as they are not replicated
drop database mysqltest2;
drop database mysqltest3;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000010.test b/mysql-test/t/rpl000010.test
index 0725214694a..261b9148774 100644
--- a/mysql-test/t/rpl000010.test
+++ b/mysql-test/t/rpl000010.test
@@ -16,3 +16,4 @@ save_master_pos;
connection slave;
sync_with_master;
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000011.test b/mysql-test/t/rpl000011.test
index 3b00afe10e4..32f6227f7c5 100644
--- a/mysql-test/t/rpl000011.test
+++ b/mysql-test/t/rpl000011.test
@@ -13,3 +13,5 @@ select * from t1;
connection master;
drop table t1;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000012.test b/mysql-test/t/rpl000012.test
index 7f440eaaa13..2c1c65e4202 100644
--- a/mysql-test/t/rpl000012.test
+++ b/mysql-test/t/rpl000012.test
@@ -41,3 +41,5 @@ drop table if exists t1,t2;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000013.test b/mysql-test/t/rpl000013.test
index 94d5feb3925..eca4803c6bc 100644
--- a/mysql-test/t/rpl000013.test
+++ b/mysql-test/t/rpl000013.test
@@ -39,3 +39,5 @@ drop table if exists t1,t2;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000015.test b/mysql-test/t/rpl000015.test
index da73c5f4db2..a53049386af 100644
--- a/mysql-test/t/rpl000015.test
+++ b/mysql-test/t/rpl000015.test
@@ -37,3 +37,5 @@ select * from t1;
connection master;
drop table t1;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000017.test b/mysql-test/t/rpl000017.test
index 3b39a6b49a6..3b4574e9547 100644
--- a/mysql-test/t/rpl000017.test
+++ b/mysql-test/t/rpl000017.test
@@ -17,3 +17,5 @@ select * from t1;
connection master;
drop table t1;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl000018.test b/mysql-test/t/rpl000018.test
index fd2be2399a5..bc6d887cc99 100644
--- a/mysql-test/t/rpl000018.test
+++ b/mysql-test/t/rpl000018.test
@@ -25,3 +25,5 @@ select * from t1;
connection master;
drop table t1;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_EE_error.test b/mysql-test/t/rpl_EE_error.test
index 90d8c36685f..683ccf1bc40 100644
--- a/mysql-test/t/rpl_EE_error.test
+++ b/mysql-test/t/rpl_EE_error.test
@@ -28,3 +28,5 @@ drop table t1;
save_master_pos;
connection slave;
wait_for_slave_to_stop;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_alter.test b/mysql-test/t/rpl_alter.test
index a913f01cd81..576376a0264 100644
--- a/mysql-test/t/rpl_alter.test
+++ b/mysql-test/t/rpl_alter.test
@@ -20,3 +20,5 @@ drop database mysqltest;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_chain_temp_table.test b/mysql-test/t/rpl_chain_temp_table.test
index 007b018e9d8..96e228a17a1 100644
--- a/mysql-test/t/rpl_chain_temp_table.test
+++ b/mysql-test/t/rpl_chain_temp_table.test
@@ -97,3 +97,5 @@ sync_with_master;
# memory they use is freed (it should) by mysqld before it terminates).
# If they wouldn't be cleaned up, you would see some "still reachable" blocks in
# Valgrind.
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_change_master.test b/mysql-test/t/rpl_change_master.test
index 23866447c98..45a6d2c0c28 100644
--- a/mysql-test/t/rpl_change_master.test
+++ b/mysql-test/t/rpl_change_master.test
@@ -33,3 +33,5 @@ drop table t1;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_charset.test b/mysql-test/t/rpl_charset.test
index ee54bc72a65..e5ddf084461 100644
--- a/mysql-test/t/rpl_charset.test
+++ b/mysql-test/t/rpl_charset.test
@@ -169,3 +169,5 @@ set @p=_latin1 'test';
update t1 set pk='test' where pk=@p;
drop table t1;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_commit_after_flush.test b/mysql-test/t/rpl_commit_after_flush.test
index 62c89b3aae6..6129e5485a6 100644
--- a/mysql-test/t/rpl_commit_after_flush.test
+++ b/mysql-test/t/rpl_commit_after_flush.test
@@ -15,3 +15,5 @@ drop table t1;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_create_database.test b/mysql-test/t/rpl_create_database.test
index c63b0bc85ef..cfccc4567b5 100644
--- a/mysql-test/t/rpl_create_database.test
+++ b/mysql-test/t/rpl_create_database.test
@@ -69,3 +69,5 @@ DROP DATABASE IF EXISTS mysqltest_prometheus;
DROP DATABASE IF EXISTS mysqltest_sisyfos;
DROP DATABASE IF EXISTS mysqltest_bob;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_ddl.test b/mysql-test/t/rpl_ddl.test
index d043d40d96e..9521ba3d4c1 100644
--- a/mysql-test/t/rpl_ddl.test
+++ b/mysql-test/t/rpl_ddl.test
@@ -348,3 +348,5 @@ DROP DATABASE IF EXISTS mysqltest1;
DROP DATABASE IF EXISTS mysqltest2;
DROP DATABASE IF EXISTS mysqltest3;
--enable_warnings
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_deadlock.test b/mysql-test/t/rpl_deadlock.test
index eb4c5c33714..d31ef3a5bef 100644
--- a/mysql-test/t/rpl_deadlock.test
+++ b/mysql-test/t/rpl_deadlock.test
@@ -109,3 +109,5 @@ show slave status;
connection master;
drop table t1,t2,t3,t4;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_delete_all.test b/mysql-test/t/rpl_delete_all.test
index ad2ce29c610..db33ee3bb86 100644
--- a/mysql-test/t/rpl_delete_all.test
+++ b/mysql-test/t/rpl_delete_all.test
@@ -39,3 +39,5 @@ select * from t1;
connection master;
drop table t1;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_do_grant.test b/mysql-test/t/rpl_do_grant.test
index 27a22874497..54287a67657 100644
--- a/mysql-test/t/rpl_do_grant.test
+++ b/mysql-test/t/rpl_do_grant.test
@@ -44,3 +44,5 @@ sync_with_master;
# no need to delete manually, as the DELETEs must have done some real job on
# master (updated binlog)
flush privileges;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_drop.test b/mysql-test/t/rpl_drop.test
index ab5b608cab6..2544599208e 100644
--- a/mysql-test/t/rpl_drop.test
+++ b/mysql-test/t/rpl_drop.test
@@ -10,3 +10,5 @@ drop table t1, t2;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_drop_temp.test b/mysql-test/t/rpl_drop_temp.test
index cf663367b78..18fc17ed064 100644
--- a/mysql-test/t/rpl_drop_temp.test
+++ b/mysql-test/t/rpl_drop_temp.test
@@ -14,3 +14,4 @@ show status like 'Slave_open_temp_tables';
connection default;
drop database mysqltest;
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_empty_master_crash.test b/mysql-test/t/rpl_empty_master_crash.test
index 98a630c69ca..5f26bedc9fe 100644
--- a/mysql-test/t/rpl_empty_master_crash.test
+++ b/mysql-test/t/rpl_empty_master_crash.test
@@ -11,3 +11,5 @@ load table t1 from master;
connection slave;
--error 1188
load table t1 from master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_error_ignored_table.test b/mysql-test/t/rpl_error_ignored_table.test
index 5388b6af8d4..7d948e96c39 100644
--- a/mysql-test/t/rpl_error_ignored_table.test
+++ b/mysql-test/t/rpl_error_ignored_table.test
@@ -55,3 +55,5 @@ connection slave;
# SQL slave thread should not have stopped (because table of the killed
# query is in the ignore list).
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_failed_optimize.test b/mysql-test/t/rpl_failed_optimize.test
index d245d1bacbb..57afaa89e83 100644
--- a/mysql-test/t/rpl_failed_optimize.test
+++ b/mysql-test/t/rpl_failed_optimize.test
@@ -16,3 +16,5 @@ OPTIMIZE TABLE t1;
OPTIMIZE TABLE non_existing;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_failsafe.test b/mysql-test/t/rpl_failsafe.test
index ae61b061153..4336d897fc0 100644
--- a/mysql-test/t/rpl_failsafe.test
+++ b/mysql-test/t/rpl_failsafe.test
@@ -20,3 +20,5 @@ start slave;
sync_with_master;
show variables like 'rpl_recovery_rank';
show status like 'Rpl_status';
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_flush_log_loop.test b/mysql-test/t/rpl_flush_log_loop.test
index ccaae8ad765..ff599af89a3 100644
--- a/mysql-test/t/rpl_flush_log_loop.test
+++ b/mysql-test/t/rpl_flush_log_loop.test
@@ -20,3 +20,5 @@ sleep 5;
--replace_result $SLAVE_MYPORT SLAVE_PORT
--replace_column 1 # 8 # 9 # 23 # 33 #
show slave status;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_flush_tables.test b/mysql-test/t/rpl_flush_tables.test
index eb16ddcd8de..eff0a79bc45 100644
--- a/mysql-test/t/rpl_flush_tables.test
+++ b/mysql-test/t/rpl_flush_tables.test
@@ -35,3 +35,5 @@ sync_with_master;
select * from t3;
# Note that all this confusion may cause warnings 'table xx is open on rename'
# in the .err files; these are not fatal and are not reported by mysql-test-run.
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_free_items.test b/mysql-test/t/rpl_free_items.test
index 3228ffd9cde..043e84160b8 100644
--- a/mysql-test/t/rpl_free_items.test
+++ b/mysql-test/t/rpl_free_items.test
@@ -18,3 +18,5 @@ connection master;
drop table t1;
drop table t2;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_get_lock.test b/mysql-test/t/rpl_get_lock.test
index 847e7145be6..945bd98c993 100644
--- a/mysql-test/t/rpl_get_lock.test
+++ b/mysql-test/t/rpl_get_lock.test
@@ -39,3 +39,5 @@ drop table t1;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_heap.test b/mysql-test/t/rpl_heap.test
index 3452f3990bf..3ee335fe58d 100644
--- a/mysql-test/t/rpl_heap.test
+++ b/mysql-test/t/rpl_heap.test
@@ -47,3 +47,5 @@ drop table t1;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_ignore_grant.test b/mysql-test/t/rpl_ignore_grant.test
index 9b012d08df3..2e6e2ce9a31 100644
--- a/mysql-test/t/rpl_ignore_grant.test
+++ b/mysql-test/t/rpl_ignore_grant.test
@@ -55,3 +55,5 @@ sync_with_master;
delete from mysql.user where user=_binary'rpl_ignore_grant';
delete from mysql.db where user=_binary'rpl_ignore_grant';
flush privileges;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_init_slave.test b/mysql-test/t/rpl_init_slave.test
index 3ea04117ced..cefb04a7b75 100644
--- a/mysql-test/t/rpl_init_slave.test
+++ b/mysql-test/t/rpl_init_slave.test
@@ -24,3 +24,5 @@ save_master_pos;
connection slave;
sync_with_master;
stop slave;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_innodb.test b/mysql-test/t/rpl_innodb.test
index b171dced26e..551657fd7e3 100644
--- a/mysql-test/t/rpl_innodb.test
+++ b/mysql-test/t/rpl_innodb.test
@@ -44,3 +44,5 @@ connection master;
DROP TABLE t4;
--enable_query_log
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_insert_id.test b/mysql-test/t/rpl_insert_id.test
index a4506e32963..704de1a423b 100644
--- a/mysql-test/t/rpl_insert_id.test
+++ b/mysql-test/t/rpl_insert_id.test
@@ -74,6 +74,4 @@ SET FOREIGN_KEY_CHECKS=0;
INSERT INTO t1 VALUES (1),(1);
sync_slave_with_master;
-
-
-
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_insert_ignore.test b/mysql-test/t/rpl_insert_ignore.test
index 58eaa287817..a6cc69b1df8 100644
--- a/mysql-test/t/rpl_insert_ignore.test
+++ b/mysql-test/t/rpl_insert_ignore.test
@@ -69,3 +69,5 @@ SELECT * FROM t1 ORDER BY a;
connection master;
drop table t1, t2;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_loaddata.test b/mysql-test/t/rpl_loaddata.test
index 3d54897adda..1b5980eb92e 100644
--- a/mysql-test/t/rpl_loaddata.test
+++ b/mysql-test/t/rpl_loaddata.test
@@ -149,3 +149,5 @@ wait_for_slave_to_stop;
drop table t2;
connection master;
drop table t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_loaddata_rule_m.test b/mysql-test/t/rpl_loaddata_rule_m.test
index 97c984c4369..68024c340a8 100644
--- a/mysql-test/t/rpl_loaddata_rule_m.test
+++ b/mysql-test/t/rpl_loaddata_rule_m.test
@@ -25,3 +25,5 @@ load data infile '../../std_data/rpl_loaddata.dat' into table test.t1;
--replace_column 2 # 5 #
show binlog events from 98;
drop database mysqltest;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_loaddata_rule_s.test b/mysql-test/t/rpl_loaddata_rule_s.test
index 9802c00d35f..98fad3cc06f 100644
--- a/mysql-test/t/rpl_loaddata_rule_s.test
+++ b/mysql-test/t/rpl_loaddata_rule_s.test
@@ -18,3 +18,5 @@ connection slave;
sync_with_master;
select count(*) from t1; # check that LOAD was replicated
show binlog events from 98; # should be nothing
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_loaddatalocal.test b/mysql-test/t/rpl_loaddatalocal.test
index f9325b39af6..0b54de8462e 100644
--- a/mysql-test/t/rpl_loaddatalocal.test
+++ b/mysql-test/t/rpl_loaddatalocal.test
@@ -35,6 +35,8 @@ save_master_pos;
connection slave;
sync_with_master;
+# End of 4.1 tests
+
#
# Now let us test how well we replicate LOAD DATA LOCAL in situation when
# we met duplicates in tables to which we are adding rows.
diff --git a/mysql-test/t/rpl_log.test b/mysql-test/t/rpl_log.test
index 8cb99d5432e..899f812535a 100644
--- a/mysql-test/t/rpl_log.test
+++ b/mysql-test/t/rpl_log.test
@@ -108,3 +108,5 @@ show slave status;
--error 1220
show binlog events in 'slave-bin.000005' from 4;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_log_pos.test b/mysql-test/t/rpl_log_pos.test
index 2a03497846b..979b146bb22 100644
--- a/mysql-test/t/rpl_log_pos.test
+++ b/mysql-test/t/rpl_log_pos.test
@@ -45,3 +45,5 @@ select * from t1;
connection master;
drop table t1;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_many_optimize.test b/mysql-test/t/rpl_many_optimize.test
index 525e23abe15..91fab0b27a8 100644
--- a/mysql-test/t/rpl_many_optimize.test
+++ b/mysql-test/t/rpl_many_optimize.test
@@ -18,3 +18,5 @@ enable_query_log;
drop table t1;
# Bug was that slave segfaulted after ~ a hundred of OPTIMIZE (or ANALYZE)
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_master_pos_wait.test b/mysql-test/t/rpl_master_pos_wait.test
index 4d4d51b04ab..893c8746efc 100644
--- a/mysql-test/t/rpl_master_pos_wait.test
+++ b/mysql-test/t/rpl_master_pos_wait.test
@@ -14,3 +14,5 @@ connection slave1;
stop slave sql_thread;
connection slave;
reap;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_max_relay_size.test b/mysql-test/t/rpl_max_relay_size.test
index 963a76fb959..8b54cf5ab7f 100644
--- a/mysql-test/t/rpl_max_relay_size.test
+++ b/mysql-test/t/rpl_max_relay_size.test
@@ -91,3 +91,5 @@ connection master;
# test that the absence of relay logs does not make a master crash
flush logs;
show master status;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_misc_functions.test b/mysql-test/t/rpl_misc_functions.test
index 12eadbb25ed..f20d0aa83e4 100644
--- a/mysql-test/t/rpl_misc_functions.test
+++ b/mysql-test/t/rpl_misc_functions.test
@@ -28,3 +28,5 @@ load data local infile './var/master-data/test/rpl_misc_functions.outfile' into
# compare them with the replica; the SELECT below should return no row
select * from t1, t2 where (t1.id=t2.id) and not(t1.i=t2.i and t1.r1=t2.r1 and t1.r2=t2.r2 and t1.p=t2.p);
stop slave;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_multi_delete.test b/mysql-test/t/rpl_multi_delete.test
index 299cb720b62..2fd7b820b1a 100644
--- a/mysql-test/t/rpl_multi_delete.test
+++ b/mysql-test/t/rpl_multi_delete.test
@@ -21,3 +21,5 @@ drop table t1,t2;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_multi_delete2.test b/mysql-test/t/rpl_multi_delete2.test
index c5128833843..62d95a3a90f 100644
--- a/mysql-test/t/rpl_multi_delete2.test
+++ b/mysql-test/t/rpl_multi_delete2.test
@@ -21,3 +21,5 @@ select * from t2;
connection master;
drop table t1,t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_multi_query.test b/mysql-test/t/rpl_multi_query.test
index 2ddd61ce7ba..fa94928e13a 100644
--- a/mysql-test/t/rpl_multi_query.test
+++ b/mysql-test/t/rpl_multi_query.test
@@ -27,3 +27,5 @@ connection master;
show binlog events from 98;
drop database mysqltest;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_multi_update.test b/mysql-test/t/rpl_multi_update.test
index 88994aa66bd..dd75edb3055 100644
--- a/mysql-test/t/rpl_multi_update.test
+++ b/mysql-test/t/rpl_multi_update.test
@@ -22,3 +22,5 @@ UPDATE t1, t2 SET t1.b = t2.b WHERE t1.a = t2.a;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_multi_update2.test b/mysql-test/t/rpl_multi_update2.test
index bba7700a88e..f92c5504f43 100644
--- a/mysql-test/t/rpl_multi_update2.test
+++ b/mysql-test/t/rpl_multi_update2.test
@@ -31,3 +31,5 @@ connection slave;
sync_with_master;
SELECT * FROM t1 ORDER BY a;
SELECT * FROM t2 ORDER BY a;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_multi_update3.test b/mysql-test/t/rpl_multi_update3.test
index 80b0603eb60..64e46882c16 100644
--- a/mysql-test/t/rpl_multi_update3.test
+++ b/mysql-test/t/rpl_multi_update3.test
@@ -157,3 +157,5 @@ SELECT * FROM t1;
connection master;
DROP TABLE t1, t2, t3;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_mystery22.test b/mysql-test/t/rpl_mystery22.test
index d49f1a210f4..f190968a03c 100644
--- a/mysql-test/t/rpl_mystery22.test
+++ b/mysql-test/t/rpl_mystery22.test
@@ -37,3 +37,4 @@ connection master;
drop table t1;
sync_slave_with_master;
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_openssl.test b/mysql-test/t/rpl_openssl.test
index 779ec4e84bf..78731e4dc7d 100644
--- a/mysql-test/t/rpl_openssl.test
+++ b/mysql-test/t/rpl_openssl.test
@@ -60,3 +60,5 @@ sync_with_master;
--replace_result $MYSQL_TEST_DIR MYSQL_TEST_DIR $MASTER_MYPORT MASTER_MYPORT
--replace_column 1 # 8 # 9 # 23 # 33 #
show slave status;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_optimize.test b/mysql-test/t/rpl_optimize.test
index 9f02b715885..6858f52abab 100644
--- a/mysql-test/t/rpl_optimize.test
+++ b/mysql-test/t/rpl_optimize.test
@@ -41,3 +41,5 @@ sync_with_master;
# If the machine is so fast that slave syncs before OPTIMIZE
# starts, this test wil demonstrate nothing but will pass.
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_ps.test b/mysql-test/t/rpl_ps.test
index 79f48381a4f..adf39b1e4ab 100644
--- a/mysql-test/t/rpl_ps.test
+++ b/mysql-test/t/rpl_ps.test
@@ -41,3 +41,4 @@ connection slave;
sync_with_master;
stop slave;
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_redirect.test b/mysql-test/t/rpl_redirect.test
index d505351cc69..beb18348b40 100644
--- a/mysql-test/t/rpl_redirect.test
+++ b/mysql-test/t/rpl_redirect.test
@@ -41,3 +41,5 @@ select * from t1;
drop table t1;
connection master;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_relayrotate.test b/mysql-test/t/rpl_relayrotate.test
index 2fde590356a..b66cf7a6e0d 100644
--- a/mysql-test/t/rpl_relayrotate.test
+++ b/mysql-test/t/rpl_relayrotate.test
@@ -75,3 +75,5 @@ drop table t1;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_relayspace.test b/mysql-test/t/rpl_relayspace.test
index bb82781b511..70315c14f34 100644
--- a/mysql-test/t/rpl_relayspace.test
+++ b/mysql-test/t/rpl_relayspace.test
@@ -30,3 +30,5 @@ start slave;
# also the slave will probably not cooperate to shutdown
# (as 2 threads are locked)
select master_pos_wait('master-bin.001',200,6)=-1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_replicate_do.test b/mysql-test/t/rpl_replicate_do.test
index 108dd54ce0a..ff5af71ea5b 100644
--- a/mysql-test/t/rpl_replicate_do.test
+++ b/mysql-test/t/rpl_replicate_do.test
@@ -36,3 +36,4 @@ sync_with_master;
--replace_column 1 # 8 # 9 # 23 # 33 #
show slave status;
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_reset_slave.test b/mysql-test/t/rpl_reset_slave.test
index 1b27e059f92..aeac1b50110 100644
--- a/mysql-test/t/rpl_reset_slave.test
+++ b/mysql-test/t/rpl_reset_slave.test
@@ -46,3 +46,5 @@ reset slave;
start slave;
sync_with_master;
show status like 'slave_open_temp_tables';
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_rewrite_db.test b/mysql-test/t/rpl_rewrite_db.test
index b77d57294fa..1e8e5a992d8 100644
--- a/mysql-test/t/rpl_rewrite_db.test
+++ b/mysql-test/t/rpl_rewrite_db.test
@@ -78,3 +78,4 @@ drop database rewrite;
connection master;
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_rotate_logs.test b/mysql-test/t/rpl_rotate_logs.test
index 2355e92e58b..26cb5ac8631 100644
--- a/mysql-test/t/rpl_rotate_logs.test
+++ b/mysql-test/t/rpl_rotate_logs.test
@@ -153,3 +153,4 @@ connection master;
drop table if exists t1,t2,t3,t4;
sync_slave_with_master;
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_server_id1.test b/mysql-test/t/rpl_server_id1.test
index 4d504325294..3583f05284c 100644
--- a/mysql-test/t/rpl_server_id1.test
+++ b/mysql-test/t/rpl_server_id1.test
@@ -22,3 +22,5 @@ insert into t1 values (1);
sleep 2; # enough time for the event to be replicated (it should not)
show status like "slave_running";
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_server_id2.test b/mysql-test/t/rpl_server_id2.test
index 7bbac358ada..0f2eb560d18 100644
--- a/mysql-test/t/rpl_server_id2.test
+++ b/mysql-test/t/rpl_server_id2.test
@@ -22,3 +22,5 @@ select * from t1; # check that indeed 2 were inserted
# (not critical).
stop slave;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_set_charset.test b/mysql-test/t/rpl_set_charset.test
index 269074b1c42..c70eb2681f5 100644
--- a/mysql-test/t/rpl_set_charset.test
+++ b/mysql-test/t/rpl_set_charset.test
@@ -31,3 +31,5 @@ drop database mysqltest1;
save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_skip_error.test b/mysql-test/t/rpl_skip_error.test
index 86c89c70314..e0e569a65b7 100644
--- a/mysql-test/t/rpl_skip_error.test
+++ b/mysql-test/t/rpl_skip_error.test
@@ -12,3 +12,5 @@ save_master_pos;
connection slave;
sync_with_master;
select * from t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_sporadic_master.test b/mysql-test/t/rpl_sporadic_master.test
index b24901c62a9..26b633a1c4f 100644
--- a/mysql-test/t/rpl_sporadic_master.test
+++ b/mysql-test/t/rpl_sporadic_master.test
@@ -22,3 +22,5 @@ select * from t1;
connection master;
drop table t1,t2;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_start_stop_slave.test b/mysql-test/t/rpl_start_stop_slave.test
index 903ff204194..19988cf902a 100644
--- a/mysql-test/t/rpl_start_stop_slave.test
+++ b/mysql-test/t/rpl_start_stop_slave.test
@@ -32,3 +32,5 @@ save_master_pos;
connection slave;
sync_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_temporary.test b/mysql-test/t/rpl_temporary.test
index e65469de7e0..fcb2391a9d8 100644
--- a/mysql-test/t/rpl_temporary.test
+++ b/mysql-test/t/rpl_temporary.test
@@ -130,3 +130,5 @@ create temporary table t3 (f int);
sync_with_master;
# The server will now close done
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_timezone.test b/mysql-test/t/rpl_timezone.test
index a7547f7afc6..2e9883141d8 100644
--- a/mysql-test/t/rpl_timezone.test
+++ b/mysql-test/t/rpl_timezone.test
@@ -122,3 +122,5 @@ select * from t2;
connection master;
drop table t1, t2;
sync_slave_with_master;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_until.test b/mysql-test/t/rpl_until.test
index c1aee2cb1db..5bc7a040b1b 100644
--- a/mysql-test/t/rpl_until.test
+++ b/mysql-test/t/rpl_until.test
@@ -83,3 +83,5 @@ start slave until relay_log_file='slave-relay-bin.000002', master_log_pos=561;
# Warning should be given for second command
start slave sql_thread;
start slave until master_log_file='master-bin.000001', master_log_pos=776;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_user_variables.test b/mysql-test/t/rpl_user_variables.test
index 711d83219a6..e8985397703 100644
--- a/mysql-test/t/rpl_user_variables.test
+++ b/mysql-test/t/rpl_user_variables.test
@@ -54,3 +54,5 @@ save_master_pos;
connection slave;
sync_with_master;
stop slave;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/rpl_variables.test b/mysql-test/t/rpl_variables.test
index ea40181ecd3..57ae2b9c3c4 100644
--- a/mysql-test/t/rpl_variables.test
+++ b/mysql-test/t/rpl_variables.test
@@ -3,6 +3,8 @@ source include/master-slave.inc;
set global slave_net_timeout=100;
set global sql_slave_skip_counter=100;
+# End of 4.1 tests
+
# BUG #7800: Add various-slave related variables to SHOW VARIABLES
show variables like 'slave_compressed_protocol';
--replace_column 2 SLAVE_LOAD_TMPDIR
diff --git a/mysql-test/t/select.test b/mysql-test/t/select.test
index 8004d308dfa..eac76749589 100644
--- a/mysql-test/t/select.test
+++ b/mysql-test/t/select.test
@@ -2168,6 +2168,8 @@ select found_rows();
DROP TABLE t1;
+# End of 4.1 tests
+
#
# Test case for bug 7098: substitution of a constant for a string field
#
diff --git a/mysql-test/t/select_found.test b/mysql-test/t/select_found.test
index 91879015b51..e4bc54a5538 100644
--- a/mysql-test/t/select_found.test
+++ b/mysql-test/t/select_found.test
@@ -191,3 +191,5 @@ INSERT INTO t1 VALUES (1,2), (1,3), (1,4), (1,5);
SELECT SQL_CALC_FOUND_ROWS DISTINCT 'a' FROM t1 GROUP BY b LIMIT 2;
SELECT FOUND_ROWS();
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/select_safe.test b/mysql-test/t/select_safe.test
index 5b2dfb00bb7..236370bef03 100644
--- a/mysql-test/t/select_safe.test
+++ b/mysql-test/t/select_safe.test
@@ -87,3 +87,5 @@ select * from (select 1 union select 2 union select 3) x;
drop table t1;
SET SQL_SAFE_UPDATES=0,SQL_SELECT_LIMIT=DEFAULT, SQL_MAX_JOIN_SIZE=DEFAULT;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/show_check.test b/mysql-test/t/show_check.test
index d591f90dd65..efe3504ad7d 100644
--- a/mysql-test/t/show_check.test
+++ b/mysql-test/t/show_check.test
@@ -385,3 +385,5 @@ create table t1 (
);
SHOW CREATE TABLE t1;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/skip_name_resolve.test b/mysql-test/t/skip_name_resolve.test
index b669579acbf..02339ca14c5 100644
--- a/mysql-test/t/skip_name_resolve.test
+++ b/mysql-test/t/skip_name_resolve.test
@@ -6,3 +6,5 @@ GRANT ALL ON test.* TO mysqltest_1@'127.0.0.1/255.255.255.255';
SHOW GRANTS FOR mysqltest_1@'127.0.0.1/255.255.255.255';
REVOKE ALL ON test.* FROM mysqltest_1@'127.0.0.1/255.255.255.255';
DROP USER mysqltest_1@'127.0.0.1/255.255.255.255';
+
+# End of 4.1 tests
diff --git a/mysql-test/t/sql_mode.test b/mysql-test/t/sql_mode.test
index f8ab521e665..10db520cd12 100644
--- a/mysql-test/t/sql_mode.test
+++ b/mysql-test/t/sql_mode.test
@@ -86,6 +86,8 @@ drop table t1 ;
--error 1231
set @@SQL_MODE=NULL;
+# End of 4.1 tests
+
#
# test for
# WL 1941 "NO_C_ESCAPES sql_mode"
diff --git a/mysql-test/t/status.test b/mysql-test/t/status.test
index 31d9c8154d5..7fea51c9327 100644
--- a/mysql-test/t/status.test
+++ b/mysql-test/t/status.test
@@ -35,3 +35,5 @@ connection con1;
reap;
show status like 'Table_lock%';
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/subselect.test b/mysql-test/t/subselect.test
index ecb3432753d..41cdf9f1c64 100644
--- a/mysql-test/t/subselect.test
+++ b/mysql-test/t/subselect.test
@@ -1867,3 +1867,5 @@ insert into t1 values ('1');
select * from (select max(fld) from t1) as foo;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/subselect2.test b/mysql-test/t/subselect2.test
index 2d42320334a..839e94206d0 100644
--- a/mysql-test/t/subselect2.test
+++ b/mysql-test/t/subselect2.test
@@ -146,4 +146,5 @@ SELECT t2.*, t4.DOCTYPENAME, t1.CONTENTSIZE,t1.MIMETYPE FROM t2 INNER JOIN t4 ON
EXPLAIN SELECT t2.*, t4.DOCTYPENAME, t1.CONTENTSIZE,t1.MIMETYPE FROM t2 INNER JOIN t4 ON t2.DOCTYPEID = t4.DOCTYPEID LEFT OUTER JOIN t1 ON t2.DOCID = t1.DOCID WHERE t2.FOLDERID IN(SELECT t3.FOLDERID FROM t3 WHERE t3.PARENTID IN(SELECT t3.FOLDERID FROM t3 WHERE t3.PARENTID IN(SELECT t3.FOLDERID FROM t3 WHERE t3.PARENTID IN(SELECT t3.FOLDERID FROM t3 WHERE t3.PARENTID IN(SELECT t3.FOLDERID FROM t3 WHERE t3.PARENTID='2f6161e879db43c1a5b82c21ddc49089' AND t3.FOLDERNAME = 'Level1') AND t3.FOLDERNAME = 'Level2') AND t3.FOLDERNAME = 'Level3') AND t3.FOLDERNAME = 'CopiedFolder') AND t3.FOLDERNAME = 'Movie Reviews') AND t2.DOCNAME = 'Last Discussion';
-drop table t1, t2, t3, t4; \ No newline at end of file
+drop table t1, t2, t3, t4;
+# End of 4.1 tests
diff --git a/mysql-test/t/subselect_gis.test b/mysql-test/t/subselect_gis.test
index 338051029c4..1ab139b7822 100644
--- a/mysql-test/t/subselect_gis.test
+++ b/mysql-test/t/subselect_gis.test
@@ -13,3 +13,5 @@ select City from t1 where (select
intersects(GeomFromText(AsText(Location)),GeomFromText('Polygon((2 50, 2.5
50, 2.5 47, 2 47, 2 50))'))=0);
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/subselect_innodb.test b/mysql-test/t/subselect_innodb.test
index 5d796988178..3b1d2f393c2 100644
--- a/mysql-test/t/subselect_innodb.test
+++ b/mysql-test/t/subselect_innodb.test
@@ -159,3 +159,5 @@ EXECUTE my_stmt;
EXECUTE my_stmt;
deallocate prepare my_stmt;
drop table t1,t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/symlink.test b/mysql-test/t/symlink.test
index f477fc378c6..b7a7e83d569 100644
--- a/mysql-test/t/symlink.test
+++ b/mysql-test/t/symlink.test
@@ -136,3 +136,5 @@ eval create table t1 (i int) index directory = "$MYSQL_TEST_DIR/var/master-data/
enable_query_log;
show create table t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/synchronization.test b/mysql-test/t/synchronization.test
index 09324b32b97..c7696195ee0 100644
--- a/mysql-test/t/synchronization.test
+++ b/mysql-test/t/synchronization.test
@@ -36,3 +36,5 @@ while ($1)
dec $1;
}
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/system_mysql_db.test b/mysql-test/t/system_mysql_db.test
index acd19f47728..27c17da2731 100644
--- a/mysql-test/t/system_mysql_db.test
+++ b/mysql-test/t/system_mysql_db.test
@@ -16,3 +16,5 @@ use test;
-- enable_query_log
# keep results same with system_mysql_db_fix
show tables;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/system_mysql_db_fix.test b/mysql-test/t/system_mysql_db_fix.test
index f47b4cba6e6..3b19df5f756 100644
--- a/mysql-test/t/system_mysql_db_fix.test
+++ b/mysql-test/t/system_mysql_db_fix.test
@@ -91,3 +91,5 @@ DROP TABLE db, host, user, func, tables_priv, columns_priv, procs_priv, help_cat
# check that we droped all system tables
show tables;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/system_mysql_db_refs.test b/mysql-test/t/system_mysql_db_refs.test
index 9e2c5a20b54..c5146e1b043 100644
--- a/mysql-test/t/system_mysql_db_refs.test
+++ b/mysql-test/t/system_mysql_db_refs.test
@@ -99,3 +99,5 @@ drop table test_func;
drop table test_host;
drop table test_user;
drop table test_db;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/tablelock.test b/mysql-test/t/tablelock.test
index fbc5d685096..95533903b45 100644
--- a/mysql-test/t/tablelock.test
+++ b/mysql-test/t/tablelock.test
@@ -47,3 +47,5 @@ CREATE TABLE t2 (a int);
lock tables t1 write,t1 as b write, t2 write, t2 as c read;
drop table t2,t1;
unlock tables;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/temp_table.test b/mysql-test/t/temp_table.test
index da7ce9b4722..9a7678ed712 100644
--- a/mysql-test/t/temp_table.test
+++ b/mysql-test/t/temp_table.test
@@ -112,3 +112,5 @@ insert into t1 values (3,1),(3,2);
insert into t2 values (NULL, 'foo'), (NULL, 'bar');
select d, c from t1 left join t2 on b = c where a = 3 order by d;
drop table t1, t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/timezone.test b/mysql-test/t/timezone.test
index ffc2e3a3ebf..34bbb365c70 100644
--- a/mysql-test/t/timezone.test
+++ b/mysql-test/t/timezone.test
@@ -58,3 +58,5 @@ select unix_timestamp('1970-01-01 01:00:00'),
unix_timestamp('1970-01-01 01:00:01'),
unix_timestamp('2038-01-01 00:59:59'),
unix_timestamp('2038-01-01 01:00:00');
+
+# End of 4.1 tests
diff --git a/mysql-test/t/timezone2.test b/mysql-test/t/timezone2.test
index 40fcd153877..069c19341e4 100644
--- a/mysql-test/t/timezone2.test
+++ b/mysql-test/t/timezone2.test
@@ -220,3 +220,5 @@ select convert_tz('2005-01-14 17:00:00', 'UTC', custTimeZone) from (select 'UTC'
create table t1 select convert_tz(NULL, NULL, NULL);
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/timezone3.test b/mysql-test/t/timezone3.test
index 8910783cd85..0aedbafcec4 100644
--- a/mysql-test/t/timezone3.test
+++ b/mysql-test/t/timezone3.test
@@ -57,3 +57,5 @@ create table t1 (ts timestamp);
insert into t1 values (19730101235900), (20040101235900);
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/timezone_grant.test b/mysql-test/t/timezone_grant.test
index 5dbf457e1f1..f94d86eb266 100644
--- a/mysql-test/t/timezone_grant.test
+++ b/mysql-test/t/timezone_grant.test
@@ -81,3 +81,4 @@ delete from mysql.tables_priv where user like 'mysqltest\_%';
flush privileges;
drop table t1, t2;
+# End of 4.1 tests
diff --git a/mysql-test/t/truncate.test b/mysql-test/t/truncate.test
index b7ec506ecf1..f806bd8ec17 100644
--- a/mysql-test/t/truncate.test
+++ b/mysql-test/t/truncate.test
@@ -50,3 +50,5 @@ delete from t1;
insert into t1 (a) values (NULL),(NULL);
SELECT * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/type_blob.test b/mysql-test/t/type_blob.test
index 80aabf6c5e0..1ec5c600296 100644
--- a/mysql-test/t/type_blob.test
+++ b/mysql-test/t/type_blob.test
@@ -394,6 +394,8 @@ INSERT t1 (i, c) VALUES (1,''),(2,''),(3,'asdfh'),(4,'');
select max(i) from t1 where c = '';
drop table t1;
+# End of 4.1 tests
+
#
# Bug#11657: Creation of secondary index fails
#
diff --git a/mysql-test/t/type_date.test b/mysql-test/t/type_date.test
index 304ed19b971..78bdd9b8a80 100644
--- a/mysql-test/t/type_date.test
+++ b/mysql-test/t/type_date.test
@@ -114,3 +114,5 @@ CREATE TABLE t1 (y YEAR);
INSERT INTO t1 VALUES ('abc');
SELECT * FROM t1;
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/type_datetime.test b/mysql-test/t/type_datetime.test
index a7eb78cb292..f60bc5adb16 100644
--- a/mysql-test/t/type_datetime.test
+++ b/mysql-test/t/type_datetime.test
@@ -101,3 +101,5 @@ insert into t1 values ("12-00-00"), ("00-00-00 01:00:00");
insert into t1 values ("00-00-00"), ("00-00-00 00:00:00");
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/type_decimal.test b/mysql-test/t/type_decimal.test
index 2901592fd9e..44032fde46f 100644
--- a/mysql-test/t/type_decimal.test
+++ b/mysql-test/t/type_decimal.test
@@ -268,7 +268,11 @@ insert into t1 values ('1'),('+1'),('-1'),('0000000001'),('+0000000001'),('-0000
select * from t1;
drop table t1;
+# End of 4.1 tests
+
+#
# Test for BUG#8397: decimal type in subselects (Item_cache_decimal)
+#
CREATE TABLE t1
(EMPNUM CHAR(3) NOT NULL,
HOURS DECIMAL(5));
diff --git a/mysql-test/t/type_enum.test b/mysql-test/t/type_enum.test
index 6b2183df069..0d479f312cd 100644
--- a/mysql-test/t/type_enum.test
+++ b/mysql-test/t/type_enum.test
@@ -126,3 +126,5 @@ create table t1 (a set('x','y') default 'x');
--error 1067
alter table t1 alter a set default 'z';
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/type_float.test b/mysql-test/t/type_float.test
index a27fd4c58b4..c0f1854d5b2 100644
--- a/mysql-test/t/type_float.test
+++ b/mysql-test/t/type_float.test
@@ -145,3 +145,5 @@ select * from t1 where reckey=1.08E2;
select * from t1 where reckey=109;
select * from t1 where reckey=1.09E2;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/type_nchar.test b/mysql-test/t/type_nchar.test
index e85609e3f0c..f2258830450 100644
--- a/mysql-test/t/type_nchar.test
+++ b/mysql-test/t/type_nchar.test
@@ -33,3 +33,4 @@ create table t1 (c nchar varying(10));
show create table t1;
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/type_ranges.test b/mysql-test/t/type_ranges.test
index a2deb367e14..c1a5ac382ec 100644
--- a/mysql-test/t/type_ranges.test
+++ b/mysql-test/t/type_ranges.test
@@ -165,3 +165,5 @@ drop table t3;
create table t3 select t1.id as id_A, t2.id as id_B from t1 left join t2 using ( id );
select * from t3;
drop table t1,t2,t3;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/type_set.test b/mysql-test/t/type_set.test
index b6410a9ea3d..56df3328246 100644
--- a/mysql-test/t/type_set.test
+++ b/mysql-test/t/type_set.test
@@ -37,3 +37,5 @@ INSERT INTO t1 VALUES ('ae,oe,ue,ss');
SELECT c FROM t1 ORDER BY c;
SELECT c FROM t1 ORDER BY concat(c);
DROP TABLE t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/type_time.test b/mysql-test/t/type_time.test
index 2f342f8bf67..7ae3f65f7cc 100644
--- a/mysql-test/t/type_time.test
+++ b/mysql-test/t/type_time.test
@@ -20,3 +20,5 @@ insert into t1 values ('09:00:00'),('13:00:00'),('19:38:34'), ('13:00:00'),('09:
select t, time_to_sec(t),sec_to_time(time_to_sec(t)) from t1;
select sec_to_time(time_to_sec(t)) from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/type_timestamp.test b/mysql-test/t/type_timestamp.test
index 01d18afc5af..f96beedbebc 100644
--- a/mysql-test/t/type_timestamp.test
+++ b/mysql-test/t/type_timestamp.test
@@ -321,3 +321,4 @@ insert into t1 (a, c) values (4, '2004-04-04 00:00:00'),
select * from t1;
drop table t1;
+# End of 4.1 tests
diff --git a/mysql-test/t/type_uint.test b/mysql-test/t/type_uint.test
index b1f59242e8e..a9212183cb6 100644
--- a/mysql-test/t/type_uint.test
+++ b/mysql-test/t/type_uint.test
@@ -13,3 +13,5 @@ insert into t1 values (-1);
insert into t1 values ('5000000000');
select * from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/type_year.test b/mysql-test/t/type_year.test
index c67b8447494..9744da24c02 100644
--- a/mysql-test/t/type_year.test
+++ b/mysql-test/t/type_year.test
@@ -20,3 +20,5 @@ create table t1 (y year);
insert into t1 values (now());
select if(y = now(), 1, 0) from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/union.test b/mysql-test/t/union.test
index 4da19622dcb..227d1cddcfa 100644
--- a/mysql-test/t/union.test
+++ b/mysql-test/t/union.test
@@ -793,3 +793,5 @@ insert into t1 (col1) values (2),(3),(4),(5),(6);
select 99 union all select id from t1 order by 1;
select id from t1 union all select 99 order by 1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/update.test b/mysql-test/t/update.test
index 66b3a2886b6..dd6c36d8414 100644
--- a/mysql-test/t/update.test
+++ b/mysql-test/t/update.test
@@ -214,3 +214,5 @@ insert into t2 values(1,1),(2,2);
UPDATE t1 SET t1.f2=(SELECT MAX(t2.f4) FROM t2 WHERE t2.f3=t1.f1);
select * from t1;
drop table t1,t2;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/user_var-binlog.test b/mysql-test/t/user_var-binlog.test
index 916a7dfa47b..004154339b2 100644
--- a/mysql-test/t/user_var-binlog.test
+++ b/mysql-test/t/user_var-binlog.test
@@ -17,3 +17,5 @@ show binlog events from 98;
--replace_result $MYSQL_TEST_DIR MYSQL_TEST_DIR
--exec $MYSQL_BINLOG --short-form $MYSQL_TEST_DIR/var/log/master-bin.000001
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/user_var.test b/mysql-test/t/user_var.test
index f8c441c7564..91372b67f5e 100644
--- a/mysql-test/t/user_var.test
+++ b/mysql-test/t/user_var.test
@@ -121,6 +121,8 @@ set session @honk=99;
--error 1382
set one_shot @honk=99;
+# End of 4.1 tests
+
#
# Bug #6598: problem with cast(NULL as signed integer);
#
diff --git a/mysql-test/t/varbinary.test b/mysql-test/t/varbinary.test
index 9425bd7bd99..5fbd116d7b8 100644
--- a/mysql-test/t/varbinary.test
+++ b/mysql-test/t/varbinary.test
@@ -35,3 +35,5 @@ select 0xfg;
create table t1 select 1 as x, 2 as xx;
select x,xx from t1;
drop table t1;
+
+# End of 4.1 tests
diff --git a/mysql-test/t/variables.test b/mysql-test/t/variables.test
index c3ffdc79c16..d9fba14b802 100644
--- a/mysql-test/t/variables.test
+++ b/mysql-test/t/variables.test
@@ -390,6 +390,8 @@ SET GLOBAL table_cache=-1;
SHOW VARIABLES LIKE 'table_cache';
SET GLOBAL table_cache=DEFAULT;
+# End of 4.1 tests
+
#
# Bug#6282 Packet error with SELECT INTO
#
diff --git a/mysql-test/t/warnings.test b/mysql-test/t/warnings.test
index 314432af83e..f6ae7cdaf30 100644
--- a/mysql-test/t/warnings.test
+++ b/mysql-test/t/warnings.test
@@ -151,3 +151,5 @@ select * from t1 limit 0;
select * from t1 limit 1, 0;
select * from t1 limit 0, 0;
drop table t1;
+
+# End of 4.1 tests