summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorunknown <antony@ltantony.rdg.cyberkinetica.homeunix.net>2003-12-10 04:31:42 +0000
committerunknown <antony@ltantony.rdg.cyberkinetica.homeunix.net>2003-12-10 04:31:42 +0000
commit80ec807976ca5ae291883b1096e4af7233788af0 (patch)
tree786b29c1b82119fc7dc8cadff03c8bd8607d3deb
parentb6df8bb66ac8eefcbea86aecb0f8c067dcbe004c (diff)
downloadmariadb-git-80ec807976ca5ae291883b1096e4af7233788af0.tar.gz
WorkLog#1323
Deprecate the use of TYPE=... Preferred syntax is ENGINE= include/mysqld_error.h: New warning for deprecated syntax sql/lex.h: Introduce ENGINE keyword Sort order of symbols sql/share/czech/errmsg.txt: New warning for deprecated syntax sql/share/danish/errmsg.txt: New warning for deprecated syntax sql/share/dutch/errmsg.txt: New warning for deprecated syntax sql/share/english/errmsg.txt: New warning for deprecated syntax sql/share/estonian/errmsg.txt: New warning for deprecated syntax sql/share/french/errmsg.txt: New warning for deprecated syntax sql/share/german/errmsg.txt: New warning for deprecated syntax sql/share/greek/errmsg.txt: New warning for deprecated syntax sql/share/hungarian/errmsg.txt: New warning for deprecated syntax sql/share/italian/errmsg.txt: New warning for deprecated syntax sql/share/japanese/errmsg.txt: New warning for deprecated syntax sql/share/korean/errmsg.txt: New warning for deprecated syntax sql/share/norwegian-ny/errmsg.txt: New warning for deprecated syntax sql/share/norwegian/errmsg.txt: New warning for deprecated syntax sql/share/polish/errmsg.txt: New warning for deprecated syntax sql/share/portuguese/errmsg.txt: New warning for deprecated syntax sql/share/romanian/errmsg.txt: New warning for deprecated syntax sql/share/russian/errmsg.txt: New warning for deprecated syntax sql/share/serbian/errmsg.txt: New warning for deprecated syntax sql/share/slovak/errmsg.txt: New warning for deprecated syntax sql/share/spanish/errmsg.txt: New warning for deprecated syntax sql/share/swedish/errmsg.txt: New warning for deprecated syntax sql/share/ukrainian/errmsg.txt: New warning for deprecated syntax sql/sql_show.cc: Change TYPE= with ENGINE= sql/sql_yacc.yy: Introduce ENGINE keyword, Deprecate TYPE= syntax, Introduce SHOW ENGINE syntax, Deprecate SHOW INNODB/BDB syntax. mysql-test/r/alias.result: Change occurances of TYPE= to ENGINE= mysql-test/r/alter_table.result: Change occurances of TYPE= to ENGINE= mysql-test/r/auto_increment.result: Change occurances of TYPE= to ENGINE= mysql-test/r/bdb-alter-table-1.result: Change occurances of TYPE= to ENGINE= mysql-test/r/bdb-crash.result: Change occurances of TYPE= to ENGINE= mysql-test/r/bdb-deadlock.result: Change occurances of TYPE= to ENGINE= mysql-test/r/bdb.result: Change occurances of TYPE= to ENGINE= mysql-test/r/bdb_cache.result: Change occurances of TYPE= to ENGINE= mysql-test/r/case.result: Change occurances of TYPE= to ENGINE= mysql-test/r/cast.result: Change occurances of TYPE= to ENGINE= mysql-test/r/constraints.result: Change occurances of TYPE= to ENGINE= mysql-test/r/create.result: Change occurances of TYPE= to ENGINE= mysql-test/r/ctype_collate.result: Change occurances of TYPE= to ENGINE= mysql-test/r/ctype_latin1_de.result: Change occurances of TYPE= to ENGINE= mysql-test/r/ctype_many.result: Change occurances of TYPE= to ENGINE= mysql-test/r/ctype_mb.result: Change occurances of TYPE= to ENGINE= mysql-test/r/ctype_recoding.result: Change occurances of TYPE= to ENGINE= mysql-test/r/ctype_ucs.result: Change occurances of TYPE= to ENGINE= mysql-test/r/delete.result: Change occurances of TYPE= to ENGINE= mysql-test/r/distinct.result: Change occurances of TYPE= to ENGINE= mysql-test/r/fulltext.result: Change occurances of TYPE= to ENGINE= mysql-test/r/fulltext2.result: Change occurances of TYPE= to ENGINE= mysql-test/r/fulltext_distinct.result: Change occurances of TYPE= to ENGINE= mysql-test/r/fulltext_left_join.result: Change occurances of TYPE= to ENGINE= mysql-test/r/func_compress.result: Change occurances of TYPE= to ENGINE= mysql-test/r/func_date_add.result: Change occurances of TYPE= to ENGINE= mysql-test/r/func_group.result: Change occurances of TYPE= to ENGINE= mysql-test/r/func_if.result: Change occurances of TYPE= to ENGINE= mysql-test/r/func_str.result: Change occurances of TYPE= to ENGINE= mysql-test/r/func_system.result: Change occurances of TYPE= to ENGINE= mysql-test/r/func_test.result: Change occurances of TYPE= to ENGINE= mysql-test/r/func_time.result: Change occurances of TYPE= to ENGINE= mysql-test/r/gis-rtree.result: Change occurances of TYPE= to ENGINE= mysql-test/r/group_by.result: Change occurances of TYPE= to ENGINE= mysql-test/r/handler.result: Change occurances of TYPE= to ENGINE= mysql-test/r/heap.result: Change occurances of TYPE= to ENGINE= mysql-test/r/heap_auto_increment.result: Change occurances of TYPE= to ENGINE= mysql-test/r/heap_btree.result: Change occurances of TYPE= to ENGINE= mysql-test/r/heap_hash.result: Change occurances of TYPE= to ENGINE= mysql-test/r/help.result: Change occurances of TYPE= to ENGINE= mysql-test/r/innodb-deadlock.result: Change occurances of TYPE= to ENGINE= mysql-test/r/innodb.result: Change occurances of TYPE= to ENGINE= mysql-test/r/innodb_cache.result: Change occurances of TYPE= to ENGINE= mysql-test/r/innodb_handler.result: Change occurances of TYPE= to ENGINE= mysql-test/r/insert_select.result: Change occurances of TYPE= to ENGINE= mysql-test/r/isam.result: Change occurances of TYPE= to ENGINE= mysql-test/r/join.result: Change occurances of TYPE= to ENGINE= mysql-test/r/join_crash.result: Change occurances of TYPE= to ENGINE= mysql-test/r/join_outer.result: Change occurances of TYPE= to ENGINE= mysql-test/r/key.result: Change occurances of TYPE= to ENGINE= mysql-test/r/lock.result: Change occurances of TYPE= to ENGINE= mysql-test/r/lock_tables_lost_commit.result: Change occurances of TYPE= to ENGINE= mysql-test/r/merge.result: Change occurances of TYPE= to ENGINE= mysql-test/r/mix_innodb_myisam_binlog.result: Change occurances of TYPE= to ENGINE= mysql-test/r/multi_update.result: Change occurances of TYPE= to ENGINE= mysql-test/r/myisam.result: Change occurances of TYPE= to ENGINE= mysql-test/r/null.result: Change occurances of TYPE= to ENGINE= mysql-test/r/null_key.result: Change occurances of TYPE= to ENGINE= mysql-test/r/order_by.result: Change occurances of TYPE= to ENGINE= mysql-test/r/query_cache.result: Change occurances of TYPE= to ENGINE= mysql-test/r/range.result: Change occurances of TYPE= to ENGINE= mysql-test/r/repair_part1.result: Change occurances of TYPE= to ENGINE= mysql-test/r/replace.result: Change occurances of TYPE= to ENGINE= mysql-test/r/rollback.result: Change occurances of TYPE= to ENGINE= mysql-test/r/rpl000006.result: Change occurances of TYPE= to ENGINE= mysql-test/r/rpl_flush_tables.result: Change occurances of TYPE= to ENGINE= mysql-test/r/rpl_insert_id.result: Change occurances of TYPE= to ENGINE= mysql-test/r/rpl_relayrotate.result: Change occurances of TYPE= to ENGINE= mysql-test/r/select.result: Change occurances of TYPE= to ENGINE= mysql-test/r/select_found.result: Change occurances of TYPE= to ENGINE= mysql-test/r/show_check.result: Change occurances of TYPE= to ENGINE= mysql-test/r/sql_mode.result: Change occurances of TYPE= to ENGINE= mysql-test/r/status.result: Change occurances of TYPE= to ENGINE= mysql-test/r/subselect.result: Change occurances of TYPE= to ENGINE= mysql-test/r/subselect2.result: Change occurances of TYPE= to ENGINE= mysql-test/r/subselect_innodb.result: Change occurances of TYPE= to ENGINE= mysql-test/r/symlink.result: Change occurances of TYPE= to ENGINE= mysql-test/r/temp_table.result: Change occurances of TYPE= to ENGINE= mysql-test/r/type_blob.result: Change occurances of TYPE= to ENGINE= mysql-test/r/type_datetime.result: Change occurances of TYPE= to ENGINE= mysql-test/r/type_enum.result: Change occurances of TYPE= to ENGINE= mysql-test/r/type_nchar.result: Change occurances of TYPE= to ENGINE= mysql-test/r/type_set.result: Change occurances of TYPE= to ENGINE= mysql-test/r/union.result: Change occurances of TYPE= to ENGINE= mysql-test/r/update.result: Change occurances of TYPE= to ENGINE= mysql-test/r/warnings.result: Change occurances of TYPE= to ENGINE= mysql-test/t/alias.test: Change occurances of TYPE= to ENGINE= mysql-test/t/alter_table.test: Change occurances of TYPE= to ENGINE= mysql-test/t/auto_increment.test: Change occurances of TYPE= to ENGINE= mysql-test/t/bdb-alter-table-1.test: Change occurances of TYPE= to ENGINE= mysql-test/t/bdb-crash.test: Change occurances of TYPE= to ENGINE= mysql-test/t/bdb-deadlock.test: Change occurances of TYPE= to ENGINE= mysql-test/t/bdb.test: Change occurances of TYPE= to ENGINE= mysql-test/t/bdb_cache.test: Change occurances of TYPE= to ENGINE= mysql-test/t/create.test: Change occurances of TYPE= to ENGINE= mysql-test/t/ctype_ucs.test: Change occurances of TYPE= to ENGINE= mysql-test/t/delete.test: Change occurances of TYPE= to ENGINE= mysql-test/t/distinct.test: Change occurances of TYPE= to ENGINE= mysql-test/t/fulltext.test: Change occurances of TYPE= to ENGINE= mysql-test/t/fulltext2.test: Change occurances of TYPE= to ENGINE= mysql-test/t/fulltext_distinct.test: Change occurances of TYPE= to ENGINE= mysql-test/t/fulltext_left_join.test: Change occurances of TYPE= to ENGINE= mysql-test/t/func_compress.test: Change occurances of TYPE= to ENGINE= mysql-test/t/func_date_add.test: Change occurances of TYPE= to ENGINE= mysql-test/t/func_group.test: Change occurances of TYPE= to ENGINE= mysql-test/t/func_if.test: Change occurances of TYPE= to ENGINE= mysql-test/t/func_str.test: Change occurances of TYPE= to ENGINE= mysql-test/t/func_test.test: Change occurances of TYPE= to ENGINE= mysql-test/t/func_time.test: Change occurances of TYPE= to ENGINE= mysql-test/t/gis-rtree.test: Change occurances of TYPE= to ENGINE= mysql-test/t/group_by.test: Change occurances of TYPE= to ENGINE= mysql-test/t/handler.test: Change occurances of TYPE= to ENGINE= mysql-test/t/heap.test: Change occurances of TYPE= to ENGINE= mysql-test/t/heap_auto_increment.test: Change occurances of TYPE= to ENGINE= mysql-test/t/heap_btree.test: Change occurances of TYPE= to ENGINE= mysql-test/t/heap_hash.test: Change occurances of TYPE= to ENGINE= mysql-test/t/help.test: Change occurances of TYPE= to ENGINE= mysql-test/t/innodb-deadlock.test: Change occurances of TYPE= to ENGINE= mysql-test/t/innodb.test: Change occurances of TYPE= to ENGINE= mysql-test/t/innodb_cache.test: Change occurances of TYPE= to ENGINE= mysql-test/t/innodb_handler.test: Change occurances of TYPE= to ENGINE= mysql-test/t/insert_select.test: Change occurances of TYPE= to ENGINE= mysql-test/t/isam.test: Change occurances of TYPE= to ENGINE= mysql-test/t/join.test: Change occurances of TYPE= to ENGINE= mysql-test/t/join_crash.test: Change occurances of TYPE= to ENGINE= mysql-test/t/join_outer.test: Change occurances of TYPE= to ENGINE= mysql-test/t/key.test: Change occurances of TYPE= to ENGINE= mysql-test/t/lock.test: Change occurances of TYPE= to ENGINE= mysql-test/t/lock_tables_lost_commit.test: Change occurances of TYPE= to ENGINE= mysql-test/t/merge.test: Change occurances of TYPE= to ENGINE= mysql-test/t/mix_innodb_myisam_binlog.test: Change occurances of TYPE= to ENGINE= mysql-test/t/multi_update.test: Change occurances of TYPE= to ENGINE= mysql-test/t/myisam.test: Change occurances of TYPE= to ENGINE= mysql-test/t/null.test: Change occurances of TYPE= to ENGINE= mysql-test/t/null_key.test: Change occurances of TYPE= to ENGINE= mysql-test/t/order_by.test: Change occurances of TYPE= to ENGINE= mysql-test/t/outfile.test: Change occurances of TYPE= to ENGINE= mysql-test/t/query_cache.test: Change occurances of TYPE= to ENGINE= mysql-test/t/query_cache_merge.test: Change occurances of TYPE= to ENGINE= mysql-test/t/range.test: Change occurances of TYPE= to ENGINE= mysql-test/t/repair_part1.test: Change occurances of TYPE= to ENGINE= mysql-test/t/replace.test: Change occurances of TYPE= to ENGINE= mysql-test/t/rollback.test: Change occurances of TYPE= to ENGINE= mysql-test/t/rpl000006.test: Change occurances of TYPE= to ENGINE= mysql-test/t/rpl_flush_tables.test: Change occurances of TYPE= to ENGINE= mysql-test/t/rpl_insert_id.test: Change occurances of TYPE= to ENGINE= mysql-test/t/rpl_relayrotate.test: Change occurances of TYPE= to ENGINE= mysql-test/t/select.test: Change occurances of TYPE= to ENGINE= mysql-test/t/select_found.test: Change occurances of TYPE= to ENGINE= mysql-test/t/show_check.test: Change occurances of TYPE= to ENGINE= mysql-test/t/sql_mode.test: Change occurances of TYPE= to ENGINE= mysql-test/t/status.test: Change occurances of TYPE= to ENGINE= mysql-test/t/subselect.test: Change occurances of TYPE= to ENGINE= mysql-test/t/subselect2.test: Change occurances of TYPE= to ENGINE= mysql-test/t/subselect_innodb.test: Change occurances of TYPE= to ENGINE= mysql-test/t/symlink.test: Change occurances of TYPE= to ENGINE= mysql-test/t/temp_table.test: Change occurances of TYPE= to ENGINE= mysql-test/t/type_datetime.test: Change occurances of TYPE= to ENGINE= mysql-test/t/type_set.test: Change occurances of TYPE= to ENGINE= mysql-test/t/union.test: Change occurances of TYPE= to ENGINE= mysql-test/t/update.test: Change occurances of TYPE= to ENGINE= mysql-test/t/warnings.test: Change occurances of TYPE= to ENGINE= New test for deprecated syntax
-rw-r--r--include/mysqld_error.h3
-rw-r--r--mysql-test/r/alias.result2
-rw-r--r--mysql-test/r/alter_table.result18
-rw-r--r--mysql-test/r/auto_increment.result2
-rw-r--r--mysql-test/r/bdb-alter-table-1.result2
-rw-r--r--mysql-test/r/bdb-crash.result2
-rw-r--r--mysql-test/r/bdb-deadlock.result4
-rw-r--r--mysql-test/r/bdb.result94
-rw-r--r--mysql-test/r/bdb_cache.result10
-rw-r--r--mysql-test/r/case.result4
-rw-r--r--mysql-test/r/cast.result6
-rw-r--r--mysql-test/r/constraints.result2
-rw-r--r--mysql-test/r/create.result28
-rw-r--r--mysql-test/r/ctype_collate.result6
-rw-r--r--mysql-test/r/ctype_latin1_de.result4
-rw-r--r--mysql-test/r/ctype_many.result10
-rw-r--r--mysql-test/r/ctype_mb.result10
-rw-r--r--mysql-test/r/ctype_recoding.result8
-rw-r--r--mysql-test/r/ctype_ucs.result10
-rw-r--r--mysql-test/r/delete.result2
-rw-r--r--mysql-test/r/distinct.result10
-rw-r--r--mysql-test/r/fulltext.result8
-rw-r--r--mysql-test/r/fulltext2.result4
-rw-r--r--mysql-test/r/fulltext_distinct.result4
-rw-r--r--mysql-test/r/fulltext_left_join.result4
-rw-r--r--mysql-test/r/func_compress.result2
-rw-r--r--mysql-test/r/func_date_add.result2
-rw-r--r--mysql-test/r/func_group.result2
-rw-r--r--mysql-test/r/func_if.result2
-rw-r--r--mysql-test/r/func_str.result8
-rw-r--r--mysql-test/r/func_system.result2
-rw-r--r--mysql-test/r/func_test.result4
-rw-r--r--mysql-test/r/func_time.result2
-rw-r--r--mysql-test/r/gis-rtree.result8
-rw-r--r--mysql-test/r/group_by.result4
-rw-r--r--mysql-test/r/handler.result2
-rw-r--r--mysql-test/r/heap.result34
-rw-r--r--mysql-test/r/heap_auto_increment.result4
-rw-r--r--mysql-test/r/heap_btree.result34
-rw-r--r--mysql-test/r/heap_hash.result32
-rw-r--r--mysql-test/r/help.result16
-rw-r--r--mysql-test/r/innodb-deadlock.result10
-rw-r--r--mysql-test/r/innodb.result150
-rw-r--r--mysql-test/r/innodb_cache.result12
-rw-r--r--mysql-test/r/innodb_handler.result6
-rw-r--r--mysql-test/r/insert_select.result4
-rw-r--r--mysql-test/r/isam.result14
-rw-r--r--mysql-test/r/join.result12
-rw-r--r--mysql-test/r/join_crash.result8
-rw-r--r--mysql-test/r/join_outer.result2
-rw-r--r--mysql-test/r/key.result2
-rw-r--r--mysql-test/r/lock.result6
-rw-r--r--mysql-test/r/lock_tables_lost_commit.result2
-rw-r--r--mysql-test/r/merge.result68
-rw-r--r--mysql-test/r/mix_innodb_myisam_binlog.result6
-rw-r--r--mysql-test/r/multi_update.result18
-rw-r--r--mysql-test/r/myisam.result8
-rw-r--r--mysql-test/r/null.result2
-rw-r--r--mysql-test/r/null_key.result10
-rw-r--r--mysql-test/r/order_by.result8
-rw-r--r--mysql-test/r/query_cache.result2
-rw-r--r--mysql-test/r/range.result4
-rw-r--r--mysql-test/r/repair_part1.result4
-rw-r--r--mysql-test/r/replace.result6
-rw-r--r--mysql-test/r/rollback.result2
-rw-r--r--mysql-test/r/rpl000006.result2
-rw-r--r--mysql-test/r/rpl_flush_tables.result20
-rw-r--r--mysql-test/r/rpl_insert_id.result4
-rw-r--r--mysql-test/r/rpl_relayrotate.result2
-rw-r--r--mysql-test/r/select.result12
-rw-r--r--mysql-test/r/select_found.result2
-rw-r--r--mysql-test/r/show_check.result22
-rw-r--r--mysql-test/r/sql_mode.result10
-rw-r--r--mysql-test/r/status.result2
-rw-r--r--mysql-test/r/subselect.result64
-rw-r--r--mysql-test/r/subselect2.result8
-rw-r--r--mysql-test/r/subselect_innodb.result14
-rw-r--r--mysql-test/r/symlink.result4
-rw-r--r--mysql-test/r/temp_table.result6
-rw-r--r--mysql-test/r/type_blob.result2
-rw-r--r--mysql-test/r/type_datetime.result2
-rw-r--r--mysql-test/r/type_enum.result4
-rw-r--r--mysql-test/r/type_nchar.result14
-rw-r--r--mysql-test/r/type_set.result6
-rw-r--r--mysql-test/r/union.result56
-rw-r--r--mysql-test/r/update.result4
-rw-r--r--mysql-test/r/warnings.result11
-rw-r--r--mysql-test/t/alias.test2
-rw-r--r--mysql-test/t/alter_table.test10
-rw-r--r--mysql-test/t/auto_increment.test2
-rw-r--r--mysql-test/t/bdb-alter-table-1.test2
-rw-r--r--mysql-test/t/bdb-crash.test2
-rw-r--r--mysql-test/t/bdb-deadlock.test4
-rw-r--r--mysql-test/t/bdb.test94
-rw-r--r--mysql-test/t/bdb_cache.test10
-rw-r--r--mysql-test/t/create.test8
-rw-r--r--mysql-test/t/ctype_ucs.test8
-rw-r--r--mysql-test/t/delete.test2
-rw-r--r--mysql-test/t/distinct.test10
-rw-r--r--mysql-test/t/fulltext.test6
-rw-r--r--mysql-test/t/fulltext2.test4
-rw-r--r--mysql-test/t/fulltext_distinct.test4
-rw-r--r--mysql-test/t/fulltext_left_join.test4
-rw-r--r--mysql-test/t/func_compress.test2
-rw-r--r--mysql-test/t/func_date_add.test2
-rw-r--r--mysql-test/t/func_group.test2
-rw-r--r--mysql-test/t/func_if.test2
-rw-r--r--mysql-test/t/func_str.test6
-rw-r--r--mysql-test/t/func_test.test4
-rw-r--r--mysql-test/t/func_time.test2
-rw-r--r--mysql-test/t/gis-rtree.test4
-rw-r--r--mysql-test/t/group_by.test4
-rw-r--r--mysql-test/t/handler.test2
-rw-r--r--mysql-test/t/heap.test34
-rw-r--r--mysql-test/t/heap_auto_increment.test4
-rw-r--r--mysql-test/t/heap_btree.test34
-rw-r--r--mysql-test/t/heap_hash.test32
-rw-r--r--mysql-test/t/help.test16
-rw-r--r--mysql-test/t/innodb-deadlock.test10
-rw-r--r--mysql-test/t/innodb.test148
-rw-r--r--mysql-test/t/innodb_cache.test12
-rw-r--r--mysql-test/t/innodb_handler.test6
-rw-r--r--mysql-test/t/insert_select.test4
-rw-r--r--mysql-test/t/isam.test14
-rw-r--r--mysql-test/t/join.test12
-rw-r--r--mysql-test/t/join_crash.test8
-rw-r--r--mysql-test/t/join_outer.test2
-rw-r--r--mysql-test/t/key.test2
-rw-r--r--mysql-test/t/lock.test6
-rw-r--r--mysql-test/t/lock_tables_lost_commit.test2
-rw-r--r--mysql-test/t/merge.test48
-rw-r--r--mysql-test/t/mix_innodb_myisam_binlog.test6
-rw-r--r--mysql-test/t/multi_update.test18
-rw-r--r--mysql-test/t/myisam.test8
-rw-r--r--mysql-test/t/null.test2
-rw-r--r--mysql-test/t/null_key.test10
-rw-r--r--mysql-test/t/order_by.test8
-rw-r--r--mysql-test/t/outfile.test2
-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/range.test4
-rw-r--r--mysql-test/t/repair_part1.test4
-rw-r--r--mysql-test/t/replace.test6
-rw-r--r--mysql-test/t/rollback.test2
-rw-r--r--mysql-test/t/rpl000006.test2
-rw-r--r--mysql-test/t/rpl_flush_tables.test2
-rw-r--r--mysql-test/t/rpl_insert_id.test4
-rw-r--r--mysql-test/t/rpl_relayrotate.test2
-rw-r--r--mysql-test/t/select.test12
-rw-r--r--mysql-test/t/select_found.test2
-rw-r--r--mysql-test/t/show_check.test4
-rw-r--r--mysql-test/t/sql_mode.test2
-rw-r--r--mysql-test/t/status.test2
-rw-r--r--mysql-test/t/subselect.test56
-rw-r--r--mysql-test/t/subselect2.test8
-rw-r--r--mysql-test/t/subselect_innodb.test14
-rw-r--r--mysql-test/t/symlink.test12
-rw-r--r--mysql-test/t/temp_table.test6
-rw-r--r--mysql-test/t/type_datetime.test2
-rw-r--r--mysql-test/t/type_set.test2
-rw-r--r--mysql-test/t/union.test6
-rw-r--r--mysql-test/t/update.test4
-rw-r--r--mysql-test/t/warnings.test12
-rw-r--r--sql/lex.h123
-rw-r--r--sql/share/czech/errmsg.txt1
-rw-r--r--sql/share/danish/errmsg.txt1
-rw-r--r--sql/share/dutch/errmsg.txt1
-rw-r--r--sql/share/english/errmsg.txt1
-rw-r--r--sql/share/estonian/errmsg.txt1
-rw-r--r--sql/share/french/errmsg.txt1
-rw-r--r--sql/share/german/errmsg.txt1
-rw-r--r--sql/share/greek/errmsg.txt1
-rw-r--r--sql/share/hungarian/errmsg.txt1
-rw-r--r--sql/share/italian/errmsg.txt1
-rw-r--r--sql/share/japanese/errmsg.txt1
-rw-r--r--sql/share/korean/errmsg.txt1
-rw-r--r--sql/share/norwegian-ny/errmsg.txt1
-rw-r--r--sql/share/norwegian/errmsg.txt1
-rw-r--r--sql/share/polish/errmsg.txt1
-rw-r--r--sql/share/portuguese/errmsg.txt1
-rw-r--r--sql/share/romanian/errmsg.txt1
-rw-r--r--sql/share/russian/errmsg.txt1
-rw-r--r--sql/share/serbian/errmsg.txt1
-rw-r--r--sql/share/slovak/errmsg.txt1
-rw-r--r--sql/share/spanish/errmsg.txt1
-rw-r--r--sql/share/swedish/errmsg.txt1
-rw-r--r--sql/share/ukrainian/errmsg.txt1
-rw-r--r--sql/sql_show.cc2
-rw-r--r--sql/sql_yacc.yy43
189 files changed, 1071 insertions, 996 deletions
diff --git a/include/mysqld_error.h b/include/mysqld_error.h
index bb138f2c7eb..40169cf73c6 100644
--- a/include/mysqld_error.h
+++ b/include/mysqld_error.h
@@ -302,4 +302,5 @@
#define ER_UNKNOWN_KEY_CACHE 1283
#define ER_WARN_HOSTNAME_WONT_WORK 1284
#define ER_UNKNOWN_TABLE_ENGINE 1285
-#define ER_ERROR_MESSAGES 286
+#define ER_WARN_DEPRECATED_SYNTAX 1286
+#define ER_ERROR_MESSAGES 287
diff --git a/mysql-test/r/alias.result b/mysql-test/r/alias.result
index 5ed10b58929..7f606367f39 100644
--- a/mysql-test/r/alias.result
+++ b/mysql-test/r/alias.result
@@ -47,7 +47,7 @@ KEY prov_hdl_nr(prov_hdl_nr),
KEY mcbs_aufnr(mcbs_aufnr),
KEY kundentyp(kundentyp),
KEY p_nr(p_nr,suffix)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (3359356,405,3359356,'Mustermann Musterfrau',52500,'2000-05-20','workflow','Auftrag erledigt','Originalvertrag eingegangen und geprüft','','privat',1485525,2122316,'+','','N',1909160,'MobilComSuper92000D2',NULL,NULL,'MS9ND2',3,24,'MobilCom Shop Koeln',52500,NULL,'auto',20010202105916,'Mobilfunk','PP','','','');
INSERT INTO t1 VALUES (3359357,468,3359357,'Mustermann Musterfrau',7001,'2000-05-20','workflow','Auftrag erledigt','Originalvertrag eingegangen und geprüft','','privat',1503580,2139699,'+','','P',1909171,'MobilComSuper9D1T10SFreisprech(Akquise)',NULL,NULL,'MS9NS1',327,24,'MobilCom Intern',7003,NULL,'auto',20010202105916,'Mobilfunk','PP','','','');
INSERT INTO t1 VALUES (3359358,407,3359358,'Mustermann Musterfrau',7001,'2000-05-20','workflow','Auftrag erledigt','Originalvertrag eingegangen und geprüft','','privat',1501358,2137473,'N','','N',1909159,'MobilComSuper92000D2',NULL,NULL,'MS9ND2',325,24,'MobilCom Intern',7003,NULL,'auto',20010202105916,'Mobilfunk','PP','','','');
diff --git a/mysql-test/r/alter_table.result b/mysql-test/r/alter_table.result
index b82255bf652..7ec12c1b021 100644
--- a/mysql-test/r/alter_table.result
+++ b/mysql-test/r/alter_table.result
@@ -73,10 +73,10 @@ body text NOT NULL,
user_id int(11) unsigned NOT NULL default '0',
status enum('new','old') NOT NULL default 'new',
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
ALTER TABLE t1 ORDER BY t1.id, t1.status, t1.type_id, t1.user_id, t1.body;
DROP TABLE t1;
-CREATE TABLE t1 (AnamneseId int(10) unsigned NOT NULL auto_increment,B BLOB,PRIMARY KEY (AnamneseId)) type=myisam;
+CREATE TABLE t1 (AnamneseId int(10) unsigned NOT NULL auto_increment,B BLOB,PRIMARY KEY (AnamneseId)) engine=myisam;
insert into t1 values (null,"hello");
LOCK TABLES t1 WRITE;
ALTER TABLE t1 ADD Column new_col int not null;
@@ -323,31 +323,31 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` char(10) character set koi8r default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
alter table t1 DEFAULT CHARACTER SET latin1;
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` char(10) character set koi8r default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
alter table t1 CHARACTER SET latin1;
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` char(10) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
alter table t1 DEFAULT CHARACTER SET cp1251;
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` char(10) character set latin1 default NULL
-) TYPE=MyISAM DEFAULT CHARSET=cp1251
+) ENGINE=MyISAM DEFAULT CHARSET=cp1251
drop table t1;
CREATE TABLE t1 (
Host varchar(16) binary NOT NULL default '',
User varchar(16) binary NOT NULL default '',
PRIMARY KEY (Host,User)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
ALTER TABLE t1 DISABLE KEYS;
LOCK TABLES t1 WRITE;
INSERT INTO t1 VALUES ('localhost','root'),('localhost',''),('games','monty');
@@ -366,7 +366,7 @@ Host varchar(16) binary NOT NULL default '',
User varchar(16) binary NOT NULL default '',
PRIMARY KEY (Host,User),
KEY (Host)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
ALTER TABLE t1 DISABLE KEYS;
SHOW INDEX FROM t1;
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
@@ -403,7 +403,7 @@ Host varchar(16) binary NOT NULL default '',
User varchar(16) binary NOT NULL default '',
PRIMARY KEY (Host,User),
KEY (Host)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
LOCK TABLES t1 WRITE;
ALTER TABLE t1 DISABLE KEYS;
SHOW INDEX FROM t1;
diff --git a/mysql-test/r/auto_increment.result b/mysql-test/r/auto_increment.result
index 113c2930977..05317c0f845 100644
--- a/mysql-test/r/auto_increment.result
+++ b/mysql-test/r/auto_increment.result
@@ -1,6 +1,6 @@
drop table if exists t1;
SET SQL_WARNINGS=1;
-create table t1 (a int not null auto_increment,b int, primary key (a)) type=myisam auto_increment=3;
+create table t1 (a int not null auto_increment,b int, primary key (a)) engine=myisam auto_increment=3;
insert into t1 values (1,1),(NULL,3),(NULL,4);
delete from t1 where a=4;
insert into t1 values (NULL,5),(NULL,6);
diff --git a/mysql-test/r/bdb-alter-table-1.result b/mysql-test/r/bdb-alter-table-1.result
index 095d89355ad..0401002f1f3 100644
--- a/mysql-test/r/bdb-alter-table-1.result
+++ b/mysql-test/r/bdb-alter-table-1.result
@@ -1,5 +1,5 @@
drop table if exists t1;
-create table t1(objid BIGINT not null, tablename varchar(64), oid BIGINT not null, test BIGINT, PRIMARY KEY (objid), UNIQUE(tablename)) type=BDB;
+create table t1(objid BIGINT not null, tablename varchar(64), oid BIGINT not null, test BIGINT, PRIMARY KEY (objid), UNIQUE(tablename)) engine=BDB;
insert into t1 values(1, 't1',4,9);
insert into t1 values(2, 'metatable',1,9);
insert into t1 values(3, 'metaindex',1,9 );
diff --git a/mysql-test/r/bdb-crash.result b/mysql-test/r/bdb-crash.result
index 5079368ea21..8f5b8c08f1d 100644
--- a/mysql-test/r/bdb-crash.result
+++ b/mysql-test/r/bdb-crash.result
@@ -14,7 +14,7 @@ ChargeTimeStamp varchar(20),
PRIMARY KEY (ChargeID),
KEY ServiceID (ServiceID),
KEY ChargeDate (ChargeDate)
-) type=BDB;
+) engine=BDB;
BEGIN;
INSERT INTO t1
VALUES(NULL,1,'2001-03-01',1,1,1,'New',NULL,NULL,'now');
diff --git a/mysql-test/r/bdb-deadlock.result b/mysql-test/r/bdb-deadlock.result
index 6606b0d9b38..c5871ff282a 100644
--- a/mysql-test/r/bdb-deadlock.result
+++ b/mysql-test/r/bdb-deadlock.result
@@ -1,6 +1,6 @@
drop table if exists t1,t2;
-create table t1 (id integer, x integer) type=BDB;
-create table t2 (id integer, x integer) type=BDB;
+create table t1 (id integer, x integer) engine=BDB;
+create table t2 (id integer, x integer) engine=BDB;
insert into t1 values(0, 0);
insert into t2 values(0, 0);
set autocommit=0;
diff --git a/mysql-test/r/bdb.result b/mysql-test/r/bdb.result
index f619775aa97..6021f02f2a6 100644
--- a/mysql-test/r/bdb.result
+++ b/mysql-test/r/bdb.result
@@ -1,5 +1,5 @@
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8;
-create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) type=bdb;
+create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) engine=bdb;
insert into t1 (code, name) values (1, 'Tim'), (1, 'Monty'), (2, 'David'), (2, 'Erik'), (3, 'Sasha'), (3, 'Jeremy'), (4, 'Matt');
select id, code, name from t1 order by id;
id code name
@@ -38,7 +38,7 @@ level tinyint(4) DEFAULT '0' NOT NULL,
PRIMARY KEY (id),
KEY parent_id (parent_id),
KEY level (level)
-) type=bdb;
+) engine=bdb;
INSERT INTO t1 VALUES (1,0,0),(3,1,1),(4,1,1),(8,2,2),(9,2,2),(17,3,2),(22,4,2),(24,4,2),(28,5,2),(29,5,2),(30,5,2),(31,6,2),(32,6,2),(33,6,2),(203,7,2),(202,7,2),(20,3,2),(157,0,0),(193,5,2),(40,7,2),(2,1,1),(15,2,2),(6,1,1),(34,6,2),(35,6,2),(16,3,2),(7,1,1),(36,7,2),(18,3,2),(26,5,2),(27,5,2),(183,4,2),(38,7,2),(25,5,2),(37,7,2),(21,4,2),(19,3,2),(5,1,1),(179,5,2);
update t1 set parent_id=parent_id+100;
select * from t1 where parent_id=102;
@@ -176,7 +176,7 @@ CREATE TABLE t1 (
gesuchnr int(11) DEFAULT '0' NOT NULL,
benutzer_id int(11) DEFAULT '0' NOT NULL,
PRIMARY KEY (gesuchnr,benutzer_id)
-) type=BDB;
+) engine=BDB;
replace into t1 (gesuchnr,benutzer_id) values (2,1);
replace into t1 (gesuchnr,benutzer_id) values (1,1);
replace into t1 (gesuchnr,benutzer_id) values (1,1);
@@ -185,14 +185,14 @@ gesuchnr benutzer_id
1 1
2 1
drop table t1;
-create table t1 (id int not null primary key, x int not null, key (x)) type=bdb;
+create table t1 (id int not null primary key, x int not null, key (x)) engine=bdb;
insert into t1 (id, x) values (1, 1);
replace into t1 (id, x) values (1, 2);
select * from t1;
id x
1 2
drop table t1;
-create table t1 (a int) type=bdb;
+create table t1 (a int) engine=bdb;
insert into t1 values (1), (2);
optimize table t1;
Table Op Msg_type Msg_text
@@ -205,7 +205,7 @@ check table t1;
Table Op Msg_type Msg_text
test.t1 check error The storage engine for the table doesn't support check
drop table t1;
-create table t1 (a int,b varchar(20)) type=bdb;
+create table t1 (a int,b varchar(20)) engine=bdb;
insert into t1 values (1,""), (2,"testing");
delete from t1 where a = 1;
select * from t1;
@@ -220,13 +220,13 @@ show keys from t1;
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
t1 1 skr 1 a A 3 NULL NULL YES BTREE
drop table t1;
-create table t1 (a int,b varchar(20),key(a)) type=bdb;
+create table t1 (a int,b varchar(20),key(a)) engine=bdb;
insert into t1 values (1,""), (2,"testing");
select * from t1 where a = 1;
a b
1
drop table t1;
-create table t1 (a char(10) not null, b int not null auto_increment, primary key(a,b)) type=BDB;
+create table t1 (a char(10) not null, b int not null auto_increment, primary key(a,b)) engine=BDB;
insert into t1 values ("a",1),("b",2),("a",2),("c",1);
insert into t1 values ("a",NULL),("b",NULL),("c",NULL),("e",NULL);
insert into t1 (a) values ("a"),("b"),("c"),("d");
@@ -256,7 +256,7 @@ select count(*) from t1;
count(*)
16
drop table t1;
-create table t1 (n int not null primary key) type=bdb;
+create table t1 (n int not null primary key) engine=bdb;
set autocommit=0;
insert into t1 values (4);
rollback;
@@ -287,7 +287,7 @@ n
6
rollback;
drop table t1;
-create table t1 ( id int NOT NULL PRIMARY KEY, nom varchar(64)) type=BDB;
+create table t1 ( id int NOT NULL PRIMARY KEY, nom varchar(64)) engine=BDB;
begin;
insert into t1 values(1,'hamdouni');
select id as afterbegin_id,nom as afterbegin_nom from t1;
@@ -306,7 +306,7 @@ select id as afterrollback_id,nom as afterrollback_nom from t1;
afterrollback_id afterrollback_nom
set autocommit=1;
drop table t1;
-CREATE TABLE t1 (id char(8) not null primary key, val int not null) type=bdb;
+CREATE TABLE t1 (id char(8) not null primary key, val int not null) engine=bdb;
insert into t1 values ('pippo', 12);
insert into t1 values ('pippo', 12);
ERROR 23000: Duplicate entry 'pippo' for key 1
@@ -327,13 +327,13 @@ select * from t1;
id val
drop table t1;
set autocommit=1;
-CREATE TABLE t1 (ID INTEGER NOT NULL PRIMARY KEY, NAME VARCHAR(64)) TYPE=BDB;
+CREATE TABLE t1 (ID INTEGER NOT NULL PRIMARY KEY, NAME VARCHAR(64)) ENGINE=BDB;
INSERT INTO t1 VALUES (1, 'Jochen');
select * from t1;
ID NAME
1 Jochen
drop table t1;
-CREATE TABLE t1 ( _userid VARCHAR(60) NOT NULL PRIMARY KEY) TYPE=BDB;
+CREATE TABLE t1 ( _userid VARCHAR(60) NOT NULL PRIMARY KEY) ENGINE=BDB;
set autocommit=0;
INSERT INTO t1 SET _userid='marc@anyware.co.uk';
COMMIT;
@@ -352,7 +352,7 @@ phone varchar(100),
ref_email varchar(100) DEFAULT '' NOT NULL,
detail varchar(200),
PRIMARY KEY (user_id,ref_email)
-)type=bdb;
+)engine=bdb;
INSERT INTO t1 VALUES (10292,'sanjeev','29153373','sansh777@hotmail.com','xxx'),(10292,'shirish','2333604','shirish@yahoo.com','ddsds'),(10292,'sonali','323232','sonali@bolly.com','filmstar');
select * from t1 where user_id=10292;
user_id name phone ref_email detail
@@ -390,7 +390,7 @@ t1 1 a 1 a A NULL NULL NULL BTREE
t1 1 a_2 1 a A NULL NULL NULL BTREE
drop table t1;
create table t1 (col1 int not null, col2 char(4) not null, primary key(col1));
-alter table t1 type=BDB;
+alter table t1 engine=BDB;
insert into t1 values ('1','1'),('5','2'),('2','3'),('3','4'),('4','4');
select * from t1;
col1 col2
@@ -424,8 +424,8 @@ col1 col2 co3
4 7 0
5 2 0
drop table t1;
-create table t1 (a int not null , b int, primary key (a)) type = BDB;
-create table t2 (a int not null , b int, primary key (a)) type = myisam;
+create table t1 (a int not null , b int, primary key (a)) engine = BDB;
+create table t2 (a int not null , b int, primary key (a)) engine = myisam;
insert into t1 VALUES (1,3) , (2,3), (3,3);
select * from t1;
a b
@@ -460,7 +460,7 @@ email varchar(64) DEFAULT '' NOT NULL,
passwd varchar(32) binary DEFAULT '' NOT NULL,
PRIMARY KEY (id),
UNIQUE ggid (ggid)
-) TYPE=BDB;
+) ENGINE=BDB;
insert into t1 (ggid,passwd) values ('test1','xxx');
insert into t1 (ggid,passwd) values ('test2','yyy');
insert into t1 (ggid,passwd) values ('test2','this will fail');
@@ -502,7 +502,7 @@ access_time time,
approved datetime,
dummy_primary_key int(11) NOT NULL auto_increment,
PRIMARY KEY (dummy_primary_key)
-) TYPE=BDB;
+) ENGINE=BDB;
INSERT INTO t1 VALUES ('user_0','somepassword','N',0,0,0,'2000-09-07','23:06:59','2000-09-07 23:06:59',1);
INSERT INTO t1 VALUES ('user_1','somepassword','Y',1,1,1,'2000-09-07','23:06:59','2000-09-07 23:06:59',2);
INSERT INTO t1 VALUES ('user_2','somepassword','N',2,2,1.4142135623731,'2000-09-07','23:06:59','2000-09-07 23:06:59',3);
@@ -523,7 +523,7 @@ level tinyint(4) DEFAULT '0' NOT NULL,
KEY (id),
KEY parent_id (parent_id),
KEY level (level)
-) type=bdb;
+) engine=bdb;
INSERT INTO t1 VALUES (1,0,0),(3,1,1),(4,1,1),(8,2,2),(9,2,2),(17,3,2),(22,4,2),(24,4,2),(28,5,2),(29,5,2),(30,5,2),(31,6,2),(32,6,2),(33,6,2),(203,7,2),(202,7,2),(20,3,2),(157,0,0),(193,5,2),(40,7,2),(2,1,1),(15,2,2),(6,1,1),(34,6,2),(35,6,2),(16,3,2),(7,1,1),(36,7,2),(18,3,2),(26,5,2),(27,5,2),(183,4,2),(38,7,2),(25,5,2),(37,7,2),(21,4,2),(19,3,2),(5,1,1);
INSERT INTO t1 values (179,5,2);
update t1 set parent_id=parent_id+100;
@@ -697,7 +697,7 @@ sca_sdesc varchar(50),
sca_sch_desc varchar(16),
PRIMARY KEY (sca_code, cat_code, lan_code),
INDEX sca_pic (sca_pic)
-) type = bdb ;
+) engine = bdb ;
INSERT INTO t1 ( sca_code, cat_code, sca_desc, lan_code, sca_pic, sca_sdesc, sca_sch_desc) VALUES ( 'PD', 'J', 'PENDANT', 'EN', NULL, NULL, 'PENDANT'),( 'RI', 'J', 'RING', 'EN', NULL, NULL, 'RING'),( 'QQ', 'N', 'RING', 'EN', 'not null', NULL, 'RING');
select count(*) from t1 where sca_code = 'PD';
count(*)
@@ -730,7 +730,7 @@ update t1 set sca_pic="test" where sca_pic is null;
delete from t1 where sca_code='pd';
drop table t1;
set @a:=now();
-CREATE TABLE t1 (a int not null, b timestamp not null, primary key (a)) type=bdb;
+CREATE TABLE t1 (a int not null, b timestamp not null, primary key (a)) engine=bdb;
insert into t1 (a) values(1),(2),(3);
select t1.a from t1 natural join t1 as t2 where t1.b >= @a order by t1.a;
a
@@ -745,7 +745,7 @@ a
5
drop table t1;
flush logs;
-create table t1 (b blob, i int, key (b(100)), key (i), key (i, b(20))) type=bdb;
+create table t1 (b blob, i int, key (b(100)), key (i), key (i, b(20))) engine=bdb;
insert into t1 values ('this is a blob', 1), (null, -1), (null, null),("",1),("",2),("",3);
select b from t1 where b = 'this is a blob';
b
@@ -774,7 +774,7 @@ updated 1
2
3
drop table t1;
-create table t1 (a varchar(100) not null, primary key(a), b int not null) type=bdb;
+create table t1 (a varchar(100) not null, primary key(a), b int not null) engine=bdb;
insert into t1 values("hello",1),("world",2);
select * from t1 order by b desc;
a b
@@ -787,7 +787,7 @@ show keys from t1;
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
t1 0 PRIMARY 1 a A 2 NULL NULL BTREE
drop table t1;
-create table t1 (i int, j int )TYPE=BDB;
+create table t1 (i int, j int )ENGINE=BDB;
insert into t1 values (1,2);
select * from t1 where i=1 and j=2;
i j
@@ -804,7 +804,7 @@ branch_name varchar(255) not null,
branch_active int not null default 1,
unique branch_name(branch_name),
index branch_active(branch_active)
-) type=bdb;
+) engine=bdb;
create table t2
(
target_id int auto_increment primary key,
@@ -812,7 +812,7 @@ target_name varchar(255) not null,
target_active int not null default 1,
unique target_name(target_name),
index target_active(target_active)
-) type=bdb;
+) engine=bdb;
create table t3
(
platform_id int auto_increment primary key,
@@ -820,7 +820,7 @@ platform_name varchar(255) not null,
platform_active int not null default 1,
unique platform_name(platform_name),
index platform_active(platform_active)
-) type=bdb;
+) engine=bdb;
create table t4
(
product_id int auto_increment primary key,
@@ -829,7 +829,7 @@ version_file varchar(255) not null,
product_active int not null default 1,
unique product_name(product_name),
index product_active(product_active)
-) type=bdb;
+) engine=bdb;
create table t5
(
product_file_id int auto_increment primary key,
@@ -841,7 +841,7 @@ module_name varchar(255) not null,
file_included int not null default 1,
unique product_file(product_id,file_name),
index file_included(file_included)
-) type=bdb;
+) engine=bdb;
create table t6
(
file_platform_id int auto_increment primary key,
@@ -853,7 +853,7 @@ build_filename varchar(255) not null,
/* default filename in the build archive */
archive_filename varchar(255) not null,
unique file_platform(product_file_id,platform_id,branch_id)
-) type=bdb;
+) engine=bdb;
create table t8
(
archive_id int auto_increment primary key,
@@ -864,7 +864,7 @@ product_id int not null,
status_id int not null default 1,
unique archive(branch_id,target_id,platform_id,product_id),
index status_id(status_id)
-) type=bdb;
+) engine=bdb;
create table t7
(
build_id int auto_increment primary key,
@@ -877,7 +877,7 @@ build_tag varchar(255) not null,
/* path relative to the build archive root, e.g. 'current' */
build_path text not null,
unique build(branch_id,target_id,build_number)
-) type=bdb;
+) engine=bdb;
insert into t1 (branch_name)
values ('RealMedia');
insert into t1 (branch_name)
@@ -981,7 +981,7 @@ CREATE TABLE t1 (
a tinytext NOT NULL,
b tinyint(3) unsigned NOT NULL default '0',
PRIMARY KEY (a(32),b)
-) TYPE=BDB;
+) ENGINE=BDB;
INSERT INTO t1 VALUES ('a',1),('a',2);
SELECT * FROM t1 WHERE a='a' AND b=2;
a b
@@ -998,13 +998,13 @@ CREATE TABLE t1 (
a int3 unsigned NOT NULL,
b int1 unsigned NOT NULL,
UNIQUE (a, b)
-) TYPE = BDB;
+) ENGINE = BDB;
INSERT INTO t1 VALUES (1, 1);
SELECT MIN(B),MAX(b) FROM t1 WHERE t1.a = 1;
MIN(B) MAX(b)
1 1
drop table t1;
-create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) type=bdb;
+create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) engine=bdb;
insert into t1 values (0,0,0,'ABCDEFGHIJ'),(2,2,2,'BCDEFGHIJK'),(1,1,1,'CDEFGHIJKL');
LOCK TABLES t1 WRITE;
insert into t1 values (99,1,2,'D'),(1,1,2,'D');
@@ -1021,7 +1021,7 @@ id
2
UNLOCK TABLES;
DROP TABLE t1;
-create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) type=bdb;
+create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) engine=bdb;
insert into t1 values (0,0,0,'ABCDEFGHIJ'),(2,2,2,'BCDEFGHIJK'),(1,1,1,'CDEFGHIJKL');
LOCK TABLES t1 WRITE;
begin;
@@ -1042,14 +1042,14 @@ id id3
100 2
UNLOCK TABLES;
DROP TABLE t1;
-CREATE TABLE t1 (SYAIN_NO char(5) NOT NULL default '', KINMU_DATE char(6) NOT NULL default '', PRIMARY KEY (SYAIN_NO,KINMU_DATE)) TYPE=BerkeleyDB;
-CREATE TABLE t2 ( SYAIN_NO char(5) NOT NULL default '',STR_DATE char(8) NOT NULL default '',PRIMARY KEY (SYAIN_NO,STR_DATE) ) TYPE=BerkeleyDB;
+CREATE TABLE t1 (SYAIN_NO char(5) NOT NULL default '', KINMU_DATE char(6) NOT NULL default '', PRIMARY KEY (SYAIN_NO,KINMU_DATE)) ENGINE=BerkeleyDB;
+CREATE TABLE t2 ( SYAIN_NO char(5) NOT NULL default '',STR_DATE char(8) NOT NULL default '',PRIMARY KEY (SYAIN_NO,STR_DATE) ) ENGINE=BerkeleyDB;
select T1.KINMU_DATE from t1 T1 ,t2 T2 where T1.SYAIN_NO = '12345' and T1.KINMU_DATE = '200106' and T2.SYAIN_NO = T1.SYAIN_NO;
KINMU_DATE
select T1.KINMU_DATE from t1 T1 ,t2 T2 where T1.SYAIN_NO = '12345' and T1.KINMU_DATE = '200106' and T2.SYAIN_NO = T1.SYAIN_NO;
KINMU_DATE
DROP TABLE t1,t2;
-create table t1 (a int(11) not null, b int(11) not null, unique (a,b)) type=bdb;
+create table t1 (a int(11) not null, b int(11) not null, unique (a,b)) engine=bdb;
insert into t1 values (1,1), (1,2);
select * from t1 where a = 1;
a b
@@ -1066,9 +1066,9 @@ a b
1 1
1 2
drop table t1;
-create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) type=bdb;
+create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) engine=bdb;
insert into t1 values (0,0,0,'ABCDEFGHIJ');
-create table t2 (id int NOT NULL,primary key (id)) type=bdb;
+create table t2 (id int NOT NULL,primary key (id)) engine=bdb;
LOCK TABLES t1 WRITE, t2 WRITE;
insert into t2 values(1);
SELECT t1.* FROM t1 WHERE id IN (1);
@@ -1078,13 +1078,13 @@ id id2 id3 dummy1
NULL NULL NULL NULL
delete from t1 where id3 >= 0 and id3 <= 0;
drop table t1,t2;
-CREATE TABLE t1 (i varchar(48) NOT NULL default '', p varchar(255) default NULL,s varchar(48) NOT NULL default '', PRIMARY KEY (i), UNIQUE(p,s)) TYPE=BDB;
+CREATE TABLE t1 (i varchar(48) NOT NULL default '', p varchar(255) default NULL,s varchar(48) NOT NULL default '', PRIMARY KEY (i), UNIQUE(p,s)) ENGINE=BDB;
INSERT INTO t1 VALUES ('00000000-e6c4ddeaa6-003b8-83458387','programs/xxxxxxxx.wmv','00000000-e6c4ddeb32-003bc-83458387');
SELECT * FROM t1 WHERE p='programs/xxxxxxxx.wmv';
i p s
00000000-e6c4ddeaa6-003b8-83458387 programs/xxxxxxxx.wmv 00000000-e6c4ddeb32-003bc-83458387
drop table t1;
-CREATE TABLE t1 ( STR_DATE varchar(8) NOT NULL default '',INFO_NOTE varchar(200) default NULL,PRIMARY KEY (STR_DATE) ) TYPE=BerkeleyDB;
+CREATE TABLE t1 ( STR_DATE varchar(8) NOT NULL default '',INFO_NOTE varchar(200) default NULL,PRIMARY KEY (STR_DATE) ) ENGINE=BerkeleyDB;
select INFO_NOTE from t1 where STR_DATE = '20010610';
INFO_NOTE
select INFO_NOTE from t1 where STR_DATE < '20010610';
@@ -1092,8 +1092,8 @@ INFO_NOTE
select INFO_NOTE from t1 where STR_DATE > '20010610';
INFO_NOTE
drop table t1;
-create table t1 (a int not null, b int, primary key (a)) type =bdb;
-create table t2 (a int not null, b int, primary key (a)) type =bdb;
+create table t1 (a int not null, b int, primary key (a)) engine =bdb;
+create table t2 (a int not null, b int, primary key (a)) engine =bdb;
insert into t1 values (2, 3),(1, 7),(10, 7);
insert into t2 values (2, 3),(1, 7),(10, 7);
select * from t1;
@@ -1114,7 +1114,7 @@ a b
select * from t2;
a b
drop table t1,t2;
-create table t1 (x int not null, index(x)) type=bdb;
+create table t1 (x int not null, index(x)) engine=bdb;
insert into t1 values (1), (2), (3), (4), (5), (6), (7), (8), (9), (10);
select * from t1 where x <= 10 and x >= 7;
x
diff --git a/mysql-test/r/bdb_cache.result b/mysql-test/r/bdb_cache.result
index ea00feb2111..218fd489c6a 100644
--- a/mysql-test/r/bdb_cache.result
+++ b/mysql-test/r/bdb_cache.result
@@ -1,7 +1,7 @@
drop table if exists t1, t2, t3;
flush status;
set autocommit=0;
-create table t1 (a int not null) type=bdb;
+create table t1 (a int not null) engine=bdb;
insert into t1 values (1),(2),(3);
select * from t1;
a
@@ -15,7 +15,7 @@ drop table t1;
commit;
set autocommit=1;
begin;
-create table t1 (a int not null) type=bdb;
+create table t1 (a int not null) engine=bdb;
insert into t1 values (1),(2),(3);
select * from t1;
a
@@ -27,9 +27,9 @@ Variable_name Value
Qcache_queries_in_cache 0
drop table t1;
commit;
-create table t1 (a int not null) type=bdb;
-create table t2 (a int not null) type=bdb;
-create table t3 (a int not null) type=bdb;
+create table t1 (a int not null) engine=bdb;
+create table t2 (a int not null) engine=bdb;
+create table t3 (a int not null) engine=bdb;
insert into t1 values (1),(2);
insert into t2 values (1),(2);
insert into t3 values (1),(2);
diff --git a/mysql-test/r/case.result b/mysql-test/r/case.result
index e9d432de077..14b1788ddd6 100644
--- a/mysql-test/r/case.result
+++ b/mysql-test/r/case.result
@@ -105,7 +105,7 @@ t1 CREATE TABLE `t1` (
`c7` double(3,1) NOT NULL default '0.0',
`c8` double(3,1) NOT NULL default '0.0',
`c9` double(3,1) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
DROP TABLE t1;
SELECT CASE
WHEN 1
@@ -152,5 +152,5 @@ t1 CREATE TABLE `t1` (
`COALESCE(1,'1')` char(1) NOT NULL default '',
`COALESCE(1.1,'1')` char(3) NOT NULL default '',
`COALESCE('a' COLLATE latin1_bin,'b')` char(1) character set latin1 collate latin1_bin NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
DROP TABLE t1;
diff --git a/mysql-test/r/cast.result b/mysql-test/r/cast.result
index 43afd02169c..acca50b45dd 100644
--- a/mysql-test/r/cast.result
+++ b/mysql-test/r/cast.result
@@ -45,7 +45,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`t` char(4) character set cp1251 NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
select
cast(_latin1'ab' AS char) as c1,
@@ -72,7 +72,7 @@ t1 CREATE TABLE `t1` (
`c3` char(2) binary NOT NULL default '',
`c4` char(2) binary NOT NULL default '',
`c5` char(2) binary NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
select
cast(_koi8r'ÆÇ' AS nchar) as c1,
@@ -99,7 +99,7 @@ t1 CREATE TABLE `t1` (
`c3` char(2) character set utf8 NOT NULL default '',
`c4` char(2) character set utf8 NOT NULL default '',
`c5` char(2) character set utf8 NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
select cast("2001-1-1" as date) = "2001-01-01";
cast("2001-1-1" as date) = "2001-01-01"
diff --git a/mysql-test/r/constraints.result b/mysql-test/r/constraints.result
index 7cd8053c21b..d4d525c8991 100644
--- a/mysql-test/r/constraints.result
+++ b/mysql-test/r/constraints.result
@@ -25,5 +25,5 @@ t1 CREATE TABLE `t1` (
UNIQUE KEY `constraint_1` (`a`),
UNIQUE KEY `key_1` (`a`),
UNIQUE KEY `key_2` (`a`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
diff --git a/mysql-test/r/create.result b/mysql-test/r/create.result
index 2f61b4838ee..5df29fee298 100644
--- a/mysql-test/r/create.result
+++ b/mysql-test/r/create.result
@@ -17,9 +17,9 @@ b
drop table t1;
-create table t1 (a int not null auto_increment,primary key (a)) type=heap;
+create table t1 (a int not null auto_increment,primary key (a)) engine=heap;
drop table t1;
-create table t2 type=heap select * from t1;
+create table t2 engine=heap select * from t1;
ERROR 42S02: Table 'test.t1' doesn't exist
create table t2 select auto+1 from t1;
ERROR 42S02: Table 'test.t1' doesn't exist
@@ -29,12 +29,12 @@ Note 1051 Unknown table 't1'
Note 1051 Unknown table 't2'
create table t1 (b char(0) not null, index(b));
ERROR 42000: The used storage engine can't index column 'b'
-create table t1 (a int not null,b text) type=heap;
+create table t1 (a int not null,b text) engine=heap;
ERROR 42000: The used table type doesn't support BLOB/TEXT columns
drop table if exists t1;
Warnings:
Note 1051 Unknown table 't1'
-create table t1 (ordid int(8) not null auto_increment, ord varchar(50) not null, primary key (ord,ordid)) type=heap;
+create table t1 (ordid int(8) not null auto_increment, ord varchar(50) not null, primary key (ord,ordid)) engine=heap;
ERROR 42000: Incorrect table definition; There can only be one auto column and it must be defined as a key
create table not_existing_database.test (a int);
Got one of the listed errors
@@ -180,7 +180,7 @@ t1 CREATE TABLE `t1` (
KEY `b_29` (`b`),
KEY `b_30` (`b`),
KEY `b_31` (`b`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 select if(1,'1','0'), month("2002-08-02");
drop table t1;
@@ -198,7 +198,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) NOT NULL default '0'
-) TYPE=HEAP DEFAULT CHARSET=latin1
+) ENGINE=HEAP DEFAULT CHARSET=latin1
drop table t1;
SET SESSION table_type="gemini";
ERROR 42000: Unknown table engine 'gemini'
@@ -210,7 +210,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) NOT NULL default '0'
-) TYPE=HEAP DEFAULT CHARSET=latin1
+) ENGINE=HEAP DEFAULT CHARSET=latin1
SET SESSION table_type=default;
drop table t1;
create table t1 ( k1 varchar(2), k2 int, primary key(k1,k2));
@@ -275,7 +275,7 @@ Table Create Table
t3 CREATE TABLE `t3` (
`id` int(11) NOT NULL default '0',
`name` char(20) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
select * from t3;
id name
create table if not exists t3 like t1;
@@ -289,7 +289,7 @@ show create table t3;
Table Create Table
t3 CREATE TEMPORARY TABLE `t3` (
`id` int(11) NOT NULL default '0'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
select * from t3;
id
drop table t3;
@@ -298,7 +298,7 @@ Table Create Table
t3 CREATE TABLE `t3` (
`id` int(11) NOT NULL default '0',
`name` char(20) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
select * from t3;
id name
drop table t2, t3;
@@ -310,14 +310,14 @@ Table Create Table
t3 CREATE TEMPORARY TABLE `t3` (
`id` int(11) NOT NULL default '0',
`name` char(20) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
create table t2 like t3;
show create table t2;
Table Create Table
t2 CREATE TABLE `t2` (
`id` int(11) NOT NULL default '0',
`name` char(20) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
select * from t2;
id name
create table t3 like t1;
@@ -343,7 +343,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) NOT NULL default '0'
-) TYPE=HEAP DEFAULT CHARSET=latin1
+) ENGINE=HEAP DEFAULT CHARSET=latin1
drop table t1;
SET SESSION table_type="gemini";
ERROR 42000: Unknown table engine 'gemini'
@@ -355,7 +355,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) NOT NULL default '0'
-) TYPE=HEAP DEFAULT CHARSET=latin1
+) ENGINE=HEAP DEFAULT CHARSET=latin1
SET SESSION table_type=default;
drop table t1;
create table t1(a int,b int,c int unsigned,d date,e char,f datetime,g time,h blob);
diff --git a/mysql-test/r/ctype_collate.result b/mysql-test/r/ctype_collate.result
index 2186b155f99..a3e29d24264 100644
--- a/mysql-test/r/ctype_collate.result
+++ b/mysql-test/r/ctype_collate.result
@@ -491,7 +491,7 @@ SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`latin1_f` char(32) NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
SHOW FIELDS FROM t1;
Field Type Null Key Default Extra
latin1_f char(32)
@@ -501,7 +501,7 @@ SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`latin1_f` char(32) character set latin1 collate latin1_bin default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
SHOW FIELDS FROM t1;
Field Type Null Key Default Extra
latin1_f char(32) YES NULL
@@ -510,7 +510,7 @@ SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`latin1_f` char(32) character set latin1 collate latin1_bin default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
SHOW FIELDS FROM t1;
Field Type Null Key Default Extra
latin1_f char(32) YES NULL
diff --git a/mysql-test/r/ctype_latin1_de.result b/mysql-test/r/ctype_latin1_de.result
index f1049b81d26..7f150cb0698 100644
--- a/mysql-test/r/ctype_latin1_de.result
+++ b/mysql-test/r/ctype_latin1_de.result
@@ -225,7 +225,7 @@ t1 CREATE TABLE `t1` (
`word` varchar(255) collate latin1_german2_ci NOT NULL default '',
`word2` varchar(255) collate latin1_german2_ci NOT NULL default '',
KEY `word` (`word`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_german2_ci
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_german2_ci
insert into t1 (word) values ('ss'),(0xDF),(0xE4),('ae');
update t1 set word2=word;
select word, word=binary 0xdf as t from t1 having t > 0;
@@ -284,7 +284,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`s1` char(5) collate latin1_german2_ci default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_german2_ci
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_german2_ci
INSERT INTO t1 VALUES ('Ü');
INSERT INTO t1 VALUES ('ue');
SELECT DISTINCT s1 FROM t1;
diff --git a/mysql-test/r/ctype_many.result b/mysql-test/r/ctype_many.result
index 764503f9e22..173d41ecdd1 100644
--- a/mysql-test/r/ctype_many.result
+++ b/mysql-test/r/ctype_many.result
@@ -9,14 +9,14 @@ Table Create Table
t1 CREATE TABLE `t1` (
`comment` char(32) character set latin1 NOT NULL default '',
`koi8_ru_f` char(32) character set koi8r NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin5
+) ENGINE=MyISAM DEFAULT CHARSET=latin5
ALTER TABLE t1 CHANGE comment comment CHAR(32) CHARACTER SET latin2 NOT NULL;
SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`comment` char(32) character set latin2 NOT NULL default '',
`koi8_ru_f` char(32) character set koi8r NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin5
+) ENGINE=MyISAM DEFAULT CHARSET=latin5
ALTER TABLE t1 ADD latin5_f CHAR(32) NOT NULL;
SHOW CREATE TABLE t1;
Table Create Table
@@ -24,7 +24,7 @@ t1 CREATE TABLE `t1` (
`comment` char(32) character set latin2 NOT NULL default '',
`koi8_ru_f` char(32) character set koi8r NOT NULL default '',
`latin5_f` char(32) NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin5
+) ENGINE=MyISAM DEFAULT CHARSET=latin5
ALTER TABLE t1 DEFAULT CHARSET=latin2;
ALTER TABLE t1 ADD latin2_f CHAR(32) NOT NULL;
SHOW CREATE TABLE t1;
@@ -34,14 +34,14 @@ t1 CREATE TABLE `t1` (
`koi8_ru_f` char(32) character set koi8r NOT NULL default '',
`latin5_f` char(32) character set latin5 NOT NULL default '',
`latin2_f` char(32) NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin2
+) ENGINE=MyISAM DEFAULT CHARSET=latin2
ALTER TABLE t1 DROP latin2_f, DROP latin5_f;
SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`comment` char(32) NOT NULL default '',
`koi8_ru_f` char(32) character set koi8r NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin2
+) ENGINE=MyISAM DEFAULT CHARSET=latin2
INSERT INTO t1 (koi8_ru_f,comment) VALUES ('a','LAT SMALL A');
INSERT INTO t1 (koi8_ru_f,comment) VALUES ('b','LAT SMALL B');
INSERT INTO t1 (koi8_ru_f,comment) VALUES ('c','LAT SMALL C');
diff --git a/mysql-test/r/ctype_mb.result b/mysql-test/r/ctype_mb.result
index 88cd1b4f7fe..288033e7530 100644
--- a/mysql-test/r/ctype_mb.result
+++ b/mysql-test/r/ctype_mb.result
@@ -5,7 +5,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`c1` char(4) character set utf8 NOT NULL default '',
`c2` char(4) character set utf8 NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
DELETE FROM t1;
ALTER TABLE t1 ADD c3 CHAR(4) CHARACTER SET utf8;
SHOW CREATE TABLE t1;
@@ -14,7 +14,7 @@ t1 CREATE TABLE `t1` (
`c1` char(4) character set utf8 NOT NULL default '',
`c2` char(4) character set utf8 NOT NULL default '',
`c3` char(4) character set utf8 default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
INSERT INTO t1 VALUES ('aaaabbbbccccdddd','aaaabbbbccccdddd','aaaabbbbccccdddd');
Warnings:
Warning 1264 Data truncated for column 'c1' at row 1
@@ -30,7 +30,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` char(4) character set utf8 default NULL,
KEY `key_a` (`a`(3))
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
SHOW KEYS FROM t1;
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
t1 1 key_a 1 a A NULL 9 NULL YES BTREE
@@ -40,7 +40,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` char(4) default NULL,
KEY `key_a` (`a`(3))
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
SHOW KEYS FROM t1;
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
t1 1 key_a 1 a A NULL 3 NULL YES BTREE
@@ -50,7 +50,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` char(4) character set utf8 default NULL,
KEY `key_a` (`a`(3))
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
SHOW KEYS FROM t1;
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
t1 1 key_a 1 a A NULL 9 NULL YES BTREE
diff --git a/mysql-test/r/ctype_recoding.result b/mysql-test/r/ctype_recoding.result
index 5afd2c041c8..646dcb76f96 100644
--- a/mysql-test/r/ctype_recoding.result
+++ b/mysql-test/r/ctype_recoding.result
@@ -6,7 +6,7 @@ SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` char(10) character set cp1251 default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
SELECT a FROM t1;
a
ÐÒÏÂÁ
@@ -25,7 +25,7 @@ SHOW CREATE TABLE ÔÁÂÌÉÃÁ;
Table Create Table
ÔÁÂÌÉÃÁ CREATE TABLE `ÔÁÂÌÉÃÁ` (
`ÐÏÌÅ` char(32) character set koi8r NOT NULL default '' COMMENT 'ËÏÍÍÅÎÔÁÒÉÊ ÐÏÌÑ'
-) TYPE=MyISAM DEFAULT CHARSET=latin1 COMMENT='ËÏÍÍÅÎÔÁÒÉÊ ÔÁÂÌÉÃÙ'
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='ËÏÍÍÅÎÔÁÒÉÊ ÔÁÂÌÉÃÙ'
SHOW FIELDS FROM ÔÁÂÌÉÃÁ;
Field Type Null Key Default Extra
ÐÏÌÅ char(32)
@@ -37,7 +37,7 @@ SHOW CREATE TABLE òàáëèöà;
Table Create Table
òàáëèöà CREATE TABLE `òàáëèöà` (
`ïîëå` char(32) character set koi8r NOT NULL default '' COMMENT 'êîììåíòàðèé ïîëÿ'
-) TYPE=MyISAM DEFAULT CHARSET=latin1 COMMENT='êîììåíòàðèé òàáëèöû'
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='êîììåíòàðèé òàáëèöû'
SHOW FIELDS FROM òàáëèöà;
Field Type Null Key Default Extra
ïîëå char(32)
@@ -49,7 +49,7 @@ SHOW CREATE TABLE таблица;
Table Create Table
таблица CREATE TABLE `таблица` (
`поле` char(32) character set koi8r NOT NULL default '' COMMENT 'комментарий полÑ'
-) TYPE=MyISAM DEFAULT CHARSET=latin1 COMMENT='комментарий таблицы'
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='комментарий таблицы'
SHOW FIELDS FROM таблица;
Field Type Null Key Default Extra
поле char(32)
diff --git a/mysql-test/r/ctype_ucs.result b/mysql-test/r/ctype_ucs.result
index 977797f0278..2f6dc0c23ca 100644
--- a/mysql-test/r/ctype_ucs.result
+++ b/mysql-test/r/ctype_ucs.result
@@ -45,7 +45,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`l` char(10) character set ucs2 NOT NULL default '',
`r` char(10) character set ucs2 NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
DROP TABLE t1;
SET NAMES koi8r;
SET character_set_connection=ucs2;
@@ -155,7 +155,7 @@ a
Æù×ÁÐÒÏÌÄÖ
DROP TABLE t1;
CREATE TABLE t1 (word varchar(64) NOT NULL, PRIMARY KEY (word))
-TYPE=MyISAM CHARACTER SET ucs2 COLLATE ucs2_general_ci;
+ENGINE=MyISAM CHARACTER SET ucs2 COLLATE ucs2_general_ci;
INSERT INTO t1 (word) VALUES ("cat");
SELECT * FROM t1 WHERE word LIKE "c%";
word
@@ -178,7 +178,7 @@ CREATE TABLE t1 (
word VARCHAR(64),
bar INT(11) default 0,
PRIMARY KEY (word))
-TYPE=MyISAM
+ENGINE=MyISAM
CHARSET ucs2
COLLATE ucs2_general_ci ;
INSERT INTO t1 (word) VALUES ("aar");
@@ -213,7 +213,7 @@ DROP TABLE t1;
CREATE TABLE t1 (
word VARCHAR(64) ,
PRIMARY KEY (word))
-TYPE=MyISAM
+ENGINE=MyISAM
CHARSET ucs2
COLLATE ucs2_general_ci;
INSERT INTO t1 (word) VALUES ("aar");
@@ -238,7 +238,7 @@ CREATE TABLE t1 (
word TEXT,
bar INT(11) AUTO_INCREMENT,
PRIMARY KEY (bar))
-TYPE=MyISAM
+ENGINE=MyISAM
CHARSET ucs2
COLLATE ucs2_general_ci ;
INSERT INTO t1 (word) VALUES ("aar");
diff --git a/mysql-test/r/delete.result b/mysql-test/r/delete.result
index 62724c19576..10f2c069429 100644
--- a/mysql-test/r/delete.result
+++ b/mysql-test/r/delete.result
@@ -37,7 +37,7 @@ bool char(0) default NULL,
not_null varchar(20) binary NOT NULL default '',
misc integer not null,
PRIMARY KEY (not_null)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (NULL,'a',4), (NULL,'b',5), (NULL,'c',6), (NULL,'d',7);
select * from t1 where misc > 5 and bool is null;
bool not_null misc
diff --git a/mysql-test/r/distinct.result b/mysql-test/r/distinct.result
index d9beed25edf..80af2dd0983 100644
--- a/mysql-test/r/distinct.result
+++ b/mysql-test/r/distinct.result
@@ -360,7 +360,7 @@ a c
4 NULL
3 NULL
drop table t1;
-create table t1 (a char(1), key(a)) type=myisam;
+create table t1 (a char(1), key(a)) engine=myisam;
insert into t1 values('1'),('1');
select * from t1 where a >= '1';
a
@@ -402,9 +402,9 @@ test2@testdomain.com Z001
test2@testdomain.com R002
test3@testdomain.com Z001
drop table t1,t2;
-CREATE TABLE t1 (privatemessageid int(10) unsigned NOT NULL auto_increment, folderid smallint(6) NOT NULL default '0', userid int(10) unsigned NOT NULL default '0', touserid int(10) unsigned NOT NULL default '0', fromuserid int(10) unsigned NOT NULL default '0', title varchar(250) NOT NULL default '', message mediumtext NOT NULL, dateline int(10) unsigned NOT NULL default '0', showsignature smallint(6) NOT NULL default '0', iconid smallint(5) unsigned NOT NULL default '0', messageread smallint(6) NOT NULL default '0', readtime int(10) unsigned NOT NULL default '0', receipt smallint(6) unsigned NOT NULL default '0', deleteprompt smallint(6) unsigned NOT NULL default '0', multiplerecipients smallint(6) unsigned NOT NULL default '0', PRIMARY KEY (privatemessageid), KEY userid (userid)) TYPE=MyISAM;
+CREATE TABLE t1 (privatemessageid int(10) unsigned NOT NULL auto_increment, folderid smallint(6) NOT NULL default '0', userid int(10) unsigned NOT NULL default '0', touserid int(10) unsigned NOT NULL default '0', fromuserid int(10) unsigned NOT NULL default '0', title varchar(250) NOT NULL default '', message mediumtext NOT NULL, dateline int(10) unsigned NOT NULL default '0', showsignature smallint(6) NOT NULL default '0', iconid smallint(5) unsigned NOT NULL default '0', messageread smallint(6) NOT NULL default '0', readtime int(10) unsigned NOT NULL default '0', receipt smallint(6) unsigned NOT NULL default '0', deleteprompt smallint(6) unsigned NOT NULL default '0', multiplerecipients smallint(6) unsigned NOT NULL default '0', PRIMARY KEY (privatemessageid), KEY userid (userid)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (128,0,33,33,8,':D','',996121863,1,0,2,996122850,2,0,0);
-CREATE TABLE t2 (userid int(10) unsigned NOT NULL auto_increment, usergroupid smallint(5) unsigned NOT NULL default '0', username varchar(50) NOT NULL default '', password varchar(50) NOT NULL default '', email varchar(50) NOT NULL default '', styleid smallint(5) unsigned NOT NULL default '0', parentemail varchar(50) NOT NULL default '', coppauser smallint(6) NOT NULL default '0', homepage varchar(100) NOT NULL default '', icq varchar(20) NOT NULL default '', aim varchar(20) NOT NULL default '', yahoo varchar(20) NOT NULL default '', signature mediumtext NOT NULL, adminemail smallint(6) NOT NULL default '0', showemail smallint(6) NOT NULL default '0', invisible smallint(6) NOT NULL default '0', usertitle varchar(250) NOT NULL default '', customtitle smallint(6) NOT NULL default '0', joindate int(10) unsigned NOT NULL default '0', cookieuser smallint(6) NOT NULL default '0', daysprune smallint(6) NOT NULL default '0', lastvisit int(10) unsigned NOT NULL default '0', lastactivity int(10) unsigned NOT NULL default '0', lastpost int(10) unsigned NOT NULL default '0', posts smallint(5) unsigned NOT NULL default '0', timezoneoffset varchar(4) NOT NULL default '', emailnotification smallint(6) NOT NULL default '0', buddylist mediumtext NOT NULL, ignorelist mediumtext NOT NULL, pmfolders mediumtext NOT NULL, receivepm smallint(6) NOT NULL default '0', emailonpm smallint(6) NOT NULL default '0', pmpopup smallint(6) NOT NULL default '0', avatarid smallint(6) NOT NULL default '0', avatarrevision int(6) unsigned NOT NULL default '0', options smallint(6) NOT NULL default '15', birthday date NOT NULL default '0000-00-00', maxposts smallint(6) NOT NULL default '-1', startofweek smallint(6) NOT NULL default '1', ipaddress varchar(20) NOT NULL default '', referrerid int(10) unsigned NOT NULL default '0', nosessionhash smallint(6) NOT NULL default '0', autorefresh smallint(6) NOT NULL default '-1', messagepopup tinyint(2) NOT NULL default '0', inforum smallint(5) unsigned NOT NULL default '0', ratenum smallint(5) unsigned NOT NULL default '0', ratetotal smallint(5) unsigned NOT NULL default '0', allowrate smallint(5) unsigned NOT NULL default '1', PRIMARY KEY (userid), KEY usergroupid (usergroupid), KEY username (username), KEY inforum (inforum)) TYPE=MyISAM;
+CREATE TABLE t2 (userid int(10) unsigned NOT NULL auto_increment, usergroupid smallint(5) unsigned NOT NULL default '0', username varchar(50) NOT NULL default '', password varchar(50) NOT NULL default '', email varchar(50) NOT NULL default '', styleid smallint(5) unsigned NOT NULL default '0', parentemail varchar(50) NOT NULL default '', coppauser smallint(6) NOT NULL default '0', homepage varchar(100) NOT NULL default '', icq varchar(20) NOT NULL default '', aim varchar(20) NOT NULL default '', yahoo varchar(20) NOT NULL default '', signature mediumtext NOT NULL, adminemail smallint(6) NOT NULL default '0', showemail smallint(6) NOT NULL default '0', invisible smallint(6) NOT NULL default '0', usertitle varchar(250) NOT NULL default '', customtitle smallint(6) NOT NULL default '0', joindate int(10) unsigned NOT NULL default '0', cookieuser smallint(6) NOT NULL default '0', daysprune smallint(6) NOT NULL default '0', lastvisit int(10) unsigned NOT NULL default '0', lastactivity int(10) unsigned NOT NULL default '0', lastpost int(10) unsigned NOT NULL default '0', posts smallint(5) unsigned NOT NULL default '0', timezoneoffset varchar(4) NOT NULL default '', emailnotification smallint(6) NOT NULL default '0', buddylist mediumtext NOT NULL, ignorelist mediumtext NOT NULL, pmfolders mediumtext NOT NULL, receivepm smallint(6) NOT NULL default '0', emailonpm smallint(6) NOT NULL default '0', pmpopup smallint(6) NOT NULL default '0', avatarid smallint(6) NOT NULL default '0', avatarrevision int(6) unsigned NOT NULL default '0', options smallint(6) NOT NULL default '15', birthday date NOT NULL default '0000-00-00', maxposts smallint(6) NOT NULL default '-1', startofweek smallint(6) NOT NULL default '1', ipaddress varchar(20) NOT NULL default '', referrerid int(10) unsigned NOT NULL default '0', nosessionhash smallint(6) NOT NULL default '0', autorefresh smallint(6) NOT NULL default '-1', messagepopup tinyint(2) NOT NULL default '0', inforum smallint(5) unsigned NOT NULL default '0', ratenum smallint(5) unsigned NOT NULL default '0', ratetotal smallint(5) unsigned NOT NULL default '0', allowrate smallint(5) unsigned NOT NULL default '1', PRIMARY KEY (userid), KEY usergroupid (usergroupid), KEY username (username), KEY inforum (inforum)) ENGINE=MyISAM;
INSERT INTO t2 VALUES (33,6,'Kevin','0','kevin@stileproject.com',1,'',0,'http://www.stileproject.com','','','','',1,1,0,'Administrator',0,996120694,1,-1,1030996168,1031027028,1030599436,36,'-6',0,'','','',1,0,1,0,0,15,'0000-00-00',-1,1,'64.0.0.0',0,1,-1,0,0,4,19,1);
SELECT DISTINCT t1.*, t2.* FROM t1 LEFT JOIN t2 ON (t2.userid = t1.touserid);
privatemessageid folderid userid touserid fromuserid title message dateline showsignature iconid messageread readtime receipt deleteprompt multiplerecipients userid usergroupid username password email styleid parentemail coppauser homepage icq aim yahoo signature adminemail showemail invisible usertitle customtitle joindate cookieuser daysprune lastvisit lastactivity lastpost posts timezoneoffset emailnotification buddylist ignorelist pmfolders receivepm emailonpm pmpopup avatarid avatarrevision options birthday maxposts startofweek ipaddress referrerid nosessionhash autorefresh messagepopup inforum ratenum ratetotal allowrate
@@ -418,7 +418,7 @@ SELECT DISTINCT t1.a, t2.b FROM t1, t2 WHERE t1.a=1 ORDER BY t2.c;
a b
1 4
DROP TABLE t1,t2;
-CREATE table t1 ( `id` int(11) NOT NULL auto_increment, `name` varchar(50) NOT NULL default '', PRIMARY KEY (`id`)) TYPE=MyISAM AUTO_INCREMENT=3 ;
+CREATE table t1 ( `id` int(11) NOT NULL auto_increment, `name` varchar(50) NOT NULL default '', PRIMARY KEY (`id`)) ENGINE=MyISAM AUTO_INCREMENT=3 ;
INSERT INTO t1 VALUES (1, 'aaaaa');
INSERT INTO t1 VALUES (3, 'aaaaa');
INSERT INTO t1 VALUES (2, 'eeeeeee');
@@ -458,7 +458,7 @@ CREATE TABLE t1 (
html varchar(5) default NULL,
rin int(11) default '0',
out int(11) default '0'
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('1',1,0);
SELECT DISTINCT html,SUM(out)/(SUM(rin)+1) as 'prod' FROM t1 GROUP BY rin;
html prod
diff --git a/mysql-test/r/fulltext.result b/mysql-test/r/fulltext.result
index 191331e7a2a..04c36f059e2 100644
--- a/mysql-test/r/fulltext.result
+++ b/mysql-test/r/fulltext.result
@@ -218,7 +218,7 @@ t2 CREATE TABLE `t2` (
`inhalt` text,
KEY `tig` (`ticket`),
FULLTEXT KEY `tix` (`inhalt`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
select * from t2 where MATCH inhalt AGAINST (NULL);
ticket inhalt
select * from t2 where MATCH inhalt AGAINST ('foobar');
@@ -251,7 +251,7 @@ id int(11) auto_increment,
title varchar(100) default '',
PRIMARY KEY (id),
KEY ind5 (title)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE FULLTEXT INDEX ft1 ON t1(title);
insert into t1 (title) values ('this is a test');
select * from t1 where match title against ('test' in boolean mode);
@@ -267,7 +267,7 @@ id title
1 this test once revealed a bug
update t1 set title=NULL where id=1;
drop table t1;
-CREATE TABLE t1 (a int(11), b text, FULLTEXT KEY (b)) TYPE=MyISAM;
+CREATE TABLE t1 (a int(11), b text, FULLTEXT KEY (b)) ENGINE=MyISAM;
insert into t1 values (1,"I wonder why the fulltext index doesnt work?");
SELECT * from t1 where MATCH (b) AGAINST ('apples');
a b
@@ -277,7 +277,7 @@ a b
2 fullaaa fullzzz
1 I wonder why the fulltext index doesnt work?
drop table t1;
-CREATE TABLE t1 ( id int(11) NOT NULL auto_increment primary key, mytext text NOT NULL, FULLTEXT KEY mytext (mytext)) TYPE=MyISAM;
+CREATE TABLE t1 ( id int(11) NOT NULL auto_increment primary key, mytext text NOT NULL, FULLTEXT KEY mytext (mytext)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,'my small mouse'),(2,'la-la-la'),(3,'It is so funny'),(4,'MySQL Tutorial');
select 8 from t1;
8
diff --git a/mysql-test/r/fulltext2.result b/mysql-test/r/fulltext2.result
index 687bc6edfa0..0fdb7d4dbd1 100644
--- a/mysql-test/r/fulltext2.result
+++ b/mysql-test/r/fulltext2.result
@@ -3,7 +3,7 @@ CREATE TABLE t1 (
i int(10) unsigned not null auto_increment primary key,
a varchar(255) not null,
FULLTEXT KEY (a)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
repair table t1 quick;
Table Op Msg_type Msg_text
test.t1 repair status OK
@@ -108,7 +108,7 @@ CREATE TABLE t1 (
i int(10) unsigned not null auto_increment primary key,
a varchar(255) not null,
FULLTEXT KEY (a)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
select count(*) from t1 where match a against ('aaaxxx');
count(*)
260
diff --git a/mysql-test/r/fulltext_distinct.result b/mysql-test/r/fulltext_distinct.result
index abb4929d0ec..de0668ff28c 100644
--- a/mysql-test/r/fulltext_distinct.result
+++ b/mysql-test/r/fulltext_distinct.result
@@ -7,14 +7,14 @@ PRIMARY KEY (id),
KEY kt(tag),
KEY kv(value(15)),
FULLTEXT KEY kvf(value)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE t2 (
id_t2 mediumint unsigned NOT NULL default '0',
id_t1 mediumint unsigned NOT NULL default '0',
field_number tinyint unsigned NOT NULL default '0',
PRIMARY KEY (id_t2,id_t1,field_number),
KEY id_t1(id_t1)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (tag,value) VALUES ('foo123','bar111');
INSERT INTO t1 (tag,value) VALUES ('foo123','bar222');
INSERT INTO t1 (tag,value) VALUES ('bar345','baz333 ar');
diff --git a/mysql-test/r/fulltext_left_join.result b/mysql-test/r/fulltext_left_join.result
index d215ea0cea8..bf3fe73690a 100644
--- a/mysql-test/r/fulltext_left_join.result
+++ b/mysql-test/r/fulltext_left_join.result
@@ -31,9 +31,9 @@ match(t1.texte,t1.sujet,t1.motsclefs) against('droit' IN BOOLEAN MODE)
1
0
drop table t1, t2;
-create table t1 (venue_id int(11) default null, venue_text varchar(255) default null, dt datetime default null) type=myisam;
+create table t1 (venue_id int(11) default null, venue_text varchar(255) default null, dt datetime default null) engine=myisam;
insert into t1 (venue_id, venue_text, dt) values (1, 'a1', '2003-05-23 19:30:00'),(null, 'a2', '2003-05-23 19:30:00');
-create table t2 (name varchar(255) not null default '', entity_id int(11) not null auto_increment, primary key (entity_id), fulltext key name (name)) type=myisam;
+create table t2 (name varchar(255) not null default '', entity_id int(11) not null auto_increment, primary key (entity_id), fulltext key name (name)) engine=myisam;
insert into t2 (name, entity_id) values ('aberdeen town hall', 1), ('glasgow royal concert hall', 2), ('queen\'s hall, edinburgh', 3);
select * from t1 left join t2 on venue_id = entity_id where match(name) against('aberdeen' in boolean mode) and dt = '2003-05-23 19:30:00';
venue_id venue_text dt name entity_id
diff --git a/mysql-test/r/func_compress.result b/mysql-test/r/func_compress.result
index 461fc1018c1..1fcda7748b3 100644
--- a/mysql-test/r/func_compress.result
+++ b/mysql-test/r/func_compress.result
@@ -26,7 +26,7 @@ uncompressed_length(compress(@test_compress_string))
select length(compress(@test_compress_string))<length(@test_compress_string);
length(compress(@test_compress_string))<length(@test_compress_string)
1
-create table t1 (a text, b char(255), c char(4)) type=myisam;
+create table t1 (a text, b char(255), c char(4)) engine=myisam;
insert into t1 (a,b,c) values (compress(@test_compress_string),compress(@test_compress_string),'d ');
select uncompress(a) from t1;
uncompress(a)
diff --git a/mysql-test/r/func_date_add.result b/mysql-test/r/func_date_add.result
index 234fded9a68..f4091ff4c0e 100644
--- a/mysql-test/r/func_date_add.result
+++ b/mysql-test/r/func_date_add.result
@@ -6,7 +6,7 @@ hits int(10) unsigned DEFAULT '0' NOT NULL,
sessions int(10) unsigned DEFAULT '0' NOT NULL,
ts timestamp(14),
PRIMARY KEY (visitor_id,group_id)
-)/*! type=MyISAM */;
+)/*! engine=MyISAM */;
INSERT INTO t1 VALUES (465931136,7,2,2,20000318160952);
INSERT INTO t1 VALUES (173865424,2,2,2,20000318233615);
INSERT INTO t1 VALUES (173865424,8,2,2,20000318233615);
diff --git a/mysql-test/r/func_group.result b/mysql-test/r/func_group.result
index 7ae3bbb0608..bdac40d3378 100644
--- a/mysql-test/r/func_group.result
+++ b/mysql-test/r/func_group.result
@@ -608,7 +608,7 @@ id select_type table type possible_keys key key_len ref rows Extra
Warnings:
Note 1003 select high_priority big_result test.t1.a AS `a`,count(test.t1.b) AS `count(b)`,sum(test.t1.b) AS `sum(b)`,avg(test.t1.b) AS `avg(b)`,std(test.t1.b) AS `std(b)`,min(test.t1.b) AS `min(b)`,max(test.t1.b) AS `max(b)`,bit_and(test.t1.b) AS `bit_and(b)`,bit_or(test.t1.b) AS `bit_or(b)`,bit_xor(test.t1.b) AS `bit_xor(b)` from test.t1 group by test.t1.a
drop table t1;
-create table t1 (USR_ID integer not null, MAX_REQ integer not null, constraint PK_SEA_USER primary key (USR_ID)) type=InnoDB;
+create table t1 (USR_ID integer not null, MAX_REQ integer not null, constraint PK_SEA_USER primary key (USR_ID)) engine=InnoDB;
insert into t1 values (1, 3);
select count(*) + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ from t1 group by MAX_REQ;
count(*) + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ
diff --git a/mysql-test/r/func_if.result b/mysql-test/r/func_if.result
index 64070179395..bea16c07f86 100644
--- a/mysql-test/r/func_if.result
+++ b/mysql-test/r/func_if.result
@@ -2,7 +2,7 @@ drop table if exists t1;
select IF(0,"ERROR","this"),IF(1,"is","ERROR"),IF(NULL,"ERROR","a"),IF(1,2,3)|0,IF(1,2.0,3.0)+0 ;
IF(0,"ERROR","this") IF(1,"is","ERROR") IF(NULL,"ERROR","a") IF(1,2,3)|0 IF(1,2.0,3.0)+0
this is a 2 2.0
-CREATE TABLE t1 (st varchar(255) NOT NULL, u int(11) NOT NULL) TYPE=MyISAM;
+CREATE TABLE t1 (st varchar(255) NOT NULL, u int(11) NOT NULL) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('a',1),('A',1),('aa',1),('AA',1),('a',1),('aaa',0),('BBB',0);
select if(1,st,st) s from t1 order by s;
s
diff --git a/mysql-test/r/func_str.result b/mysql-test/r/func_str.result
index 64b6d7e65f9..ac075e129ee 100644
--- a/mysql-test/r/func_str.result
+++ b/mysql-test/r/func_str.result
@@ -239,7 +239,7 @@ created datetime default NULL,
modified timestamp(14) NOT NULL,
bugstatus int(10) unsigned default NULL,
submitter int(10) unsigned default NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,'Link',1,1,1,'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa','2001-02-28 08:40:16',20010228084016,0,4);
SELECT CONCAT('"',CONCAT_WS('";"',title,prio,category,program,bugdesc,created,modified+0,bugstatus,submitter), '"') FROM t1;
CONCAT('"',CONCAT_WS('";"',title,prio,category,program,bugdesc,created,modified+0,bugstatus,submitter), '"')
@@ -254,7 +254,7 @@ SELECT bugdesc, REPLACE(bugdesc, 'xxxxxxxxxxxxxxxxxxxx', 'bbbbbbbbbbbbbbbbbbbb')
bugdesc REPLACE(bugdesc, 'xxxxxxxxxxxxxxxxxxxx', 'bbbbbbbbbbbbbbbbbbbb')
aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa
drop table t1;
-CREATE TABLE t1 (id int(11) NOT NULL auto_increment, tmp text NOT NULL, KEY id (id)) TYPE=MyISAM;
+CREATE TABLE t1 (id int(11) NOT NULL auto_increment, tmp text NOT NULL, KEY id (id)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1, 'a545f661efdd1fb66fdee3aab79945bf');
SELECT 1 FROM t1 WHERE tmp=AES_DECRYPT(tmp,"password");
1
@@ -539,7 +539,7 @@ t1 CREATE TABLE `t1` (
`substring(_latin2'ab',1)` char(2) character set latin2 NOT NULL default '',
`insert(_latin2'abcd',2,3,_latin2'ef')` char(6) character set latin2 NOT NULL default '',
`replace(_latin2'abcd',_latin2'b',_latin2'B')` char(4) character set latin2 NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
select SUBSTR('abcdefg',3,2);
SUBSTR('abcdefg',3,2)
@@ -580,7 +580,7 @@ elt(status_wnio,data_podp)
NULL
NULL
DROP TABLE t1;
-CREATE TABLE t1 (title text) TYPE=MyISAM;
+CREATE TABLE t1 (title text) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('Congress reconvenes in September to debate welfare and adult education');
INSERT INTO t1 VALUES ('House passes the CAREERS bill');
SELECT CONCAT("</a>",RPAD("",(55 - LENGTH(title)),".")) from t1;
diff --git a/mysql-test/r/func_system.result b/mysql-test/r/func_system.result
index d045d4865dc..a0437ca1c56 100644
--- a/mysql-test/r/func_system.result
+++ b/mysql-test/r/func_system.result
@@ -49,7 +49,7 @@ t1 CREATE TABLE `t1` (
`database()` char(34) character set utf8 NOT NULL default '',
`user()` char(77) character set utf8 NOT NULL default '',
`version` char(40) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
select TRUE,FALSE,NULL;
TRUE FALSE NULL
diff --git a/mysql-test/r/func_test.result b/mysql-test/r/func_test.result
index 4951d954abb..4bb2e067f9c 100644
--- a/mysql-test/r/func_test.result
+++ b/mysql-test/r/func_test.result
@@ -157,9 +157,9 @@ select _koi8r'a' COLLATE koi8r_general_ci LIKE _koi8r'A' COLLATE koi8r_bin;
ERROR HY000: Illegal mix of collations (koi8r_general_ci,EXPLICIT) and (koi8r_bin,EXPLICIT) for operation 'like'
select _koi8r'a' LIKE _latin1'A';
ERROR HY000: Illegal mix of collations (koi8r_general_ci,COERCIBLE) and (latin1_swedish_ci,COERCIBLE) for operation 'like'
-CREATE TABLE t1 ( faq_group_id int(11) NOT NULL default '0', faq_id int(11) NOT NULL default '0', title varchar(240) default NULL, keywords text, description longblob, solution longblob, status tinyint(4) NOT NULL default '0', access_id smallint(6) default NULL, lang_id smallint(6) NOT NULL default '0', created datetime NOT NULL default '0000-00-00 00:00:00', updated datetime default NULL, last_access datetime default NULL, last_notify datetime default NULL, solved_count int(11) NOT NULL default '0', static_solved int(11) default NULL, solved_1 int(11) default NULL, solved_2 int(11) default NULL, solved_3 int(11) default NULL, solved_4 int(11) default NULL, solved_5 int(11) default NULL, expires datetime default NULL, notes text, assigned_to smallint(6) default NULL, assigned_group smallint(6) default NULL, last_edited_by smallint(6) default NULL, orig_ref_no varchar(15) binary default NULL, c$fundstate smallint(6) default NULL, c$contributor smallint(6) default NULL, UNIQUE KEY t1$faq_id (faq_id), KEY t1$group_id$faq_id (faq_group_id,faq_id), KEY t1$c$fundstate (c$fundstate) ) TYPE=MyISAM;
+CREATE TABLE t1 ( faq_group_id int(11) NOT NULL default '0', faq_id int(11) NOT NULL default '0', title varchar(240) default NULL, keywords text, description longblob, solution longblob, status tinyint(4) NOT NULL default '0', access_id smallint(6) default NULL, lang_id smallint(6) NOT NULL default '0', created datetime NOT NULL default '0000-00-00 00:00:00', updated datetime default NULL, last_access datetime default NULL, last_notify datetime default NULL, solved_count int(11) NOT NULL default '0', static_solved int(11) default NULL, solved_1 int(11) default NULL, solved_2 int(11) default NULL, solved_3 int(11) default NULL, solved_4 int(11) default NULL, solved_5 int(11) default NULL, expires datetime default NULL, notes text, assigned_to smallint(6) default NULL, assigned_group smallint(6) default NULL, last_edited_by smallint(6) default NULL, orig_ref_no varchar(15) binary default NULL, c$fundstate smallint(6) default NULL, c$contributor smallint(6) default NULL, UNIQUE KEY t1$faq_id (faq_id), KEY t1$group_id$faq_id (faq_group_id,faq_id), KEY t1$c$fundstate (c$fundstate) ) ENGINE=MyISAM;
INSERT INTO t1 VALUES (82,82,'How to use the DynaVox Usage Counts Feature','usages count, number, corner, white, box, button','<as-html>\r\n<table width=\"100%\" border=\"0\">\r\n <tr>\r\n <td width=\"3%\"> </td>\r\n <td width=\"97%\">\r\n <h3><font face=\"Verdana, Arial, Helvetica, sans-serif\" color=\"#000000\">How \r\n To</font><!-- #BeginEditable \"CS_troubleshoot_question\" --><font face=\"Verdana, Arial, Helvetica, sans-serif\" color=\"#000099\"><font color=\"#000000\">: \r\n Display or Hide the Usage Counts to find out how many times each button is being selected. </font></font><!-- #EndEditable --></h3>\r\n </td>\r\n </tr>\r\n</table>','<as-html>\r\n <table width=\"100%\" border=\"0\">\r\n <tr>\r\n <td width=\"3%\"> </td>\r\n \r\n<td width=\"97%\"><!-- #BeginEditable \"CS_troubleshoot_answer\" --> \r\n \r\n<p><font color=\"#000000\" face=\"Verdana, Arial, Helvetica, sans-serif\">1. Select \r\n the <i>On/Setup</i> button to access the DynaVox Setup Menu.<br>\r\n 2. Select <b>Button Features.</b><br>\r\n 3. Below the <b>OK</b> button is the <b>Usage Counts</b> button.<br>\r\n a. If it says \"Hidden\" then the Usage Counts will not be displayed.<br>\r\n b. If it says \"Displayed\" then the Usage Counts will be shown.<br>\r\n c. Select the <b>Usage Counts</b> Option Ring once and it will toggle \r\n to the alternative option.<br>\r\n 4. Once the correct setting has been chosen, select <b>OK</b> to leave the <i>Button \r\n Features</i> menu.<br>\r\n 5. Select <b>OK</b> out of the <i>Setup</i> menu and return to the communication \r\n page.</font></p>\r\n <p><font color=\"#000000\" face=\"Verdana, Arial, Helvetica, sans-serif\">For \r\n further information on <i>Usage Counts,</i> see the <i>Button Features \r\n Menu Entry</i> in the DynaVox/DynaMyte Reference Manual.</font></p>\r\n<!-- #EndEditable --></td>\r\n </tr>\r\n</table>',4,1,1,'2001-11-16 16:43:34','2002-11-25 12:09:43','2003-07-24 01:04:48',NULL,11,NULL,0,0,0,0,0,NULL,NULL,NULL,NULL,11,NULL,NULL,NULL);
-CREATE TABLE t2 ( access_id smallint(6) NOT NULL default '0', name varchar(20) binary default NULL, rank smallint(6) NOT NULL default '0', KEY t2$access_id (access_id) ) TYPE=MyISAM;
+CREATE TABLE t2 ( access_id smallint(6) NOT NULL default '0', name varchar(20) binary default NULL, rank smallint(6) NOT NULL default '0', KEY t2$access_id (access_id) ) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,'Everyone',2),(2,'Help',3),(3,'Customer Support',1);
SELECT f_acc.rank, a1.rank, a2.rank FROM t1 LEFT JOIN t1 f1 ON (f1.access_id=1 AND f1.faq_group_id = t1.faq_group_id) LEFT JOIN t2 a1 ON (a1.access_id = f1.access_id) LEFT JOIN t1 f2 ON (f2.access_id=3 AND f2.faq_group_id = t1.faq_group_id) LEFT JOIN t2 a2 ON (a2.access_id = f2.access_id), t2 f_acc WHERE LEAST(a1.rank,a2.rank) = f_acc.rank;
rank rank rank
diff --git a/mysql-test/r/func_time.result b/mysql-test/r/func_time.result
index feaebc9b514..b3c3d8dff5c 100644
--- a/mysql-test/r/func_time.result
+++ b/mysql-test/r/func_time.result
@@ -353,7 +353,7 @@ monthname(date)
NULL
January
drop table t1,t2;
-CREATE TABLE t1 (updated text) TYPE=MyISAM;
+CREATE TABLE t1 (updated text) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('');
SELECT month(updated) from t1;
month(updated)
diff --git a/mysql-test/r/gis-rtree.result b/mysql-test/r/gis-rtree.result
index ca54ec59938..2a47d0c048d 100644
--- a/mysql-test/r/gis-rtree.result
+++ b/mysql-test/r/gis-rtree.result
@@ -3,7 +3,7 @@ CREATE TABLE t1 (
fid INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
g GEOMETRY NOT NULL,
SPATIAL KEY(g)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
@@ -11,7 +11,7 @@ t1 CREATE TABLE `t1` (
`g` geometry NOT NULL default '',
PRIMARY KEY (`fid`),
SPATIAL KEY `g` (`g`(32))
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
INSERT INTO t1 (g) VALUES (GeomFromText('LineString(150 150, 150 150)'));
INSERT INTO t1 (g) VALUES (GeomFromText('LineString(149 149, 151 151)'));
INSERT INTO t1 (g) VALUES (GeomFromText('LineString(148 148, 152 152)'));
@@ -185,7 +185,7 @@ DROP TABLE t1;
CREATE TABLE t2 (
fid INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
g GEOMETRY NOT NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 (g) VALUES (GeometryFromWKB(LineString(Point(10 * 10 - 9, 10 * 10 - 9), Point(10 * 10, 10 * 10))));
INSERT INTO t2 (g) VALUES (GeometryFromWKB(LineString(Point(10 * 10 - 9, 9 * 10 - 9), Point(10 * 10, 9 * 10))));
INSERT INTO t2 (g) VALUES (GeometryFromWKB(LineString(Point(10 * 10 - 9, 8 * 10 - 9), Point(10 * 10, 8 * 10))));
@@ -294,7 +294,7 @@ t2 CREATE TABLE `t2` (
`g` geometry NOT NULL default '',
PRIMARY KEY (`fid`),
SPATIAL KEY `g` (`g`(32))
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
SELECT count(*) FROM t2;
count(*)
100
diff --git a/mysql-test/r/group_by.result b/mysql-test/r/group_by.result
index b9eaa81ba2a..853260a0164 100644
--- a/mysql-test/r/group_by.result
+++ b/mysql-test/r/group_by.result
@@ -476,13 +476,13 @@ c2id int(11) unsigned default NULL,
value int(11) unsigned NOT NULL default '0',
UNIQUE KEY pid2 (pid,c1id,c2id),
UNIQUE KEY pid (pid,value)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1, 1, NULL, 1),(1, 2, NULL, 2),(1, NULL, 3, 3),(1, 4, NULL, 4),(1, 5, NULL, 5);
CREATE TABLE t2 (
id int(11) unsigned NOT NULL default '0',
active enum('Yes','No') NOT NULL default 'Yes',
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1, 'Yes'),(2, 'No'),(4, 'Yes'),(5, 'No');
CREATE TABLE t3 (
id int(11) unsigned NOT NULL default '0',
diff --git a/mysql-test/r/handler.result b/mysql-test/r/handler.result
index 78ccf941b88..d0ea16c5699 100644
--- a/mysql-test/r/handler.result
+++ b/mysql-test/r/handler.result
@@ -144,7 +144,7 @@ insert into t1 values (17);
handler t2 read first;
ERROR 42S02: Unknown table 't2' in HANDLER
handler t1 open as t2;
-alter table t1 type=MyISAM;
+alter table t1 engine=MyISAM;
handler t2 read first;
ERROR 42S02: Unknown table 't2' in HANDLER
drop table t1;
diff --git a/mysql-test/r/heap.result b/mysql-test/r/heap.result
index 6c5ef8f3441..c3fbd73ac42 100644
--- a/mysql-test/r/heap.result
+++ b/mysql-test/r/heap.result
@@ -1,5 +1,5 @@
drop table if exists t1;
-create table t1 (a int not null,b int not null, primary key (a)) type=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
+create table t1 (a int not null,b int not null, primary key (a)) engine=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
insert into t1 values(1,1),(2,2),(3,3),(4,4);
delete from t1 where a=1 or a=0;
show keys from t1;
@@ -23,15 +23,15 @@ a b
4 6
alter table t1 add c int not null, add key (c,a);
drop table t1;
-create table t1 (a int not null,b int not null, primary key (a)) type=memory comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key (a)) engine=memory comment="testing heaps";
insert into t1 values(1,1),(2,2),(3,3),(4,4);
delete from t1 where a > 0;
select * from t1;
a b
drop table t1;
-create table t1 (a int not null,b int not null, primary key (a)) type=heap comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key (a)) engine=heap comment="testing heaps";
insert into t1 values(1,1),(2,2),(3,3),(4,4);
-alter table t1 modify a int not null auto_increment, type=myisam, comment="new myisam table";
+alter table t1 modify a int not null auto_increment, engine=myisam, comment="new myisam table";
select * from t1;
a b
1 1
@@ -39,7 +39,7 @@ a b
3 3
4 4
drop table t1;
-create table t1 (a int not null) type=heap;
+create table t1 (a int not null) engine=heap;
insert into t1 values (869751),(736494),(226312),(802616);
select * from t1 where a > 736494;
a
@@ -63,13 +63,13 @@ a
736494
802616
869751
-alter table t1 type=myisam;
+alter table t1 engine=myisam;
explain select * from t1 where a in (869751,736494,226312,802616);
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range uniq_id uniq_id 4 NULL 4 Using where; Using index
drop table t1;
create table t1 (x int not null, y int not null, key x (x), unique y (y))
-type=heap;
+engine=heap;
insert into t1 values (1,1),(2,2),(1,3),(2,4),(2,5),(2,6);
select * from t1 where x=1;
x y
@@ -88,13 +88,13 @@ id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 ALL x NULL NULL NULL 6
1 SIMPLE t2 eq_ref y y 4 test.t1.x 1
drop table t1;
-create table t1 (a int) type=heap;
+create table t1 (a int) engine=heap;
insert into t1 values(1);
select max(a) from t1;
max(a)
1
drop table t1;
-CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key(a), key(b) ) TYPE=HEAP;
+CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key(a), key(b) ) ENGINE=HEAP;
insert into t1 values(1,1),(1,2),(2,3),(1,3),(1,4),(1,5),(1,6);
select * from t1 where a=1;
a b
@@ -120,7 +120,7 @@ a b
1 2
1 1
drop table t1;
-create table t1 (id int unsigned not null, primary key (id)) type=HEAP;
+create table t1 (id int unsigned not null, primary key (id)) engine=HEAP;
insert into t1 values(1);
select max(id) from t1;
max(id)
@@ -131,12 +131,12 @@ max(id)
2
replace into t1 values(1);
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table if exists t1;
CREATE table t1(f1 int not null,f2 char(20) not
-null,index(f2)) type=heap;
+null,index(f2)) engine=heap;
INSERT into t1 set f1=12,f2="bill";
INSERT into t1 set f1=13,f2="bill";
INSERT into t1 set f1=14,f2="bill";
@@ -155,7 +155,7 @@ f1 f2
12 ted
12 ted
drop table t1;
-create table t1 (btn char(10) not null, key(btn)) type=heap;
+create table t1 (btn char(10) not null, key(btn)) engine=heap;
insert into t1 values ("hello"),("hello"),("hello"),("hello"),("hello"),("a"),("b"),("c"),("d"),("e"),("f"),("g"),("h"),("i");
explain select * from t1 where btn like "q%";
id select_type table type possible_keys key key_len ref rows Extra
@@ -176,7 +176,7 @@ a int default NULL,
b int default NULL,
KEY a (a),
UNIQUE b (b)
-) type=heap;
+) engine=heap;
INSERT INTO t1 VALUES (NULL,99),(99,NULL),(1,1),(2,2),(1,3);
SELECT * FROM t1 WHERE a=NULL;
a b
@@ -200,7 +200,7 @@ DROP TABLE t1;
CREATE TABLE t1 (
a int default NULL,
key a (a)
-) TYPE=HEAP;
+) ENGINE=HEAP;
INSERT INTO t1 VALUES (10), (10), (10);
EXPLAIN SELECT * FROM t1 WHERE a=10;
id select_type table type possible_keys key key_len ref rows Extra
@@ -211,7 +211,7 @@ a
10
10
DROP TABLE t1;
-CREATE TABLE t1 (a int not null, primary key(a)) type=heap;
+CREATE TABLE t1 (a int not null, primary key(a)) engine=heap;
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
DELETE from t1 where a < 100;
SELECT * from t1;
diff --git a/mysql-test/r/heap_auto_increment.result b/mysql-test/r/heap_auto_increment.result
index 9a5ed57d741..5b04a77e9eb 100644
--- a/mysql-test/r/heap_auto_increment.result
+++ b/mysql-test/r/heap_auto_increment.result
@@ -1,5 +1,5 @@
drop table if exists t1;
-create table t1 (a int not null auto_increment,b int, primary key (a)) type=heap auto_increment=3;
+create table t1 (a int not null auto_increment,b int, primary key (a)) engine=heap auto_increment=3;
insert into t1 values (1,1),(NULL,3),(NULL,4);
delete from t1 where a=4;
insert into t1 values (NULL,5),(NULL,6);
@@ -27,7 +27,7 @@ drop table t1;
create table t1 (
skey tinyint unsigned NOT NULL auto_increment PRIMARY KEY,
sval char(20)
-) type=heap;
+) engine=heap;
insert into t1 values (NULL, "hello");
insert into t1 values (NULL, "hey");
select * from t1;
diff --git a/mysql-test/r/heap_btree.result b/mysql-test/r/heap_btree.result
index c42c5e60675..ef63b1d4e00 100644
--- a/mysql-test/r/heap_btree.result
+++ b/mysql-test/r/heap_btree.result
@@ -1,5 +1,5 @@
drop table if exists t1;
-create table t1 (a int not null,b int not null, primary key using BTREE (a)) type=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
+create table t1 (a int not null,b int not null, primary key using BTREE (a)) engine=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
insert into t1 values(1,1),(2,2),(3,3),(4,4);
delete from t1 where a=1 or a=0;
show keys from t1;
@@ -23,15 +23,15 @@ a b
4 6
alter table t1 add c int not null, add key using BTREE (c,a);
drop table t1;
-create table t1 (a int not null,b int not null, primary key using BTREE (a)) type=heap comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key using BTREE (a)) engine=heap comment="testing heaps";
insert into t1 values(-2,-2),(-1,-1),(0,0),(1,1),(2,2),(3,3),(4,4);
delete from t1 where a > -3;
select * from t1;
a b
drop table t1;
-create table t1 (a int not null,b int not null, primary key using BTREE (a)) type=heap comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key using BTREE (a)) engine=heap comment="testing heaps";
insert into t1 values(1,1),(2,2),(3,3),(4,4);
-alter table t1 modify a int not null auto_increment, type=myisam, comment="new myisam table";
+alter table t1 modify a int not null auto_increment, engine=myisam, comment="new myisam table";
select * from t1;
a b
1 1
@@ -39,7 +39,7 @@ a b
3 3
4 4
drop table t1;
-create table t1 (a int not null) type=heap;
+create table t1 (a int not null) engine=heap;
insert into t1 values (869751),(736494),(226312),(802616);
select * from t1 where a > 736494;
a
@@ -63,13 +63,13 @@ a
736494
802616
869751
-alter table t1 type=myisam;
+alter table t1 engine=myisam;
explain select * from t1 where a in (869751,736494,226312,802616);
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range uniq_id uniq_id 4 NULL 4 Using where; Using index
drop table t1;
create table t1 (x int not null, y int not null, key x using BTREE (x,y), unique y using BTREE (y))
-type=heap;
+engine=heap;
insert into t1 values (1,1),(2,2),(1,3),(2,4),(2,5),(2,6);
explain select * from t1 where x=1;
id select_type table type possible_keys key key_len ref rows Extra
@@ -91,13 +91,13 @@ id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 ALL x NULL NULL NULL 6
1 SIMPLE t2 eq_ref y y 4 test.t1.x 1
drop table t1;
-create table t1 (a int) type=heap;
+create table t1 (a int) engine=heap;
insert into t1 values(1);
select max(a) from t1;
max(a)
1
drop table t1;
-CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key using BTREE (a,b), key using BTREE (b) ) TYPE=HEAP;
+CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key using BTREE (a,b), key using BTREE (b) ) ENGINE=HEAP;
insert into t1 values(1,1),(1,2),(2,3),(1,3),(1,4),(1,5),(1,6);
select * from t1 where a=1;
a b
@@ -136,7 +136,7 @@ explain select * from tx where b=x;
id select_type table type possible_keys key key_len ref rows Extra
x SIMPLE tx ref b b x const x Using where
drop table t1;
-create table t1 (id int unsigned not null, primary key using BTREE (id)) type=HEAP;
+create table t1 (id int unsigned not null, primary key using BTREE (id)) engine=HEAP;
insert into t1 values(1);
select max(id) from t1;
max(id)
@@ -147,12 +147,12 @@ max(id)
2
replace into t1 values(1);
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table if exists t1;
CREATE table t1(f1 int not null,f2 char(20) not
-null,index(f2)) type=heap;
+null,index(f2)) engine=heap;
INSERT into t1 set f1=12,f2="bill";
INSERT into t1 set f1=13,f2="bill";
INSERT into t1 set f1=14,f2="bill";
@@ -171,7 +171,7 @@ f1 f2
12 ted
12 ted
drop table t1;
-create table t1 (btn char(10) not null, key using BTREE (btn)) type=heap;
+create table t1 (btn char(10) not null, key using BTREE (btn)) engine=heap;
insert into t1 values ("hello"),("hello"),("hello"),("hello"),("hello"),("a"),("b"),("c"),("d"),("e"),("f"),("g"),("h"),("i");
explain select * from t1 where btn like "q%";
id select_type table type possible_keys key key_len ref rows Extra
@@ -192,7 +192,7 @@ a int default NULL,
b int default NULL,
KEY a using BTREE (a),
UNIQUE b using BTREE (b)
-) type=heap;
+) engine=heap;
INSERT INTO t1 VALUES (NULL,99),(99,NULL),(1,1),(2,2),(1,3);
SELECT * FROM t1 WHERE a=NULL;
a b
@@ -213,7 +213,7 @@ a b
INSERT INTO t1 VALUES (1,3);
ERROR 23000: Duplicate entry '3' for key 1
DROP TABLE t1;
-CREATE TABLE t1 (a int, b int, c int, key using BTREE (a, b, c)) type=heap;
+CREATE TABLE t1 (a int, b int, c int, key using BTREE (a, b, c)) engine=heap;
INSERT INTO t1 VALUES (1, NULL, NULL), (1, 1, NULL), (1, NULL, 1);
SELECT * FROM t1 WHERE a=1 and b IS NULL;
a b c
@@ -227,7 +227,7 @@ SELECT * FROM t1 WHERE a=1 and b IS NULL and c IS NULL;
a b c
1 NULL NULL
DROP TABLE t1;
-CREATE TABLE t1 (a int not null, primary key using BTREE (a)) type=heap;
+CREATE TABLE t1 (a int not null, primary key using BTREE (a)) engine=heap;
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
DELETE from t1 where a < 100;
SELECT * from t1;
diff --git a/mysql-test/r/heap_hash.result b/mysql-test/r/heap_hash.result
index 7ecd1db7447..7affbf788fb 100644
--- a/mysql-test/r/heap_hash.result
+++ b/mysql-test/r/heap_hash.result
@@ -1,5 +1,5 @@
drop table if exists t1;
-create table t1 (a int not null,b int not null, primary key using HASH (a)) type=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
+create table t1 (a int not null,b int not null, primary key using HASH (a)) engine=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
insert into t1 values(1,1),(2,2),(3,3),(4,4);
delete from t1 where a=1 or a=0;
show keys from t1;
@@ -23,15 +23,15 @@ a b
4 6
alter table t1 add c int not null, add key using HASH (c,a);
drop table t1;
-create table t1 (a int not null,b int not null, primary key using HASH (a)) type=heap comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key using HASH (a)) engine=heap comment="testing heaps";
insert into t1 values(1,1),(2,2),(3,3),(4,4);
delete from t1 where a > 0;
select * from t1;
a b
drop table t1;
-create table t1 (a int not null,b int not null, primary key using HASH (a)) type=heap comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key using HASH (a)) engine=heap comment="testing heaps";
insert into t1 values(1,1),(2,2),(3,3),(4,4);
-alter table t1 modify a int not null auto_increment, type=myisam, comment="new myisam table";
+alter table t1 modify a int not null auto_increment, engine=myisam, comment="new myisam table";
select * from t1;
a b
1 1
@@ -39,7 +39,7 @@ a b
3 3
4 4
drop table t1;
-create table t1 (a int not null) type=heap;
+create table t1 (a int not null) engine=heap;
insert into t1 values (869751),(736494),(226312),(802616);
select * from t1 where a > 736494;
a
@@ -63,13 +63,13 @@ a
736494
802616
869751
-alter table t1 type=myisam;
+alter table t1 engine=myisam;
explain select * from t1 where a in (869751,736494,226312,802616);
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range uniq_id uniq_id 4 NULL 4 Using where; Using index
drop table t1;
create table t1 (x int not null, y int not null, key x using HASH (x), unique y using HASH (y))
-type=heap;
+engine=heap;
insert into t1 values (1,1),(2,2),(1,3),(2,4),(2,5),(2,6);
select * from t1 where x=1;
x y
@@ -88,13 +88,13 @@ id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 ALL x NULL NULL NULL 6
1 SIMPLE t2 eq_ref y y 4 test.t1.x 1
drop table t1;
-create table t1 (a int) type=heap;
+create table t1 (a int) engine=heap;
insert into t1 values(1);
select max(a) from t1;
max(a)
1
drop table t1;
-CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key using HASH (a), key using HASH (b) ) TYPE=HEAP;
+CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key using HASH (a), key using HASH (b) ) ENGINE=HEAP;
insert into t1 values(1,1),(1,2),(2,3),(1,3),(1,4),(1,5),(1,6);
select * from t1 where a=1;
a b
@@ -120,7 +120,7 @@ a b
1 2
1 1
drop table t1;
-create table t1 (id int unsigned not null, primary key using HASH (id)) type=HEAP;
+create table t1 (id int unsigned not null, primary key using HASH (id)) engine=HEAP;
insert into t1 values(1);
select max(id) from t1;
max(id)
@@ -131,12 +131,12 @@ max(id)
2
replace into t1 values(1);
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table if exists t1;
CREATE table t1(f1 int not null,f2 char(20) not
-null,index(f2)) type=heap;
+null,index(f2)) engine=heap;
INSERT into t1 set f1=12,f2="bill";
INSERT into t1 set f1=13,f2="bill";
INSERT into t1 set f1=14,f2="bill";
@@ -155,7 +155,7 @@ f1 f2
12 ted
12 ted
drop table t1;
-create table t1 (btn char(10) not null, key using HASH (btn)) type=heap;
+create table t1 (btn char(10) not null, key using HASH (btn)) engine=heap;
insert into t1 values ("hello"),("hello"),("hello"),("hello"),("hello"),("a"),("b"),("c"),("d"),("e"),("f"),("g"),("h"),("i");
explain select * from t1 where btn like "q%";
id select_type table type possible_keys key key_len ref rows Extra
@@ -176,7 +176,7 @@ a int default NULL,
b int default NULL,
KEY a using HASH (a),
UNIQUE b using HASH (b)
-) type=heap;
+) engine=heap;
INSERT INTO t1 VALUES (NULL,99),(99,NULL),(1,1),(2,2),(1,3);
SELECT * FROM t1 WHERE a=NULL;
a b
@@ -197,7 +197,7 @@ a b
INSERT INTO t1 VALUES (1,3);
ERROR 23000: Duplicate entry '3' for key 1
DROP TABLE t1;
-CREATE TABLE t1 (a int not null, primary key using HASH (a)) type=heap;
+CREATE TABLE t1 (a int not null, primary key using HASH (a)) engine=heap;
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
DELETE from t1 where a < 100;
SELECT * from t1;
diff --git a/mysql-test/r/help.result b/mysql-test/r/help.result
index d22539b2bcb..edf7d0e91cb 100644
--- a/mysql-test/r/help.result
+++ b/mysql-test/r/help.result
@@ -132,10 +132,10 @@ help 'impossible_category_1';
source_category_name name is_it_category
impossible_category_1 impossible_function_1 N
impossible_category_1 impossible_function_2 N
-alter table mysql.help_relation type=innodb;
-alter table mysql.help_keyword type=innodb;
-alter table mysql.help_topic type=innodb;
-alter table mysql.help_category type=innodb;
+alter table mysql.help_relation engine=innodb;
+alter table mysql.help_keyword engine=innodb;
+alter table mysql.help_topic engine=innodb;
+alter table mysql.help_category engine=innodb;
help 'function_of_my_dream';
name is_it_category
help '%possible_f%';
@@ -222,10 +222,10 @@ help 'impossible_category_1';
source_category_name name is_it_category
impossible_category_1 impossible_function_1 N
impossible_category_1 impossible_function_2 N
-alter table mysql.help_relation type=myisam;
-alter table mysql.help_keyword type=myisam;
-alter table mysql.help_topic type=myisam;
-alter table mysql.help_category type=myisam;
+alter table mysql.help_relation engine=myisam;
+alter table mysql.help_keyword engine=myisam;
+alter table mysql.help_topic engine=myisam;
+alter table mysql.help_category engine=myisam;
delete from mysql.help_topic where help_topic_id=@topic1_id;
delete from mysql.help_topic where help_topic_id=@topic2_id;
delete from mysql.help_topic where help_topic_id=@topic3_id;
diff --git a/mysql-test/r/innodb-deadlock.result b/mysql-test/r/innodb-deadlock.result
index e1b3e38b243..2ca82101fb4 100644
--- a/mysql-test/r/innodb-deadlock.result
+++ b/mysql-test/r/innodb-deadlock.result
@@ -1,5 +1,5 @@
drop table if exists t1,t2;
-create table t1 (id integer, x integer) type=INNODB;
+create table t1 (id integer, x integer) engine=INNODB;
insert into t1 values(0, 0);
set autocommit=0;
SELECT * from t1 where id = 0 FOR UPDATE;
@@ -18,8 +18,8 @@ id x
0 2
commit;
drop table t1;
-create table t1 (id integer, x integer) type=INNODB;
-create table t2 (b integer, a integer) type=INNODB;
+create table t1 (id integer, x integer) engine=INNODB;
+create table t2 (b integer, a integer) engine=INNODB;
insert into t1 values(0, 0), (300, 300);
insert into t2 values(0, 10), (1, 20), (2, 30);
commit;
@@ -54,8 +54,8 @@ id x
300 300
commit;
drop table t1, t2;
-create table t1 (id integer, x integer) type=INNODB;
-create table t2 (b integer, a integer) type=INNODB;
+create table t1 (id integer, x integer) engine=INNODB;
+create table t2 (b integer, a integer) engine=INNODB;
insert into t1 values(0, 0), (300, 300);
insert into t2 values(0, 0), (1, 20), (2, 30);
commit;
diff --git a/mysql-test/r/innodb.result b/mysql-test/r/innodb.result
index 0ebf3d50ab8..58c0042e122 100644
--- a/mysql-test/r/innodb.result
+++ b/mysql-test/r/innodb.result
@@ -1,6 +1,6 @@
drop table if exists t1,t2,t3,t4;
drop database if exists mysqltest;
-create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) type=innodb;
+create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) engine=innodb;
insert into t1 (code, name) values (1, 'Tim'), (1, 'Monty'), (2, 'David'), (2, 'Erik'), (3, 'Sasha'), (3, 'Jeremy'), (4, 'Matt');
select id, code, name from t1 order by id;
id code name
@@ -39,7 +39,7 @@ level tinyint(4) DEFAULT '0' NOT NULL,
PRIMARY KEY (id),
KEY parent_id (parent_id),
KEY level (level)
-) type=innodb;
+) engine=innodb;
INSERT INTO t1 VALUES (1,0,0),(3,1,1),(4,1,1),(8,2,2),(9,2,2),(17,3,2),(22,4,2),(24,4,2),(28,5,2),(29,5,2),(30,5,2),(31,6,2),(32,6,2),(33,6,2),(203,7,2),(202,7,2),(20,3,2),(157,0,0),(193,5,2),(40,7,2),(2,1,1),(15,2,2),(6,1,1),(34,6,2),(35,6,2),(16,3,2),(7,1,1),(36,7,2),(18,3,2),(26,5,2),(27,5,2),(183,4,2),(38,7,2),(25,5,2),(37,7,2),(21,4,2),(19,3,2),(5,1,1),(179,5,2);
update t1 set parent_id=parent_id+100;
select * from t1 where parent_id=102;
@@ -177,7 +177,7 @@ CREATE TABLE t1 (
gesuchnr int(11) DEFAULT '0' NOT NULL,
benutzer_id int(11) DEFAULT '0' NOT NULL,
PRIMARY KEY (gesuchnr,benutzer_id)
-) type=innodb;
+) engine=innodb;
replace into t1 (gesuchnr,benutzer_id) values (2,1);
replace into t1 (gesuchnr,benutzer_id) values (1,1);
replace into t1 (gesuchnr,benutzer_id) values (1,1);
@@ -186,7 +186,7 @@ gesuchnr benutzer_id
1 1
2 1
drop table t1;
-create table t1 (a int) type=innodb;
+create table t1 (a int) engine=innodb;
insert into t1 values (1), (2);
optimize table t1;
Table Op Msg_type Msg_text
@@ -199,7 +199,7 @@ check table t1;
Table Op Msg_type Msg_text
test.t1 check status OK
drop table t1;
-create table t1 (a int,b varchar(20)) type=innodb;
+create table t1 (a int,b varchar(20)) engine=innodb;
insert into t1 values (1,""), (2,"testing");
delete from t1 where a = 1;
select * from t1;
@@ -214,13 +214,13 @@ show keys from t1;
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
t1 1 skr 1 a A # NULL NULL YES BTREE
drop table t1;
-create table t1 (a int,b varchar(20),key(a)) type=innodb;
+create table t1 (a int,b varchar(20),key(a)) engine=innodb;
insert into t1 values (1,""), (2,"testing");
select * from t1 where a = 1;
a b
1
drop table t1;
-create table t1 (n int not null primary key) type=innodb;
+create table t1 (n int not null primary key) engine=innodb;
set autocommit=0;
insert into t1 values (4);
rollback;
@@ -251,7 +251,7 @@ n
6
rollback;
drop table t1;
-create table t1 (n int not null primary key) type=innodb;
+create table t1 (n int not null primary key) engine=innodb;
start transaction;
insert into t1 values (4);
flush tables with read lock;
@@ -262,7 +262,7 @@ select * from t1;
n
4
drop table t1;
-create table t1 ( id int NOT NULL PRIMARY KEY, nom varchar(64)) type=innodb;
+create table t1 ( id int NOT NULL PRIMARY KEY, nom varchar(64)) engine=innodb;
begin;
insert into t1 values(1,'hamdouni');
select id as afterbegin_id,nom as afterbegin_nom from t1;
@@ -281,7 +281,7 @@ select id as afterrollback_id,nom as afterrollback_nom from t1;
afterrollback_id afterrollback_nom
set autocommit=1;
drop table t1;
-CREATE TABLE t1 (id char(8) not null primary key, val int not null) type=innodb;
+CREATE TABLE t1 (id char(8) not null primary key, val int not null) engine=innodb;
insert into t1 values ('pippo', 12);
insert into t1 values ('pippo', 12);
ERROR 23000: Duplicate entry 'pippo' for key 1
@@ -301,23 +301,23 @@ commit;
select * from t1;
id val
drop table t1;
-create table t1 (a integer) type=innodb;
+create table t1 (a integer) engine=innodb;
start transaction;
rename table t1 to t2;
-create table t1 (b integer) type=innodb;
+create table t1 (b integer) engine=innodb;
insert into t1 values (1);
rollback;
drop table t1;
rename table t2 to t1;
drop table t1;
set autocommit=1;
-CREATE TABLE t1 (ID INTEGER NOT NULL PRIMARY KEY, NAME VARCHAR(64)) TYPE=innodb;
+CREATE TABLE t1 (ID INTEGER NOT NULL PRIMARY KEY, NAME VARCHAR(64)) ENGINE=innodb;
INSERT INTO t1 VALUES (1, 'Jochen');
select * from t1;
ID NAME
1 Jochen
drop table t1;
-CREATE TABLE t1 ( _userid VARCHAR(60) NOT NULL PRIMARY KEY) TYPE=innodb;
+CREATE TABLE t1 ( _userid VARCHAR(60) NOT NULL PRIMARY KEY) ENGINE=innodb;
set autocommit=0;
INSERT INTO t1 SET _userid='marc@anyware.co.uk';
COMMIT;
@@ -336,7 +336,7 @@ phone varchar(100),
ref_email varchar(100) DEFAULT '' NOT NULL,
detail varchar(200),
PRIMARY KEY (user_id,ref_email)
-)type=innodb;
+)engine=innodb;
INSERT INTO t1 VALUES (10292,'sanjeev','29153373','sansh777@hotmail.com','xxx'),(10292,'shirish','2333604','shirish@yahoo.com','ddsds'),(10292,'sonali','323232','sonali@bolly.com','filmstar');
select * from t1 where user_id=10292;
user_id name phone ref_email detail
@@ -374,7 +374,7 @@ t1 1 a 1 a A # NULL NULL BTREE
t1 1 a_2 1 a A # NULL NULL BTREE
drop table t1;
create table t1 (col1 int not null, col2 char(4) not null, primary key(col1));
-alter table t1 type=innodb;
+alter table t1 engine=innodb;
insert into t1 values ('1','1'),('5','2'),('2','3'),('3','4'),('4','4');
select * from t1;
col1 col2
@@ -408,8 +408,8 @@ col1 col2 co3
4 7 0
5 2 0
drop table t1;
-create table t1 (a int not null , b int, primary key (a)) type = innodb;
-create table t2 (a int not null , b int, primary key (a)) type = myisam;
+create table t1 (a int not null , b int, primary key (a)) engine = innodb;
+create table t2 (a int not null , b int, primary key (a)) engine = myisam;
insert into t1 VALUES (1,3) , (2,3), (3,3);
select * from t1;
a b
@@ -444,7 +444,7 @@ email varchar(64) DEFAULT '' NOT NULL,
passwd varchar(32) binary DEFAULT '' NOT NULL,
PRIMARY KEY (id),
UNIQUE ggid (ggid)
-) TYPE=innodb;
+) ENGINE=innodb;
insert into t1 (ggid,passwd) values ('test1','xxx');
insert into t1 (ggid,passwd) values ('test2','yyy');
insert into t1 (ggid,passwd) values ('test2','this will fail');
@@ -486,7 +486,7 @@ access_time time,
approved datetime,
dummy_primary_key int(11) NOT NULL auto_increment,
PRIMARY KEY (dummy_primary_key)
-) TYPE=innodb;
+) ENGINE=innodb;
INSERT INTO t1 VALUES ('user_0','somepassword','N',0,0,0,'2000-09-07','23:06:59','2000-09-07 23:06:59',1);
INSERT INTO t1 VALUES ('user_1','somepassword','Y',1,1,1,'2000-09-07','23:06:59','2000-09-07 23:06:59',2);
INSERT INTO t1 VALUES ('user_2','somepassword','N',2,2,1.4142135623731,'2000-09-07','23:06:59','2000-09-07 23:06:59',3);
@@ -507,7 +507,7 @@ level tinyint(4) DEFAULT '0' NOT NULL,
KEY (id),
KEY parent_id (parent_id),
KEY level (level)
-) type=innodb;
+) engine=innodb;
INSERT INTO t1 VALUES (1,0,0),(3,1,1),(4,1,1),(8,2,2),(9,2,2),(17,3,2),(22,4,2),(24,4,2),(28,5,2),(29,5,2),(30,5,2),(31,6,2),(32,6,2),(33,6,2),(203,7,2),(202,7,2),(20,3,2),(157,0,0),(193,5,2),(40,7,2),(2,1,1),(15,2,2),(6,1,1),(34,6,2),(35,6,2),(16,3,2),(7,1,1),(36,7,2),(18,3,2),(26,5,2),(27,5,2),(183,4,2),(38,7,2),(25,5,2),(37,7,2),(21,4,2),(19,3,2),(5,1,1);
INSERT INTO t1 values (179,5,2);
update t1 set parent_id=parent_id+100;
@@ -681,7 +681,7 @@ sca_sdesc varchar(50),
sca_sch_desc varchar(16),
PRIMARY KEY (sca_code, cat_code, lan_code),
INDEX sca_pic (sca_pic)
-) type = innodb ;
+) engine = innodb ;
INSERT INTO t1 ( sca_code, cat_code, sca_desc, lan_code, sca_pic, sca_sdesc, sca_sch_desc) VALUES ( 'PD', 'J', 'PENDANT', 'EN', NULL, NULL, 'PENDANT'),( 'RI', 'J', 'RING', 'EN', NULL, NULL, 'RING'),( 'QQ', 'N', 'RING', 'EN', 'not null', NULL, 'RING');
select count(*) from t1 where sca_code = 'PD';
count(*)
@@ -714,7 +714,7 @@ update t1 set sca_pic="test" where sca_pic is null;
delete from t1 where sca_code='pd';
drop table t1;
set @a:=now();
-CREATE TABLE t1 (a int not null, b timestamp not null, primary key (a)) type=innodb;
+CREATE TABLE t1 (a int not null, b timestamp not null, primary key (a)) engine=innodb;
insert into t1 (a) values(1),(2),(3);
select t1.a from t1 natural join t1 as t2 where t1.b >= @a order by t1.a;
a
@@ -728,7 +728,7 @@ a
3
5
drop table t1;
-create table t1 (a varchar(100) not null, primary key(a), b int not null) type=innodb;
+create table t1 (a varchar(100) not null, primary key(a), b int not null) engine=innodb;
insert into t1 values("hello",1),("world",2);
select * from t1 order by b desc;
a b
@@ -741,7 +741,7 @@ show keys from t1;
Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_part Packed Null Index_type Comment
t1 0 PRIMARY 1 a A # NULL NULL BTREE
drop table t1;
-create table t1 (i int, j int ) TYPE=innodb;
+create table t1 (i int, j int ) ENGINE=innodb;
insert into t1 values (1,2);
select * from t1 where i=1 and j=2;
i j
@@ -755,25 +755,25 @@ CREATE TABLE t1 (
a int3 unsigned NOT NULL,
b int1 unsigned NOT NULL,
UNIQUE (a, b)
-) TYPE = innodb;
+) ENGINE = innodb;
INSERT INTO t1 VALUES (1, 1);
SELECT MIN(B),MAX(b) FROM t1 WHERE t1.a = 1;
MIN(B) MAX(b)
1 1
drop table t1;
-CREATE TABLE t1 (a int unsigned NOT NULL) type=innodb;
+CREATE TABLE t1 (a int unsigned NOT NULL) engine=innodb;
INSERT INTO t1 VALUES (1);
SELECT * FROM t1;
a
1
DROP TABLE t1;
-create table t1 (a int primary key,b int, c int, d int, e int, f int, g int, h int, i int, j int, k int, l int, m int, n int, o int, p int, q int, r int, s int, t int, u int, v int, w int, x int, y int, z int, a1 int, a2 int, a3 int, a4 int, a5 int, a6 int, a7 int, a8 int, a9 int, b1 int, b2 int, b3 int, b4 int, b5 int, b6 int) type = innodb;
+create table t1 (a int primary key,b int, c int, d int, e int, f int, g int, h int, i int, j int, k int, l int, m int, n int, o int, p int, q int, r int, s int, t int, u int, v int, w int, x int, y int, z int, a1 int, a2 int, a3 int, a4 int, a5 int, a6 int, a7 int, a8 int, a9 int, b1 int, b2 int, b3 int, b4 int, b5 int, b6 int) engine = innodb;
insert into t1 values (1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1);
explain select * from t1 where a > 0 and a < 50;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 range PRIMARY PRIMARY 4 NULL # Using where
drop table t1;
-create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) type=innodb;
+create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) engine=innodb;
insert into t1 values (0,0,0,'ABCDEFGHIJ'),(2,2,2,'BCDEFGHIJK'),(1,1,1,'CDEFGHIJKL');
LOCK TABLES t1 WRITE;
insert into t1 values (99,1,2,'D'),(1,1,2,'D');
@@ -790,7 +790,7 @@ id
2
UNLOCK TABLES;
DROP TABLE t1;
-create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) type=innodb;
+create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) engine=innodb;
insert into t1 values (0,0,0,'ABCDEFGHIJ'),(2,2,2,'BCDEFGHIJK'),(1,1,1,'CDEFGHIJKL');
LOCK TABLES t1 WRITE;
begin;
@@ -811,17 +811,17 @@ id id3
100 2
UNLOCK TABLES;
DROP TABLE t1;
-create table t1 (a char(20), unique (a(5))) type=innodb;
+create table t1 (a char(20), unique (a(5))) engine=innodb;
drop table t1;
-create table t1 (a char(20), index (a(5))) type=innodb;
+create table t1 (a char(20), index (a(5))) engine=innodb;
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` char(20) default NULL,
KEY `a` (`a`(5))
-) TYPE=InnoDB DEFAULT CHARSET=latin1
+) ENGINE=InnoDB DEFAULT CHARSET=latin1
drop table t1;
-create temporary table t1 (a int not null auto_increment, primary key(a)) type=innodb;
+create temporary table t1 (a int not null auto_increment, primary key(a)) engine=innodb;
insert into t1 values (NULL),(NULL),(NULL);
delete from t1 where a=3;
insert into t1 values (NULL);
@@ -844,7 +844,7 @@ name varchar(32) not null,
value text not null,
uid int not null,
unique key(name,uid)
-) type=innodb;
+) engine=innodb;
insert into t1 values (1,'one','one value',101),
(2,'two','two value',102),(3,'three','three value',103);
set insert_id=5;
@@ -861,18 +861,18 @@ id name value uid
6 two other value 102
drop table t1;
create database mysqltest;
-create table mysqltest.t1 (a int not null) type= innodb;
+create table mysqltest.t1 (a int not null) engine= innodb;
insert into mysqltest.t1 values(1);
-create table mysqltest.t2 (a int not null) type= myisam;
+create table mysqltest.t2 (a int not null) engine= myisam;
insert into mysqltest.t2 values(1);
-create table mysqltest.t3 (a int not null) type= heap;
+create table mysqltest.t3 (a int not null) engine= heap;
insert into mysqltest.t3 values(1);
commit;
drop database mysqltest;
show tables from mysqltest;
Got one of the listed errors
set autocommit=0;
-create table t1 (a int not null) type= innodb;
+create table t1 (a int not null) engine= innodb;
insert into t1 values(1),(2);
truncate table t1;
ERROR HY000: Can't execute the given command because you have active locked tables or an active transaction
@@ -887,7 +887,7 @@ a
commit;
drop table t1;
set autocommit=1;
-create table t1 (a int not null) type= innodb;
+create table t1 (a int not null) engine= innodb;
insert into t1 values(1),(2);
truncate table t1;
insert into t1 values(1),(2);
@@ -901,7 +901,7 @@ delete from t1;
select * from t1;
a
drop table t1;
-create table t1 (a int not null, b int not null, c int not null, primary key (a),key(b)) type=innodb;
+create table t1 (a int not null, b int not null, c int not null, primary key (a),key(b)) engine=innodb;
insert into t1 values (3,3,3),(1,1,1),(2,2,2),(4,4,4);
explain select * from t1 order by a;
id select_type table type possible_keys key key_len ref rows Extra
@@ -928,7 +928,7 @@ explain select a,b,c from t1;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 ALL NULL NULL NULL NULL #
drop table t1;
-create table t1 (t int not null default 1, key (t)) type=innodb;
+create table t1 (t int not null default 1, key (t)) engine=innodb;
desc t1;
Field Type Null Key Default Extra
t int(11) MUL 1
@@ -945,7 +945,7 @@ last_app_id smallint(6) default '-1',
version smallint(6) NOT NULL default '0',
assigned_scps int(11) default '0',
status tinyint(4) default '0'
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t1 VALUES (4077711111,'SeanWheeler',90,2,20020111112846,500,00000000000000,-1,2,3,1);
INSERT INTO t1 VALUES (9197722223,'berry',90,3,20020111112809,500,20020102114532,501,4,10,0);
INSERT INTO t1 VALUES (650,'San Francisco',0,0,20011227111336,342,00000000000000,-1,1,24,1);
@@ -964,7 +964,7 @@ last_app_id smallint(6) default '-1',
version smallint(6) NOT NULL default '0',
assigned_scps int(11) default '0',
status tinyint(4) default '0'
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t2 VALUES (4077711111,'SeanWheeler',0,2,20020111112853,500,00000000000000,-1,2,3,1);
INSERT INTO t2 VALUES (9197722223,'berry',90,3,20020111112818,500,20020102114532,501,4,10,0);
INSERT INTO t2 VALUES (650,'San Francisco',90,0,20020109113158,342,00000000000000,-1,1,24,1);
@@ -995,7 +995,7 @@ select * from t2;
number cname carrier_id privacy last_mod_date last_mod_id last_app_date last_app_id version assigned_scps status
333 tubs 99 2 2002-01-09 11:34:53 501 2002-01-09 11:34:53 500 3 10 0
drop table t1,t2;
-create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) type=innodb;
+create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) engine=innodb;
BEGIN;
SET SESSION TRANSACTION ISOLATION LEVEL SERIALIZABLE;
SELECT @@tx_isolation,@@global.tx_isolation;
@@ -1033,8 +1033,8 @@ id code name
7 4 Matt
COMMIT;
DROP TABLE t1;
-create table t1 (n int(10), d int(10)) type=innodb;
-create table t2 (n int(10), d int(10)) type=innodb;
+create table t1 (n int(10), d int(10)) engine=innodb;
+create table t2 (n int(10), d int(10)) engine=innodb;
insert into t1 values(1,1),(1,2);
insert into t2 values(1,10),(2,20);
UPDATE t1,t2 SET t1.d=t2.d,t2.d=30 WHERE t1.n=t2.n;
@@ -1047,7 +1047,7 @@ n d
1 30
2 20
drop table t1,t2;
-create table t1 (a int, b int) type=innodb;
+create table t1 (a int, b int) engine=innodb;
insert into t1 values(20,null);
select t2.b, ifnull(t2.b,"this is null") from t1 as t2 left join t1 as t3 on
t2.b=t3.a;
@@ -1064,19 +1064,19 @@ b ifnull(t2.b,"this is null")
NULL this is null
NULL this is null
drop table t1;
-create table t1 (a varchar(10) not null) type=myisam;
-create table t2 (b varchar(10) not null unique) type=innodb;
+create table t1 (a varchar(10) not null) engine=myisam;
+create table t2 (b varchar(10) not null unique) engine=innodb;
select t1.a from t1,t2 where t1.a=t2.b;
a
drop table t1,t2;
-create table t1 (a int not null, b int, primary key (a)) type = innodb;
-create table t2 (a int not null, b int, primary key (a)) type = innodb;
+create table t1 (a int not null, b int, primary key (a)) engine = innodb;
+create table t2 (a int not null, b int, primary key (a)) engine = innodb;
insert into t1 values (10, 20);
insert into t2 values (10, 20);
update t1, t2 set t1.b = 150, t2.b = t1.b where t2.a = t1.a and t1.a = 10;
drop table t1,t2;
-CREATE TABLE t1 (id INT NOT NULL, PRIMARY KEY (id)) TYPE=INNODB;
-CREATE TABLE t2 (id INT PRIMARY KEY, t1_id INT, INDEX par_ind (t1_id), FOREIGN KEY (t1_id) REFERENCES t1(id) ON DELETE CASCADE ) TYPE=INNODB;
+CREATE TABLE t1 (id INT NOT NULL, PRIMARY KEY (id)) ENGINE=INNODB;
+CREATE TABLE t2 (id INT PRIMARY KEY, t1_id INT, INDEX par_ind (t1_id), FOREIGN KEY (t1_id) REFERENCES t1(id) ON DELETE CASCADE ) ENGINE=INNODB;
insert into t1 set id=1;
insert into t2 set id=1, t1_id=1;
delete t1,t2 from t1,t2 where t1.id=t2.t1_id;
@@ -1089,8 +1089,8 @@ DROP TABLE IF EXISTS t1,t2;
Warnings:
Note 1051 Unknown table 't1'
Note 1051 Unknown table 't2'
-CREATE TABLE t1(id INT NOT NULL, PRIMARY KEY (id)) TYPE=INNODB;
-CREATE TABLE t2(id INT PRIMARY KEY, t1_id INT, INDEX par_ind (t1_id) ) TYPE=INNODB;
+CREATE TABLE t1(id INT NOT NULL, PRIMARY KEY (id)) ENGINE=INNODB;
+CREATE TABLE t2(id INT PRIMARY KEY, t1_id INT, INDEX par_ind (t1_id) ) ENGINE=INNODB;
INSERT INTO t1 VALUES(1);
INSERT INTO t2 VALUES(1, 1);
SELECT * from t1;
@@ -1106,9 +1106,9 @@ id
3
DROP TABLE t1,t2;
set autocommit=0;
-CREATE TABLE t1 (id CHAR(15) NOT NULL, value CHAR(40) NOT NULL, PRIMARY KEY(id)) TYPE=InnoDB;
-CREATE TABLE t2 (id CHAR(15) NOT NULL, value CHAR(40) NOT NULL, PRIMARY KEY(id)) TYPE=InnoDB;
-CREATE TABLE t3 (id1 CHAR(15) NOT NULL, id2 CHAR(15) NOT NULL, PRIMARY KEY(id1, id2)) TYPE=InnoDB;
+CREATE TABLE t1 (id CHAR(15) NOT NULL, value CHAR(40) NOT NULL, PRIMARY KEY(id)) ENGINE=InnoDB;
+CREATE TABLE t2 (id CHAR(15) NOT NULL, value CHAR(40) NOT NULL, PRIMARY KEY(id)) ENGINE=InnoDB;
+CREATE TABLE t3 (id1 CHAR(15) NOT NULL, id2 CHAR(15) NOT NULL, PRIMARY KEY(id1, id2)) ENGINE=InnoDB;
INSERT INTO t3 VALUES("my-test-1", "my-test-2");
COMMIT;
INSERT INTO t1 VALUES("this-key", "will disappear");
@@ -1136,7 +1136,7 @@ my-test-1 my-test-2
COMMIT;
set autocommit=1;
DROP TABLE t1,t2,t3;
-CREATE TABLE t1 (a int not null primary key, b int not null, unique (b)) type=innodb;
+CREATE TABLE t1 (a int not null primary key, b int not null, unique (b)) engine=innodb;
INSERT INTO t1 values (1,1),(2,2),(3,3),(4,4),(5,5),(6,6),(7,7),(8,8),(9,9);
UPDATE t1 set a=a+100 where b between 2 and 3 and a < 1000;
SELECT * from t1;
@@ -1151,8 +1151,8 @@ a b
8 8
9 9
drop table t1;
-CREATE TABLE t1 (a int not null primary key, b int not null, key (b)) type=innodb;
-CREATE TABLE t2 (a int not null primary key, b int not null, key (b)) type=innodb;
+CREATE TABLE t1 (a int not null primary key, b int not null, key (b)) engine=innodb;
+CREATE TABLE t2 (a int not null primary key, b int not null, key (b)) engine=innodb;
INSERT INTO t1 values (1,1),(2,2),(3,3),(4,4),(5,5),(6,6),(7,7),(8,8),(9,9),(10,10),(11,11),(12,12);
INSERT INTO t2 values (1,1),(2,2),(3,3),(4,4),(5,5),(6,6),(7,7),(8,8),(9,9);
update t1,t2 set t1.a=t1.a+100;
@@ -1227,8 +1227,8 @@ a b
4 14
5 15
drop table t1,t2;
-CREATE TABLE t2 ( NEXT_T BIGINT NOT NULL PRIMARY KEY) TYPE=MyISAM;
-CREATE TABLE t1 ( B_ID INTEGER NOT NULL PRIMARY KEY) TYPE=InnoDB;
+CREATE TABLE t2 ( NEXT_T BIGINT NOT NULL PRIMARY KEY) ENGINE=MyISAM;
+CREATE TABLE t1 ( B_ID INTEGER NOT NULL PRIMARY KEY) ENGINE=InnoDB;
SET AUTOCOMMIT=0;
INSERT INTO t1 ( B_ID ) VALUES ( 1 );
INSERT INTO t2 ( NEXT_T ) VALUES ( 1 );
@@ -1238,7 +1238,7 @@ Warning 1196 Some non-transactional changed tables couldn't be rolled back
SELECT * FROM t1;
B_ID
drop table t1,t2;
-create table t1 ( pk int primary key, parent int not null, child int not null, index (parent) ) type = innodb;
+create table t1 ( pk int primary key, parent int not null, child int not null, index (parent) ) engine = innodb;
insert into t1 values (1,0,4), (2,1,3), (3,2,1), (4,1,2);
select distinct parent,child from t1 order by parent;
parent child
@@ -1247,7 +1247,7 @@ parent child
1 3
2 1
drop table t1;
-create table t1 (a int not null auto_increment primary key, b int, c int, key(c)) type=innodb;
+create table t1 (a int not null auto_increment primary key, b int, c int, key(c)) engine=innodb;
create table t2 (a int not null auto_increment primary key, b int);
insert into t1 (b) values (null),(null),(null),(null),(null),(null),(null);
insert into t2 (a) select b from t1;
@@ -1279,7 +1279,7 @@ explain select * from t1 where c between 1 and 10000;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t1 ALL c NULL NULL NULL # Using where
drop table t1,t2;
-create table t1 (id int primary key auto_increment, fk int, index index_fk (fk)) type=innodb;
+create table t1 (id int primary key auto_increment, fk int, index index_fk (fk)) engine=innodb;
insert into t1 (id) values (null),(null),(null),(null),(null);
update t1 set fk=69 where fk is null order by id limit 1;
SELECT * from t1;
@@ -1312,9 +1312,9 @@ a b
111 100
111 100
drop table t1;
-CREATE TABLE t1 (col1 int(1))TYPE=InnoDB;
+CREATE TABLE t1 (col1 int(1))ENGINE=InnoDB;
CREATE TABLE t2 (col1 int(1),stamp TIMESTAMP,INDEX stamp_idx
-(stamp))TYPE=InnoDB;
+(stamp))ENGINE=InnoDB;
insert into t1 values (1),(2),(3);
insert into t2 values (1, 20020204130000),(2, 20020204130000),(4,20020204310000 );
SELECT col1 FROM t1 UNION SELECT col1 FROM t2 WHERE stamp <
@@ -1333,14 +1333,14 @@ label varchar(100) NOT NULL default '',
PRIMARY KEY (`id`),
KEY `id_object` (`id_object`),
KEY `id_version` (`id_version`)
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t1 VALUES("6", "3382", "9", "Test", NULL), ("7", "102", "5", "Le Pekin (Test)", NULL),("584", "1794", "4", "Test de resto", NULL),("837", "1822", "6", "Test 3", NULL),("1119", "3524", "1", "Societe Test", NULL),("1122", "3525", "1", "Fournisseur Test", NULL);
CREATE TABLE t2 (
`id` int(10) unsigned NOT NULL auto_increment,
`id_version` int(10) unsigned NOT NULL default '1',
PRIMARY KEY (`id`),
KEY `id_version` (`id_version`)
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t2 VALUES("3524", "1"),("3525", "1"),("1794", "4"),("102", "5"),("1822", "6"),("3382", "9");
SELECT t2.id, t1.label FROM t2 INNER JOIN
(SELECT t1.id_object as id_object FROM t1 WHERE t1.label LIKE '%test%') AS lbl
@@ -1353,7 +1353,7 @@ id label
3524 Societe Test
3525 Fournisseur Test
drop table t1,t2;
-create table t1 (c1 char(5) unique not null, c2 int, stamp timestamp) type=innodb;
+create table t1 (c1 char(5) unique not null, c2 int, stamp timestamp) engine=innodb;
select * from t1;
c1 c2 stamp
replace delayed into t1 (c1, c2) values ( "text1","11"),( "text2","12");
@@ -1365,9 +1365,9 @@ ERROR HY000: Table storage engine for 't1' doesn't have this option
select * from t1;
c1 c2 stamp
drop table t1;
-create table t1 (a int, b varchar(200), c text not null) checksum=1 type=myisam;
-create table t2 (a int, b varchar(200), c text not null) checksum=0 type=innodb;
-create table t3 (a int, b varchar(200), c text not null) checksum=1 type=innodb;
+create table t1 (a int, b varchar(200), c text not null) checksum=1 engine=myisam;
+create table t2 (a int, b varchar(200), c text not null) checksum=0 engine=innodb;
+create table t3 (a int, b varchar(200), c text not null) checksum=1 engine=innodb;
insert t1 values (1, "aaa", "bbb"), (NULL, "", "ccccc"), (0, NULL, "");
insert t2 select * from t1;
insert t3 select * from t1;
diff --git a/mysql-test/r/innodb_cache.result b/mysql-test/r/innodb_cache.result
index 7706e60d143..5c5e0bb6dfe 100644
--- a/mysql-test/r/innodb_cache.result
+++ b/mysql-test/r/innodb_cache.result
@@ -1,7 +1,7 @@
drop table if exists t1,t2,t3;
flush status;
set autocommit=0;
-create table t1 (a int not null) type=innodb;
+create table t1 (a int not null) engine=innodb;
insert into t1 values (1),(2),(3);
select * from t1;
a
@@ -15,7 +15,7 @@ drop table t1;
commit;
set autocommit=1;
begin;
-create table t1 (a int not null) type=innodb;
+create table t1 (a int not null) engine=innodb;
insert into t1 values (1),(2),(3);
select * from t1;
a
@@ -27,9 +27,9 @@ Variable_name Value
Qcache_queries_in_cache 0
drop table t1;
commit;
-create table t1 (a int not null) type=innodb;
-create table t2 (a int not null) type=innodb;
-create table t3 (a int not null) type=innodb;
+create table t1 (a int not null) engine=innodb;
+create table t2 (a int not null) engine=innodb;
+create table t3 (a int not null) engine=innodb;
insert into t1 values (1),(2);
insert into t2 values (1),(2);
insert into t3 values (1),(2);
@@ -99,7 +99,7 @@ show status like "Qcache_queries_in_cache";
Variable_name Value
Qcache_queries_in_cache 1
drop table if exists t1;
-CREATE TABLE t1 (id int(11) NOT NULL auto_increment, PRIMARY KEY (id)) TYPE=InnoDB;
+CREATE TABLE t1 (id int(11) NOT NULL auto_increment, PRIMARY KEY (id)) ENGINE=InnoDB;
select count(*) from t1;
count(*)
0
diff --git a/mysql-test/r/innodb_handler.result b/mysql-test/r/innodb_handler.result
index 1fadc3a61de..a608e5c71ab 100644
--- a/mysql-test/r/innodb_handler.result
+++ b/mysql-test/r/innodb_handler.result
@@ -1,5 +1,5 @@
drop table if exists t1,t2;
-create table t1 (a int, b char(10), key a(a), key b(a,b)) type=innodb;
+create table t1 (a int, b char(10), key a(a), key b(a,b)) engine=innodb;
insert into t1 values
(17,"ddd"),(18,"eee"),(19,"fff"),(19,"yyy"),
(14,"aaa"),(15,"bbb"),(16,"ccc"),(16,"xxx"),
@@ -136,11 +136,11 @@ handler t1 open as t2;
handler t2 read first;
a b
17 ddd
-alter table t1 type=innodb;
+alter table t1 engine=innodb;
handler t2 read first;
ERROR 42S02: Unknown table 't2' in HANDLER
drop table t1;
-CREATE TABLE t1 ( no1 smallint(5) NOT NULL default '0', no2 int(10) NOT NULL default '0', PRIMARY KEY (no1,no2)) TYPE=InnoDB;
+CREATE TABLE t1 ( no1 smallint(5) NOT NULL default '0', no2 int(10) NOT NULL default '0', PRIMARY KEY (no1,no2)) ENGINE=InnoDB;
INSERT INTO t1 VALUES (1,274),(1,275),(2,6),(2,8),(4,1),(4,2);
HANDLER t1 OPEN;
HANDLER t1 READ `primary` = (1, 1000);
diff --git a/mysql-test/r/insert_select.result b/mysql-test/r/insert_select.result
index 8eecccf6fec..a77d67b5f64 100644
--- a/mysql-test/r/insert_select.result
+++ b/mysql-test/r/insert_select.result
@@ -35,7 +35,7 @@ PRIMARY KEY (`numeropost`,`numreponse`)
KEY `date` (`date`),
KEY `pseudo` (`pseudo`),
KEY `numreponse` (`numreponse`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE `t2` (
`numeropost` bigint(20) unsigned NOT NULL default '0',
`icone` tinyint(4) unsigned NOT NULL default '0',
@@ -50,7 +50,7 @@ KEY `ip` (`ip`),
KEY `date` (`date`),
KEY `pseudo` (`pseudo`),
KEY `numreponse` (`numreponse`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2
(numeropost,icone,numreponse,contenu,pseudo,date,ip,signature) VALUES
(9,1,56,'test','joce','2001-07-25 13:50:53'
diff --git a/mysql-test/r/isam.result b/mysql-test/r/isam.result
index 80d78bc72da..4c698075150 100644
--- a/mysql-test/r/isam.result
+++ b/mysql-test/r/isam.result
@@ -1,11 +1,11 @@
drop table if exists t1,t2;
-create table t1 (a tinyint not null auto_increment, b blob not null, primary key (a)) type=isam;
+create table t1 (a tinyint not null auto_increment, b blob not null, primary key (a)) engine=isam;
delete from t1 where (a & 1);
select sum(length(b)) from t1;
sum(length(b))
3274494
drop table t1;
-create table t1 (a int not null auto_increment,b int, primary key (a)) type=isam;
+create table t1 (a int not null auto_increment,b int, primary key (a)) engine=isam;
insert into t1 values (1,1),(NULL,2),(3,3),(NULL,4);
delete from t1 where a=4 or a=2;
insert into t1 values (NULL,4),(NULL,5),(6,6);
@@ -29,20 +29,20 @@ a b c
4 4 NULL
6 6 6
drop table t1;
-create table t1 (a int,b text, index(a)) type=isam;
+create table t1 (a int,b text, index(a)) engine=isam;
ERROR 42000: Column 'a' is used with UNIQUE or INDEX but is not defined as NOT NULL
-create table t1 (a int,b text, index(b)) type=isam;
+create table t1 (a int,b text, index(b)) engine=isam;
ERROR 42000: BLOB column 'b' can't be used in key specification with the used table type
-create table t1 (ordid int(8) not null auto_increment, ord varchar(50) not null, primary key (ord,ordid)) type=isam;
+create table t1 (ordid int(8) not null auto_increment, ord varchar(50) not null, primary key (ord,ordid)) engine=isam;
ERROR 42000: Incorrect table definition; There can only be one auto column and it must be defined as a key
-create table t1 (ordid int(8), unique (ordid)) type=isam;
+create table t1 (ordid int(8), unique (ordid)) engine=isam;
ERROR 42000: Column 'ordid' is used with UNIQUE or INDEX but is not defined as NOT NULL
drop table if exists t1;
Warnings:
Note 1051 Unknown table 't1'
create table t1 (a int not null primary key, b int not null,c int not null, key(b,c));
insert into t1 values (1,2,2),(2,2,3),(3,2,4),(4,2,4);
-create table t2 type=isam select * from t1;
+create table t2 engine=isam select * from t1;
optimize table t1;
Table Op Msg_type Msg_text
test.t1 optimize status OK
diff --git a/mysql-test/r/join.result b/mysql-test/r/join.result
index 24b272a1985..7dbc09f9cc0 100644
--- a/mysql-test/r/join.result
+++ b/mysql-test/r/join.result
@@ -132,11 +132,11 @@ CREATE TABLE t1 (
a int(11) NOT NULL,
b int(11) NOT NULL,
PRIMARY KEY (a,b)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,1),(1,2),(1,3),(1,4),(1,5),(1,6),(1,7),(2,3);
CREATE TABLE t2 (
a int(11) default NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (2),(3);
SELECT t1.a,t2.a,b FROM t1,t2 WHERE t1.a=t2.a AND (t1.a=1 OR t1.a=2) AND b>=1 AND b<=3;
a a b
@@ -236,13 +236,13 @@ min_value double default NULL,
max_value double default NULL,
t3_id int(11) default NULL,
item_id int(11) default NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (12,5,'Percent','Cost',-1,0,-1,-1),(14,4,'Percent','Cost',-1,0,-1,-1),(18,5,'Percent','Cost',-1,0,-1,-1),(19,4,'Percent','Cost',-1,0,-1,-1),(20,5,'Percent','Cost',100,-1,22,291),(21,5,'Percent','Cost',100,-1,18,291),(22,1,'Percent','Cost',100,-1,6,291),(23,1,'Percent','Cost',100,-1,21,291),(24,1,'Percent','Cost',100,-1,9,291),(25,1,'Percent','Cost',100,-1,4,291),(26,1,'Percent','Cost',100,-1,20,291),(27,4,'Percent','Cost',100,-1,7,202),(28,1,'Percent','Cost',50,-1,-1,137),(29,2,'Percent','Cost',100,-1,4,354),(30,2,'Percent','Cost',100,-1,9,137),(93,2,'Cost','Cost',-1,10000000,-1,-1);
CREATE TABLE t2 (
id int(10) unsigned NOT NULL auto_increment,
name varchar(255) default NULL,
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,'s1'),(2,'s2'),(3,'s3'),(4,'s4'),(5,'s5');
select t1.*, t2.* from t1, t2 where t2.id=t1.t2_id limit 2;
t1_id t2_id type cost_unit min_value max_value t3_id item_id id name
@@ -255,7 +255,7 @@ emp_id varchar(30) NOT NULL default '',
rate_code varchar(10) default NULL,
UNIQUE KEY site_emp (siteid,emp_id),
KEY siteid (siteid)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('rivercats','psmith','cust'), ('rivercats','KWalker','cust');
CREATE TABLE t2 (
siteid varchar(25) NOT NULL default '',
@@ -263,7 +263,7 @@ rate_code varchar(10) NOT NULL default '',
base_rate float NOT NULL default '0',
PRIMARY KEY (siteid,rate_code),
FULLTEXT KEY rate_code (rate_code)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES ('rivercats','cust',20);
SELECT emp.rate_code, lr.base_rate FROM t1 AS emp LEFT JOIN t2 AS lr USING (siteid, rate_code) WHERE emp.emp_id = 'psmith' AND lr.siteid = 'rivercats';
rate_code base_rate
diff --git a/mysql-test/r/join_crash.result b/mysql-test/r/join_crash.result
index c7bca9f7497..c1671ea7e20 100644
--- a/mysql-test/r/join_crash.result
+++ b/mysql-test/r/join_crash.result
@@ -10,7 +10,7 @@ billing_contact_ptr int(11) default NULL,
comments mediumtext,
PRIMARY KEY (project_id),
UNIQUE KEY project (client_ptr,project_name)
-) TYPE=MyISAM PACK_KEYS=1;
+) ENGINE=MyISAM PACK_KEYS=1;
INSERT INTO t1 VALUES (1,0,'Rejected Time',1,NULL,NULL,NULL,NULL);
INSERT INTO t1 VALUES (209,0,'MDGRAD Proposal/Investigation',97,NULL,NULL,NULL,'');
INSERT INTO t1 VALUES (208,0,'Font 9 Design',84,NULL,NULL,NULL,'');
@@ -31,7 +31,7 @@ work_load int(11) default NULL,
PRIMARY KEY (period_id),
KEY period_index (period_type,period_key),
KEY date_index (start_date,end_date)
-) TYPE=MyISAM PACK_KEYS=1;
+) ENGINE=MyISAM PACK_KEYS=1;
INSERT INTO t2 VALUES (1,'user_table',98,'2000-01-01 00:00:00',NULL,NULL);
INSERT INTO t2 VALUES (2,'user_table',99,'2000-01-01 00:00:00',NULL,NULL);
INSERT INTO t2 VALUES (3,'user_table',100,'2000-01-01 00:00:00',NULL,NULL);
@@ -57,7 +57,7 @@ amount_received float(10,2) default NULL,
adjustment float(10,2) default NULL,
PRIMARY KEY (budget_id),
UNIQUE KEY po (project_ptr,po_number)
-) TYPE=MyISAM PACK_KEYS=1;
+) ENGINE=MyISAM PACK_KEYS=1;
CREATE TABLE t4 (
client_id int(11) NOT NULL auto_increment,
client_row_lock int(11) NOT NULL default '0',
@@ -66,7 +66,7 @@ contact_ptr int(11) default NULL,
comments mediumtext,
PRIMARY KEY (client_id),
UNIQUE KEY client_name (client_name)
-) TYPE=MyISAM PACK_KEYS=1;
+) ENGINE=MyISAM PACK_KEYS=1;
INSERT INTO t4 VALUES (1,0,'CPS',NULL,NULL);
select distinct
t1.project_id as project_id,
diff --git a/mysql-test/r/join_outer.result b/mysql-test/r/join_outer.result
index 165f1522378..76c1b06b638 100644
--- a/mysql-test/r/join_outer.result
+++ b/mysql-test/r/join_outer.result
@@ -3,7 +3,7 @@ CREATE TABLE t1 (
grp int(11) default NULL,
a bigint(20) unsigned default NULL,
c char(10) NOT NULL default ''
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,1,'a'),(2,2,'b'),(2,3,'c'),(3,4,'E'),(3,5,'C'),(3,6,'D'),(NULL,NULL,'');
create table t2 (id int, a bigint unsigned not null, c char(10), d int, primary key (a));
insert into t2 values (1,1,"a",1),(3,4,"A",4),(3,5,"B",5),(3,6,"C",6),(4,7,"D",7);
diff --git a/mysql-test/r/key.result b/mysql-test/r/key.result
index 89deab4bb1f..d8e10fd20c7 100644
--- a/mysql-test/r/key.result
+++ b/mysql-test/r/key.result
@@ -130,7 +130,7 @@ CREATE TABLE t1 (
a tinytext NOT NULL,
b tinyint(3) unsigned NOT NULL default '0',
PRIMARY KEY (a(32),b)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('a',1),('a',2);
SELECT * FROM t1 WHERE a='a' AND b=2;
a b
diff --git a/mysql-test/r/lock.result b/mysql-test/r/lock.result
index 68feb9c44d7..2cb9527b94b 100644
--- a/mysql-test/r/lock.result
+++ b/mysql-test/r/lock.result
@@ -1,5 +1,5 @@
drop table if exists t1,t2;
-CREATE TABLE t1 ( `id` int(11) NOT NULL default '0', `id2` int(11) NOT NULL default '0', `id3` int(11) NOT NULL default '0', `dummy1` char(30) default NULL, PRIMARY KEY (`id`,`id2`), KEY `index_id3` (`id3`)) TYPE=MyISAM;
+CREATE TABLE t1 ( `id` int(11) NOT NULL default '0', `id2` int(11) NOT NULL default '0', `id3` int(11) NOT NULL default '0', `dummy1` char(30) default NULL, PRIMARY KEY (`id`,`id2`), KEY `index_id3` (`id3`)) ENGINE=MyISAM;
insert into t1 (id,id2) values (1,1),(1,2),(1,3);
LOCK TABLE t1 WRITE;
select dummy1,count(distinct id) from t1 group by dummy1;
@@ -23,11 +23,11 @@ CREATE TABLE t1 (
index1 smallint(6) default NULL,
nr smallint(6) default NULL,
KEY index1(index1)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE t2 (
nr smallint(6) default NULL,
name varchar(20) default NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,'item1');
INSERT INTO t2 VALUES (2,'item2');
lock tables t1 write, t2 read;
diff --git a/mysql-test/r/lock_tables_lost_commit.result b/mysql-test/r/lock_tables_lost_commit.result
index ccf56793f45..22885d93d40 100644
--- a/mysql-test/r/lock_tables_lost_commit.result
+++ b/mysql-test/r/lock_tables_lost_commit.result
@@ -1,5 +1,5 @@
drop table if exists t1;
-create table t1(a int) type=innodb;
+create table t1(a int) engine=innodb;
lock tables t1 write;
insert into t1 values(10);
select * from t1;
diff --git a/mysql-test/r/merge.result b/mysql-test/r/merge.result
index 01635313590..63e0a228aa5 100644
--- a/mysql-test/r/merge.result
+++ b/mysql-test/r/merge.result
@@ -4,7 +4,7 @@ create table t1 (a int not null primary key auto_increment, message char(20));
create table t2 (a int not null primary key auto_increment, message char(20));
INSERT INTO t1 (message) VALUES ("Testing"),("table"),("t1");
INSERT INTO t2 (message) VALUES ("Testing"),("table"),("t2");
-create table t3 (a int not null, b char(20), key(a)) type=MERGE UNION=(t1,t2);
+create table t3 (a int not null, b char(20), key(a)) engine=MERGE UNION=(t1,t2);
select * from t3;
a b
1 Testing
@@ -33,7 +33,7 @@ insert into t2 select NULL,message from t1;
insert into t1 select NULL,message from t2;
insert into t2 select NULL,message from t1;
insert into t1 select NULL,message from t2;
-create table t3 (a int not null, b char(20), key(a)) type=MERGE UNION=(test.t1,test.t2);
+create table t3 (a int not null, b char(20), key(a)) engine=MERGE UNION=(test.t1,test.t2);
explain select * from t3 where a < 10;
id select_type table type possible_keys key key_len ref rows Extra
1 SIMPLE t3 range a a 4 NULL 18 Using where
@@ -175,29 +175,29 @@ t3 CREATE TABLE `t3` (
`a` int(11) NOT NULL default '0',
`b` char(20) default NULL,
KEY `a` (`a`)
-) TYPE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`t2`)
-create table t4 (a int not null, b char(10), key(a)) type=MERGE UNION=(t1,t2);
+) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`t2`)
+create table t4 (a int not null, b char(10), key(a)) engine=MERGE UNION=(t1,t2);
select * from t4;
ERROR HY000: Can't open file: 't4.MRG' (errno: 143)
alter table t4 add column c int;
ERROR HY000: Can't open file: 't4.MRG' (errno: 143)
create database mysqltest;
create table mysqltest.t6 (a int not null primary key auto_increment, message char(20));
-create table t5 (a int not null, b char(20), key(a)) type=MERGE UNION=(test.t1,mysqltest.t6);
+create table t5 (a int not null, b char(20), key(a)) engine=MERGE UNION=(test.t1,mysqltest.t6);
show create table t5;
Table Create Table
t5 CREATE TABLE `t5` (
`a` int(11) NOT NULL default '0',
`b` char(20) default NULL,
KEY `a` (`a`)
-) TYPE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`mysqltest`.`t6`)
-alter table t5 type=myisam;
+) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`mysqltest`.`t6`)
+alter table t5 engine=myisam;
drop table t5, mysqltest.t6;
drop database mysqltest;
drop table t4,t3,t1,t2;
-create table t1 (c char(10)) type=myisam;
-create table t2 (c char(10)) type=myisam;
-create table t3 (c char(10)) union=(t1,t2) type=merge;
+create table t1 (c char(10)) engine=myisam;
+create table t2 (c char(10)) engine=myisam;
+create table t3 (c char(10)) union=(t1,t2) engine=merge;
insert into t1 (c) values ('test1');
insert into t1 (c) values ('test1');
insert into t1 (c) values ('test1');
@@ -229,7 +229,7 @@ drop table t3,t2,t1;
CREATE TABLE t1 (incr int not null, othr int not null, primary key(incr));
CREATE TABLE t2 (incr int not null, othr int not null, primary key(incr));
CREATE TABLE t3 (incr int not null, othr int not null, primary key(incr))
-TYPE=MERGE UNION=(t1,t2);
+ENGINE=MERGE UNION=(t1,t2);
SELECT * from t3;
incr othr
INSERT INTO t1 VALUES ( 1,10),( 3,53),( 5,21),( 7,12),( 9,17);
@@ -250,35 +250,35 @@ alter table t3 UNION=(t1,t2);
select count(*) from t3;
count(*)
20
-alter table t3 TYPE=MYISAM;
+alter table t3 ENGINE=MYISAM;
select count(*) from t3;
count(*)
20
drop table t3;
CREATE TABLE t3 (incr int not null, othr int not null, primary key(incr))
-TYPE=MERGE UNION=(t1,t2);
+ENGINE=MERGE UNION=(t1,t2);
show create table t3;
Table Create Table
t3 CREATE TABLE `t3` (
`incr` int(11) NOT NULL default '0',
`othr` int(11) NOT NULL default '0',
PRIMARY KEY (`incr`)
-) TYPE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`t2`)
+) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`t2`)
alter table t3 drop primary key;
show create table t3;
Table Create Table
t3 CREATE TABLE `t3` (
`incr` int(11) NOT NULL default '0',
`othr` int(11) NOT NULL default '0'
-) TYPE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`t2`)
+) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`t2`)
drop table t3,t2,t1;
-create table t1 (a int not null, key(a)) type=merge;
+create table t1 (a int not null, key(a)) engine=merge;
select * from t1;
a
drop table t1;
create table t1 (a int not null, b int not null, key(a,b));
create table t2 (a int not null, b int not null, key(a,b));
-create table t3 (a int not null, b int not null, key(a,b)) TYPE=MERGE UNION=(t1,t2);
+create table t3 (a int not null, b int not null, key(a,b)) ENGINE=MERGE UNION=(t1,t2);
insert into t1 values (1,2),(2,1),(0,0),(4,4),(5,5),(6,6);
insert into t2 values (1,1),(2,2),(0,0),(4,4),(5,5),(6,6);
flush tables;
@@ -290,37 +290,37 @@ drop table t3,t1,t2;
create table t1 (a int not null, b int not null auto_increment, primary key(a,b));
create table t2 (a int not null, b int not null auto_increment, primary key(a,b));
create table t3 (a int not null, b int not null, key(a,b)) UNION=(t1,t2) INSERT_METHOD=NO;
-create table t4 (a int not null, b int not null, key(a,b)) TYPE=MERGE UNION=(t1,t2) INSERT_METHOD=NO;
-create table t5 (a int not null, b int not null auto_increment, primary key(a,b)) TYPE=MERGE UNION=(t1,t2) INSERT_METHOD=FIRST;
-create table t6 (a int not null, b int not null auto_increment, primary key(a,b)) TYPE=MERGE UNION=(t1,t2) INSERT_METHOD=LAST;
+create table t4 (a int not null, b int not null, key(a,b)) ENGINE=MERGE UNION=(t1,t2) INSERT_METHOD=NO;
+create table t5 (a int not null, b int not null auto_increment, primary key(a,b)) ENGINE=MERGE UNION=(t1,t2) INSERT_METHOD=FIRST;
+create table t6 (a int not null, b int not null auto_increment, primary key(a,b)) ENGINE=MERGE UNION=(t1,t2) INSERT_METHOD=LAST;
show create table t3;
Table Create Table
t3 CREATE TABLE `t3` (
`a` int(11) NOT NULL default '0',
`b` int(11) NOT NULL default '0',
KEY `a` (`a`,`b`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
show create table t4;
Table Create Table
t4 CREATE TABLE `t4` (
`a` int(11) NOT NULL default '0',
`b` int(11) NOT NULL default '0',
KEY `a` (`a`,`b`)
-) TYPE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`t2`)
+) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`t2`)
show create table t5;
Table Create Table
t5 CREATE TABLE `t5` (
`a` int(11) NOT NULL default '0',
`b` int(11) NOT NULL auto_increment,
PRIMARY KEY (`a`,`b`)
-) TYPE=MRG_MyISAM DEFAULT CHARSET=latin1 INSERT_METHOD=FIRST UNION=(`t1`,`t2`)
+) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 INSERT_METHOD=FIRST UNION=(`t1`,`t2`)
show create table t6;
Table Create Table
t6 CREATE TABLE `t6` (
`a` int(11) NOT NULL default '0',
`b` int(11) NOT NULL auto_increment,
PRIMARY KEY (`a`,`b`)
-) TYPE=MRG_MyISAM DEFAULT CHARSET=latin1 INSERT_METHOD=LAST UNION=(`t1`,`t2`)
+) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 INSERT_METHOD=LAST UNION=(`t1`,`t2`)
insert into t1 values (1,NULL),(1,NULL),(1,NULL),(1,NULL);
insert into t2 values (2,NULL),(2,NULL),(2,NULL),(2,NULL);
select * from t3 order by b,a limit 3;
@@ -385,7 +385,7 @@ t4 CREATE TABLE `t4` (
`a` int(11) NOT NULL default '0',
`b` int(11) NOT NULL default '0',
KEY `a` (`a`,`b`)
-) TYPE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`t2`,`t3`)
+) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 UNION=(`t1`,`t2`,`t3`)
select * from t4 order by a,b;
a b
1 1
@@ -411,7 +411,7 @@ t4 CREATE TABLE `t4` (
`a` int(11) NOT NULL default '0',
`b` int(11) NOT NULL default '0',
KEY `a` (`a`,`b`)
-) TYPE=MRG_MyISAM DEFAULT CHARSET=latin1 INSERT_METHOD=FIRST UNION=(`t1`,`t2`,`t3`)
+) ENGINE=MRG_MyISAM DEFAULT CHARSET=latin1 INSERT_METHOD=FIRST UNION=(`t1`,`t2`,`t3`)
insert into t4 values (4,1),(4,2);
select * from t1 order by a,b;
a b
@@ -545,11 +545,11 @@ select * from t4 where a+0 > 90;
a b
99 1
drop table t6, t5, t4, t3, t2, t1;
-CREATE TABLE t1 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', PRIMARY KEY (a,b)) TYPE=MyISAM;
+CREATE TABLE t1 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', PRIMARY KEY (a,b)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,1), (2,1);
-CREATE TABLE t2 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', PRIMARY KEY (a,b)) TYPE=MyISAM;
+CREATE TABLE t2 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', PRIMARY KEY (a,b)) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,2), (2,2);
-CREATE TABLE t3 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', KEY a (a,b)) TYPE=MRG_MyISAM UNION=(t1,t2);
+CREATE TABLE t3 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', KEY a (a,b)) ENGINE=MRG_MyISAM UNION=(t1,t2);
select max(b) from t3 where a = 2;
max(b)
2
@@ -561,7 +561,7 @@ create table t1 (a int not null);
create table t2 (a int not null);
insert into t1 values (1);
insert into t2 values (2);
-create temporary table t3 (a int not null) TYPE=MERGE UNION=(t1,t2);
+create temporary table t3 (a int not null) ENGINE=MERGE UNION=(t1,t2);
select * from t3;
a
1
@@ -570,7 +570,7 @@ create temporary table t4 (a int not null);
create temporary table t5 (a int not null);
insert into t4 values (1);
insert into t5 values (2);
-create temporary table t6 (a int not null) TYPE=MERGE UNION=(t4,t5);
+create temporary table t6 (a int not null) ENGINE=MERGE UNION=(t4,t5);
select * from t6;
a
1
@@ -582,7 +582,7 @@ file_code varchar(32) NOT NULL default '',
fileset_root_id tinyint(3) unsigned NOT NULL default '0',
PRIMARY KEY (fileset_id,file_code),
KEY files (fileset_id,fileset_root_id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (2, '0000000111', 1), (2, '0000000112', 1), (2, '0000000113', 1),
(2, '0000000114', 1), (2, '0000000115', 1), (2, '0000000116', 1), (2, '0000000117', 1),
(2, '0000000118', 1), (2, '0000000119', 1), (2, '0000000120', 1);
@@ -592,7 +592,7 @@ file_code varchar(32) NOT NULL default '',
fileset_root_id tinyint(3) unsigned NOT NULL default '0',
PRIMARY KEY (fileset_id,file_code),
KEY files (fileset_id,fileset_root_id)
-) TYPE=MRG_MyISAM UNION=(t1);
+) ENGINE=MRG_MyISAM UNION=(t1);
EXPLAIN SELECT * FROM t2 IGNORE INDEX (files) WHERE fileset_id = 2
AND file_code BETWEEN '0000000115' AND '0000000120' LIMIT 1;
id select_type table type possible_keys key key_len ref rows Extra
@@ -612,7 +612,7 @@ id select_type table type possible_keys key key_len ref rows Extra
DROP TABLE t2, t1;
create table t1 (x int, y int, index xy(x, y));
create table t2 (x int, y int, index xy(x, y));
-create table t3 (x int, y int, index xy(x, y)) type=merge union=(t1,t2);
+create table t3 (x int, y int, index xy(x, y)) engine=merge union=(t1,t2);
insert into t1 values(1, 2);
insert into t2 values(1, 3);
select * from t3 where x = 1 and y < 5 order by y;
diff --git a/mysql-test/r/mix_innodb_myisam_binlog.result b/mysql-test/r/mix_innodb_myisam_binlog.result
index d6da3604fd2..54d99d5609e 100644
--- a/mysql-test/r/mix_innodb_myisam_binlog.result
+++ b/mysql-test/r/mix_innodb_myisam_binlog.result
@@ -1,6 +1,6 @@
drop table if exists t1, t2;
-create table t1 (a int) type=innodb;
-create table t2 (a int) type=myisam;
+create table t1 (a int) engine=innodb;
+create table t2 (a int) engine=myisam;
reset master;
begin;
insert into t1 values(1);
@@ -121,7 +121,7 @@ master-bin.000001 139 Query 1 139 use `test`; insert into t2 select * from t1
master-bin.000001 205 Query 1 205 use `test`; BEGIN
master-bin.000001 245 Query 1 205 use `test`; insert into t1 values(11)
master-bin.000001 305 Query 1 305 use `test`; COMMIT
-alter table t2 type=INNODB;
+alter table t2 engine=INNODB;
delete from t1;
delete from t2;
reset master;
diff --git a/mysql-test/r/multi_update.result b/mysql-test/r/multi_update.result
index b0d597f238a..38d60cd21d5 100644
--- a/mysql-test/r/multi_update.result
+++ b/mysql-test/r/multi_update.result
@@ -74,19 +74,19 @@ CREATE TABLE t1 (
id int(11) NOT NULL default '0',
name varchar(10) default NULL,
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,'aaa'),(2,'aaa'),(3,'aaa');
CREATE TABLE t2 (
id int(11) NOT NULL default '0',
name varchar(10) default NULL,
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (2,'bbb'),(3,'bbb'),(4,'bbb');
CREATE TABLE t3 (
id int(11) NOT NULL default '0',
mydate datetime default NULL,
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t3 VALUES (1,'2002-02-04 00:00:00'),(3,'2002-05-12 00:00:00'),(5,'2002-05-12 00:00:00'),(6,'2002-06-22
00:00:00'),(7,'2002-07-22 00:00:00');
delete t1,t2,t3 from t1,t2,t3 where to_days(now())-to_days(t3.mydate)>=30 and t3.id=t1.id and t3.id=t2.id;
@@ -102,7 +102,7 @@ CREATE TABLE IF NOT EXISTS `t1` (
`tst` text,
`tst1` text,
PRIMARY KEY (`id`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE IF NOT EXISTS `t2` (
`ID` int(11) NOT NULL auto_increment,
`ParId` int(11) default NULL,
@@ -111,7 +111,7 @@ CREATE TABLE IF NOT EXISTS `t2` (
PRIMARY KEY (`ID`),
KEY `IX_ParId_t2` (`ParId`),
FOREIGN KEY (`ParId`) REFERENCES `t1` (`id`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1(tst,tst1) VALUES("MySQL","MySQL AB"), ("MSSQL","Microsoft"), ("ORACLE","ORACLE");
INSERT INTO t2(ParId) VALUES(1), (2), (3);
select * from t2;
@@ -251,11 +251,11 @@ n d
select * from t2;
n d
drop table t1,t2;
-CREATE TABLE t1 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) TYPE=MyISAM;
+CREATE TABLE t1 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,'jedan'),(2,'dva'),(3,'tri'),(4,'xxxxxxxxxx'),(5,'a'),(10,''),(11,''),(12,''),(13,'');
-CREATE TABLE t2 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) TYPE=MyISAM;
+CREATE TABLE t2 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,'jedan'),(2,'dva'),(3,'tri'),(4,'xxxxxxxxxx'),(5,'a');
-CREATE TABLE t3 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) TYPE=MyISAM;
+CREATE TABLE t3 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) ENGINE=MyISAM;
INSERT INTO t3 VALUES (1,'jedan'),(2,'dva');
update t1,t2 set t1.naziv="aaaa" where t1.broj=t2.broj;
update t1,t2,t3 set t1.naziv="bbbb", t2.naziv="aaaa" where t1.broj=t2.broj and t2.broj=t3.broj;
@@ -324,7 +324,7 @@ a b
8 8
9 9
drop table t1,t2;
-CREATE TABLE t3 ( KEY1 varchar(50) NOT NULL default '', PARAM_CORR_DISTANCE_RUSH double default NULL, PARAM_CORR_DISTANCE_GEM double default NULL, PARAM_AVG_TARE double default NULL, PARAM_AVG_NB_DAYS double default NULL, PARAM_DEFAULT_PROP_GEM_SRVC varchar(50) default NULL, PARAM_DEFAULT_PROP_GEM_NO_ETIK varchar(50) default NULL, PARAM_SCENARIO_COSTS varchar(50) default NULL, PARAM_DEFAULT_WAGON_COST double default NULL, tmp int(11) default NULL, PRIMARY KEY (KEY1)) TYPE=MyISAM;
+CREATE TABLE t3 ( KEY1 varchar(50) NOT NULL default '', PARAM_CORR_DISTANCE_RUSH double default NULL, PARAM_CORR_DISTANCE_GEM double default NULL, PARAM_AVG_TARE double default NULL, PARAM_AVG_NB_DAYS double default NULL, PARAM_DEFAULT_PROP_GEM_SRVC varchar(50) default NULL, PARAM_DEFAULT_PROP_GEM_NO_ETIK varchar(50) default NULL, PARAM_SCENARIO_COSTS varchar(50) default NULL, PARAM_DEFAULT_WAGON_COST double default NULL, tmp int(11) default NULL, PRIMARY KEY (KEY1)) ENGINE=MyISAM;
INSERT INTO t3 VALUES ('A',1,1,22,3.2,'R','R','BASE2',0.24,NULL);
create table t1 (A varchar(1));
insert into t1 values ("A") ,("B"),("C"),("D");
diff --git a/mysql-test/r/myisam.result b/mysql-test/r/myisam.result
index 49475c9cbec..ec70cefc63f 100644
--- a/mysql-test/r/myisam.result
+++ b/mysql-test/r/myisam.result
@@ -3,7 +3,7 @@ SET SQL_WARNINGS=1;
CREATE TABLE t1 (
STRING_DATA char(255) default NULL,
KEY string_data (STRING_DATA)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA');
INSERT INTO t1 VALUES ('DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD');
INSERT INTO t1 VALUES ('FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF');
@@ -49,7 +49,7 @@ Table Non_unique Key_name Seq_in_index Column_name Collation Cardinality Sub_par
t1 0 PRIMARY 1 a A 5 NULL NULL BTREE
t1 1 b 1 b A 1 NULL NULL BTREE
drop table t1;
-create table t1 (a int not null, b int not null, c int not null, primary key (a),key(b)) type=myisam;
+create table t1 (a int not null, b int not null, c int not null, primary key (a),key(b)) engine=myisam;
insert into t1 values (3,3,3),(1,1,1),(2,2,2),(4,4,4);
explain select * from t1 order by a;
id select_type table type possible_keys key key_len ref rows Extra
@@ -313,7 +313,7 @@ KEY `ip` (`ip`),
KEY `poster_login` (`poster_login`),
KEY `topic_id` (`topic_id`),
FULLTEXT KEY `post_text` (`post_text`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (post_text) VALUES ('ceci est un test'),('ceci est un test'),('ceci est un test'),('ceci est un test'),('ceci est un test');
REPAIR TABLE t1;
Table Op Msg_type Msg_text
@@ -398,7 +398,7 @@ check table t1;
Table Op Msg_type Msg_text
test.t1 check status OK
drop table t1;
-CREATE TABLE t1 (`a` int(11) NOT NULL default '0', `b` int(11) NOT NULL default '0', UNIQUE KEY `a` USING RTREE (`a`,`b`)) TYPE=MyISAM;
+CREATE TABLE t1 (`a` int(11) NOT NULL default '0', `b` int(11) NOT NULL default '0', UNIQUE KEY `a` USING RTREE (`a`,`b`)) ENGINE=MyISAM;
ERROR 42000: This version of MySQL doesn't yet support 'RTREE INDEX'
create table t1 (a int, b varchar(200), c text not null) checksum=1;
create table t2 (a int, b varchar(200), c text not null) checksum=0;
diff --git a/mysql-test/r/null.result b/mysql-test/r/null.result
index f4decd3b79e..c4af221e117 100644
--- a/mysql-test/r/null.result
+++ b/mysql-test/r/null.result
@@ -71,7 +71,7 @@ indexed_field
NULL
NULL
DROP TABLE t1;
-create table t1 (a int, b int) type=myisam;
+create table t1 (a int, b int) engine=myisam;
insert into t1 values(20,null);
select t2.b, ifnull(t2.b,"this is null") from t1 as t2 left join t1 as t3 on
t2.b=t3.a;
diff --git a/mysql-test/r/null_key.result b/mysql-test/r/null_key.result
index 9aaea0d800b..385108216bf 100644
--- a/mysql-test/r/null_key.result
+++ b/mysql-test/r/null_key.result
@@ -1,5 +1,5 @@
drop table if exists t1,t2;
-create table t1 (a int, b int not null,unique key (a,b),index(b)) type=myisam;
+create table t1 (a int, b int not null,unique key (a,b),index(b)) engine=myisam;
insert ignore into t1 values (1,1),(2,2),(3,3),(4,4),(5,5),(6,6),(null,7),(9,9),(8,8),(7,7),(null,9),(null,9),(6,6);
explain select * from t1 where a is null;
id select_type table type possible_keys key key_len ref rows Extra
@@ -243,12 +243,12 @@ id int(10) unsigned NOT NULL auto_increment,
uniq_id int(10) unsigned default NULL,
PRIMARY KEY (id),
UNIQUE KEY idx1 (uniq_id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE t2 (
id int(10) unsigned NOT NULL auto_increment,
uniq_id int(10) unsigned default NULL,
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,NULL),(2,NULL),(3,1),(4,2),(5,NULL),(6,NULL),(7,3),(8,4),(9,NULL),(10,NULL);
INSERT INTO t2 VALUES (1,NULL),(2,NULL),(3,1),(4,2),(5,NULL),(6,NULL),(7,3),(8,4),(9,NULL),(10,NULL);
explain select id from t1 where uniq_id is null;
@@ -295,13 +295,13 @@ CREATE TABLE `t1` (
`product_id` char(32) NOT NULL default '',
`product_type` int(11) NOT NULL default '0',
PRIMARY KEY (`order_id`,`product_id`,`product_type`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE `t2` (
`order_id` char(32) NOT NULL default '',
`product_id` char(32) NOT NULL default '',
`product_type` int(11) NOT NULL default '0',
PRIMARY KEY (`order_id`,`product_id`,`product_type`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (order_id, product_id, product_type) VALUES
('3d7ce39b5d4b3e3d22aaafe9b633de51',1206029, 3),
('3d7ce39b5d4b3e3d22aaafe9b633de51',5880836, 3),
diff --git a/mysql-test/r/order_by.result b/mysql-test/r/order_by.result
index a37f7e3c485..a321e8a44f9 100644
--- a/mysql-test/r/order_by.result
+++ b/mysql-test/r/order_by.result
@@ -251,7 +251,7 @@ favo_muziek varchar(30) NOT NULL default '',
info text NOT NULL,
ipnr varchar(30) NOT NULL default '',
PRIMARY KEY (member_id)
-) TYPE=MyISAM PACK_KEYS=1;
+) ENGINE=MyISAM PACK_KEYS=1;
insert into t1 (member_id) values (1),(2),(3);
select member_id, nickname, voornaam FROM t1
ORDER by lastchange_datum DESC LIMIT 2;
@@ -429,7 +429,7 @@ gid int(10) unsigned NOT NULL auto_increment,
cid smallint(5) unsigned NOT NULL default '0',
PRIMARY KEY (gid),
KEY component_id (cid)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (103853,108),(103867,108),(103962,108),(104505,108),(104619,108),(104620,108);
ALTER TABLE t1 add skr int(10) not null;
CREATE TABLE t2 (
@@ -439,12 +439,12 @@ sid tinyint(3) unsigned NOT NULL default '1',
PRIMARY KEY (gid),
KEY uid (uid),
KEY status_id (sid)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (103853,250,5),(103867,27,5),(103962,27,5),(104505,117,5),(104619,75,5),(104620,15,5);
CREATE TABLE t3 (
uid smallint(6) NOT NULL auto_increment,
PRIMARY KEY (uid)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t3 VALUES (1),(15),(27),(75),(117),(250);
ALTER TABLE t3 add skr int(10) not null;
select t1.gid, t2.sid, t3.uid from t2, t1, t3 where t2.gid = t1.gid and t2.uid = t3.uid order by t3.uid, t1.gid;
diff --git a/mysql-test/r/query_cache.result b/mysql-test/r/query_cache.result
index e668b9031cc..bf658bae89e 100644
--- a/mysql-test/r/query_cache.result
+++ b/mysql-test/r/query_cache.result
@@ -44,7 +44,7 @@ create table t1 (a int not null);
insert into t1 values (1),(2),(3);
create table t2 (a int not null);
insert into t2 values (4),(5),(6);
-create table t3 (a int not null) type=MERGE UNION=(t1,t2) INSERT_METHOD=FIRST;
+create table t3 (a int not null) engine=MERGE UNION=(t1,t2) INSERT_METHOD=FIRST;
select * from t3;
a
1
diff --git a/mysql-test/r/range.result b/mysql-test/r/range.result
index 0c8f2cb5323..5e61b1c58c3 100644
--- a/mysql-test/r/range.result
+++ b/mysql-test/r/range.result
@@ -160,7 +160,7 @@ PRIMARY KEY (t1ID),
KEY IdxArt (art),
KEY IdxKnr (KNR),
KEY IdxArtnr (ARTNR)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (art) VALUES ('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),
('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),
('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),
@@ -267,7 +267,7 @@ a int(11) default NULL,
b int(11) default NULL,
KEY a (a),
KEY b (b)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES
(1,1),(2,1),(3,1),(4,1),(5,1),(6,1),(7,1),(8,1),(9,1),(10,2),(10,2),
(13,2),(14,2),(15,2),(16,2),(17,3),(17,3),(16,3),(17,3),(19,3),(20,3),
diff --git a/mysql-test/r/repair_part1.result b/mysql-test/r/repair_part1.result
index 27dfdac24f0..e0030327743 100644
--- a/mysql-test/r/repair_part1.result
+++ b/mysql-test/r/repair_part1.result
@@ -4,7 +4,7 @@ repair table t1 use_frm;
Table Op Msg_type Msg_text
test.t1 repair warning Number of rows changed from 0 to 1
test.t1 repair status OK
-alter table t1 TYPE=HEAP;
+alter table t1 ENGINE=HEAP;
repair table t1 use_frm;
Table Op Msg_type Msg_text
test.t1 repair error The storage engine for the table doesn't support repair
@@ -12,4 +12,4 @@ drop table t1;
repair table t1 use_frm;
Table Op Msg_type Msg_text
test.t1 repair error Table 'test.t1' doesn't exist
-create table t1 type=myisam SELECT 1,"table 1";
+create table t1 engine=myisam SELECT 1,"table 1";
diff --git a/mysql-test/r/replace.result b/mysql-test/r/replace.result
index 2d95343245b..83cde76215a 100644
--- a/mysql-test/r/replace.result
+++ b/mysql-test/r/replace.result
@@ -3,13 +3,13 @@ CREATE TABLE t1 (
gesuchnr int(11) DEFAULT '0' NOT NULL,
benutzer_id int(11) DEFAULT '0' NOT NULL,
PRIMARY KEY (gesuchnr,benutzer_id)
-) type=ISAM;
+) engine=ISAM;
replace into t1 (gesuchnr,benutzer_id) values (2,1);
replace into t1 (gesuchnr,benutzer_id) values (1,1);
replace into t1 (gesuchnr,benutzer_id) values (1,1);
-alter table t1 type=myisam;
+alter table t1 engine=myisam;
replace into t1 (gesuchnr,benutzer_id) values (1,1);
-alter table t1 type=heap;
+alter table t1 engine=heap;
replace into t1 (gesuchnr,benutzer_id) values (1,1);
drop table t1;
create table t1 (a tinyint not null auto_increment primary key, b char(20) default "default_value");
diff --git a/mysql-test/r/rollback.result b/mysql-test/r/rollback.result
index d87aa68dce4..e562b73c981 100644
--- a/mysql-test/r/rollback.result
+++ b/mysql-test/r/rollback.result
@@ -1,5 +1,5 @@
drop table if exists t1;
-create table t1 (n int not null primary key) type=myisam;
+create table t1 (n int not null primary key) engine=myisam;
begin work;
insert into t1 values (4);
insert into t1 values (5);
diff --git a/mysql-test/r/rpl000006.result b/mysql-test/r/rpl000006.result
index 7209ec3c3d1..e4c2006c2f0 100644
--- a/mysql-test/r/rpl000006.result
+++ b/mysql-test/r/rpl000006.result
@@ -19,7 +19,7 @@ drop table t1;
set SQL_LOG_BIN=0;
CREATE TABLE t1 (
a int not null
-) TYPE=MyISAM MAX_ROWS=4000 CHECKSUM=1;
+) ENGINE=MyISAM MAX_ROWS=4000 CHECKSUM=1;
INSERT INTO t1 VALUES (1);
load table t1 from master;
check table t1;
diff --git a/mysql-test/r/rpl_flush_tables.result b/mysql-test/r/rpl_flush_tables.result
index 6353a6101d6..70e4774a920 100644
--- a/mysql-test/r/rpl_flush_tables.result
+++ b/mysql-test/r/rpl_flush_tables.result
@@ -7,7 +7,7 @@ start slave;
create table t1 (a int);
insert into t1 values (10);
create table t2 (a int);
-create table t3 (a int) type=merge union(t1);
+create table t3 (a int) engine=merge union(t1);
create table t4 (a int);
insert into t4 select * from t3;
rename table t1 to t5, t2 to t1;
@@ -18,10 +18,10 @@ master-bin.000001 4 Start 1 4 Server ver: SERVER_VERSION, Binlog ver: 3
master-bin.000001 79 Query 1 79 use `test`; create table t1 (a int)
master-bin.000001 137 Query 1 137 use `test`; insert into t1 values (10)
master-bin.000001 198 Query 1 198 use `test`; create table t2 (a int)
-master-bin.000001 256 Query 1 256 use `test`; create table t3 (a int) type=merge union(t1)
-master-bin.000001 335 Query 1 335 use `test`; create table t4 (a int)
-master-bin.000001 393 Query 1 393 use `test`; insert into t4 select * from t3
-master-bin.000001 459 Query 1 459 use `test`; rename table t1 to t5, t2 to t1
+master-bin.000001 256 Query 1 256 use `test`; create table t3 (a int) engine=merge union(t1)
+master-bin.000001 337 Query 1 337 use `test`; create table t4 (a int)
+master-bin.000001 395 Query 1 395 use `test`; insert into t4 select * from t3
+master-bin.000001 461 Query 1 461 use `test`; rename table t1 to t5, t2 to t1
select * from t3;
a
flush tables;
@@ -31,10 +31,10 @@ master-bin.000001 4 Start 1 4 Server ver: SERVER_VERSION, Binlog ver: 3
master-bin.000001 79 Query 1 79 use `test`; create table t1 (a int)
master-bin.000001 137 Query 1 137 use `test`; insert into t1 values (10)
master-bin.000001 198 Query 1 198 use `test`; create table t2 (a int)
-master-bin.000001 256 Query 1 256 use `test`; create table t3 (a int) type=merge union(t1)
-master-bin.000001 335 Query 1 335 use `test`; create table t4 (a int)
-master-bin.000001 393 Query 1 393 use `test`; insert into t4 select * from t3
-master-bin.000001 459 Query 1 459 use `test`; rename table t1 to t5, t2 to t1
-master-bin.000001 525 Query 1 525 use `test`; flush tables
+master-bin.000001 256 Query 1 256 use `test`; create table t3 (a int) engine=merge union(t1)
+master-bin.000001 337 Query 1 337 use `test`; create table t4 (a int)
+master-bin.000001 395 Query 1 395 use `test`; insert into t4 select * from t3
+master-bin.000001 461 Query 1 461 use `test`; rename table t1 to t5, t2 to t1
+master-bin.000001 527 Query 1 527 use `test`; flush tables
select * from t3;
a
diff --git a/mysql-test/r/rpl_insert_id.result b/mysql-test/r/rpl_insert_id.result
index cf70e196921..6e331abf102 100644
--- a/mysql-test/r/rpl_insert_id.result
+++ b/mysql-test/r/rpl_insert_id.result
@@ -20,8 +20,8 @@ b c
1 4
drop table t1;
drop table t2;
-create table t1(a int auto_increment, key(a)) type=innodb;
-create table t2(b int auto_increment, c int, key(b), foreign key(b) references t1(a)) type=innodb;
+create table t1(a int auto_increment, key(a)) engine=innodb;
+create table t2(b int auto_increment, c int, key(b), foreign key(b) references t1(a)) engine=innodb;
SET FOREIGN_KEY_CHECKS=0;
insert into t1 values (10);
insert into t1 values (null),(null),(null);
diff --git a/mysql-test/r/rpl_relayrotate.result b/mysql-test/r/rpl_relayrotate.result
index 802be911ad7..bf9bbbb9b93 100644
--- a/mysql-test/r/rpl_relayrotate.result
+++ b/mysql-test/r/rpl_relayrotate.result
@@ -5,7 +5,7 @@ reset slave;
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8,t9;
start slave;
stop slave;
-create table t1 (a int) type=innodb;
+create table t1 (a int) engine=innodb;
reset slave;
start slave;
stop slave;
diff --git a/mysql-test/r/select.result b/mysql-test/r/select.result
index 8edd0182dec..30b391dd947 100644
--- a/mysql-test/r/select.result
+++ b/mysql-test/r/select.result
@@ -488,7 +488,7 @@ price2 double(11,0),
key (period),
key (name)
);
-create temporary table tmp type = myisam select * from t3;
+create temporary table tmp engine = myisam select * from t3;
insert into t3 select * from tmp;
insert into tmp select * from t3;
insert into t3 select * from tmp;
@@ -1288,7 +1288,7 @@ companynr tinyint(2) unsigned zerofill NOT NULL default '00',
companyname char(30) NOT NULL default '',
PRIMARY KEY (companynr),
UNIQUE KEY companyname(companyname)
-) TYPE=MyISAM MAX_ROWS=50 PACK_KEYS=1 COMMENT='companynames';
+) ENGINE=MyISAM MAX_ROWS=50 PACK_KEYS=1 COMMENT='companynames';
select STRAIGHT_JOIN t2.companynr,companyname from t4,t2 where t2.companynr=t4.companynr group by t2.companynr;
companynr companyname
00 Unknown
@@ -2067,9 +2067,9 @@ INSERT INTO t1 (pseudo) VALUES ('test1');
SELECT 1 as rnd1 from t1 where rand() > 2;
rnd1
DROP TABLE t1;
-CREATE TABLE t1 (gvid int(10) unsigned default NULL, hmid int(10) unsigned default NULL, volid int(10) unsigned default NULL, mmid int(10) unsigned default NULL, hdid int(10) unsigned default NULL, fsid int(10) unsigned default NULL, ctid int(10) unsigned default NULL, dtid int(10) unsigned default NULL, cost int(10) unsigned default NULL, performance int(10) unsigned default NULL, serialnumber bigint(20) unsigned default NULL, monitored tinyint(3) unsigned default '1', removed tinyint(3) unsigned default '0', target tinyint(3) unsigned default '0', dt_modified timestamp(14) NOT NULL, name varchar(255) binary default NULL, description varchar(255) default NULL, UNIQUE KEY hmid (hmid,volid)) TYPE=MyISAM;
+CREATE TABLE t1 (gvid int(10) unsigned default NULL, hmid int(10) unsigned default NULL, volid int(10) unsigned default NULL, mmid int(10) unsigned default NULL, hdid int(10) unsigned default NULL, fsid int(10) unsigned default NULL, ctid int(10) unsigned default NULL, dtid int(10) unsigned default NULL, cost int(10) unsigned default NULL, performance int(10) unsigned default NULL, serialnumber bigint(20) unsigned default NULL, monitored tinyint(3) unsigned default '1', removed tinyint(3) unsigned default '0', target tinyint(3) unsigned default '0', dt_modified timestamp(14) NOT NULL, name varchar(255) binary default NULL, description varchar(255) default NULL, UNIQUE KEY hmid (hmid,volid)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (200001,2,1,1,100,1,1,1,0,0,0,1,0,1,20020425060057,'\\\\ARKIVIO-TESTPDC\\E$',''),(200002,2,2,1,101,1,1,1,0,0,0,1,0,1,20020425060057,'\\\\ARKIVIO-TESTPDC\\C$',''),(200003,1,3,2,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,1,20020425060427,'c:',NULL);
-CREATE TABLE t2 ( hmid int(10) unsigned default NULL, volid int(10) unsigned default NULL, sampletid smallint(5) unsigned default NULL, sampletime datetime default NULL, samplevalue bigint(20) unsigned default NULL, KEY idx1 (hmid,volid,sampletid,sampletime)) TYPE=MyISAM;
+CREATE TABLE t2 ( hmid int(10) unsigned default NULL, volid int(10) unsigned default NULL, sampletid smallint(5) unsigned default NULL, sampletime datetime default NULL, samplevalue bigint(20) unsigned default NULL, KEY idx1 (hmid,volid,sampletid,sampletime)) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,3,10,'2002-06-01 08:00:00',35),(1,3,1010,'2002-06-01 12:00:01',35);
SELECT a.gvid, (SUM(CASE b.sampletid WHEN 140 THEN b.samplevalue ELSE 0 END)) as the_success,(SUM(CASE b.sampletid WHEN 141 THEN b.samplevalue ELSE 0 END)) as the_fail,(SUM(CASE b.sampletid WHEN 142 THEN b.samplevalue ELSE 0 END)) as the_size,(SUM(CASE b.sampletid WHEN 143 THEN b.samplevalue ELSE 0 END)) as the_time FROM t1 a, t2 b WHERE a.hmid = b.hmid AND a.volid = b.volid AND b.sampletime >= 'NULL' AND b.sampletime < 'NULL' AND b.sampletid IN (140, 141, 142, 143) GROUP BY a.gvid;
gvid the_success the_fail the_size the_time
@@ -2289,9 +2289,9 @@ a a a
2 2 2
3 3 3
drop table t1;
-CREATE TABLE t1 ( aa char(2), id int(11) NOT NULL auto_increment, t2_id int(11) NOT NULL default '0', PRIMARY KEY (id), KEY replace_id (t2_id)) TYPE=MyISAM;
+CREATE TABLE t1 ( aa char(2), id int(11) NOT NULL auto_increment, t2_id int(11) NOT NULL default '0', PRIMARY KEY (id), KEY replace_id (t2_id)) ENGINE=MyISAM;
INSERT INTO t1 VALUES ("1",8264,2506),("2",8299,2517),("3",8301,2518),("4",8302,2519),("5",8303,2520),("6",8304,2521),("7",8305,2522);
-CREATE TABLE t2 ( id int(11) NOT NULL auto_increment, PRIMARY KEY (id)) TYPE=MyISAM;
+CREATE TABLE t2 ( id int(11) NOT NULL auto_increment, PRIMARY KEY (id)) ENGINE=MyISAM;
INSERT INTO t2 VALUES (2517), (2518), (2519), (2520), (2521), (2522);
select * from t1, t2 WHERE t1.t2_id = t2.id and t1.t2_id > 0 order by t1.id LIMIT 0, 5;
aa id t2_id id
diff --git a/mysql-test/r/select_found.result b/mysql-test/r/select_found.result
index d79f45a9334..42f7257dbba 100644
--- a/mysql-test/r/select_found.result
+++ b/mysql-test/r/select_found.result
@@ -159,7 +159,7 @@ CREATE TABLE `t1` (
`maxnumrep` int(10) unsigned NOT NULL default '0',
PRIMARY KEY (`numeropost`),
KEY `maxnumrep` (`maxnumrep`)
-) TYPE=MyISAM ROW_FORMAT=FIXED;
+) ENGINE=MyISAM ROW_FORMAT=FIXED;
INSERT INTO t1 (titre,maxnumrep) VALUES
('test1','1'),('test2','2'),('test3','3');
SELECT SQL_CALC_FOUND_ROWS titre,numeropost,maxnumrep FROM t1 WHERE numeropost IN (1,2) ORDER BY maxnumrep DESC LIMIT 0, 1;
diff --git a/mysql-test/r/show_check.result b/mysql-test/r/show_check.result
index 2f29dcfdb47..f39fa3e7576 100644
--- a/mysql-test/r/show_check.result
+++ b/mysql-test/r/show_check.result
@@ -77,13 +77,13 @@ show create table t1;
Table Create Table
t1 CREATE TEMPORARY TABLE `t1` (
`a` int(11) NOT NULL default '0'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
alter table t1 rename t2;
show create table t2;
Table Create Table
t2 CREATE TEMPORARY TABLE `t2` (
`a` int(11) NOT NULL default '0'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t2;
create table t1 (
test_set set( 'val1', 'val2', 'val3' ) not null default '',
@@ -96,7 +96,7 @@ t1 CREATE TABLE `t1` (
`test_set` set('val1','val2','val3') NOT NULL default '',
`name` char(20) default 'O''Brien' COMMENT 'O''Brien as default',
`c` int(11) NOT NULL default '0' COMMENT 'int column'
-) TYPE=MyISAM DEFAULT CHARSET=latin1 COMMENT='it''s a table'
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 COMMENT='it''s a table'
show full columns from t1;
Field Type Collation Null Key Default Extra Privileges Comment
test_set set('val1','val2','val3') latin1_swedish_ci select,insert,update,references
@@ -109,7 +109,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) NOT NULL default '0',
UNIQUE KEY `aa` (`a`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (a int not null, primary key (a));
show create table t1;
@@ -117,7 +117,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) NOT NULL default '0',
PRIMARY KEY (`a`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
flush tables;
show open tables;
@@ -128,14 +128,14 @@ show open tables;
Database Table In_use Name_locked
test t1 0 0
drop table t1;
-create table t1 (a int not null, b VARCHAR(10), INDEX (b) ) AVG_ROW_LENGTH=10 CHECKSUM=1 COMMENT="test" TYPE=MYISAM MIN_ROWS=10 MAX_ROWS=100 PACK_KEYS=1 DELAY_KEY_WRITE=1 ROW_FORMAT=fixed;
+create table t1 (a int not null, b VARCHAR(10), INDEX (b) ) AVG_ROW_LENGTH=10 CHECKSUM=1 COMMENT="test" ENGINE=MYISAM MIN_ROWS=10 MAX_ROWS=100 PACK_KEYS=1 DELAY_KEY_WRITE=1 ROW_FORMAT=fixed;
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` int(11) NOT NULL default '0',
`b` char(10) default NULL,
KEY `b` (`b`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1 MIN_ROWS=10 MAX_ROWS=100 AVG_ROW_LENGTH=10 PACK_KEYS=1 CHECKSUM=1 DELAY_KEY_WRITE=1 ROW_FORMAT=FIXED COMMENT='test'
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 MIN_ROWS=10 MAX_ROWS=100 AVG_ROW_LENGTH=10 PACK_KEYS=1 CHECKSUM=1 DELAY_KEY_WRITE=1 ROW_FORMAT=FIXED COMMENT='test'
alter table t1 MAX_ROWS=200 ROW_FORMAT=dynamic PACK_KEYS=0;
show create table t1;
Table Create Table
@@ -143,7 +143,7 @@ t1 CREATE TABLE `t1` (
`a` int(11) NOT NULL default '0',
`b` varchar(10) default NULL,
KEY `b` (`b`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1 MIN_ROWS=10 MAX_ROWS=200 AVG_ROW_LENGTH=10 PACK_KEYS=0 CHECKSUM=1 DELAY_KEY_WRITE=1 ROW_FORMAT=DYNAMIC COMMENT='test'
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 MIN_ROWS=10 MAX_ROWS=200 AVG_ROW_LENGTH=10 PACK_KEYS=0 CHECKSUM=1 DELAY_KEY_WRITE=1 ROW_FORMAT=DYNAMIC COMMENT='test'
ALTER TABLE t1 AVG_ROW_LENGTH=0 CHECKSUM=0 COMMENT="" MIN_ROWS=0 MAX_ROWS=0 PACK_KEYS=DEFAULT DELAY_KEY_WRITE=0 ROW_FORMAT=default;
show create table t1;
Table Create Table
@@ -151,7 +151,7 @@ t1 CREATE TABLE `t1` (
`a` int(11) NOT NULL default '0',
`b` varchar(10) default NULL,
KEY `b` (`b`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (a decimal(9,2), b decimal (9,0), e double(9,2), f double(5,0), h float(3,2), i float(3,0));
show columns from t1;
@@ -194,7 +194,7 @@ type_blob blob,
type_medium_blob mediumblob,
type_long_blob longblob,
index(type_short)
-) AVG_ROW_LENGTH=10 CHECKSUM=1 COMMENT="test" TYPE=MYISAM MIN_ROWS=10 MAX_ROWS=100 PACK_KEYS=1 DELAY_KEY_WRITE=1 ROW_FORMAT=fixed CHARSET=latin1;
+) AVG_ROW_LENGTH=10 CHECKSUM=1 COMMENT="test" ENGINE=MYISAM MIN_ROWS=10 MAX_ROWS=100 PACK_KEYS=1 DELAY_KEY_WRITE=1 ROW_FORMAT=fixed CHARSET=latin1;
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
@@ -221,7 +221,7 @@ t1 CREATE TABLE `t1` (
`type_long_blob` longblob,
PRIMARY KEY (`type_tiny`),
KEY `type_short` (`type_short`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1 MIN_ROWS=10 MAX_ROWS=100 AVG_ROW_LENGTH=10 PACK_KEYS=1 CHECKSUM=1 DELAY_KEY_WRITE=1 ROW_FORMAT=FIXED COMMENT='test'
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 MIN_ROWS=10 MAX_ROWS=100 AVG_ROW_LENGTH=10 PACK_KEYS=1 CHECKSUM=1 DELAY_KEY_WRITE=1 ROW_FORMAT=FIXED COMMENT='test'
insert into t1 (type_timestamp) values ("2003-02-07 10:00:01");
select * from t1;
type_bool type_tiny type_short type_mediumint type_bigint type_decimal type_numeric empty_char type_char type_varchar type_timestamp type_date type_time type_datetime type_year type_enum type_set type_tinyblob type_blob type_medium_blob type_long_blob
diff --git a/mysql-test/r/sql_mode.result b/mysql-test/r/sql_mode.result
index dddfe2432ee..ddc848af1ed 100644
--- a/mysql-test/r/sql_mode.result
+++ b/mysql-test/r/sql_mode.result
@@ -5,7 +5,7 @@ a int not null auto_increment,
`email` varchar(60) character set latin2 NOT NULL default '',
PRIMARY KEY (a),
UNIQUE KEY `email` USING BTREE (`email`)
-) TYPE=HEAP CHARSET=latin1 ROW_FORMAT DYNAMIC;
+) ENGINE=HEAP CHARSET=latin1 ROW_FORMAT DYNAMIC;
set @@sql_mode="";
show variables like 'sql_mode';
Variable_name Value
@@ -18,7 +18,7 @@ t1 CREATE TABLE `t1` (
`email` varchar(60) character set latin2 NOT NULL default '',
PRIMARY KEY (`a`),
UNIQUE KEY `email` TYPE BTREE (`email`)
-) TYPE=HEAP DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
+) ENGINE=HEAP DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
set @@sql_mode="ansi_quotes";
show variables like 'sql_mode';
Variable_name Value
@@ -31,7 +31,7 @@ t1 CREATE TABLE "t1" (
"email" varchar(60) character set latin2 NOT NULL default '',
PRIMARY KEY ("a"),
UNIQUE KEY "email" TYPE BTREE ("email")
-) TYPE=HEAP DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
+) ENGINE=HEAP DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
set @@sql_mode="no_table_options";
show variables like 'sql_mode';
Variable_name Value
@@ -57,7 +57,7 @@ t1 CREATE TABLE `t1` (
`email` varchar(60) character set latin2 NOT NULL default '',
PRIMARY KEY (`a`),
UNIQUE KEY `email` (`email`)
-) TYPE=HEAP DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
+) ENGINE=HEAP DEFAULT CHARSET=latin1 ROW_FORMAT=DYNAMIC
set @@sql_mode="no_field_options,mysql323,mysql40";
show variables like 'sql_mode';
Variable_name Value
@@ -70,7 +70,7 @@ t1 CREATE TABLE `t1` (
`email` varchar(60) NOT NULL default '',
PRIMARY KEY (`a`),
UNIQUE KEY `email` (`email`)
-) TYPE=HEAP ROW_FORMAT=DYNAMIC
+) ENGINE=HEAP ROW_FORMAT=DYNAMIC
set sql_mode="postgresql,oracle,mssql,db2,maxdb";
select @@sql_mode;
@@sql_mode
diff --git a/mysql-test/r/status.result b/mysql-test/r/status.result
index 3ef6cec32b3..e9616232fa1 100644
--- a/mysql-test/r/status.result
+++ b/mysql-test/r/status.result
@@ -5,7 +5,7 @@ Table_locks_immediate 0
Table_locks_waited 0
SET SQL_LOG_BIN=0;
drop table if exists t1;
-create table t1(n int) type=myisam;
+create table t1(n int) engine=myisam;
insert into t1 values(1);
lock tables t1 read;
unlock tables;
diff --git a/mysql-test/r/subselect.result b/mysql-test/r/subselect.result
index 71755aac52d..672a39299dd 100644
--- a/mysql-test/r/subselect.result
+++ b/mysql-test/r/subselect.result
@@ -351,7 +351,7 @@ CREATE TABLE `t8` (
`email` varchar(60) character set latin1 NOT NULL default '',
PRIMARY KEY (`pseudo`),
UNIQUE KEY `email` (`email`)
-) TYPE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
INSERT INTO t8 (pseudo,email) VALUES ('joce','test');
INSERT INTO t8 (pseudo,email) VALUES ('joce1','test1');
INSERT INTO t8 (pseudo,email) VALUES ('2joce1','2test1');
@@ -381,7 +381,7 @@ CREATE TABLE `t1` (
`pseudo` varchar(35) character set latin1 NOT NULL default '',
PRIMARY KEY (`pseudo`,`date`,`topic`),
KEY `topic` (`topic`)
-) TYPE=MyISAM ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM ROW_FORMAT=DYNAMIC;
INSERT INTO t1 (topic,date,pseudo) VALUES
('43506','2002-10-02','joce'),('40143','2002-08-03','joce');
EXPLAIN EXTENDED SELECT DISTINCT date FROM t1 WHERE date='2002-08-03';
@@ -421,7 +421,7 @@ CREATE TABLE `t1` (
`maxnumrep` int(10) unsigned NOT NULL default '0',
PRIMARY KEY (`numeropost`),
UNIQUE KEY `maxnumrep` (`maxnumrep`)
-) TYPE=MyISAM ROW_FORMAT=FIXED;
+) ENGINE=MyISAM ROW_FORMAT=FIXED;
INSERT INTO t1 (numeropost,maxnumrep) VALUES (40143,1),(43506,2);
CREATE TABLE `t2` (
`mot` varchar(30) NOT NULL default '',
@@ -429,7 +429,7 @@ CREATE TABLE `t2` (
`date` date NOT NULL default '0000-00-00',
`pseudo` varchar(35) NOT NULL default '',
PRIMARY KEY (`mot`,`pseudo`,`date`,`topic`)
-) TYPE=MyISAM ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM ROW_FORMAT=DYNAMIC;
INSERT INTO t2 (mot,topic,date,pseudo) VALUES ('joce','40143','2002-10-22','joce'), ('joce','43506','2002-10-22','joce');
select numeropost as a FROM t1 GROUP BY (SELECT 1 FROM t1 HAVING a=1);
a
@@ -493,7 +493,7 @@ CREATE TABLE `t1` (
`maxnumrep` int(10) unsigned NOT NULL default '0',
PRIMARY KEY (`numeropost`),
UNIQUE KEY `maxnumrep` (`maxnumrep`)
-) TYPE=MyISAM ROW_FORMAT=FIXED;
+) ENGINE=MyISAM ROW_FORMAT=FIXED;
INSERT INTO t1 (numeropost,maxnumrep) VALUES (1,0),(2,1);
select numeropost as a FROM t1 GROUP BY (SELECT 1 FROM t1 HAVING a=1);
ERROR 21000: Subquery returns more than 1 row
@@ -520,7 +520,7 @@ CREATE TABLE `t1` (
PRIMARY KEY (`numeropost`,`numreponse`),
UNIQUE KEY `numreponse` (`numreponse`),
KEY `pseudo` (`pseudo`,`numeropost`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
SELECT (SELECT numeropost FROM t1 HAVING numreponse=a),numreponse FROM (SELECT * FROM t1) as a;
ERROR 42S22: Reference 'numreponse' not supported (forward reference in item list)
SELECT numreponse, (SELECT numeropost FROM t1 HAVING numreponse=a) FROM (SELECT * FROM t1) as a;
@@ -698,7 +698,7 @@ x y
drop table t1, t2, t3;
SELECT * FROM (SELECT 1) b WHERE 1 IN (SELECT *);
ERROR HY000: No tables used
-CREATE TABLE t2 (id int(11) default NULL, KEY id (id)) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t2 (id int(11) default NULL, KEY id (id)) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t2 VALUES (1),(2);
SELECT * FROM t2 WHERE id IN (SELECT 1);
id
@@ -742,7 +742,7 @@ SELECT * FROM t2;
id
1
2
-CREATE TABLE t1 (id int(11) default NULL, KEY id (id)) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t1 (id int(11) default NULL, KEY id (id)) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 values (1),(1);
UPDATE t2 SET id=(SELECT * FROM t1);
ERROR 21000: Subquery returns more than 1 row
@@ -990,7 +990,7 @@ a b
1 2
1 3
drop table t1, t2;
-CREATE TABLE `t1` (`i` int(11) NOT NULL default '0',PRIMARY KEY (`i`)) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE `t1` (`i` int(11) NOT NULL default '0',PRIMARY KEY (`i`)) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES (1);
UPDATE t1 SET i=i+1 WHERE i=(SELECT MAX(i));
ERROR HY000: Invalid use of group function
@@ -1023,7 +1023,7 @@ CREATE TABLE `t1` (
PRIMARY KEY (`mot`,`pseudo`,`date`,`topic`),
KEY `pseudo` (`pseudo`,`date`,`topic`),
KEY `topic` (`topic`)
-) TYPE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
CREATE TABLE `t2` (
`mot` varchar(30) character set latin1 NOT NULL default '',
`topic` mediumint(8) unsigned NOT NULL default '0',
@@ -1032,13 +1032,13 @@ CREATE TABLE `t2` (
PRIMARY KEY (`mot`,`pseudo`,`date`,`topic`),
KEY `pseudo` (`pseudo`,`date`,`topic`),
KEY `topic` (`topic`)
-) TYPE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
CREATE TABLE `t3` (
`numeropost` mediumint(8) unsigned NOT NULL auto_increment,
`maxnumrep` int(10) unsigned NOT NULL default '0',
PRIMARY KEY (`numeropost`),
UNIQUE KEY `maxnumrep` (`maxnumrep`)
-) TYPE=MyISAM CHARSET=latin1;
+) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES ('joce','1','','joce'),('test','2','','test');
Warnings:
Warning 1264 Data truncated for column 'date' at row 1
@@ -1071,7 +1071,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` bigint(1) NOT NULL default '0',
`(SELECT 1)` bigint(1) NOT NULL default '0'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
CREATE TABLE t1 SELECT * FROM (SELECT 1 as a,(SELECT a)) a;
SHOW CREATE TABLE t1;
@@ -1079,7 +1079,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` bigint(1) NOT NULL default '0',
`(SELECT a)` bigint(1) NOT NULL default '0'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
CREATE TABLE t1 SELECT * FROM (SELECT 1 as a,(SELECT a+0)) a;
SHOW CREATE TABLE t1;
@@ -1087,7 +1087,7 @@ Table Create Table
t1 CREATE TABLE `t1` (
`a` bigint(1) NOT NULL default '0',
`(SELECT a+0)` bigint(17) NOT NULL default '0'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
CREATE TABLE t1 SELECT (SELECT 1 as a UNION SELECT 1+1 limit 1,1) as a;
select * from t1;
@@ -1097,7 +1097,7 @@ SHOW CREATE TABLE t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` bigint(17) NOT NULL default '0'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (a int);
insert into t1 values (1), (2), (3);
@@ -1119,7 +1119,7 @@ t2 char(3) NOT NULL default '',
District char(20) NOT NULL default '',
Population int(11) NOT NULL default '0',
PRIMARY KEY (ID)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (130,'Sydney','AUS','New South Wales',3276207);
INSERT INTO t1 VALUES (131,'Melbourne','AUS','Victoria',2865329);
INSERT INTO t1 VALUES (132,'Brisbane','AUS','Queensland',1291117);
@@ -1140,7 +1140,7 @@ HeadOfState char(60) default NULL,
Capital int(11) default NULL,
Code2 char(2) NOT NULL default '',
PRIMARY KEY (Code)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES ('AUS','Australia','Oceania','Australia and New Zealand',7741220.00,1901,18886000,79.8,351182.00,392911.00,'Australia','Constitutional Monarchy, Federation','Elisabeth II',135,'AU');
INSERT INTO t2 VALUES ('AZE','Azerbaijan','Asia','Middle East',86600.00,1991,7734000,62.9,4127.00,4100.00,'Azärbaycan','Federal Republic','Heydär Äliyev',144,'AZ');
select t2.Continent, t1.Name, t1.Population from t2 LEFT JOIN t1 ON t2.Code = t1.t2 where t1.Population IN (select max(t1.Population) AS Population from t1, t2 where t1.t2 = t2.Code group by Continent);
@@ -1152,7 +1152,7 @@ CREATE TABLE `t1` (
`pseudo` varchar(35) character set latin1 NOT NULL default '',
PRIMARY KEY (`id`),
UNIQUE KEY `pseudo` (`pseudo`),
-) TYPE=MyISAM PACK_KEYS=1 ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM PACK_KEYS=1 ROW_FORMAT=DYNAMIC;
INSERT INTO t1 (pseudo) VALUES ('test');
SELECT 0 IN (SELECT 1 FROM t1 a);
0 IN (SELECT 1 FROM t1 a)
@@ -1177,7 +1177,7 @@ drop table t1;
CREATE TABLE `t1` (
`i` int(11) NOT NULL default '0',
PRIMARY KEY (`i`)
-) TYPE=MyISAM CHARSET=latin1;
+) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES (1);
UPDATE t1 SET i=i+(SELECT MAX(i) FROM (SELECT 1) t) WHERE i=(SELECT MAX(i));
ERROR HY000: Invalid use of group function
@@ -1188,12 +1188,12 @@ ERROR 42S02: Unknown table 't' in field list
drop table t1;
CREATE TABLE t1 (
id int(11) default NULL
-) TYPE=MyISAM CHARSET=latin1;
+) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES (1),(1),(2),(2),(1),(3);
CREATE TABLE t2 (
id int(11) default NULL,
name varchar(15) default NULL
-) TYPE=MyISAM CHARSET=latin1;
+) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t2 VALUES (4,'vita'), (1,'vita'), (2,'vita'), (1,'vita');
update t1, t2 set t2.name='lenka' where t2.id in (select id from t1);
select * from t2;
@@ -1227,7 +1227,7 @@ PRIMARY KEY (ID,SUB_ID),
UNIQUE KEY t1_PK (ID,SUB_ID),
KEY t1_FK (REF_ID,REF_SUB),
KEY t1_REFID (REF_ID)
-) TYPE=MyISAM CHARSET=cp1251;
+) ENGINE=MyISAM CHARSET=cp1251;
INSERT INTO t1 VALUES (1,0,NULL,NULL),(2,0,NULL,NULL);
SELECT DISTINCT REF_ID FROM t1 WHERE ID= (SELECT DISTINCT REF_ID FROM t1 WHERE ID=2);
REF_ID
@@ -1257,7 +1257,7 @@ CREATE TABLE `t1` (
PRIMARY KEY (`id`),
UNIQUE KEY `email` (`email`),
UNIQUE KEY `pseudo` (`pseudo`),
-) TYPE=MyISAM CHARSET=latin1 PACK_KEYS=1 ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM CHARSET=latin1 PACK_KEYS=1 ROW_FORMAT=DYNAMIC;
INSERT INTO t1 (id,pseudo,email) VALUES (1,'test','test'),(2,'test1','test1');
SELECT pseudo as a, pseudo as b FROM t1 GROUP BY (SELECT a) ORDER BY (SELECT id*1);
a b
@@ -1496,13 +1496,13 @@ id select_type table type possible_keys key key_len ref rows Extra
Warnings:
Note 1003 select high_priority test.t3.a AS `a` from test.t3 where <not>((test.t3.a <= <max>(select max(test.t2.b) AS `max(b)` from test.t2 group by test.t2.a)))
drop table t2, t3;
-CREATE TABLE `t1` ( `id` mediumint(9) NOT NULL auto_increment, `taskid` bigint(20) NOT NULL default '0', `dbid` int(11) NOT NULL default '0', `create_date` datetime NOT NULL default '0000-00-00 00:00:00', `last_update` datetime NOT NULL default '0000-00-00 00:00:00', PRIMARY KEY (`id`)) TYPE=MyISAM CHARSET=latin1 AUTO_INCREMENT=3 ;
+CREATE TABLE `t1` ( `id` mediumint(9) NOT NULL auto_increment, `taskid` bigint(20) NOT NULL default '0', `dbid` int(11) NOT NULL default '0', `create_date` datetime NOT NULL default '0000-00-00 00:00:00', `last_update` datetime NOT NULL default '0000-00-00 00:00:00', PRIMARY KEY (`id`)) ENGINE=MyISAM CHARSET=latin1 AUTO_INCREMENT=3 ;
INSERT INTO `t1` (`id`, `taskid`, `dbid`, `create_date`,`last_update`) VALUES (1, 1, 15, '2003-09-29 10:31:36', '2003-09-29 10:31:36'), (2, 1, 21, now(), now());
-CREATE TABLE `t2` (`db_id` int(11) NOT NULL auto_increment,`name` varchar(200) NOT NULL default '',`primary_uid` smallint(6) NOT NULL default '0',`secondary_uid` smallint(6) NOT NULL default '0',PRIMARY KEY (`db_id`),UNIQUE KEY `name_2` (`name`),FULLTEXT KEY `name` (`name`)) TYPE=MyISAM CHARSET=latin1 AUTO_INCREMENT=2147483647;
+CREATE TABLE `t2` (`db_id` int(11) NOT NULL auto_increment,`name` varchar(200) NOT NULL default '',`primary_uid` smallint(6) NOT NULL default '0',`secondary_uid` smallint(6) NOT NULL default '0',PRIMARY KEY (`db_id`),UNIQUE KEY `name_2` (`name`),FULLTEXT KEY `name` (`name`)) ENGINE=MyISAM CHARSET=latin1 AUTO_INCREMENT=2147483647;
INSERT INTO `t2` (`db_id`, `name`, `primary_uid`, `secondary_uid`) VALUES (18, 'Not Set 1', 0, 0),(19, 'Valid', 1, 2),(20, 'Valid 2', 1, 2),(21, 'Should Not Return', 1, 2),(26, 'Not Set 2', 0, 0),(-1, 'ALL DB\'S', 0, 0);
-CREATE TABLE `t3` (`taskgenid` mediumint(9) NOT NULL auto_increment,`dbid` int(11) NOT NULL default '0',`taskid` int(11) NOT NULL default '0',`mon` tinyint(4) NOT NULL default '1',`tues` tinyint(4) NOT NULL default '1',`wed` tinyint(4) NOT NULL default '1',`thur` tinyint(4) NOT NULL default '1',`fri` tinyint(4) NOT NULL default '1',`sat` tinyint(4) NOT NULL default '0',`sun` tinyint(4) NOT NULL default '0',`how_often` smallint(6) NOT NULL default '1',`userid` smallint(6) NOT NULL default '0',`active` tinyint(4) NOT NULL default '1',PRIMARY KEY (`taskgenid`)) TYPE=MyISAM CHARSET=latin1 AUTO_INCREMENT=2 ;
+CREATE TABLE `t3` (`taskgenid` mediumint(9) NOT NULL auto_increment,`dbid` int(11) NOT NULL default '0',`taskid` int(11) NOT NULL default '0',`mon` tinyint(4) NOT NULL default '1',`tues` tinyint(4) NOT NULL default '1',`wed` tinyint(4) NOT NULL default '1',`thur` tinyint(4) NOT NULL default '1',`fri` tinyint(4) NOT NULL default '1',`sat` tinyint(4) NOT NULL default '0',`sun` tinyint(4) NOT NULL default '0',`how_often` smallint(6) NOT NULL default '1',`userid` smallint(6) NOT NULL default '0',`active` tinyint(4) NOT NULL default '1',PRIMARY KEY (`taskgenid`)) ENGINE=MyISAM CHARSET=latin1 AUTO_INCREMENT=2 ;
INSERT INTO `t3` (`taskgenid`, `dbid`, `taskid`, `mon`, `tues`,`wed`, `thur`, `fri`, `sat`, `sun`, `how_often`, `userid`, `active`) VALUES (1,-1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 1);
-CREATE TABLE `t4` (`task_id` smallint(6) NOT NULL default '0',`description` varchar(200) NOT NULL default '') TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE `t4` (`task_id` smallint(6) NOT NULL default '0',`description` varchar(200) NOT NULL default '') ENGINE=MyISAM CHARSET=latin1;
INSERT INTO `t4` (`task_id`, `description`) VALUES (1, 'Daily Check List'),(2, 'Weekly Status');
select dbid, name, (date_format(now() , '%Y-%m-%d') - INTERVAL how_often DAY) >= ifnull((SELECT date_format(max(create_date),'%Y-%m-%d') FROM t1 WHERE dbid = b.db_id AND taskid = a.taskgenid), '1950-01-01') from t3 a, t2 b, t4 WHERE dbid = - 1 AND primary_uid = '1' AND t4.task_id = taskid;
dbid name (date_format(now() , '%Y-%m-%d') - INTERVAL how_often DAY) >= ifnull((SELECT date_format(max(create_date),'%Y-%m-%d') FROM t1 WHERE dbid = b.db_id AND taskid = a.taskgenid), '1950-01-01')
@@ -1514,9 +1514,9 @@ dbid name
-1 Valid
-1 Valid 2
drop table t1,t2,t3,t4;
-CREATE TABLE t1 (id int(11) default NULL) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t1 (id int(11) default NULL) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES (1),(5);
-CREATE TABLE t2 (id int(11) default NULL) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t2 (id int(11) default NULL) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t2 VALUES (2),(6);
select * from t1 where (1,2,6) in (select * from t2);
ERROR 21000: Operand should contain 3 column(s)
@@ -1542,9 +1542,9 @@ id select_type table type possible_keys key key_len ref rows Extra
2 SUBQUERY t1 system NULL NULL NULL NULL 1
3 UNION t1 system NULL NULL NULL NULL 1
drop table t1;
-CREATE TABLE t1 (number char(11) NOT NULL default '') TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t1 (number char(11) NOT NULL default '') ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES ('69294728265'),('18621828126'),('89356874041'),('95895001874');
-CREATE TABLE t2 (code char(5) NOT NULL default '',UNIQUE KEY code (code)) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t2 (code char(5) NOT NULL default '',UNIQUE KEY code (code)) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t2 VALUES ('1'),('1226'),('1245'),('1862'),('18623'),('1874'),('1967'),('6');
select c.number as phone,(select p.code from t2 p where c.number like concat(p.code, '%') order by length(p.code) desc limit 1) as code from t1 c;
phone code
diff --git a/mysql-test/r/subselect2.result b/mysql-test/r/subselect2.result
index 98df44553d2..b04fec26c6f 100644
--- a/mysql-test/r/subselect2.result
+++ b/mysql-test/r/subselect2.result
@@ -12,7 +12,7 @@ DOCID VARCHAR(32)BINARY NOT NULL
, MODIFIER VARCHAR(255)BINARY
, ORIGINATOR INTEGER
, PRIMARY KEY ( DOCID )
-) TYPE=InnoDB
+) ENGINE=InnoDB
;
CREATE TABLE t2
(
@@ -36,7 +36,7 @@ DOCID VARCHAR(32)BINARY NOT NULL
, PUBLISHSTATUS INTEGER
, ORIGINATOR INTEGER
, PRIMARY KEY ( DOCID )
-) TYPE=InnoDB
+) ENGINE=InnoDB
;
CREATE INDEX DDOCTYPEID_IDX ON t2 (DOCTYPEID);
CREATE INDEX DFOLDERID_IDX ON t2 (FOLDERID);
@@ -55,7 +55,7 @@ FOLDERID VARCHAR(32)BINARY NOT NULL
, REPID VARCHAR(32)BINARY
, ORIGINATOR INTEGER
, PRIMARY KEY ( FOLDERID )
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
CREATE INDEX FFOLDERID_IDX ON t3 (FOLDERID);
CREATE INDEX CMFLDRPARNT_IDX ON t3 (PARENTID);
CREATE TABLE t4
@@ -68,7 +68,7 @@ DOCTYPEID VARCHAR(32)BINARY NOT NULL
, MODIFIER VARCHAR(255)BINARY
, ORIGINATOR INTEGER
, PRIMARY KEY ( DOCTYPEID )
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t2 VALUES("c373e9f59cf15a6c3e57444553544200", "c373e9f59cf15a6c3e57444553544200", "340d243d45f111d497b00010a4ef934d", "2f6161e879db43c1a5b82c21ddc49089", NULL, "2003-06-06 07:48:42", NULL, NULL, NULL, "2003-06-06 07:48:42", "2003-06-06 07:48:42", NULL, NULL, NULL, "03eea05112b845949f3fd03278b5fe43", "2003-06-06 07:48:42", "admin", "0", NULL);
INSERT INTO t2 VALUES("c373e9f5a472f43ba45e444553544200", "c373e9f5a472f43ba45e444553544200", "340d243d45f111d497b00010a4ef934d", "2f6161e879db43c1a5b82c21ddc49089", NULL, "2003-06-07 18:50:12", NULL, NULL, NULL, "2003-06-07 18:50:12", "2003-06-07 18:50:12", NULL, NULL, NULL, "03eea05112b845949f3fd03278b5fe43", "2003-06-07 18:50:12", "admin", "0", NULL);
INSERT INTO t2 VALUES("c373e9f5a4a0f56014eb444553544200", "c373e9f5a4a0f56014eb444553544200", "340d243d45f111d497b00010a4ef934d", "2f6161e879db43c1a5b82c21ddc49089", NULL, "2003-06-07 19:39:26", NULL, NULL, NULL, "2003-06-07 19:39:26", "2003-06-07 19:39:26", NULL, NULL, NULL, "03eea05112b845949f3fd03278b5fe43", "2003-06-07 19:39:26", "admin", "0", NULL);
diff --git a/mysql-test/r/subselect_innodb.result b/mysql-test/r/subselect_innodb.result
index 2f5b92fd05d..6729916f1c8 100644
--- a/mysql-test/r/subselect_innodb.result
+++ b/mysql-test/r/subselect_innodb.result
@@ -14,7 +14,7 @@ FOLDERID VARCHAR(32)BINARY NOT NULL
, REPID VARCHAR(32)BINARY
, ORIGINATOR INTEGER
, PRIMARY KEY ( FOLDERID )
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
CREATE INDEX FFOLDERID_IDX ON t1 (FOLDERID);
CREATE INDEX CMFLDRPARNT_IDX ON t1 (PARENTID);
INSERT INTO t1 VALUES("0c9aab05b15048c59bc35c8461507deb", "System", "System", "2003-06-05 16:30:00", "The system content repository folder.", "3", "2003-06-05 16:30:00", "System", "0", NULL, "9c9aab05b15048c59bc35c8461507deb", "1");
@@ -24,9 +24,9 @@ SELECT 'c373e9f5ad0791a0dab5444553544200' IN(SELECT t1.FOLDERID FROM t1 WHERE t1
'c373e9f5ad0791a0dab5444553544200' IN(SELECT t1.FOLDERID FROM t1 WHERE t1.PARENTID='2f6161e879db43c1a5b82c21ddc49089' AND t1.FOLDERNAME = 'Level1')
0
drop table t1;
-create table t1 (a int) type=innodb;
-create table t2 (a int) type=innodb;
-create table t3 (a int) type=innodb;
+create table t1 (a int) engine=innodb;
+create table t2 (a int) engine=innodb;
+create table t3 (a int) engine=innodb;
insert into t1 values (1),(2),(3),(4);
insert into t2 values (10),(20),(30),(40);
insert into t3 values (1),(2),(10),(50);
@@ -39,12 +39,12 @@ drop table t1,t2,t3;
CREATE TABLE t1 (
processor_id INTEGER NOT NULL,
PRIMARY KEY (processor_id)
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
CREATE TABLE t3 (
yod_id BIGINT UNSIGNED AUTO_INCREMENT NOT NULL,
login_processor INTEGER UNSIGNED ,
PRIMARY KEY (yod_id)
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
CREATE TABLE t2 (
processor_id INTEGER NOT NULL,
yod_id BIGINT UNSIGNED NOT NULL,
@@ -53,7 +53,7 @@ INDEX (processor_id),
INDEX (yod_id),
FOREIGN KEY (processor_id) REFERENCES t1(processor_id),
FOREIGN KEY (yod_id) REFERENCES t3(yod_id)
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t1 VALUES (1),(2),(3);
INSERT INTO t3 VALUES (1,1),(2,2),(3,3);
INSERT INTO t2 VALUES (1,1),(2,2),(3,3);
diff --git a/mysql-test/r/symlink.result b/mysql-test/r/symlink.result
index a56fe3e1462..48a44fc2b44 100644
--- a/mysql-test/r/symlink.result
+++ b/mysql-test/r/symlink.result
@@ -40,7 +40,7 @@ t9 CREATE TABLE `t9` (
`b` char(16) NOT NULL default '',
`c` int(11) NOT NULL default '0',
PRIMARY KEY (`a`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1 DATA DIRECTORY='TEST_DIR/var/tmp/' INDEX DIRECTORY='TEST_DIR/var/run/'
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 DATA DIRECTORY='TEST_DIR/var/tmp/' INDEX DIRECTORY='TEST_DIR/var/run/'
alter table t9 rename t8, add column d int not null;
alter table t8 rename t7;
rename table t7 to t9;
@@ -62,5 +62,5 @@ t9 CREATE TABLE `t9` (
`c` int(11) NOT NULL default '0',
`d` int(11) NOT NULL default '0',
PRIMARY KEY (`a`)
-) TYPE=MyISAM DEFAULT CHARSET=latin1 DATA DIRECTORY='TEST_DIR/var/tmp/' INDEX DIRECTORY='TEST_DIR/var/run/'
+) ENGINE=MyISAM DEFAULT CHARSET=latin1 DATA DIRECTORY='TEST_DIR/var/tmp/' INDEX DIRECTORY='TEST_DIR/var/run/'
drop database mysqltest;
diff --git a/mysql-test/r/temp_table.result b/mysql-test/r/temp_table.result
index fbc5c234256..10c0a2e3652 100644
--- a/mysql-test/r/temp_table.result
+++ b/mysql-test/r/temp_table.result
@@ -21,8 +21,8 @@ a b
4 e
5 f
6 g
-create TEMPORARY TABLE t2 type=heap select * from t1;
-create TEMPORARY TABLE IF NOT EXISTS t2 (a int) type=heap;
+create TEMPORARY TABLE t2 engine=heap select * from t1;
+create TEMPORARY TABLE IF NOT EXISTS t2 (a int) engine=heap;
CREATE TEMPORARY TABLE t1 (a int not null, b char (10) not null);
ERROR 42S01: Table 't1' already exists
ALTER TABLE t1 RENAME t2;
@@ -78,7 +78,7 @@ ERROR 23000: Duplicate entry '1' for key 1
drop table t1;
CREATE TABLE t1 (
d datetime default NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('2002-10-24 14:50:32'),('2002-10-24 14:50:33'),('2002-10-24 14:50:34'),('2002-10-24 14:50:34'),('2002-10-24 14:50:34'),('2002-10-24 14:50:35'),('2002-10-24 14:50:35'),('2002-10-24 14:50:35'),('2002-10-24 14:50:35'),('2002-10-24 14:50:36'),('2002-10-24 14:50:36'),('2002-10-24 14:50:36'),('2002-10-24 14:50:36'),('2002-10-24 14:50:37'),('2002-10-24 14:50:37'),('2002-10-24 14:50:37'),('2002-10-24 14:50:37'),('2002-10-24 14:50:38'),('2002-10-24 14:50:38'),('2002-10-24 14:50:38'),('2002-10-24 14:50:39'),('2002-10-24 14:50:39'),('2002-10-24 14:50:39'),('2002-10-24 14:50:39'),('2002-10-24 14:50:40'),('2002-10-24 14:50:40'),('2002-10-24 14:50:40');
flush status;
select * from t1 group by d;
diff --git a/mysql-test/r/type_blob.result b/mysql-test/r/type_blob.result
index c521aa0296c..a69e3308f0a 100644
--- a/mysql-test/r/type_blob.result
+++ b/mysql-test/r/type_blob.result
@@ -23,7 +23,7 @@ Table Create Table
t3 CREATE TABLE `t3` (
`a` mediumtext,
`b` mediumblob
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1,t2,t3
#;
CREATE TABLE t1 (a char(257) default "hello");
diff --git a/mysql-test/r/type_datetime.result b/mysql-test/r/type_datetime.result
index 95e64a2a70e..204266d6ec2 100644
--- a/mysql-test/r/type_datetime.result
+++ b/mysql-test/r/type_datetime.result
@@ -71,7 +71,7 @@ CREATE TABLE `t1` (
PRIMARY KEY (`numfacture`),
KEY `date` (`date`),
KEY `expedition` (`expedition`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (expedition) VALUES ('0001-00-00 00:00:00');
SELECT * FROM t1 WHERE expedition='0001-00-00 00:00:00';
date numfacture expedition
diff --git a/mysql-test/r/type_enum.result b/mysql-test/r/type_enum.result
index f30feb4c0e6..42ee54ce105 100644
--- a/mysql-test/r/type_enum.result
+++ b/mysql-test/r/type_enum.result
@@ -1627,12 +1627,12 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` enum('','a','b') NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (a enum (' ','a','b ') not null default 'b ');
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` enum('','a','b') NOT NULL default 'b'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
diff --git a/mysql-test/r/type_nchar.result b/mysql-test/r/type_nchar.result
index 63193418f77..f844b3b0241 100644
--- a/mysql-test/r/type_nchar.result
+++ b/mysql-test/r/type_nchar.result
@@ -4,47 +4,47 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` char(10) character set utf8 default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (c national char(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` char(10) character set utf8 default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (c national varchar(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` varchar(10) character set utf8 default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (c nvarchar(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` varchar(10) character set utf8 default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (c nchar varchar(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` varchar(10) character set utf8 default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (c national character varying(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` varchar(10) character set utf8 default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (c nchar varying(10));
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`c` varchar(10) character set utf8 default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
diff --git a/mysql-test/r/type_set.result b/mysql-test/r/type_set.result
index e98ec2c3fc4..084e004cd47 100644
--- a/mysql-test/r/type_set.result
+++ b/mysql-test/r/type_set.result
@@ -4,14 +4,14 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` set('','a','b') NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (a set (' ','a','b ') not null default 'b ');
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` set('','a','b') NOT NULL default 'b'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
-CREATE TABLE t1 ( user varchar(64) NOT NULL default '', path varchar(255) NOT NULL default '', privilege set('select','RESERVED30','RESERVED29','RESERVED28','RESERVED27','RESERVED26', 'RESERVED25','RESERVED24','data.delete','RESERVED22','RESERVED21', 'RESERVED20','data.insert.none','data.insert.approve', 'data.insert.delete','data.insert.move','data.insert.propose', 'data.insert.reject','RESERVED13','RESERVED12','RESERVED11','RESERVED10', 'RESERVED09','data.update','RESERVED07','RESERVED06','RESERVED05', 'RESERVED04','metadata.delete','metadata.put','RESERVED01','RESERVED00') NOT NULL default '', KEY user (user) ) TYPE=MyISAM CHARSET=utf8;
+CREATE TABLE t1 ( user varchar(64) NOT NULL default '', path varchar(255) NOT NULL default '', privilege set('select','RESERVED30','RESERVED29','RESERVED28','RESERVED27','RESERVED26', 'RESERVED25','RESERVED24','data.delete','RESERVED22','RESERVED21', 'RESERVED20','data.insert.none','data.insert.approve', 'data.insert.delete','data.insert.move','data.insert.propose', 'data.insert.reject','RESERVED13','RESERVED12','RESERVED11','RESERVED10', 'RESERVED09','data.update','RESERVED07','RESERVED06','RESERVED05', 'RESERVED04','metadata.delete','metadata.put','RESERVED01','RESERVED00') NOT NULL default '', KEY user (user) ) ENGINE=MyISAM CHARSET=utf8;
DROP TABLE t1;
diff --git a/mysql-test/r/union.result b/mysql-test/r/union.result
index 642c07904b5..b3bf95bdf3d 100644
--- a/mysql-test/r/union.result
+++ b/mysql-test/r/union.result
@@ -168,7 +168,7 @@ CREATE TABLE t1 (
`same` tinyint(1) unsigned NOT NULL default '1',
PRIMARY KEY (`pseudo1`),
KEY `pseudo` (`pseudo`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (pseudo,pseudo1,same) VALUES ('joce', 'testtt', 1),('joce', 'tsestset', 1),('dekad', 'joce', 1);
SELECT pseudo FROM t1 WHERE pseudo1='joce' UNION SELECT pseudo FROM t1 WHERE pseudo='joce';
pseudo
@@ -435,9 +435,9 @@ a
(SELECT * FROM t1) UNION all (SELECT SQL_CALC_FOUND_ROWS * FROM t2) LIMIT 1;
ERROR 42000: Wrong usage/placement of 'SQL_CALC_FOUND_ROWS'
drop table t1,t2;
-CREATE TABLE t1 ( id int(3) unsigned default '0') TYPE=MyISAM;
+CREATE TABLE t1 ( id int(3) unsigned default '0') ENGINE=MyISAM;
INSERT INTO t1 (id) VALUES("1");
-CREATE TABLE t2 ( id int(3) unsigned default '0', id_master int(5) default '0', text1 varchar(5) default NULL, text2 varchar(5) default NULL) TYPE=MyISAM;
+CREATE TABLE t2 ( id int(3) unsigned default '0', id_master int(5) default '0', text1 varchar(5) default NULL, text2 varchar(5) default NULL) ENGINE=MyISAM;
INSERT INTO t2 (id, id_master, text1, text2) VALUES("1", "1",
"foo1", "bar1");
INSERT INTO t2 (id, id_master, text1, text2) VALUES("2", "1",
@@ -532,7 +532,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` char(2) NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT 12 as a UNION select "aa" as a;
select * from t1;
@@ -543,7 +543,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` char(2) NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT 12 as a UNION select 12.2 as a;
select * from t1;
@@ -554,7 +554,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` double(4,1) NOT NULL default '0.0'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t2 (it1 tinyint, it2 tinyint not null, i int not null, ib bigint, f float, d double, y year, da date, dt datetime, sc char(10), sv varchar(10), b blob, tx text);
insert into t2 values (NULL, 1, 3, 4, 1.5, 2.5, 1972, '1972-10-22', '1972-10-22 11:50', 'testc', 'testv', 'tetetetetest', 'teeeeeeeeeeeest');
@@ -567,7 +567,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`it2` tinyint(4) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT it2 from t2 UNION select i from t2;
select * from t1;
@@ -578,7 +578,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`it2` int(11) NOT NULL default '0'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT i from t2 UNION select f from t2;
select * from t1;
@@ -589,7 +589,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`i` double default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT f from t2 UNION select d from t2;
select * from t1;
@@ -600,7 +600,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`f` double default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT ib from t2 UNION select f from t2;
select * from t1;
@@ -611,7 +611,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`ib` double default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT ib from t2 UNION select d from t2;
select * from t1;
@@ -622,7 +622,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`ib` double default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT f from t2 UNION select y from t2;
select * from t1;
@@ -633,7 +633,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`f` float default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT f from t2 UNION select da from t2;
select * from t1;
@@ -644,7 +644,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`f` char(12) binary default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT y from t2 UNION select da from t2;
select * from t1;
@@ -655,7 +655,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`y` char(10) binary default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT y from t2 UNION select dt from t2;
select * from t1;
@@ -666,7 +666,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`y` char(19) binary default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT da from t2 UNION select dt from t2;
select * from t1;
@@ -677,7 +677,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`da` datetime default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT dt from t2 UNION select sc from t2;
select * from t1;
@@ -688,7 +688,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`dt` char(19) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT dt from t2 UNION select sv from t2;
select * from t1;
@@ -699,7 +699,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`dt` char(19) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT sc from t2 UNION select sv from t2;
select * from t1;
@@ -710,7 +710,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`sc` varchar(10) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT dt from t2 UNION select b from t2;
select * from t1;
@@ -721,7 +721,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`dt` longblob
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT sv from t2 UNION select b from t2;
select * from t1;
@@ -732,7 +732,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`sv` longblob
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT i from t2 UNION select d from t2 UNION select b from t2;
select * from t1;
@@ -744,7 +744,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`i` blob
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT sv from t2 UNION select tx from t2;
select * from t1;
@@ -755,7 +755,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`sv` text
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 SELECT b from t2 UNION select tx from t2;
select * from t1;
@@ -766,7 +766,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`b` longblob
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1,t2;
create table t1 (d decimal(10,1));
create table t2 (d decimal(10,9));
@@ -781,7 +781,7 @@ show create table t3;
Table Create Table
t3 CREATE TABLE `t3` (
`d` decimal(10,9) default NULL
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1,t2,t3;
create table t1 select 1 union select -1;
select * from t1;
@@ -792,7 +792,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`1` bigint(1) NOT NULL default '0'
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 select _latin1"test" union select _latin2"testt" ;
ERROR HY000: Illegal mix of collations (latin1_swedish_ci,COERCIBLE) and (latin2_general_ci,COERCIBLE) for operation 'UNION'
@@ -801,7 +801,7 @@ show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`test` char(5) character set latin2 NOT NULL default ''
-) TYPE=MyISAM DEFAULT CHARSET=latin1
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
drop table t1;
create table t1 (s char(200));
insert into t1 values (repeat("1",200));
diff --git a/mysql-test/r/update.result b/mysql-test/r/update.result
index a0370272396..6a5546200ce 100644
--- a/mysql-test/r/update.result
+++ b/mysql-test/r/update.result
@@ -94,7 +94,7 @@ KEY k2 (type),
KEY k3 (parent),
KEY k4 (assignment),
KEY ticket (ticket)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (773,773,'','','',980257344,20010318180652,0,'Open',10,0,0,0,1,'','','','','');
alter table t1 change lfdnr lfdnr int(10) unsigned not null auto_increment;
update t1 set status=1 where type='Open';
@@ -146,7 +146,7 @@ CREATE TABLE t1 (
`nom_option` char(40) NOT NULL default '',
`valid` tinyint(1) NOT NULL default '0',
KEY `id_param` (`id_param`,`nom_option`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (id_param,nom_option,valid) VALUES (185,'600x1200',1);
UPDATE t1 SET nom_option='test' WHERE id_param=185 AND nom_option='600x1200' AND valid=1 LIMIT 1;
select * from t1;
diff --git a/mysql-test/r/warnings.result b/mysql-test/r/warnings.result
index 1942f1a25bb..2769e284a95 100644
--- a/mysql-test/r/warnings.result
+++ b/mysql-test/r/warnings.result
@@ -119,10 +119,17 @@ select @@warning_count;
@@warning_count
50
drop table t1;
-create table t1 (id int) type=isam;
+create table t1 (id int) engine=isam;
Warnings:
Warning 1265 Using storage engine MyISAM for table 't1'
-alter table t1 type=isam;
+alter table t1 engine=isam;
Warnings:
Warning 1265 Using storage engine MyISAM for table 't1'
drop table t1;
+create table t1 (id int) type=heap;
+Warnings:
+Warning 1286 'TYPE=database_engine' is deprecated. Use 'ENGINE=database_engine' instead.
+alter table t1 type=myisam;
+Warnings:
+Warning 1286 'TYPE=database_engine' is deprecated. Use 'ENGINE=database_engine' instead.
+drop table t1;
diff --git a/mysql-test/t/alias.test b/mysql-test/t/alias.test
index e0fa10d56d5..852b78dd04e 100644
--- a/mysql-test/t/alias.test
+++ b/mysql-test/t/alias.test
@@ -50,7 +50,7 @@ CREATE TABLE t1 (
KEY mcbs_aufnr(mcbs_aufnr),
KEY kundentyp(kundentyp),
KEY p_nr(p_nr,suffix)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (3359356,405,3359356,'Mustermann Musterfrau',52500,'2000-05-20','workflow','Auftrag erledigt','Originalvertrag eingegangen und geprüft','','privat',1485525,2122316,'+','','N',1909160,'MobilComSuper92000D2',NULL,NULL,'MS9ND2',3,24,'MobilCom Shop Koeln',52500,NULL,'auto',20010202105916,'Mobilfunk','PP','','','');
INSERT INTO t1 VALUES (3359357,468,3359357,'Mustermann Musterfrau',7001,'2000-05-20','workflow','Auftrag erledigt','Originalvertrag eingegangen und geprüft','','privat',1503580,2139699,'+','','P',1909171,'MobilComSuper9D1T10SFreisprech(Akquise)',NULL,NULL,'MS9NS1',327,24,'MobilCom Intern',7003,NULL,'auto',20010202105916,'Mobilfunk','PP','','','');
diff --git a/mysql-test/t/alter_table.test b/mysql-test/t/alter_table.test
index 11fe997e789..eab4fd7f5f0 100644
--- a/mysql-test/t/alter_table.test
+++ b/mysql-test/t/alter_table.test
@@ -61,7 +61,7 @@ CREATE TABLE t1 (
user_id int(11) unsigned NOT NULL default '0',
status enum('new','old') NOT NULL default 'new',
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
ALTER TABLE t1 ORDER BY t1.id, t1.status, t1.type_id, t1.user_id, t1.body;
DROP TABLE t1;
@@ -70,7 +70,7 @@ DROP TABLE t1;
# The following combination found a hang-bug in MyISAM
#
-CREATE TABLE t1 (AnamneseId int(10) unsigned NOT NULL auto_increment,B BLOB,PRIMARY KEY (AnamneseId)) type=myisam;
+CREATE TABLE t1 (AnamneseId int(10) unsigned NOT NULL auto_increment,B BLOB,PRIMARY KEY (AnamneseId)) engine=myisam;
insert into t1 values (null,"hello");
LOCK TABLES t1 WRITE;
ALTER TABLE t1 ADD Column new_col int not null;
@@ -191,7 +191,7 @@ CREATE TABLE t1 (
Host varchar(16) binary NOT NULL default '',
User varchar(16) binary NOT NULL default '',
PRIMARY KEY (Host,User)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
ALTER TABLE t1 DISABLE KEYS;
LOCK TABLES t1 WRITE;
@@ -211,7 +211,7 @@ CREATE TABLE t1 (
User varchar(16) binary NOT NULL default '',
PRIMARY KEY (Host,User),
KEY (Host)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
ALTER TABLE t1 DISABLE KEYS;
SHOW INDEX FROM t1;
@@ -238,7 +238,7 @@ CREATE TABLE t1 (
User varchar(16) binary NOT NULL default '',
PRIMARY KEY (Host,User),
KEY (Host)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
LOCK TABLES t1 WRITE;
ALTER TABLE t1 DISABLE KEYS;
diff --git a/mysql-test/t/auto_increment.test b/mysql-test/t/auto_increment.test
index d02850f6745..6cf286f86c0 100644
--- a/mysql-test/t/auto_increment.test
+++ b/mysql-test/t/auto_increment.test
@@ -6,7 +6,7 @@ drop table if exists t1;
--enable_warnings
SET SQL_WARNINGS=1;
-create table t1 (a int not null auto_increment,b int, primary key (a)) type=myisam auto_increment=3;
+create table t1 (a int not null auto_increment,b int, primary key (a)) engine=myisam auto_increment=3;
insert into t1 values (1,1),(NULL,3),(NULL,4);
delete from t1 where a=4;
insert into t1 values (NULL,5),(NULL,6);
diff --git a/mysql-test/t/bdb-alter-table-1.test b/mysql-test/t/bdb-alter-table-1.test
index 7537cc358e8..18b6c70758f 100644
--- a/mysql-test/t/bdb-alter-table-1.test
+++ b/mysql-test/t/bdb-alter-table-1.test
@@ -6,7 +6,7 @@
drop table if exists t1;
--enable_warnings
-create table t1(objid BIGINT not null, tablename varchar(64), oid BIGINT not null, test BIGINT, PRIMARY KEY (objid), UNIQUE(tablename)) type=BDB;
+create table t1(objid BIGINT not null, tablename varchar(64), oid BIGINT not null, test BIGINT, PRIMARY KEY (objid), UNIQUE(tablename)) engine=BDB;
insert into t1 values(1, 't1',4,9);
insert into t1 values(2, 'metatable',1,9);
insert into t1 values(3, 'metaindex',1,9 );
diff --git a/mysql-test/t/bdb-crash.test b/mysql-test/t/bdb-crash.test
index d77de901a30..fffed379e79 100644
--- a/mysql-test/t/bdb-crash.test
+++ b/mysql-test/t/bdb-crash.test
@@ -20,7 +20,7 @@ DEFAULT 'New' NOT NULL,
PRIMARY KEY (ChargeID),
KEY ServiceID (ServiceID),
KEY ChargeDate (ChargeDate)
-) type=BDB;
+) engine=BDB;
BEGIN;
INSERT INTO t1
diff --git a/mysql-test/t/bdb-deadlock.test b/mysql-test/t/bdb-deadlock.test
index 2453c42e49a..d86403fcffc 100644
--- a/mysql-test/t/bdb-deadlock.test
+++ b/mysql-test/t/bdb-deadlock.test
@@ -15,8 +15,8 @@ connect (con2,localhost,root,,);
drop table if exists t1,t2;
--enable_warnings
connection con1;
-create table t1 (id integer, x integer) type=BDB;
-create table t2 (id integer, x integer) type=BDB;
+create table t1 (id integer, x integer) engine=BDB;
+create table t2 (id integer, x integer) engine=BDB;
insert into t1 values(0, 0);
insert into t2 values(0, 0);
set autocommit=0;
diff --git a/mysql-test/t/bdb.test b/mysql-test/t/bdb.test
index a0fbc56a9da..44bb753d6a1 100644
--- a/mysql-test/t/bdb.test
+++ b/mysql-test/t/bdb.test
@@ -7,7 +7,7 @@
--disable_warnings
drop table if exists t1,t2,t3,t4,t5,t6,t7,t8;
--enable_warnings
-create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) type=bdb;
+create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) engine=bdb;
insert into t1 (code, name) values (1, 'Tim'), (1, 'Monty'), (2, 'David'), (2, 'Erik'), (3, 'Sasha'), (3, 'Jeremy'), (4, 'Matt');
select id, code, name from t1 order by id;
@@ -30,7 +30,7 @@ CREATE TABLE t1 (
PRIMARY KEY (id),
KEY parent_id (parent_id),
KEY level (level)
-) type=bdb;
+) engine=bdb;
INSERT INTO t1 VALUES (1,0,0),(3,1,1),(4,1,1),(8,2,2),(9,2,2),(17,3,2),(22,4,2),(24,4,2),(28,5,2),(29,5,2),(30,5,2),(31,6,2),(32,6,2),(33,6,2),(203,7,2),(202,7,2),(20,3,2),(157,0,0),(193,5,2),(40,7,2),(2,1,1),(15,2,2),(6,1,1),(34,6,2),(35,6,2),(16,3,2),(7,1,1),(36,7,2),(18,3,2),(26,5,2),(27,5,2),(183,4,2),(38,7,2),(25,5,2),(37,7,2),(21,4,2),(19,3,2),(5,1,1),(179,5,2);
update t1 set parent_id=parent_id+100;
select * from t1 where parent_id=102;
@@ -59,7 +59,7 @@ CREATE TABLE t1 (
gesuchnr int(11) DEFAULT '0' NOT NULL,
benutzer_id int(11) DEFAULT '0' NOT NULL,
PRIMARY KEY (gesuchnr,benutzer_id)
-) type=BDB;
+) engine=BDB;
replace into t1 (gesuchnr,benutzer_id) values (2,1);
replace into t1 (gesuchnr,benutzer_id) values (1,1);
@@ -68,7 +68,7 @@ select * from t1;
drop table t1;
# test for bug in replace with secondary key
-create table t1 (id int not null primary key, x int not null, key (x)) type=bdb;
+create table t1 (id int not null primary key, x int not null, key (x)) engine=bdb;
insert into t1 (id, x) values (1, 1);
replace into t1 (id, x) values (1, 2);
select * from t1;
@@ -78,7 +78,7 @@ drop table t1;
# test delete using hidden_primary_key
#
-create table t1 (a int) type=bdb;
+create table t1 (a int) engine=bdb;
insert into t1 values (1), (2);
optimize table t1;
delete from t1 where a = 1;
@@ -86,7 +86,7 @@ select * from t1;
check table t1;
drop table t1;
-create table t1 (a int,b varchar(20)) type=bdb;
+create table t1 (a int,b varchar(20)) engine=bdb;
insert into t1 values (1,""), (2,"testing");
delete from t1 where a = 1;
select * from t1;
@@ -98,7 +98,7 @@ drop table t1;
# Test of reading on secondary key with may be null
-create table t1 (a int,b varchar(20),key(a)) type=bdb;
+create table t1 (a int,b varchar(20),key(a)) engine=bdb;
insert into t1 values (1,""), (2,"testing");
select * from t1 where a = 1;
drop table t1;
@@ -107,7 +107,7 @@ drop table t1;
# Test auto_increment on sub key
#
-create table t1 (a char(10) not null, b int not null auto_increment, primary key(a,b)) type=BDB;
+create table t1 (a char(10) not null, b int not null auto_increment, primary key(a,b)) engine=BDB;
insert into t1 values ("a",1),("b",2),("a",2),("c",1);
insert into t1 values ("a",NULL),("b",NULL),("c",NULL),("e",NULL);
insert into t1 (a) values ("a"),("b"),("c"),("d");
@@ -123,7 +123,7 @@ drop table t1;
# Test rollback
#
-create table t1 (n int not null primary key) type=bdb;
+create table t1 (n int not null primary key) engine=bdb;
set autocommit=0;
insert into t1 values (4);
rollback;
@@ -150,7 +150,7 @@ drop table t1;
# Testing transactions
#
-create table t1 ( id int NOT NULL PRIMARY KEY, nom varchar(64)) type=BDB;
+create table t1 ( id int NOT NULL PRIMARY KEY, nom varchar(64)) engine=BDB;
begin;
insert into t1 values(1,'hamdouni');
select id as afterbegin_id,nom as afterbegin_nom from t1;
@@ -168,7 +168,7 @@ drop table t1;
# Simple not autocommit test
#
-CREATE TABLE t1 (id char(8) not null primary key, val int not null) type=bdb;
+CREATE TABLE t1 (id char(8) not null primary key, val int not null) engine=bdb;
insert into t1 values ('pippo', 12);
-- error 1062
insert into t1 values ('pippo', 12); # Gives error
@@ -191,12 +191,12 @@ set autocommit=1;
# The following simple tests failed at some point
#
-CREATE TABLE t1 (ID INTEGER NOT NULL PRIMARY KEY, NAME VARCHAR(64)) TYPE=BDB;
+CREATE TABLE t1 (ID INTEGER NOT NULL PRIMARY KEY, NAME VARCHAR(64)) ENGINE=BDB;
INSERT INTO t1 VALUES (1, 'Jochen');
select * from t1;
drop table t1;
-CREATE TABLE t1 ( _userid VARCHAR(60) NOT NULL PRIMARY KEY) TYPE=BDB;
+CREATE TABLE t1 ( _userid VARCHAR(60) NOT NULL PRIMARY KEY) ENGINE=BDB;
set autocommit=0;
INSERT INTO t1 SET _userid='marc@anyware.co.uk';
COMMIT;
@@ -215,7 +215,7 @@ CREATE TABLE t1 (
ref_email varchar(100) DEFAULT '' NOT NULL,
detail varchar(200),
PRIMARY KEY (user_id,ref_email)
-)type=bdb;
+)engine=bdb;
INSERT INTO t1 VALUES (10292,'sanjeev','29153373','sansh777@hotmail.com','xxx'),(10292,'shirish','2333604','shirish@yahoo.com','ddsds'),(10292,'sonali','323232','sonali@bolly.com','filmstar');
select * from t1 where user_id=10292;
@@ -240,7 +240,7 @@ drop table t1;
#
create table t1 (col1 int not null, col2 char(4) not null, primary key(col1));
-alter table t1 type=BDB;
+alter table t1 engine=BDB;
insert into t1 values ('1','1'),('5','2'),('2','3'),('3','4'),('4','4');
select * from t1;
update t1 set col2='7' where col1='4';
@@ -255,8 +255,8 @@ drop table t1;
# INSERT INTO BDB tables
#
-create table t1 (a int not null , b int, primary key (a)) type = BDB;
-create table t2 (a int not null , b int, primary key (a)) type = myisam;
+create table t1 (a int not null , b int, primary key (a)) engine = BDB;
+create table t2 (a int not null , b int, primary key (a)) engine = myisam;
insert into t1 VALUES (1,3) , (2,3), (3,3);
select * from t1;
insert into t2 select * from t1;
@@ -279,7 +279,7 @@ CREATE TABLE t1 (
passwd varchar(32) binary DEFAULT '' NOT NULL,
PRIMARY KEY (id),
UNIQUE ggid (ggid)
-) TYPE=BDB;
+) ENGINE=BDB;
insert into t1 (ggid,passwd) values ('test1','xxx');
insert into t1 (ggid,passwd) values ('test2','yyy');
@@ -317,7 +317,7 @@ CREATE TABLE t1 (
approved datetime,
dummy_primary_key int(11) NOT NULL auto_increment,
PRIMARY KEY (dummy_primary_key)
-) TYPE=BDB;
+) ENGINE=BDB;
INSERT INTO t1 VALUES ('user_0','somepassword','N',0,0,0,'2000-09-07','23:06:59','2000-09-07 23:06:59',1);
INSERT INTO t1 VALUES ('user_1','somepassword','Y',1,1,1,'2000-09-07','23:06:59','2000-09-07 23:06:59',2);
INSERT INTO t1 VALUES ('user_2','somepassword','N',2,2,1.4142135623731,'2000-09-07','23:06:59','2000-09-07 23:06:59',3);
@@ -337,7 +337,7 @@ CREATE TABLE t1 (
KEY (id),
KEY parent_id (parent_id),
KEY level (level)
-) type=bdb;
+) engine=bdb;
INSERT INTO t1 VALUES (1,0,0),(3,1,1),(4,1,1),(8,2,2),(9,2,2),(17,3,2),(22,4,2),(24,4,2),(28,5,2),(29,5,2),(30,5,2),(31,6,2),(32,6,2),(33,6,2),(203,7,2),(202,7,2),(20,3,2),(157,0,0),(193,5,2),(40,7,2),(2,1,1),(15,2,2),(6,1,1),(34,6,2),(35,6,2),(16,3,2),(7,1,1),(36,7,2),(18,3,2),(26,5,2),(27,5,2),(183,4,2),(38,7,2),(25,5,2),(37,7,2),(21,4,2),(19,3,2),(5,1,1);
INSERT INTO t1 values (179,5,2);
update t1 set parent_id=parent_id+100;
@@ -370,7 +370,7 @@ CREATE TABLE t1 (
sca_sch_desc varchar(16),
PRIMARY KEY (sca_code, cat_code, lan_code),
INDEX sca_pic (sca_pic)
-) type = bdb ;
+) engine = bdb ;
INSERT INTO t1 ( sca_code, cat_code, sca_desc, lan_code, sca_pic, sca_sdesc, sca_sch_desc) VALUES ( 'PD', 'J', 'PENDANT', 'EN', NULL, NULL, 'PENDANT'),( 'RI', 'J', 'RING', 'EN', NULL, NULL, 'RING'),( 'QQ', 'N', 'RING', 'EN', 'not null', NULL, 'RING');
select count(*) from t1 where sca_code = 'PD';
@@ -392,7 +392,7 @@ drop table t1;
# Test of opening table twice and timestamps
#
set @a:=now();
-CREATE TABLE t1 (a int not null, b timestamp not null, primary key (a)) type=bdb;
+CREATE TABLE t1 (a int not null, b timestamp not null, primary key (a)) engine=bdb;
insert into t1 (a) values(1),(2),(3);
select t1.a from t1 natural join t1 as t2 where t1.b >= @a order by t1.a;
update t1 set a=5 where a=1;
@@ -407,7 +407,7 @@ flush logs;
#
# Test key on blob with null values
#
-create table t1 (b blob, i int, key (b(100)), key (i), key (i, b(20))) type=bdb;
+create table t1 (b blob, i int, key (b(100)), key (i), key (i, b(20))) engine=bdb;
insert into t1 values ('this is a blob', 1), (null, -1), (null, null),("",1),("",2),("",3);
select b from t1 where b = 'this is a blob';
select * from t1 where b like 't%';
@@ -421,7 +421,7 @@ drop table t1;
#
# Test with variable length primary key
#
-create table t1 (a varchar(100) not null, primary key(a), b int not null) type=bdb;
+create table t1 (a varchar(100) not null, primary key(a), b int not null) engine=bdb;
insert into t1 values("hello",1),("world",2);
select * from t1 order by b desc;
optimize table t1;
@@ -431,7 +431,7 @@ drop table t1;
#
# Test of bug in create index with NULL columns
#
-create table t1 (i int, j int )TYPE=BDB;
+create table t1 (i int, j int )ENGINE=BDB;
insert into t1 values (1,2);
select * from t1 where i=1 and j=2;
create index ax1 on t1 (i,j);
@@ -451,7 +451,7 @@ create table t1
unique branch_name(branch_name),
index branch_active(branch_active)
-) type=bdb;
+) engine=bdb;
create table t2
(
target_id int auto_increment primary key,
@@ -460,7 +460,7 @@ create table t2
unique target_name(target_name),
index target_active(target_active)
-) type=bdb;
+) engine=bdb;
create table t3
(
platform_id int auto_increment primary key,
@@ -469,7 +469,7 @@ create table t3
unique platform_name(platform_name),
index platform_active(platform_active)
-) type=bdb;
+) engine=bdb;
create table t4
(
product_id int auto_increment primary key,
@@ -479,7 +479,7 @@ create table t4
unique product_name(product_name),
index product_active(product_active)
-) type=bdb;
+) engine=bdb;
create table t5
(
product_file_id int auto_increment primary key,
@@ -492,7 +492,7 @@ create table t5
unique product_file(product_id,file_name),
index file_included(file_included)
-) type=bdb;
+) engine=bdb;
create table t6
(
file_platform_id int auto_increment primary key,
@@ -505,7 +505,7 @@ create table t6
archive_filename varchar(255) not null,
unique file_platform(product_file_id,platform_id,branch_id)
-) type=bdb;
+) engine=bdb;
create table t8
(
archive_id int auto_increment primary key,
@@ -517,7 +517,7 @@ create table t8
unique archive(branch_id,target_id,platform_id,product_id),
index status_id(status_id)
-) type=bdb;
+) engine=bdb;
create table t7
(
build_id int auto_increment primary key,
@@ -531,7 +531,7 @@ create table t7
build_path text not null,
unique build(branch_id,target_id,build_number)
-) type=bdb;
+) engine=bdb;
insert into t1 (branch_name)
values ('RealMedia');
@@ -659,7 +659,7 @@ CREATE TABLE t1 (
a tinytext NOT NULL,
b tinyint(3) unsigned NOT NULL default '0',
PRIMARY KEY (a(32),b)
-) TYPE=BDB;
+) ENGINE=BDB;
INSERT INTO t1 VALUES ('a',1),('a',2);
SELECT * FROM t1 WHERE a='a' AND b=2;
SELECT * FROM t1 WHERE a='a' AND b in (2);
@@ -674,7 +674,7 @@ CREATE TABLE t1 (
a int3 unsigned NOT NULL,
b int1 unsigned NOT NULL,
UNIQUE (a, b)
-) TYPE = BDB;
+) ENGINE = BDB;
INSERT INTO t1 VALUES (1, 1);
SELECT MIN(B),MAX(b) FROM t1 WHERE t1.a = 1;
@@ -684,7 +684,7 @@ drop table t1;
# Test problem with BDB and lock tables with duplicate write.
#
-create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) type=bdb;
+create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) engine=bdb;
insert into t1 values (0,0,0,'ABCDEFGHIJ'),(2,2,2,'BCDEFGHIJK'),(1,1,1,'CDEFGHIJKL');
LOCK TABLES t1 WRITE;
--error 1062
@@ -694,7 +694,7 @@ select id from t1;
UNLOCK TABLES;
DROP TABLE t1;
-create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) type=bdb;
+create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) engine=bdb;
insert into t1 values (0,0,0,'ABCDEFGHIJ'),(2,2,2,'BCDEFGHIJK'),(1,1,1,'CDEFGHIJKL');
LOCK TABLES t1 WRITE;
begin;
@@ -711,8 +711,8 @@ DROP TABLE t1;
# Test with empty tables (crashed with lock error)
#
-CREATE TABLE t1 (SYAIN_NO char(5) NOT NULL default '', KINMU_DATE char(6) NOT NULL default '', PRIMARY KEY (SYAIN_NO,KINMU_DATE)) TYPE=BerkeleyDB;
-CREATE TABLE t2 ( SYAIN_NO char(5) NOT NULL default '',STR_DATE char(8) NOT NULL default '',PRIMARY KEY (SYAIN_NO,STR_DATE) ) TYPE=BerkeleyDB;
+CREATE TABLE t1 (SYAIN_NO char(5) NOT NULL default '', KINMU_DATE char(6) NOT NULL default '', PRIMARY KEY (SYAIN_NO,KINMU_DATE)) ENGINE=BerkeleyDB;
+CREATE TABLE t2 ( SYAIN_NO char(5) NOT NULL default '',STR_DATE char(8) NOT NULL default '',PRIMARY KEY (SYAIN_NO,STR_DATE) ) ENGINE=BerkeleyDB;
select T1.KINMU_DATE from t1 T1 ,t2 T2 where T1.SYAIN_NO = '12345' and T1.KINMU_DATE = '200106' and T2.SYAIN_NO = T1.SYAIN_NO;
select T1.KINMU_DATE from t1 T1 ,t2 T2 where T1.SYAIN_NO = '12345' and T1.KINMU_DATE = '200106' and T2.SYAIN_NO = T1.SYAIN_NO;
DROP TABLE t1,t2;
@@ -721,7 +721,7 @@ DROP TABLE t1,t2;
# Test problem with joining table to itself on a multi-part unique key
#
-create table t1 (a int(11) not null, b int(11) not null, unique (a,b)) type=bdb;
+create table t1 (a int(11) not null, b int(11) not null, unique (a,b)) engine=bdb;
insert into t1 values (1,1), (1,2);
select * from t1 where a = 1;
select t1.*, t2.* from t1, t1 t2 where t1.a = t2.a and t2.a = 1;
@@ -732,9 +732,9 @@ drop table t1;
# This caused a deadlock in BDB internal locks
#
-create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) type=bdb;
+create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) engine=bdb;
insert into t1 values (0,0,0,'ABCDEFGHIJ');
-create table t2 (id int NOT NULL,primary key (id)) type=bdb;
+create table t2 (id int NOT NULL,primary key (id)) engine=bdb;
LOCK TABLES t1 WRITE, t2 WRITE;
insert into t2 values(1);
SELECT t1.* FROM t1 WHERE id IN (1);
@@ -746,7 +746,7 @@ drop table t1,t2;
# Test problems with NULL
#
-CREATE TABLE t1 (i varchar(48) NOT NULL default '', p varchar(255) default NULL,s varchar(48) NOT NULL default '', PRIMARY KEY (i), UNIQUE(p,s)) TYPE=BDB;
+CREATE TABLE t1 (i varchar(48) NOT NULL default '', p varchar(255) default NULL,s varchar(48) NOT NULL default '', PRIMARY KEY (i), UNIQUE(p,s)) ENGINE=BDB;
INSERT INTO t1 VALUES ('00000000-e6c4ddeaa6-003b8-83458387','programs/xxxxxxxx.wmv','00000000-e6c4ddeb32-003bc-83458387');
SELECT * FROM t1 WHERE p='programs/xxxxxxxx.wmv';
drop table t1;
@@ -755,7 +755,7 @@ drop table t1;
# Test problem which gave error 'Can't find record in 't1''
#
-CREATE TABLE t1 ( STR_DATE varchar(8) NOT NULL default '',INFO_NOTE varchar(200) default NULL,PRIMARY KEY (STR_DATE) ) TYPE=BerkeleyDB;
+CREATE TABLE t1 ( STR_DATE varchar(8) NOT NULL default '',INFO_NOTE varchar(200) default NULL,PRIMARY KEY (STR_DATE) ) ENGINE=BerkeleyDB;
select INFO_NOTE from t1 where STR_DATE = '20010610';
select INFO_NOTE from t1 where STR_DATE < '20010610';
select INFO_NOTE from t1 where STR_DATE > '20010610';
@@ -765,8 +765,8 @@ drop table t1;
# Test problem with multi table delete which quickly shows up with bdb tables.
#
-create table t1 (a int not null, b int, primary key (a)) type =bdb;
-create table t2 (a int not null, b int, primary key (a)) type =bdb;
+create table t1 (a int not null, b int, primary key (a)) engine =bdb;
+create table t2 (a int not null, b int, primary key (a)) engine =bdb;
insert into t1 values (2, 3),(1, 7),(10, 7);
insert into t2 values (2, 3),(1, 7),(10, 7);
select * from t1;
@@ -781,7 +781,7 @@ drop table t1,t2;
# The bug #971
#
-create table t1 (x int not null, index(x)) type=bdb;
+create table t1 (x int not null, index(x)) engine=bdb;
insert into t1 values (1), (2), (3), (4), (5), (6), (7), (8), (9), (10);
select * from t1 where x <= 10 and x >= 7;
select * from t1 where x <= 10 and x >= 7 order by x;
diff --git a/mysql-test/t/bdb_cache.test b/mysql-test/t/bdb_cache.test
index 0d7de75ccf6..0082c83faff 100644
--- a/mysql-test/t/bdb_cache.test
+++ b/mysql-test/t/bdb_cache.test
@@ -9,7 +9,7 @@ drop table if exists t1, t2, t3;
--enable_warnings
flush status;
set autocommit=0;
-create table t1 (a int not null) type=bdb;
+create table t1 (a int not null) engine=bdb;
insert into t1 values (1),(2),(3);
select * from t1;
show status like "Qcache_queries_in_cache";
@@ -17,15 +17,15 @@ drop table t1;
commit;
set autocommit=1;
begin;
-create table t1 (a int not null) type=bdb;
+create table t1 (a int not null) engine=bdb;
insert into t1 values (1),(2),(3);
select * from t1;
show status like "Qcache_queries_in_cache";
drop table t1;
commit;
-create table t1 (a int not null) type=bdb;
-create table t2 (a int not null) type=bdb;
-create table t3 (a int not null) type=bdb;
+create table t1 (a int not null) engine=bdb;
+create table t2 (a int not null) engine=bdb;
+create table t3 (a int not null) engine=bdb;
insert into t1 values (1),(2);
insert into t2 values (1),(2);
insert into t3 values (1),(2);
diff --git a/mysql-test/t/create.test b/mysql-test/t/create.test
index 54166c3b0dc..32565c0e20b 100644
--- a/mysql-test/t/create.test
+++ b/mysql-test/t/create.test
@@ -18,7 +18,7 @@ insert into t1 values (""),(null);
select * from t1;
drop table t1;
-create table t1 (a int not null auto_increment,primary key (a)) type=heap;
+create table t1 (a int not null auto_increment,primary key (a)) engine=heap;
drop table t1;
#
@@ -26,18 +26,18 @@ drop table t1;
#
--error 1146
-create table t2 type=heap select * from t1;
+create table t2 engine=heap select * from t1;
--error 1146
create table t2 select auto+1 from t1;
drop table if exists t1,t2;
--error 1167
create table t1 (b char(0) not null, index(b));
--error 1163
-create table t1 (a int not null,b text) type=heap;
+create table t1 (a int not null,b text) engine=heap;
drop table if exists t1;
--error 1075
-create table t1 (ordid int(8) not null auto_increment, ord varchar(50) not null, primary key (ord,ordid)) type=heap;
+create table t1 (ordid int(8) not null auto_increment, ord varchar(50) not null, primary key (ord,ordid)) engine=heap;
-- error 1044,1
create table not_existing_database.test (a int);
diff --git a/mysql-test/t/ctype_ucs.test b/mysql-test/t/ctype_ucs.test
index 0457c204e32..90b423cd1e0 100644
--- a/mysql-test/t/ctype_ucs.test
+++ b/mysql-test/t/ctype_ucs.test
@@ -84,7 +84,7 @@ DROP TABLE t1;
# Bug 1181
#
CREATE TABLE t1 (word varchar(64) NOT NULL, PRIMARY KEY (word))
-TYPE=MyISAM CHARACTER SET ucs2 COLLATE ucs2_general_ci;
+ENGINE=MyISAM CHARACTER SET ucs2 COLLATE ucs2_general_ci;
INSERT INTO t1 (word) VALUES ("cat");
SELECT * FROM t1 WHERE word LIKE "c%";
SELECT * FROM t1 WHERE word LIKE "ca_";
@@ -126,7 +126,7 @@ CREATE TABLE t1 (
word VARCHAR(64),
bar INT(11) default 0,
PRIMARY KEY (word))
- TYPE=MyISAM
+ ENGINE=MyISAM
CHARSET ucs2
COLLATE ucs2_general_ci ;
@@ -149,7 +149,7 @@ DROP TABLE t1;
CREATE TABLE t1 (
word VARCHAR(64) ,
PRIMARY KEY (word))
- TYPE=MyISAM
+ ENGINE=MyISAM
CHARSET ucs2
COLLATE ucs2_general_ci;
@@ -172,7 +172,7 @@ CREATE TABLE t1 (
word TEXT,
bar INT(11) AUTO_INCREMENT,
PRIMARY KEY (bar))
- TYPE=MyISAM
+ ENGINE=MyISAM
CHARSET ucs2
COLLATE ucs2_general_ci ;
INSERT INTO t1 (word) VALUES ("aar");
diff --git a/mysql-test/t/delete.test b/mysql-test/t/delete.test
index c529994f31b..bd5d9e5c0d9 100644
--- a/mysql-test/t/delete.test
+++ b/mysql-test/t/delete.test
@@ -56,7 +56,7 @@ CREATE TABLE t1 (
not_null varchar(20) binary NOT NULL default '',
misc integer not null,
PRIMARY KEY (not_null)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (NULL,'a',4), (NULL,'b',5), (NULL,'c',6), (NULL,'d',7);
diff --git a/mysql-test/t/distinct.test b/mysql-test/t/distinct.test
index 56c00e7501c..3c1f18b7524 100644
--- a/mysql-test/t/distinct.test
+++ b/mysql-test/t/distinct.test
@@ -223,7 +223,7 @@ drop table t1;
# Test problem with DISTINCT and ORDER BY DESC
#
-create table t1 (a char(1), key(a)) type=myisam;
+create table t1 (a char(1), key(a)) engine=myisam;
insert into t1 values('1'),('1');
select * from t1 where a >= '1';
select distinct a from t1 order by a desc;
@@ -257,9 +257,9 @@ drop table t1,t2;
# test with table.* in DISTINCT
#
-CREATE TABLE t1 (privatemessageid int(10) unsigned NOT NULL auto_increment, folderid smallint(6) NOT NULL default '0', userid int(10) unsigned NOT NULL default '0', touserid int(10) unsigned NOT NULL default '0', fromuserid int(10) unsigned NOT NULL default '0', title varchar(250) NOT NULL default '', message mediumtext NOT NULL, dateline int(10) unsigned NOT NULL default '0', showsignature smallint(6) NOT NULL default '0', iconid smallint(5) unsigned NOT NULL default '0', messageread smallint(6) NOT NULL default '0', readtime int(10) unsigned NOT NULL default '0', receipt smallint(6) unsigned NOT NULL default '0', deleteprompt smallint(6) unsigned NOT NULL default '0', multiplerecipients smallint(6) unsigned NOT NULL default '0', PRIMARY KEY (privatemessageid), KEY userid (userid)) TYPE=MyISAM;
+CREATE TABLE t1 (privatemessageid int(10) unsigned NOT NULL auto_increment, folderid smallint(6) NOT NULL default '0', userid int(10) unsigned NOT NULL default '0', touserid int(10) unsigned NOT NULL default '0', fromuserid int(10) unsigned NOT NULL default '0', title varchar(250) NOT NULL default '', message mediumtext NOT NULL, dateline int(10) unsigned NOT NULL default '0', showsignature smallint(6) NOT NULL default '0', iconid smallint(5) unsigned NOT NULL default '0', messageread smallint(6) NOT NULL default '0', readtime int(10) unsigned NOT NULL default '0', receipt smallint(6) unsigned NOT NULL default '0', deleteprompt smallint(6) unsigned NOT NULL default '0', multiplerecipients smallint(6) unsigned NOT NULL default '0', PRIMARY KEY (privatemessageid), KEY userid (userid)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (128,0,33,33,8,':D','',996121863,1,0,2,996122850,2,0,0);
-CREATE TABLE t2 (userid int(10) unsigned NOT NULL auto_increment, usergroupid smallint(5) unsigned NOT NULL default '0', username varchar(50) NOT NULL default '', password varchar(50) NOT NULL default '', email varchar(50) NOT NULL default '', styleid smallint(5) unsigned NOT NULL default '0', parentemail varchar(50) NOT NULL default '', coppauser smallint(6) NOT NULL default '0', homepage varchar(100) NOT NULL default '', icq varchar(20) NOT NULL default '', aim varchar(20) NOT NULL default '', yahoo varchar(20) NOT NULL default '', signature mediumtext NOT NULL, adminemail smallint(6) NOT NULL default '0', showemail smallint(6) NOT NULL default '0', invisible smallint(6) NOT NULL default '0', usertitle varchar(250) NOT NULL default '', customtitle smallint(6) NOT NULL default '0', joindate int(10) unsigned NOT NULL default '0', cookieuser smallint(6) NOT NULL default '0', daysprune smallint(6) NOT NULL default '0', lastvisit int(10) unsigned NOT NULL default '0', lastactivity int(10) unsigned NOT NULL default '0', lastpost int(10) unsigned NOT NULL default '0', posts smallint(5) unsigned NOT NULL default '0', timezoneoffset varchar(4) NOT NULL default '', emailnotification smallint(6) NOT NULL default '0', buddylist mediumtext NOT NULL, ignorelist mediumtext NOT NULL, pmfolders mediumtext NOT NULL, receivepm smallint(6) NOT NULL default '0', emailonpm smallint(6) NOT NULL default '0', pmpopup smallint(6) NOT NULL default '0', avatarid smallint(6) NOT NULL default '0', avatarrevision int(6) unsigned NOT NULL default '0', options smallint(6) NOT NULL default '15', birthday date NOT NULL default '0000-00-00', maxposts smallint(6) NOT NULL default '-1', startofweek smallint(6) NOT NULL default '1', ipaddress varchar(20) NOT NULL default '', referrerid int(10) unsigned NOT NULL default '0', nosessionhash smallint(6) NOT NULL default '0', autorefresh smallint(6) NOT NULL default '-1', messagepopup tinyint(2) NOT NULL default '0', inforum smallint(5) unsigned NOT NULL default '0', ratenum smallint(5) unsigned NOT NULL default '0', ratetotal smallint(5) unsigned NOT NULL default '0', allowrate smallint(5) unsigned NOT NULL default '1', PRIMARY KEY (userid), KEY usergroupid (usergroupid), KEY username (username), KEY inforum (inforum)) TYPE=MyISAM;
+CREATE TABLE t2 (userid int(10) unsigned NOT NULL auto_increment, usergroupid smallint(5) unsigned NOT NULL default '0', username varchar(50) NOT NULL default '', password varchar(50) NOT NULL default '', email varchar(50) NOT NULL default '', styleid smallint(5) unsigned NOT NULL default '0', parentemail varchar(50) NOT NULL default '', coppauser smallint(6) NOT NULL default '0', homepage varchar(100) NOT NULL default '', icq varchar(20) NOT NULL default '', aim varchar(20) NOT NULL default '', yahoo varchar(20) NOT NULL default '', signature mediumtext NOT NULL, adminemail smallint(6) NOT NULL default '0', showemail smallint(6) NOT NULL default '0', invisible smallint(6) NOT NULL default '0', usertitle varchar(250) NOT NULL default '', customtitle smallint(6) NOT NULL default '0', joindate int(10) unsigned NOT NULL default '0', cookieuser smallint(6) NOT NULL default '0', daysprune smallint(6) NOT NULL default '0', lastvisit int(10) unsigned NOT NULL default '0', lastactivity int(10) unsigned NOT NULL default '0', lastpost int(10) unsigned NOT NULL default '0', posts smallint(5) unsigned NOT NULL default '0', timezoneoffset varchar(4) NOT NULL default '', emailnotification smallint(6) NOT NULL default '0', buddylist mediumtext NOT NULL, ignorelist mediumtext NOT NULL, pmfolders mediumtext NOT NULL, receivepm smallint(6) NOT NULL default '0', emailonpm smallint(6) NOT NULL default '0', pmpopup smallint(6) NOT NULL default '0', avatarid smallint(6) NOT NULL default '0', avatarrevision int(6) unsigned NOT NULL default '0', options smallint(6) NOT NULL default '15', birthday date NOT NULL default '0000-00-00', maxposts smallint(6) NOT NULL default '-1', startofweek smallint(6) NOT NULL default '1', ipaddress varchar(20) NOT NULL default '', referrerid int(10) unsigned NOT NULL default '0', nosessionhash smallint(6) NOT NULL default '0', autorefresh smallint(6) NOT NULL default '-1', messagepopup tinyint(2) NOT NULL default '0', inforum smallint(5) unsigned NOT NULL default '0', ratenum smallint(5) unsigned NOT NULL default '0', ratetotal smallint(5) unsigned NOT NULL default '0', allowrate smallint(5) unsigned NOT NULL default '1', PRIMARY KEY (userid), KEY usergroupid (usergroupid), KEY username (username), KEY inforum (inforum)) ENGINE=MyISAM;
INSERT INTO t2 VALUES (33,6,'Kevin','0','kevin@stileproject.com',1,'',0,'http://www.stileproject.com','','','','',1,1,0,'Administrator',0,996120694,1,-1,1030996168,1031027028,1030599436,36,'-6',0,'','','',1,0,1,0,0,15,'0000-00-00',-1,1,'64.0.0.0',0,1,-1,0,0,4,19,1);
SELECT DISTINCT t1.*, t2.* FROM t1 LEFT JOIN t2 ON (t2.userid = t1.touserid);
DROP TABLE t1,t2;
@@ -279,7 +279,7 @@ DROP TABLE t1,t2;
# Test of LEFT() with distinct
#
-CREATE table t1 ( `id` int(11) NOT NULL auto_increment, `name` varchar(50) NOT NULL default '', PRIMARY KEY (`id`)) TYPE=MyISAM AUTO_INCREMENT=3 ;
+CREATE table t1 ( `id` int(11) NOT NULL auto_increment, `name` varchar(50) NOT NULL default '', PRIMARY KEY (`id`)) ENGINE=MyISAM AUTO_INCREMENT=3 ;
INSERT INTO t1 VALUES (1, 'aaaaa');
INSERT INTO t1 VALUES (3, 'aaaaa');
INSERT INTO t1 VALUES (2, 'eeeeeee');
@@ -327,7 +327,7 @@ CREATE TABLE t1 (
html varchar(5) default NULL,
rin int(11) default '0',
out int(11) default '0'
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('1',1,0);
SELECT DISTINCT html,SUM(out)/(SUM(rin)+1) as 'prod' FROM t1 GROUP BY rin;
diff --git a/mysql-test/t/fulltext.test b/mysql-test/t/fulltext.test
index 38c09682bac..02ada3dc8cb 100644
--- a/mysql-test/t/fulltext.test
+++ b/mysql-test/t/fulltext.test
@@ -176,7 +176,7 @@ CREATE TABLE t1 (
title varchar(100) default '',
PRIMARY KEY (id),
KEY ind5 (title)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE FULLTEXT INDEX ft1 ON t1(title);
insert into t1 (title) values ('this is a test');
@@ -191,7 +191,7 @@ drop table t1;
# one more bug - const_table related
-CREATE TABLE t1 (a int(11), b text, FULLTEXT KEY (b)) TYPE=MyISAM;
+CREATE TABLE t1 (a int(11), b text, FULLTEXT KEY (b)) ENGINE=MyISAM;
insert into t1 values (1,"I wonder why the fulltext index doesnt work?");
SELECT * from t1 where MATCH (b) AGAINST ('apples');
@@ -199,7 +199,7 @@ insert into t1 values (2,"fullaaa fullzzz");
select * from t1 where match b against ('full*' in boolean mode);
drop table t1;
-CREATE TABLE t1 ( id int(11) NOT NULL auto_increment primary key, mytext text NOT NULL, FULLTEXT KEY mytext (mytext)) TYPE=MyISAM;
+CREATE TABLE t1 ( id int(11) NOT NULL auto_increment primary key, mytext text NOT NULL, FULLTEXT KEY mytext (mytext)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,'my small mouse'),(2,'la-la-la'),(3,'It is so funny'),(4,'MySQL Tutorial');
select 8 from t1;
drop table t1;
diff --git a/mysql-test/t/fulltext2.test b/mysql-test/t/fulltext2.test
index a01ec3a59c9..cab1d096fe7 100644
--- a/mysql-test/t/fulltext2.test
+++ b/mysql-test/t/fulltext2.test
@@ -14,7 +14,7 @@ CREATE TABLE t1 (
i int(10) unsigned not null auto_increment primary key,
a varchar(255) not null,
FULLTEXT KEY (a)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
# two-level entry, second-level tree with depth 2
--disable_query_log
@@ -100,7 +100,7 @@ CREATE TABLE t1 (
i int(10) unsigned not null auto_increment primary key,
a varchar(255) not null,
FULLTEXT KEY (a)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
# two-level entry, second-level tree with depth 2
--disable_query_log
diff --git a/mysql-test/t/fulltext_distinct.test b/mysql-test/t/fulltext_distinct.test
index 2ccfb94c819..1f4cb8cd7bc 100644
--- a/mysql-test/t/fulltext_distinct.test
+++ b/mysql-test/t/fulltext_distinct.test
@@ -15,14 +15,14 @@ CREATE TABLE t1 (
KEY kt(tag),
KEY kv(value(15)),
FULLTEXT KEY kvf(value)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE t2 (
id_t2 mediumint unsigned NOT NULL default '0',
id_t1 mediumint unsigned NOT NULL default '0',
field_number tinyint unsigned NOT NULL default '0',
PRIMARY KEY (id_t2,id_t1,field_number),
KEY id_t1(id_t1)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (tag,value) VALUES ('foo123','bar111');
INSERT INTO t1 (tag,value) VALUES ('foo123','bar222');
diff --git a/mysql-test/t/fulltext_left_join.test b/mysql-test/t/fulltext_left_join.test
index e3083ddc4e1..f8dcfb2aad6 100644
--- a/mysql-test/t/fulltext_left_join.test
+++ b/mysql-test/t/fulltext_left_join.test
@@ -35,9 +35,9 @@ drop table t1, t2;
# Bug #484, reported by Stephen Brandon <stephen@brandonitconsulting.co.uk>
#
-create table t1 (venue_id int(11) default null, venue_text varchar(255) default null, dt datetime default null) type=myisam;
+create table t1 (venue_id int(11) default null, venue_text varchar(255) default null, dt datetime default null) engine=myisam;
insert into t1 (venue_id, venue_text, dt) values (1, 'a1', '2003-05-23 19:30:00'),(null, 'a2', '2003-05-23 19:30:00');
-create table t2 (name varchar(255) not null default '', entity_id int(11) not null auto_increment, primary key (entity_id), fulltext key name (name)) type=myisam;
+create table t2 (name varchar(255) not null default '', entity_id int(11) not null auto_increment, primary key (entity_id), fulltext key name (name)) engine=myisam;
insert into t2 (name, entity_id) values ('aberdeen town hall', 1), ('glasgow royal concert hall', 2), ('queen\'s hall, edinburgh', 3);
select * from t1 left join t2 on venue_id = entity_id where match(name) against('aberdeen' in boolean mode) and dt = '2003-05-23 19:30:00';
select * from t1 left join t2 on venue_id = entity_id where match(name) against('aberdeen') and dt = '2003-05-23 19:30:00';
diff --git a/mysql-test/t/func_compress.test b/mysql-test/t/func_compress.test
index 06ebb388517..79de99276a6 100644
--- a/mysql-test/t/func_compress.test
+++ b/mysql-test/t/func_compress.test
@@ -13,7 +13,7 @@ explain extended select uncompressed_length(compress(@test_compress_string))=len
select uncompressed_length(compress(@test_compress_string));
select length(compress(@test_compress_string))<length(@test_compress_string);
-create table t1 (a text, b char(255), c char(4)) type=myisam;
+create table t1 (a text, b char(255), c char(4)) engine=myisam;
insert into t1 (a,b,c) values (compress(@test_compress_string),compress(@test_compress_string),'d ');
select uncompress(a) from t1;
select uncompress(b) from t1;
diff --git a/mysql-test/t/func_date_add.test b/mysql-test/t/func_date_add.test
index 35acfe84bee..93c77daf86e 100644
--- a/mysql-test/t/func_date_add.test
+++ b/mysql-test/t/func_date_add.test
@@ -13,7 +13,7 @@ CREATE TABLE t1 (
sessions int(10) unsigned DEFAULT '0' NOT NULL,
ts timestamp(14),
PRIMARY KEY (visitor_id,group_id)
-)/*! type=MyISAM */;
+)/*! engine=MyISAM */;
INSERT INTO t1 VALUES (465931136,7,2,2,20000318160952);
INSERT INTO t1 VALUES (173865424,2,2,2,20000318233615);
INSERT INTO t1 VALUES (173865424,8,2,2,20000318233615);
diff --git a/mysql-test/t/func_group.test b/mysql-test/t/func_group.test
index 9e0184d35ce..17ed4c03b5a 100644
--- a/mysql-test/t/func_group.test
+++ b/mysql-test/t/func_group.test
@@ -350,7 +350,7 @@ select SQL_BIG_RESULT a,count(b), sum(b), avg(b), std(b), min(b), max(b), bit_an
explain extended select SQL_BIG_RESULT a,count(b), sum(b), avg(b), std(b), min(b), max(b), bit_and(b), bit_or(b), bit_xor(b) from t1 group by a;
drop table t1;
--disable_warnings
-create table t1 (USR_ID integer not null, MAX_REQ integer not null, constraint PK_SEA_USER primary key (USR_ID)) type=InnoDB;
+create table t1 (USR_ID integer not null, MAX_REQ integer not null, constraint PK_SEA_USER primary key (USR_ID)) engine=InnoDB;
--enable_warnings
insert into t1 values (1, 3);
select count(*) + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ + MAX_REQ - MAX_REQ from t1 group by MAX_REQ;
diff --git a/mysql-test/t/func_if.test b/mysql-test/t/func_if.test
index 7842df4fd0a..e44a7f6d6f9 100644
--- a/mysql-test/t/func_if.test
+++ b/mysql-test/t/func_if.test
@@ -14,7 +14,7 @@ select IF(0,"ERROR","this"),IF(1,"is","ERROR"),IF(NULL,"ERROR","a"),IF(1,2,3)|0,
#
# Test of IF and case-sensitiveness
#
-CREATE TABLE t1 (st varchar(255) NOT NULL, u int(11) NOT NULL) TYPE=MyISAM;
+CREATE TABLE t1 (st varchar(255) NOT NULL, u int(11) NOT NULL) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('a',1),('A',1),('aa',1),('AA',1),('a',1),('aaa',0),('BBB',0);
select if(1,st,st) s from t1 order by s;
select if(u=1,st,st) s from t1 order by s;
diff --git a/mysql-test/t/func_str.test b/mysql-test/t/func_str.test
index 4ae586256ae..0003f14c9ca 100644
--- a/mysql-test/t/func_str.test
+++ b/mysql-test/t/func_str.test
@@ -120,7 +120,7 @@ CREATE TABLE t1 (
modified timestamp(14) NOT NULL,
bugstatus int(10) unsigned default NULL,
submitter int(10) unsigned default NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,'Link',1,1,1,'aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa','2001-02-28 08:40:16',20010228084016,0,4);
SELECT CONCAT('"',CONCAT_WS('";"',title,prio,category,program,bugdesc,created,modified+0,bugstatus,submitter), '"') FROM t1;
@@ -133,7 +133,7 @@ drop table t1;
# Test bug in AES_DECRYPT() when called with wrong argument
#
-CREATE TABLE t1 (id int(11) NOT NULL auto_increment, tmp text NOT NULL, KEY id (id)) TYPE=MyISAM;
+CREATE TABLE t1 (id int(11) NOT NULL auto_increment, tmp text NOT NULL, KEY id (id)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1, 'a545f661efdd1fb66fdee3aab79945bf');
SELECT 1 FROM t1 WHERE tmp=AES_DECRYPT(tmp,"password");
DROP TABLE t1;
@@ -334,7 +334,7 @@ DROP TABLE t1;
#
# test for #739
-CREATE TABLE t1 (title text) TYPE=MyISAM;
+CREATE TABLE t1 (title text) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('Congress reconvenes in September to debate welfare and adult education');
INSERT INTO t1 VALUES ('House passes the CAREERS bill');
SELECT CONCAT("</a>",RPAD("",(55 - LENGTH(title)),".")) from t1;
diff --git a/mysql-test/t/func_test.test b/mysql-test/t/func_test.test
index 86e0ee2637b..1559fef7e6e 100644
--- a/mysql-test/t/func_test.test
+++ b/mysql-test/t/func_test.test
@@ -79,9 +79,9 @@ select _koi8r'a' LIKE _latin1'A';
#
# Test for LEAST() BUG in LEFT JOIN
#
-CREATE TABLE t1 ( faq_group_id int(11) NOT NULL default '0', faq_id int(11) NOT NULL default '0', title varchar(240) default NULL, keywords text, description longblob, solution longblob, status tinyint(4) NOT NULL default '0', access_id smallint(6) default NULL, lang_id smallint(6) NOT NULL default '0', created datetime NOT NULL default '0000-00-00 00:00:00', updated datetime default NULL, last_access datetime default NULL, last_notify datetime default NULL, solved_count int(11) NOT NULL default '0', static_solved int(11) default NULL, solved_1 int(11) default NULL, solved_2 int(11) default NULL, solved_3 int(11) default NULL, solved_4 int(11) default NULL, solved_5 int(11) default NULL, expires datetime default NULL, notes text, assigned_to smallint(6) default NULL, assigned_group smallint(6) default NULL, last_edited_by smallint(6) default NULL, orig_ref_no varchar(15) binary default NULL, c$fundstate smallint(6) default NULL, c$contributor smallint(6) default NULL, UNIQUE KEY t1$faq_id (faq_id), KEY t1$group_id$faq_id (faq_group_id,faq_id), KEY t1$c$fundstate (c$fundstate) ) TYPE=MyISAM;
+CREATE TABLE t1 ( faq_group_id int(11) NOT NULL default '0', faq_id int(11) NOT NULL default '0', title varchar(240) default NULL, keywords text, description longblob, solution longblob, status tinyint(4) NOT NULL default '0', access_id smallint(6) default NULL, lang_id smallint(6) NOT NULL default '0', created datetime NOT NULL default '0000-00-00 00:00:00', updated datetime default NULL, last_access datetime default NULL, last_notify datetime default NULL, solved_count int(11) NOT NULL default '0', static_solved int(11) default NULL, solved_1 int(11) default NULL, solved_2 int(11) default NULL, solved_3 int(11) default NULL, solved_4 int(11) default NULL, solved_5 int(11) default NULL, expires datetime default NULL, notes text, assigned_to smallint(6) default NULL, assigned_group smallint(6) default NULL, last_edited_by smallint(6) default NULL, orig_ref_no varchar(15) binary default NULL, c$fundstate smallint(6) default NULL, c$contributor smallint(6) default NULL, UNIQUE KEY t1$faq_id (faq_id), KEY t1$group_id$faq_id (faq_group_id,faq_id), KEY t1$c$fundstate (c$fundstate) ) ENGINE=MyISAM;
INSERT INTO t1 VALUES (82,82,'How to use the DynaVox Usage Counts Feature','usages count, number, corner, white, box, button','<as-html>\r\n<table width=\"100%\" border=\"0\">\r\n <tr>\r\n <td width=\"3%\"> </td>\r\n <td width=\"97%\">\r\n <h3><font face=\"Verdana, Arial, Helvetica, sans-serif\" color=\"#000000\">How \r\n To</font><!-- #BeginEditable \"CS_troubleshoot_question\" --><font face=\"Verdana, Arial, Helvetica, sans-serif\" color=\"#000099\"><font color=\"#000000\">: \r\n Display or Hide the Usage Counts to find out how many times each button is being selected. </font></font><!-- #EndEditable --></h3>\r\n </td>\r\n </tr>\r\n</table>','<as-html>\r\n <table width=\"100%\" border=\"0\">\r\n <tr>\r\n <td width=\"3%\"> </td>\r\n \r\n<td width=\"97%\"><!-- #BeginEditable \"CS_troubleshoot_answer\" --> \r\n \r\n<p><font color=\"#000000\" face=\"Verdana, Arial, Helvetica, sans-serif\">1. Select \r\n the <i>On/Setup</i> button to access the DynaVox Setup Menu.<br>\r\n 2. Select <b>Button Features.</b><br>\r\n 3. Below the <b>OK</b> button is the <b>Usage Counts</b> button.<br>\r\n a. If it says \"Hidden\" then the Usage Counts will not be displayed.<br>\r\n b. If it says \"Displayed\" then the Usage Counts will be shown.<br>\r\n c. Select the <b>Usage Counts</b> Option Ring once and it will toggle \r\n to the alternative option.<br>\r\n 4. Once the correct setting has been chosen, select <b>OK</b> to leave the <i>Button \r\n Features</i> menu.<br>\r\n 5. Select <b>OK</b> out of the <i>Setup</i> menu and return to the communication \r\n page.</font></p>\r\n <p><font color=\"#000000\" face=\"Verdana, Arial, Helvetica, sans-serif\">For \r\n further information on <i>Usage Counts,</i> see the <i>Button Features \r\n Menu Entry</i> in the DynaVox/DynaMyte Reference Manual.</font></p>\r\n<!-- #EndEditable --></td>\r\n </tr>\r\n</table>',4,1,1,'2001-11-16 16:43:34','2002-11-25 12:09:43','2003-07-24 01:04:48',NULL,11,NULL,0,0,0,0,0,NULL,NULL,NULL,NULL,11,NULL,NULL,NULL);
-CREATE TABLE t2 ( access_id smallint(6) NOT NULL default '0', name varchar(20) binary default NULL, rank smallint(6) NOT NULL default '0', KEY t2$access_id (access_id) ) TYPE=MyISAM;
+CREATE TABLE t2 ( access_id smallint(6) NOT NULL default '0', name varchar(20) binary default NULL, rank smallint(6) NOT NULL default '0', KEY t2$access_id (access_id) ) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,'Everyone',2),(2,'Help',3),(3,'Customer Support',1);
SELECT f_acc.rank, a1.rank, a2.rank FROM t1 LEFT JOIN t1 f1 ON (f1.access_id=1 AND f1.faq_group_id = t1.faq_group_id) LEFT JOIN t2 a1 ON (a1.access_id = f1.access_id) LEFT JOIN t1 f2 ON (f2.access_id=3 AND f2.faq_group_id = t1.faq_group_id) LEFT JOIN t2 a2 ON (a2.access_id = f2.access_id), t2 f_acc WHERE LEAST(a1.rank,a2.rank) = f_acc.rank;
DROP TABLE t1,t2;
diff --git a/mysql-test/t/func_time.test b/mysql-test/t/func_time.test
index f1a24a4c3cb..6f114fe18ae 100644
--- a/mysql-test/t/func_time.test
+++ b/mysql-test/t/func_time.test
@@ -151,7 +151,7 @@ drop table t1,t2;
#
# Test bug with month() and year() on text fields with wrong information
-CREATE TABLE t1 (updated text) TYPE=MyISAM;
+CREATE TABLE t1 (updated text) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('');
SELECT month(updated) from t1;
SELECT year(updated) from t1;
diff --git a/mysql-test/t/gis-rtree.test b/mysql-test/t/gis-rtree.test
index 0368ddb41cb..08ba8329b48 100644
--- a/mysql-test/t/gis-rtree.test
+++ b/mysql-test/t/gis-rtree.test
@@ -9,7 +9,7 @@ CREATE TABLE t1 (
fid INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
g GEOMETRY NOT NULL,
SPATIAL KEY(g)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
SHOW CREATE TABLE t1;
@@ -31,7 +31,7 @@ DROP TABLE t1;
CREATE TABLE t2 (
fid INT NOT NULL AUTO_INCREMENT PRIMARY KEY,
g GEOMETRY NOT NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
let $1=10;
while ($1)
diff --git a/mysql-test/t/group_by.test b/mysql-test/t/group_by.test
index 705e32c82df..1e65bef19b7 100644
--- a/mysql-test/t/group_by.test
+++ b/mysql-test/t/group_by.test
@@ -352,7 +352,7 @@ CREATE TABLE t1 (
value int(11) unsigned NOT NULL default '0',
UNIQUE KEY pid2 (pid,c1id,c2id),
UNIQUE KEY pid (pid,value)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1, 1, NULL, 1),(1, 2, NULL, 2),(1, NULL, 3, 3),(1, 4, NULL, 4),(1, 5, NULL, 5);
@@ -360,7 +360,7 @@ CREATE TABLE t2 (
id int(11) unsigned NOT NULL default '0',
active enum('Yes','No') NOT NULL default 'Yes',
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1, 'Yes'),(2, 'No'),(4, 'Yes'),(5, 'No');
diff --git a/mysql-test/t/handler.test b/mysql-test/t/handler.test
index 99ca858990c..d734882591a 100644
--- a/mysql-test/t/handler.test
+++ b/mysql-test/t/handler.test
@@ -80,7 +80,7 @@ insert into t1 values (17);
--error 1109
handler t2 read first;
handler t1 open as t2;
-alter table t1 type=MyISAM;
+alter table t1 engine=MyISAM;
--error 1109
handler t2 read first;
drop table t1;
diff --git a/mysql-test/t/heap.test b/mysql-test/t/heap.test
index 797472e7769..d867d5f4323 100644
--- a/mysql-test/t/heap.test
+++ b/mysql-test/t/heap.test
@@ -6,7 +6,7 @@
drop table if exists t1;
--enable_warnings
-create table t1 (a int not null,b int not null, primary key (a)) type=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
+create table t1 (a int not null,b int not null, primary key (a)) engine=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
insert into t1 values(1,1),(2,2),(3,3),(4,4);
delete from t1 where a=1 or a=0;
#show table status like "t1";
@@ -20,20 +20,20 @@ select * from t1;
alter table t1 add c int not null, add key (c,a);
drop table t1;
-create table t1 (a int not null,b int not null, primary key (a)) type=memory comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key (a)) engine=memory comment="testing heaps";
insert into t1 values(1,1),(2,2),(3,3),(4,4);
delete from t1 where a > 0;
select * from t1;
drop table t1;
-create table t1 (a int not null,b int not null, primary key (a)) type=heap comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key (a)) engine=heap comment="testing heaps";
insert into t1 values(1,1),(2,2),(3,3),(4,4);
-alter table t1 modify a int not null auto_increment, type=myisam, comment="new myisam table";
+alter table t1 modify a int not null auto_increment, engine=myisam, comment="new myisam table";
#show table status like "t1";
select * from t1;
drop table t1;
-create table t1 (a int not null) type=heap;
+create table t1 (a int not null) engine=heap;
insert into t1 values (869751),(736494),(226312),(802616);
select * from t1 where a > 736494;
alter table t1 add unique uniq_id(a);
@@ -41,31 +41,31 @@ select * from t1 where a > 736494;
select * from t1 where a = 736494;
select * from t1 where a=869751 or a=736494;
select * from t1 where a in (869751,736494,226312,802616);
-alter table t1 type=myisam;
+alter table t1 engine=myisam;
explain select * from t1 where a in (869751,736494,226312,802616);
drop table t1;
create table t1 (x int not null, y int not null, key x (x), unique y (y))
-type=heap;
+engine=heap;
insert into t1 values (1,1),(2,2),(1,3),(2,4),(2,5),(2,6);
select * from t1 where x=1;
select * from t1,t1 as t2 where t1.x=t2.y;
explain select * from t1,t1 as t2 where t1.x=t2.y;
drop table t1;
-create table t1 (a int) type=heap;
+create table t1 (a int) engine=heap;
insert into t1 values(1);
select max(a) from t1;
drop table t1;
-CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key(a), key(b) ) TYPE=HEAP;
+CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key(a), key(b) ) ENGINE=HEAP;
insert into t1 values(1,1),(1,2),(2,3),(1,3),(1,4),(1,5),(1,6);
select * from t1 where a=1;
insert into t1 values(1,1),(1,2),(2,3),(1,3),(1,4),(1,5),(1,6);
select * from t1 where a=1;
drop table t1;
-create table t1 (id int unsigned not null, primary key (id)) type=HEAP;
+create table t1 (id int unsigned not null, primary key (id)) engine=HEAP;
insert into t1 values(1);
select max(id) from t1;
insert into t1 values(2);
@@ -73,16 +73,16 @@ select max(id) from t1;
replace into t1 values(1);
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table if exists t1;
# Test of non unique index
CREATE table t1(f1 int not null,f2 char(20) not
-null,index(f2)) type=heap;
+null,index(f2)) engine=heap;
INSERT into t1 set f1=12,f2="bill";
INSERT into t1 set f1=13,f2="bill";
INSERT into t1 set f1=14,f2="bill";
@@ -100,7 +100,7 @@ drop table t1;
# Test when using part key searches
#
-create table t1 (btn char(10) not null, key(btn)) type=heap;
+create table t1 (btn char(10) not null, key(btn)) engine=heap;
insert into t1 values ("hello"),("hello"),("hello"),("hello"),("hello"),("a"),("b"),("c"),("d"),("e"),("f"),("g"),("h"),("i");
explain select * from t1 where btn like "q%";
select * from t1 where btn like "q%";
@@ -119,7 +119,7 @@ CREATE TABLE t1 (
b int default NULL,
KEY a (a),
UNIQUE b (b)
-) type=heap;
+) engine=heap;
INSERT INTO t1 VALUES (NULL,99),(99,NULL),(1,1),(2,2),(1,3);
SELECT * FROM t1 WHERE a=NULL;
explain SELECT * FROM t1 WHERE a IS NULL;
@@ -135,7 +135,7 @@ DROP TABLE t1;
CREATE TABLE t1 (
a int default NULL,
key a (a)
-) TYPE=HEAP;
+) ENGINE=HEAP;
INSERT INTO t1 VALUES (10), (10), (10);
EXPLAIN SELECT * FROM t1 WHERE a=10;
SELECT * FROM t1 WHERE a=10;
@@ -145,7 +145,7 @@ DROP TABLE t1;
# Test when deleting all rows
#
-CREATE TABLE t1 (a int not null, primary key(a)) type=heap;
+CREATE TABLE t1 (a int not null, primary key(a)) engine=heap;
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
DELETE from t1 where a < 100;
SELECT * from t1;
diff --git a/mysql-test/t/heap_auto_increment.test b/mysql-test/t/heap_auto_increment.test
index 6f392f6830d..9d0fefa4d52 100644
--- a/mysql-test/t/heap_auto_increment.test
+++ b/mysql-test/t/heap_auto_increment.test
@@ -6,7 +6,7 @@
drop table if exists t1;
--enable_warnings
-create table t1 (a int not null auto_increment,b int, primary key (a)) type=heap auto_increment=3;
+create table t1 (a int not null auto_increment,b int, primary key (a)) engine=heap auto_increment=3;
insert into t1 values (1,1),(NULL,3),(NULL,4);
delete from t1 where a=4;
insert into t1 values (NULL,5),(NULL,6);
@@ -25,7 +25,7 @@ drop table t1;
create table t1 (
skey tinyint unsigned NOT NULL auto_increment PRIMARY KEY,
sval char(20)
-) type=heap;
+) engine=heap;
insert into t1 values (NULL, "hello");
insert into t1 values (NULL, "hey");
select * from t1;
diff --git a/mysql-test/t/heap_btree.test b/mysql-test/t/heap_btree.test
index 34aeeec0a11..a520065a8b3 100644
--- a/mysql-test/t/heap_btree.test
+++ b/mysql-test/t/heap_btree.test
@@ -6,7 +6,7 @@
drop table if exists t1;
--enable_warnings
-create table t1 (a int not null,b int not null, primary key using BTREE (a)) type=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
+create table t1 (a int not null,b int not null, primary key using BTREE (a)) engine=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
insert into t1 values(1,1),(2,2),(3,3),(4,4);
delete from t1 where a=1 or a=0;
#show table status like "t1";
@@ -20,20 +20,20 @@ select * from t1;
alter table t1 add c int not null, add key using BTREE (c,a);
drop table t1;
-create table t1 (a int not null,b int not null, primary key using BTREE (a)) type=heap comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key using BTREE (a)) engine=heap comment="testing heaps";
insert into t1 values(-2,-2),(-1,-1),(0,0),(1,1),(2,2),(3,3),(4,4);
delete from t1 where a > -3;
select * from t1;
drop table t1;
-create table t1 (a int not null,b int not null, primary key using BTREE (a)) type=heap comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key using BTREE (a)) engine=heap comment="testing heaps";
insert into t1 values(1,1),(2,2),(3,3),(4,4);
-alter table t1 modify a int not null auto_increment, type=myisam, comment="new myisam table";
+alter table t1 modify a int not null auto_increment, engine=myisam, comment="new myisam table";
#show table status like "t1";
select * from t1;
drop table t1;
-create table t1 (a int not null) type=heap;
+create table t1 (a int not null) engine=heap;
insert into t1 values (869751),(736494),(226312),(802616);
select * from t1 where a > 736494;
alter table t1 add unique uniq_id using BTREE (a);
@@ -41,12 +41,12 @@ select * from t1 where a > 736494;
select * from t1 where a = 736494;
select * from t1 where a=869751 or a=736494;
select * from t1 where a in (869751,736494,226312,802616);
-alter table t1 type=myisam;
+alter table t1 engine=myisam;
explain select * from t1 where a in (869751,736494,226312,802616);
drop table t1;
create table t1 (x int not null, y int not null, key x using BTREE (x,y), unique y using BTREE (y))
-type=heap;
+engine=heap;
insert into t1 values (1,1),(2,2),(1,3),(2,4),(2,5),(2,6);
explain select * from t1 where x=1;
select * from t1 where x=1;
@@ -54,12 +54,12 @@ select * from t1,t1 as t2 where t1.x=t2.y;
explain select * from t1,t1 as t2 where t1.x=t2.y;
drop table t1;
-create table t1 (a int) type=heap;
+create table t1 (a int) engine=heap;
insert into t1 values(1);
select max(a) from t1;
drop table t1;
-CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key using BTREE (a,b), key using BTREE (b) ) TYPE=HEAP;
+CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key using BTREE (a,b), key using BTREE (b) ) ENGINE=HEAP;
insert into t1 values(1,1),(1,2),(2,3),(1,3),(1,4),(1,5),(1,6);
select * from t1 where a=1;
insert into t1 values(1,1),(1,2),(2,3),(1,3),(1,4),(1,5),(1,6);
@@ -73,7 +73,7 @@ select * from t1 where b=1;
explain select * from t1 where b=1;
drop table t1;
-create table t1 (id int unsigned not null, primary key using BTREE (id)) type=HEAP;
+create table t1 (id int unsigned not null, primary key using BTREE (id)) engine=HEAP;
insert into t1 values(1);
select max(id) from t1;
insert into t1 values(2);
@@ -81,16 +81,16 @@ select max(id) from t1;
replace into t1 values(1);
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table if exists t1;
# Test of non unique index
CREATE table t1(f1 int not null,f2 char(20) not
-null,index(f2)) type=heap;
+null,index(f2)) engine=heap;
INSERT into t1 set f1=12,f2="bill";
INSERT into t1 set f1=13,f2="bill";
INSERT into t1 set f1=14,f2="bill";
@@ -108,7 +108,7 @@ drop table t1;
# Test when using part key searches
#
-create table t1 (btn char(10) not null, key using BTREE (btn)) type=heap;
+create table t1 (btn char(10) not null, key using BTREE (btn)) engine=heap;
insert into t1 values ("hello"),("hello"),("hello"),("hello"),("hello"),("a"),("b"),("c"),("d"),("e"),("f"),("g"),("h"),("i");
explain select * from t1 where btn like "q%";
select * from t1 where btn like "q%";
@@ -127,7 +127,7 @@ CREATE TABLE t1 (
b int default NULL,
KEY a using BTREE (a),
UNIQUE b using BTREE (b)
-) type=heap;
+) engine=heap;
INSERT INTO t1 VALUES (NULL,99),(99,NULL),(1,1),(2,2),(1,3);
SELECT * FROM t1 WHERE a=NULL;
explain SELECT * FROM t1 WHERE a IS NULL;
@@ -140,7 +140,7 @@ SELECT * FROM t1 WHERE b<=>NULL;
INSERT INTO t1 VALUES (1,3);
DROP TABLE t1;
-CREATE TABLE t1 (a int, b int, c int, key using BTREE (a, b, c)) type=heap;
+CREATE TABLE t1 (a int, b int, c int, key using BTREE (a, b, c)) engine=heap;
INSERT INTO t1 VALUES (1, NULL, NULL), (1, 1, NULL), (1, NULL, 1);
SELECT * FROM t1 WHERE a=1 and b IS NULL;
SELECT * FROM t1 WHERE a=1 and c IS NULL;
@@ -151,7 +151,7 @@ DROP TABLE t1;
# Test when deleting all rows
#
-CREATE TABLE t1 (a int not null, primary key using BTREE (a)) type=heap;
+CREATE TABLE t1 (a int not null, primary key using BTREE (a)) engine=heap;
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
DELETE from t1 where a < 100;
SELECT * from t1;
diff --git a/mysql-test/t/heap_hash.test b/mysql-test/t/heap_hash.test
index f339a10efc6..412b6f2e705 100644
--- a/mysql-test/t/heap_hash.test
+++ b/mysql-test/t/heap_hash.test
@@ -6,7 +6,7 @@
drop table if exists t1;
--enable_warnings
-create table t1 (a int not null,b int not null, primary key using HASH (a)) type=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
+create table t1 (a int not null,b int not null, primary key using HASH (a)) engine=heap comment="testing heaps" avg_row_length=100 min_rows=1 max_rows=100;
insert into t1 values(1,1),(2,2),(3,3),(4,4);
delete from t1 where a=1 or a=0;
#show table status like "t1";
@@ -20,20 +20,20 @@ select * from t1;
alter table t1 add c int not null, add key using HASH (c,a);
drop table t1;
-create table t1 (a int not null,b int not null, primary key using HASH (a)) type=heap comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key using HASH (a)) engine=heap comment="testing heaps";
insert into t1 values(1,1),(2,2),(3,3),(4,4);
delete from t1 where a > 0;
select * from t1;
drop table t1;
-create table t1 (a int not null,b int not null, primary key using HASH (a)) type=heap comment="testing heaps";
+create table t1 (a int not null,b int not null, primary key using HASH (a)) engine=heap comment="testing heaps";
insert into t1 values(1,1),(2,2),(3,3),(4,4);
-alter table t1 modify a int not null auto_increment, type=myisam, comment="new myisam table";
+alter table t1 modify a int not null auto_increment, engine=myisam, comment="new myisam table";
#show table status like "t1";
select * from t1;
drop table t1;
-create table t1 (a int not null) type=heap;
+create table t1 (a int not null) engine=heap;
insert into t1 values (869751),(736494),(226312),(802616);
select * from t1 where a > 736494;
alter table t1 add unique uniq_id using HASH (a);
@@ -41,31 +41,31 @@ select * from t1 where a > 736494;
select * from t1 where a = 736494;
select * from t1 where a=869751 or a=736494;
select * from t1 where a in (869751,736494,226312,802616);
-alter table t1 type=myisam;
+alter table t1 engine=myisam;
explain select * from t1 where a in (869751,736494,226312,802616);
drop table t1;
create table t1 (x int not null, y int not null, key x using HASH (x), unique y using HASH (y))
-type=heap;
+engine=heap;
insert into t1 values (1,1),(2,2),(1,3),(2,4),(2,5),(2,6);
select * from t1 where x=1;
select * from t1,t1 as t2 where t1.x=t2.y;
explain select * from t1,t1 as t2 where t1.x=t2.y;
drop table t1;
-create table t1 (a int) type=heap;
+create table t1 (a int) engine=heap;
insert into t1 values(1);
select max(a) from t1;
drop table t1;
-CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key using HASH (a), key using HASH (b) ) TYPE=HEAP;
+CREATE TABLE t1 ( a int not null default 0, b int not null default 0, key using HASH (a), key using HASH (b) ) ENGINE=HEAP;
insert into t1 values(1,1),(1,2),(2,3),(1,3),(1,4),(1,5),(1,6);
select * from t1 where a=1;
insert into t1 values(1,1),(1,2),(2,3),(1,3),(1,4),(1,5),(1,6);
select * from t1 where a=1;
drop table t1;
-create table t1 (id int unsigned not null, primary key using HASH (id)) type=HEAP;
+create table t1 (id int unsigned not null, primary key using HASH (id)) engine=HEAP;
insert into t1 values(1);
select max(id) from t1;
insert into t1 values(2);
@@ -73,16 +73,16 @@ select max(id) from t1;
replace into t1 values(1);
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table t1;
-create table t1 (n int) type=heap;
+create table t1 (n int) engine=heap;
drop table if exists t1;
# Test of non unique index
CREATE table t1(f1 int not null,f2 char(20) not
-null,index(f2)) type=heap;
+null,index(f2)) engine=heap;
INSERT into t1 set f1=12,f2="bill";
INSERT into t1 set f1=13,f2="bill";
INSERT into t1 set f1=14,f2="bill";
@@ -100,7 +100,7 @@ drop table t1;
# Test when using part key searches
#
-create table t1 (btn char(10) not null, key using HASH (btn)) type=heap;
+create table t1 (btn char(10) not null, key using HASH (btn)) engine=heap;
insert into t1 values ("hello"),("hello"),("hello"),("hello"),("hello"),("a"),("b"),("c"),("d"),("e"),("f"),("g"),("h"),("i");
explain select * from t1 where btn like "q%";
select * from t1 where btn like "q%";
@@ -119,7 +119,7 @@ CREATE TABLE t1 (
b int default NULL,
KEY a using HASH (a),
UNIQUE b using HASH (b)
-) type=heap;
+) engine=heap;
INSERT INTO t1 VALUES (NULL,99),(99,NULL),(1,1),(2,2),(1,3);
SELECT * FROM t1 WHERE a=NULL;
explain SELECT * FROM t1 WHERE a IS NULL;
@@ -136,7 +136,7 @@ DROP TABLE t1;
# Test when deleting all rows
#
-CREATE TABLE t1 (a int not null, primary key using HASH (a)) type=heap;
+CREATE TABLE t1 (a int not null, primary key using HASH (a)) engine=heap;
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
DELETE from t1 where a < 100;
SELECT * from t1;
diff --git a/mysql-test/t/help.test b/mysql-test/t/help.test
index 82312340336..54c551ccd7a 100644
--- a/mysql-test/t/help.test
+++ b/mysql-test/t/help.test
@@ -65,10 +65,10 @@ help 'impossible_function_1';
help 'impossible_category_1';
##############
-alter table mysql.help_relation type=innodb;
-alter table mysql.help_keyword type=innodb;
-alter table mysql.help_topic type=innodb;
-alter table mysql.help_category type=innodb;
+alter table mysql.help_relation engine=innodb;
+alter table mysql.help_keyword engine=innodb;
+alter table mysql.help_topic engine=innodb;
+alter table mysql.help_category engine=innodb;
##############
help 'function_of_my_dream';
@@ -90,10 +90,10 @@ help 'impossible_function_1';
help 'impossible_category_1';
##############
-alter table mysql.help_relation type=myisam;
-alter table mysql.help_keyword type=myisam;
-alter table mysql.help_topic type=myisam;
-alter table mysql.help_category type=myisam;
+alter table mysql.help_relation engine=myisam;
+alter table mysql.help_keyword engine=myisam;
+alter table mysql.help_topic engine=myisam;
+alter table mysql.help_category engine=myisam;
delete from mysql.help_topic where help_topic_id=@topic1_id;
delete from mysql.help_topic where help_topic_id=@topic2_id;
diff --git a/mysql-test/t/innodb-deadlock.test b/mysql-test/t/innodb-deadlock.test
index ba4ec4a9ae4..8a36982b0c1 100644
--- a/mysql-test/t/innodb-deadlock.test
+++ b/mysql-test/t/innodb-deadlock.test
@@ -12,7 +12,7 @@ drop table if exists t1,t2;
#
connection con1;
-create table t1 (id integer, x integer) type=INNODB;
+create table t1 (id integer, x integer) engine=INNODB;
insert into t1 values(0, 0);
set autocommit=0;
SELECT * from t1 where id = 0 FOR UPDATE;
@@ -44,8 +44,8 @@ drop table t1;
#
connection con1;
-create table t1 (id integer, x integer) type=INNODB;
-create table t2 (b integer, a integer) type=INNODB;
+create table t1 (id integer, x integer) engine=INNODB;
+create table t2 (b integer, a integer) engine=INNODB;
insert into t1 values(0, 0), (300, 300);
insert into t2 values(0, 10), (1, 20), (2, 30);
commit;
@@ -77,8 +77,8 @@ select * from t1;
commit;
drop table t1, t2;
-create table t1 (id integer, x integer) type=INNODB;
-create table t2 (b integer, a integer) type=INNODB;
+create table t1 (id integer, x integer) engine=INNODB;
+create table t2 (b integer, a integer) engine=INNODB;
insert into t1 values(0, 0), (300, 300);
insert into t2 values(0, 0), (1, 20), (2, 30);
commit;
diff --git a/mysql-test/t/innodb.test b/mysql-test/t/innodb.test
index 3349ea21c45..6f7a0e100c3 100644
--- a/mysql-test/t/innodb.test
+++ b/mysql-test/t/innodb.test
@@ -9,7 +9,7 @@ drop table if exists t1,t2,t3,t4;
drop database if exists mysqltest;
--enable_warnings
-create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) type=innodb;
+create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) engine=innodb;
insert into t1 (code, name) values (1, 'Tim'), (1, 'Monty'), (2, 'David'), (2, 'Erik'), (3, 'Sasha'), (3, 'Jeremy'), (4, 'Matt');
select id, code, name from t1 order by id;
@@ -34,7 +34,7 @@ CREATE TABLE t1 (
PRIMARY KEY (id),
KEY parent_id (parent_id),
KEY level (level)
-) type=innodb;
+) engine=innodb;
INSERT INTO t1 VALUES (1,0,0),(3,1,1),(4,1,1),(8,2,2),(9,2,2),(17,3,2),(22,4,2),(24,4,2),(28,5,2),(29,5,2),(30,5,2),(31,6,2),(32,6,2),(33,6,2),(203,7,2),(202,7,2),(20,3,2),(157,0,0),(193,5,2),(40,7,2),(2,1,1),(15,2,2),(6,1,1),(34,6,2),(35,6,2),(16,3,2),(7,1,1),(36,7,2),(18,3,2),(26,5,2),(27,5,2),(183,4,2),(38,7,2),(25,5,2),(37,7,2),(21,4,2),(19,3,2),(5,1,1),(179,5,2);
update t1 set parent_id=parent_id+100;
select * from t1 where parent_id=102;
@@ -67,7 +67,7 @@ CREATE TABLE t1 (
gesuchnr int(11) DEFAULT '0' NOT NULL,
benutzer_id int(11) DEFAULT '0' NOT NULL,
PRIMARY KEY (gesuchnr,benutzer_id)
-) type=innodb;
+) engine=innodb;
replace into t1 (gesuchnr,benutzer_id) values (2,1);
replace into t1 (gesuchnr,benutzer_id) values (1,1);
@@ -79,7 +79,7 @@ drop table t1;
# test delete using hidden_primary_key
#
-create table t1 (a int) type=innodb;
+create table t1 (a int) engine=innodb;
insert into t1 values (1), (2);
optimize table t1;
delete from t1 where a = 1;
@@ -87,7 +87,7 @@ select * from t1;
check table t1;
drop table t1;
-create table t1 (a int,b varchar(20)) type=innodb;
+create table t1 (a int,b varchar(20)) engine=innodb;
insert into t1 values (1,""), (2,"testing");
delete from t1 where a = 1;
select * from t1;
@@ -101,7 +101,7 @@ drop table t1;
# Test of reading on secondary key with may be null
-create table t1 (a int,b varchar(20),key(a)) type=innodb;
+create table t1 (a int,b varchar(20),key(a)) engine=innodb;
insert into t1 values (1,""), (2,"testing");
select * from t1 where a = 1;
drop table t1;
@@ -110,7 +110,7 @@ drop table t1;
# Test rollback
#
-create table t1 (n int not null primary key) type=innodb;
+create table t1 (n int not null primary key) engine=innodb;
set autocommit=0;
insert into t1 values (4);
rollback;
@@ -137,7 +137,7 @@ drop table t1;
# Test for commit and FLUSH TABLES WITH READ LOCK
#
-create table t1 (n int not null primary key) type=innodb;
+create table t1 (n int not null primary key) engine=innodb;
start transaction;
insert into t1 values (4);
flush tables with read lock;
@@ -154,7 +154,7 @@ drop table t1;
# Testing transactions
#
-create table t1 ( id int NOT NULL PRIMARY KEY, nom varchar(64)) type=innodb;
+create table t1 ( id int NOT NULL PRIMARY KEY, nom varchar(64)) engine=innodb;
begin;
insert into t1 values(1,'hamdouni');
select id as afterbegin_id,nom as afterbegin_nom from t1;
@@ -172,7 +172,7 @@ drop table t1;
# Simple not autocommit test
#
-CREATE TABLE t1 (id char(8) not null primary key, val int not null) type=innodb;
+CREATE TABLE t1 (id char(8) not null primary key, val int not null) engine=innodb;
insert into t1 values ('pippo', 12);
-- error 1062
insert into t1 values ('pippo', 12); # Gives error
@@ -194,10 +194,10 @@ drop table t1;
# Test of active transactions
#
-create table t1 (a integer) type=innodb;
+create table t1 (a integer) engine=innodb;
start transaction;
rename table t1 to t2;
-create table t1 (b integer) type=innodb;
+create table t1 (b integer) engine=innodb;
insert into t1 values (1);
rollback;
drop table t1;
@@ -209,12 +209,12 @@ set autocommit=1;
# The following simple tests failed at some point
#
-CREATE TABLE t1 (ID INTEGER NOT NULL PRIMARY KEY, NAME VARCHAR(64)) TYPE=innodb;
+CREATE TABLE t1 (ID INTEGER NOT NULL PRIMARY KEY, NAME VARCHAR(64)) ENGINE=innodb;
INSERT INTO t1 VALUES (1, 'Jochen');
select * from t1;
drop table t1;
-CREATE TABLE t1 ( _userid VARCHAR(60) NOT NULL PRIMARY KEY) TYPE=innodb;
+CREATE TABLE t1 ( _userid VARCHAR(60) NOT NULL PRIMARY KEY) ENGINE=innodb;
set autocommit=0;
INSERT INTO t1 SET _userid='marc@anyware.co.uk';
COMMIT;
@@ -233,7 +233,7 @@ CREATE TABLE t1 (
ref_email varchar(100) DEFAULT '' NOT NULL,
detail varchar(200),
PRIMARY KEY (user_id,ref_email)
-)type=innodb;
+)engine=innodb;
INSERT INTO t1 VALUES (10292,'sanjeev','29153373','sansh777@hotmail.com','xxx'),(10292,'shirish','2333604','shirish@yahoo.com','ddsds'),(10292,'sonali','323232','sonali@bolly.com','filmstar');
select * from t1 where user_id=10292;
@@ -259,7 +259,7 @@ drop table t1;
#
create table t1 (col1 int not null, col2 char(4) not null, primary key(col1));
-alter table t1 type=innodb;
+alter table t1 engine=innodb;
insert into t1 values ('1','1'),('5','2'),('2','3'),('3','4'),('4','4');
select * from t1;
update t1 set col2='7' where col1='4';
@@ -274,8 +274,8 @@ drop table t1;
# INSERT INTO innodb tables
#
-create table t1 (a int not null , b int, primary key (a)) type = innodb;
-create table t2 (a int not null , b int, primary key (a)) type = myisam;
+create table t1 (a int not null , b int, primary key (a)) engine = innodb;
+create table t2 (a int not null , b int, primary key (a)) engine = myisam;
insert into t1 VALUES (1,3) , (2,3), (3,3);
select * from t1;
insert into t2 select * from t1;
@@ -298,7 +298,7 @@ CREATE TABLE t1 (
passwd varchar(32) binary DEFAULT '' NOT NULL,
PRIMARY KEY (id),
UNIQUE ggid (ggid)
-) TYPE=innodb;
+) ENGINE=innodb;
insert into t1 (ggid,passwd) values ('test1','xxx');
insert into t1 (ggid,passwd) values ('test2','yyy');
@@ -336,7 +336,7 @@ CREATE TABLE t1 (
approved datetime,
dummy_primary_key int(11) NOT NULL auto_increment,
PRIMARY KEY (dummy_primary_key)
-) TYPE=innodb;
+) ENGINE=innodb;
INSERT INTO t1 VALUES ('user_0','somepassword','N',0,0,0,'2000-09-07','23:06:59','2000-09-07 23:06:59',1);
INSERT INTO t1 VALUES ('user_1','somepassword','Y',1,1,1,'2000-09-07','23:06:59','2000-09-07 23:06:59',2);
INSERT INTO t1 VALUES ('user_2','somepassword','N',2,2,1.4142135623731,'2000-09-07','23:06:59','2000-09-07 23:06:59',3);
@@ -356,7 +356,7 @@ CREATE TABLE t1 (
KEY (id),
KEY parent_id (parent_id),
KEY level (level)
-) type=innodb;
+) engine=innodb;
INSERT INTO t1 VALUES (1,0,0),(3,1,1),(4,1,1),(8,2,2),(9,2,2),(17,3,2),(22,4,2),(24,4,2),(28,5,2),(29,5,2),(30,5,2),(31,6,2),(32,6,2),(33,6,2),(203,7,2),(202,7,2),(20,3,2),(157,0,0),(193,5,2),(40,7,2),(2,1,1),(15,2,2),(6,1,1),(34,6,2),(35,6,2),(16,3,2),(7,1,1),(36,7,2),(18,3,2),(26,5,2),(27,5,2),(183,4,2),(38,7,2),(25,5,2),(37,7,2),(21,4,2),(19,3,2),(5,1,1);
INSERT INTO t1 values (179,5,2);
update t1 set parent_id=parent_id+100;
@@ -390,7 +390,7 @@ CREATE TABLE t1 (
sca_sch_desc varchar(16),
PRIMARY KEY (sca_code, cat_code, lan_code),
INDEX sca_pic (sca_pic)
-) type = innodb ;
+) engine = innodb ;
INSERT INTO t1 ( sca_code, cat_code, sca_desc, lan_code, sca_pic, sca_sdesc, sca_sch_desc) VALUES ( 'PD', 'J', 'PENDANT', 'EN', NULL, NULL, 'PENDANT'),( 'RI', 'J', 'RING', 'EN', NULL, NULL, 'RING'),( 'QQ', 'N', 'RING', 'EN', 'not null', NULL, 'RING');
select count(*) from t1 where sca_code = 'PD';
@@ -412,7 +412,7 @@ drop table t1;
# Test of opening table twice and timestamps
#
set @a:=now();
-CREATE TABLE t1 (a int not null, b timestamp not null, primary key (a)) type=innodb;
+CREATE TABLE t1 (a int not null, b timestamp not null, primary key (a)) engine=innodb;
insert into t1 (a) values(1),(2),(3);
select t1.a from t1 natural join t1 as t2 where t1.b >= @a order by t1.a;
update t1 set a=5 where a=1;
@@ -422,7 +422,7 @@ drop table t1;
#
# Test with variable length primary key
#
-create table t1 (a varchar(100) not null, primary key(a), b int not null) type=innodb;
+create table t1 (a varchar(100) not null, primary key(a), b int not null) engine=innodb;
insert into t1 values("hello",1),("world",2);
select * from t1 order by b desc;
optimize table t1;
@@ -433,7 +433,7 @@ drop table t1;
#
# Test of create index with NULL columns
#
-create table t1 (i int, j int ) TYPE=innodb;
+create table t1 (i int, j int ) ENGINE=innodb;
insert into t1 values (1,2);
select * from t1 where i=1 and j=2;
create index ax1 on t1 (i,j);
@@ -448,7 +448,7 @@ CREATE TABLE t1 (
a int3 unsigned NOT NULL,
b int1 unsigned NOT NULL,
UNIQUE (a, b)
-) TYPE = innodb;
+) ENGINE = innodb;
INSERT INTO t1 VALUES (1, 1);
SELECT MIN(B),MAX(b) FROM t1 WHERE t1.a = 1;
@@ -458,7 +458,7 @@ drop table t1;
# Test INSERT DELAYED
#
-CREATE TABLE t1 (a int unsigned NOT NULL) type=innodb;
+CREATE TABLE t1 (a int unsigned NOT NULL) engine=innodb;
# Can't test this in 3.23
# INSERT DELAYED INTO t1 VALUES (1);
INSERT INTO t1 VALUES (1);
@@ -470,7 +470,7 @@ DROP TABLE t1;
# Crash when using many tables (Test case by Jeremy D Zawodny)
#
-create table t1 (a int primary key,b int, c int, d int, e int, f int, g int, h int, i int, j int, k int, l int, m int, n int, o int, p int, q int, r int, s int, t int, u int, v int, w int, x int, y int, z int, a1 int, a2 int, a3 int, a4 int, a5 int, a6 int, a7 int, a8 int, a9 int, b1 int, b2 int, b3 int, b4 int, b5 int, b6 int) type = innodb;
+create table t1 (a int primary key,b int, c int, d int, e int, f int, g int, h int, i int, j int, k int, l int, m int, n int, o int, p int, q int, r int, s int, t int, u int, v int, w int, x int, y int, z int, a1 int, a2 int, a3 int, a4 int, a5 int, a6 int, a7 int, a8 int, a9 int, b1 int, b2 int, b3 int, b4 int, b5 int, b6 int) engine = innodb;
insert into t1 values (1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1);
--replace_column 9 #
explain select * from t1 where a > 0 and a < 50;
@@ -480,7 +480,7 @@ drop table t1;
# Test lock tables
#
-create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) type=innodb;
+create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) engine=innodb;
insert into t1 values (0,0,0,'ABCDEFGHIJ'),(2,2,2,'BCDEFGHIJK'),(1,1,1,'CDEFGHIJKL');
LOCK TABLES t1 WRITE;
--error 1062
@@ -490,7 +490,7 @@ select id from t1;
UNLOCK TABLES;
DROP TABLE t1;
-create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) type=innodb;
+create table t1 (id int NOT NULL,id2 int NOT NULL,id3 int NOT NULL,dummy1 char(30),primary key (id,id2),index index_id3 (id3)) engine=innodb;
insert into t1 values (0,0,0,'ABCDEFGHIJ'),(2,2,2,'BCDEFGHIJK'),(1,1,1,'CDEFGHIJKL');
LOCK TABLES t1 WRITE;
begin;
@@ -506,9 +506,9 @@ DROP TABLE t1;
#
# Test prefix key
#
-create table t1 (a char(20), unique (a(5))) type=innodb;
+create table t1 (a char(20), unique (a(5))) engine=innodb;
drop table t1;
-create table t1 (a char(20), index (a(5))) type=innodb;
+create table t1 (a char(20), index (a(5))) engine=innodb;
show create table t1;
drop table t1;
@@ -516,7 +516,7 @@ drop table t1;
# Test using temporary table and auto_increment
#
-create temporary table t1 (a int not null auto_increment, primary key(a)) type=innodb;
+create temporary table t1 (a int not null auto_increment, primary key(a)) engine=innodb;
insert into t1 values (NULL),(NULL),(NULL);
delete from t1 where a=3;
insert into t1 values (NULL);
@@ -533,7 +533,7 @@ create table t1
value text not null,
uid int not null,
unique key(name,uid)
- ) type=innodb;
+ ) engine=innodb;
insert into t1 values (1,'one','one value',101),
(2,'two','two value',102),(3,'three','three value',103);
set insert_id=5;
@@ -551,11 +551,11 @@ drop table t1;
#
create database mysqltest;
-create table mysqltest.t1 (a int not null) type= innodb;
+create table mysqltest.t1 (a int not null) engine= innodb;
insert into mysqltest.t1 values(1);
-create table mysqltest.t2 (a int not null) type= myisam;
+create table mysqltest.t2 (a int not null) engine= myisam;
insert into mysqltest.t2 values(1);
-create table mysqltest.t3 (a int not null) type= heap;
+create table mysqltest.t3 (a int not null) engine= heap;
insert into mysqltest.t3 values(1);
commit;
drop database mysqltest;
@@ -568,7 +568,7 @@ show tables from mysqltest;
#
set autocommit=0;
-create table t1 (a int not null) type= innodb;
+create table t1 (a int not null) engine= innodb;
insert into t1 values(1),(2);
--error 1192
truncate table t1;
@@ -582,7 +582,7 @@ commit;
drop table t1;
set autocommit=1;
-create table t1 (a int not null) type= innodb;
+create table t1 (a int not null) engine= innodb;
insert into t1 values(1),(2);
truncate table t1;
insert into t1 values(1),(2);
@@ -597,7 +597,7 @@ drop table t1;
# Test of how ORDER BY works when doing it on the whole table
#
-create table t1 (a int not null, b int not null, c int not null, primary key (a),key(b)) type=innodb;
+create table t1 (a int not null, b int not null, c int not null, primary key (a),key(b)) engine=innodb;
insert into t1 values (3,3,3),(1,1,1),(2,2,2),(4,4,4);
--replace_column 9 #
explain select * from t1 order by a;
@@ -621,7 +621,7 @@ drop table t1;
# Check describe
#
-create table t1 (t int not null default 1, key (t)) type=innodb;
+create table t1 (t int not null default 1, key (t)) engine=innodb;
desc t1;
drop table t1;
@@ -641,7 +641,7 @@ CREATE TABLE t1 (
version smallint(6) NOT NULL default '0',
assigned_scps int(11) default '0',
status tinyint(4) default '0'
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t1 VALUES (4077711111,'SeanWheeler',90,2,20020111112846,500,00000000000000,-1,2,3,1);
INSERT INTO t1 VALUES (9197722223,'berry',90,3,20020111112809,500,20020102114532,501,4,10,0);
INSERT INTO t1 VALUES (650,'San Francisco',0,0,20011227111336,342,00000000000000,-1,1,24,1);
@@ -660,7 +660,7 @@ CREATE TABLE t2 (
version smallint(6) NOT NULL default '0',
assigned_scps int(11) default '0',
status tinyint(4) default '0'
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t2 VALUES (4077711111,'SeanWheeler',0,2,20020111112853,500,00000000000000,-1,2,3,1);
INSERT INTO t2 VALUES (9197722223,'berry',90,3,20020111112818,500,20020102114532,501,4,10,0);
INSERT INTO t2 VALUES (650,'San Francisco',90,0,20020109113158,342,00000000000000,-1,1,24,1);
@@ -679,7 +679,7 @@ drop table t1,t2;
# this works.
#
-create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) type=innodb;
+create table t1 (id int unsigned not null auto_increment, code tinyint unsigned not null, name char(20) not null, primary key (id), key (code), unique (name)) engine=innodb;
BEGIN;
SET SESSION TRANSACTION ISOLATION LEVEL SERIALIZABLE;
@@ -704,8 +704,8 @@ DROP TABLE t1;
#
# Test of multi-table-update
#
-create table t1 (n int(10), d int(10)) type=innodb;
-create table t2 (n int(10), d int(10)) type=innodb;
+create table t1 (n int(10), d int(10)) engine=innodb;
+create table t2 (n int(10), d int(10)) engine=innodb;
insert into t1 values(1,1),(1,2);
insert into t2 values(1,10),(2,20);
UPDATE t1,t2 SET t1.d=t2.d,t2.d=30 WHERE t1.n=t2.n;
@@ -716,7 +716,7 @@ drop table t1,t2;
#
# Testing of IFNULL
#
-create table t1 (a int, b int) type=innodb;
+create table t1 (a int, b int) engine=innodb;
insert into t1 values(20,null);
select t2.b, ifnull(t2.b,"this is null") from t1 as t2 left join t1 as t3 on
t2.b=t3.a;
@@ -731,12 +731,12 @@ drop table t1;
# Test of read_through not existing const_table
#
-create table t1 (a varchar(10) not null) type=myisam;
-create table t2 (b varchar(10) not null unique) type=innodb;
+create table t1 (a varchar(10) not null) engine=myisam;
+create table t2 (b varchar(10) not null unique) engine=innodb;
select t1.a from t1,t2 where t1.a=t2.b;
drop table t1,t2;
-create table t1 (a int not null, b int, primary key (a)) type = innodb;
-create table t2 (a int not null, b int, primary key (a)) type = innodb;
+create table t1 (a int not null, b int, primary key (a)) engine = innodb;
+create table t2 (a int not null, b int, primary key (a)) engine = innodb;
insert into t1 values (10, 20);
insert into t2 values (10, 20);
update t1, t2 set t1.b = 150, t2.b = t1.b where t2.a = t1.a and t1.a = 10;
@@ -746,8 +746,8 @@ drop table t1,t2;
# Test of multi-table-delete with foreign key constraints
#
-CREATE TABLE t1 (id INT NOT NULL, PRIMARY KEY (id)) TYPE=INNODB;
-CREATE TABLE t2 (id INT PRIMARY KEY, t1_id INT, INDEX par_ind (t1_id), FOREIGN KEY (t1_id) REFERENCES t1(id) ON DELETE CASCADE ) TYPE=INNODB;
+CREATE TABLE t1 (id INT NOT NULL, PRIMARY KEY (id)) ENGINE=INNODB;
+CREATE TABLE t2 (id INT PRIMARY KEY, t1_id INT, INDEX par_ind (t1_id), FOREIGN KEY (t1_id) REFERENCES t1(id) ON DELETE CASCADE ) ENGINE=INNODB;
insert into t1 set id=1;
insert into t2 set id=1, t1_id=1;
delete t1,t2 from t1,t2 where t1.id=t2.t1_id;
@@ -755,8 +755,8 @@ select * from t1;
select * from t2;
drop table t1,t2;
DROP TABLE IF EXISTS t1,t2;
-CREATE TABLE t1(id INT NOT NULL, PRIMARY KEY (id)) TYPE=INNODB;
-CREATE TABLE t2(id INT PRIMARY KEY, t1_id INT, INDEX par_ind (t1_id) ) TYPE=INNODB;
+CREATE TABLE t1(id INT NOT NULL, PRIMARY KEY (id)) ENGINE=INNODB;
+CREATE TABLE t2(id INT PRIMARY KEY, t1_id INT, INDEX par_ind (t1_id) ) ENGINE=INNODB;
INSERT INTO t1 VALUES(1);
INSERT INTO t2 VALUES(1, 1);
SELECT * from t1;
@@ -772,11 +772,11 @@ DROP TABLE t1,t2;
set autocommit=0;
-CREATE TABLE t1 (id CHAR(15) NOT NULL, value CHAR(40) NOT NULL, PRIMARY KEY(id)) TYPE=InnoDB;
+CREATE TABLE t1 (id CHAR(15) NOT NULL, value CHAR(40) NOT NULL, PRIMARY KEY(id)) ENGINE=InnoDB;
-CREATE TABLE t2 (id CHAR(15) NOT NULL, value CHAR(40) NOT NULL, PRIMARY KEY(id)) TYPE=InnoDB;
+CREATE TABLE t2 (id CHAR(15) NOT NULL, value CHAR(40) NOT NULL, PRIMARY KEY(id)) ENGINE=InnoDB;
-CREATE TABLE t3 (id1 CHAR(15) NOT NULL, id2 CHAR(15) NOT NULL, PRIMARY KEY(id1, id2)) TYPE=InnoDB;
+CREATE TABLE t3 (id1 CHAR(15) NOT NULL, id2 CHAR(15) NOT NULL, PRIMARY KEY(id1, id2)) ENGINE=InnoDB;
INSERT INTO t3 VALUES("my-test-1", "my-test-2");
COMMIT;
@@ -802,7 +802,7 @@ DROP TABLE t1,t2,t3;
# Check update with conflicting key
#
-CREATE TABLE t1 (a int not null primary key, b int not null, unique (b)) type=innodb;
+CREATE TABLE t1 (a int not null primary key, b int not null, unique (b)) engine=innodb;
INSERT INTO t1 values (1,1),(2,2),(3,3),(4,4),(5,5),(6,6),(7,7),(8,8),(9,9);
# We need the a < 1000 test here to quard against the halloween problems
UPDATE t1 set a=a+100 where b between 2 and 3 and a < 1000;
@@ -813,8 +813,8 @@ drop table t1;
# Test multi update with different join methods
#
-CREATE TABLE t1 (a int not null primary key, b int not null, key (b)) type=innodb;
-CREATE TABLE t2 (a int not null primary key, b int not null, key (b)) type=innodb;
+CREATE TABLE t1 (a int not null primary key, b int not null, key (b)) engine=innodb;
+CREATE TABLE t2 (a int not null primary key, b int not null, key (b)) engine=innodb;
INSERT INTO t1 values (1,1),(2,2),(3,3),(4,4),(5,5),(6,6),(7,7),(8,8),(9,9),(10,10),(11,11),(12,12);
INSERT INTO t2 values (1,1),(2,2),(3,3),(4,4),(5,5),(6,6),(7,7),(8,8),(9,9);
@@ -836,15 +836,15 @@ select * from t1;
select * from t2;
drop table t1,t2;
-CREATE TABLE t2 ( NEXT_T BIGINT NOT NULL PRIMARY KEY) TYPE=MyISAM;
-CREATE TABLE t1 ( B_ID INTEGER NOT NULL PRIMARY KEY) TYPE=InnoDB;
+CREATE TABLE t2 ( NEXT_T BIGINT NOT NULL PRIMARY KEY) ENGINE=MyISAM;
+CREATE TABLE t1 ( B_ID INTEGER NOT NULL PRIMARY KEY) ENGINE=InnoDB;
SET AUTOCOMMIT=0;
INSERT INTO t1 ( B_ID ) VALUES ( 1 );
INSERT INTO t2 ( NEXT_T ) VALUES ( 1 );
ROLLBACK;
SELECT * FROM t1;
drop table t1,t2;
-create table t1 ( pk int primary key, parent int not null, child int not null, index (parent) ) type = innodb;
+create table t1 ( pk int primary key, parent int not null, child int not null, index (parent) ) engine = innodb;
insert into t1 values (1,0,4), (2,1,3), (3,2,1), (4,1,2);
select distinct parent,child from t1 order by parent;
drop table t1;
@@ -852,7 +852,7 @@ drop table t1;
#
# Test that MySQL priorities clustered indexes
#
-create table t1 (a int not null auto_increment primary key, b int, c int, key(c)) type=innodb;
+create table t1 (a int not null auto_increment primary key, b int, c int, key(c)) engine=innodb;
create table t2 (a int not null auto_increment primary key, b int);
insert into t1 (b) values (null),(null),(null),(null),(null),(null),(null);
insert into t2 (a) select b from t1;
@@ -885,7 +885,7 @@ drop table t1,t2;
# Test of UPDATE ... ORDER BY
#
-create table t1 (id int primary key auto_increment, fk int, index index_fk (fk)) type=innodb;
+create table t1 (id int primary key auto_increment, fk int, index index_fk (fk)) engine=innodb;
insert into t1 (id) values (null),(null),(null),(null),(null);
update t1 set fk=69 where fk is null order by id limit 1;
@@ -903,9 +903,9 @@ select * from t1 order by a,b;
drop table t1;
-CREATE TABLE t1 (col1 int(1))TYPE=InnoDB;
+CREATE TABLE t1 (col1 int(1))ENGINE=InnoDB;
CREATE TABLE t2 (col1 int(1),stamp TIMESTAMP,INDEX stamp_idx
-(stamp))TYPE=InnoDB;
+(stamp))ENGINE=InnoDB;
insert into t1 values (1),(2),(3);
insert into t2 values (1, 20020204130000),(2, 20020204130000),(4,20020204310000 );
SELECT col1 FROM t1 UNION SELECT col1 FROM t2 WHERE stamp <
@@ -925,7 +925,7 @@ CREATE TABLE t1 (
PRIMARY KEY (`id`),
KEY `id_object` (`id_object`),
KEY `id_version` (`id_version`)
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t1 VALUES("6", "3382", "9", "Test", NULL), ("7", "102", "5", "Le Pekin (Test)", NULL),("584", "1794", "4", "Test de resto", NULL),("837", "1822", "6", "Test 3", NULL),("1119", "3524", "1", "Societe Test", NULL),("1122", "3525", "1", "Fournisseur Test", NULL);
@@ -934,7 +934,7 @@ CREATE TABLE t2 (
`id_version` int(10) unsigned NOT NULL default '1',
PRIMARY KEY (`id`),
KEY `id_version` (`id_version`)
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t2 VALUES("3524", "1"),("3525", "1"),("1794", "4"),("102", "5"),("1822", "6"),("3382", "9");
@@ -946,7 +946,7 @@ drop table t1,t2;
#
# Bug #1078
#
-create table t1 (c1 char(5) unique not null, c2 int, stamp timestamp) type=innodb;
+create table t1 (c1 char(5) unique not null, c2 int, stamp timestamp) engine=innodb;
select * from t1;
--error 1031
replace delayed into t1 (c1, c2) values ( "text1","11"),( "text2","12");
@@ -956,9 +956,9 @@ replace delayed into t1 (c1, c2) values ( "text1","12"),( "text2","13"),( "text
select * from t1;
drop table t1;
-create table t1 (a int, b varchar(200), c text not null) checksum=1 type=myisam;
-create table t2 (a int, b varchar(200), c text not null) checksum=0 type=innodb;
-create table t3 (a int, b varchar(200), c text not null) checksum=1 type=innodb;
+create table t1 (a int, b varchar(200), c text not null) checksum=1 engine=myisam;
+create table t2 (a int, b varchar(200), c text not null) checksum=0 engine=innodb;
+create table t3 (a int, b varchar(200), c text not null) checksum=1 engine=innodb;
insert t1 values (1, "aaa", "bbb"), (NULL, "", "ccccc"), (0, NULL, "");
insert t2 select * from t1;
insert t3 select * from t1;
diff --git a/mysql-test/t/innodb_cache.test b/mysql-test/t/innodb_cache.test
index 8a08c19703d..8568fce7d97 100644
--- a/mysql-test/t/innodb_cache.test
+++ b/mysql-test/t/innodb_cache.test
@@ -11,7 +11,7 @@ drop table if exists t1,t2,t3;
#
flush status;
set autocommit=0;
-create table t1 (a int not null) type=innodb;
+create table t1 (a int not null) engine=innodb;
insert into t1 values (1),(2),(3);
select * from t1;
show status like "Qcache_queries_in_cache";
@@ -19,15 +19,15 @@ drop table t1;
commit;
set autocommit=1;
begin;
-create table t1 (a int not null) type=innodb;
+create table t1 (a int not null) engine=innodb;
insert into t1 values (1),(2),(3);
select * from t1;
show status like "Qcache_queries_in_cache";
drop table t1;
commit;
-create table t1 (a int not null) type=innodb;
-create table t2 (a int not null) type=innodb;
-create table t3 (a int not null) type=innodb;
+create table t1 (a int not null) engine=innodb;
+create table t2 (a int not null) engine=innodb;
+create table t3 (a int not null) engine=innodb;
insert into t1 values (1),(2);
insert into t2 values (1),(2);
insert into t3 values (1),(2);
@@ -54,7 +54,7 @@ commit;
show status like "Qcache_queries_in_cache";
drop table if exists t1;
-CREATE TABLE t1 (id int(11) NOT NULL auto_increment, PRIMARY KEY (id)) TYPE=InnoDB;
+CREATE TABLE t1 (id int(11) NOT NULL auto_increment, PRIMARY KEY (id)) ENGINE=InnoDB;
select count(*) from t1;
insert into t1 (id) values (0);
select count(*) from t1;
diff --git a/mysql-test/t/innodb_handler.test b/mysql-test/t/innodb_handler.test
index cf6ac9870ce..e8c486caf66 100644
--- a/mysql-test/t/innodb_handler.test
+++ b/mysql-test/t/innodb_handler.test
@@ -8,7 +8,7 @@
drop table if exists t1,t2;
--enable_warnings
-create table t1 (a int, b char(10), key a(a), key b(a,b)) type=innodb;
+create table t1 (a int, b char(10), key a(a), key b(a,b)) engine=innodb;
insert into t1 values
(17,"ddd"),(18,"eee"),(19,"fff"),(19,"yyy"),
(14,"aaa"),(15,"bbb"),(16,"ccc"),(16,"xxx"),
@@ -71,12 +71,12 @@ handler t2 close;
handler t1 open as t2;
handler t2 read first;
-alter table t1 type=innodb;
+alter table t1 engine=innodb;
--error 1109
handler t2 read first;
drop table t1;
-CREATE TABLE t1 ( no1 smallint(5) NOT NULL default '0', no2 int(10) NOT NULL default '0', PRIMARY KEY (no1,no2)) TYPE=InnoDB;
+CREATE TABLE t1 ( no1 smallint(5) NOT NULL default '0', no2 int(10) NOT NULL default '0', PRIMARY KEY (no1,no2)) ENGINE=InnoDB;
INSERT INTO t1 VALUES (1,274),(1,275),(2,6),(2,8),(4,1),(4,2);
HANDLER t1 OPEN;
HANDLER t1 READ `primary` = (1, 1000);
diff --git a/mysql-test/t/insert_select.test b/mysql-test/t/insert_select.test
index 4effed9b6de..e39e470cf31 100644
--- a/mysql-test/t/insert_select.test
+++ b/mysql-test/t/insert_select.test
@@ -35,7 +35,7 @@ CREATE TABLE `t1` (
KEY `date` (`date`),
KEY `pseudo` (`pseudo`),
KEY `numreponse` (`numreponse`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE `t2` (
`numeropost` bigint(20) unsigned NOT NULL default '0',
@@ -51,7 +51,7 @@ CREATE TABLE `t2` (
KEY `date` (`date`),
KEY `pseudo` (`pseudo`),
KEY `numreponse` (`numreponse`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2
(numeropost,icone,numreponse,contenu,pseudo,date,ip,signature) VALUES
diff --git a/mysql-test/t/isam.test b/mysql-test/t/isam.test
index e35ed0dfd4a..f77d29fd20f 100644
--- a/mysql-test/t/isam.test
+++ b/mysql-test/t/isam.test
@@ -8,7 +8,7 @@ drop table if exists t1,t2;
# Test possible problem with rows that are about 65535 bytes long
#
-create table t1 (a tinyint not null auto_increment, b blob not null, primary key (a)) type=isam;
+create table t1 (a tinyint not null auto_increment, b blob not null, primary key (a)) engine=isam;
let $1=100;
disable_query_log;
@@ -28,7 +28,7 @@ drop table t1;
# Test of auto_increment; The test for BDB tables is in bdb.test
#
-create table t1 (a int not null auto_increment,b int, primary key (a)) type=isam;
+create table t1 (a int not null auto_increment,b int, primary key (a)) engine=isam;
insert into t1 values (1,1),(NULL,2),(3,3),(NULL,4);
delete from t1 where a=4 or a=2;
insert into t1 values (NULL,4),(NULL,5),(6,6);
@@ -46,13 +46,13 @@ drop table t1;
# Test of some CREATE TABLE's that should fail
#
--error 1121
-create table t1 (a int,b text, index(a)) type=isam;
+create table t1 (a int,b text, index(a)) engine=isam;
--error 1073
-create table t1 (a int,b text, index(b)) type=isam;
+create table t1 (a int,b text, index(b)) engine=isam;
--error 1075
-create table t1 (ordid int(8) not null auto_increment, ord varchar(50) not null, primary key (ord,ordid)) type=isam;
+create table t1 (ordid int(8) not null auto_increment, ord varchar(50) not null, primary key (ord,ordid)) engine=isam;
--error 1121
-create table t1 (ordid int(8), unique (ordid)) type=isam;
+create table t1 (ordid int(8), unique (ordid)) engine=isam;
drop table if exists t1;
#
@@ -61,7 +61,7 @@ drop table if exists t1;
create table t1 (a int not null primary key, b int not null,c int not null, key(b,c));
insert into t1 values (1,2,2),(2,2,3),(3,2,4),(4,2,4);
-create table t2 type=isam select * from t1;
+create table t2 engine=isam select * from t1;
optimize table t1;
check table t1,t2;
repair table t1,t2;
diff --git a/mysql-test/t/join.test b/mysql-test/t/join.test
index 8cef925cc24..bba5cdeee58 100644
--- a/mysql-test/t/join.test
+++ b/mysql-test/t/join.test
@@ -126,13 +126,13 @@ CREATE TABLE t1 (
a int(11) NOT NULL,
b int(11) NOT NULL,
PRIMARY KEY (a,b)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,1),(1,2),(1,3),(1,4),(1,5),(1,6),(1,7),(2,3);
CREATE TABLE t2 (
a int(11) default NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (2),(3);
SELECT t1.a,t2.a,b FROM t1,t2 WHERE t1.a=t2.a AND (t1.a=1 OR t1.a=2) AND b>=1 AND b<=3;
DROP TABLE t1, t2;
@@ -235,13 +235,13 @@ CREATE TABLE t1 (
max_value double default NULL,
t3_id int(11) default NULL,
item_id int(11) default NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (12,5,'Percent','Cost',-1,0,-1,-1),(14,4,'Percent','Cost',-1,0,-1,-1),(18,5,'Percent','Cost',-1,0,-1,-1),(19,4,'Percent','Cost',-1,0,-1,-1),(20,5,'Percent','Cost',100,-1,22,291),(21,5,'Percent','Cost',100,-1,18,291),(22,1,'Percent','Cost',100,-1,6,291),(23,1,'Percent','Cost',100,-1,21,291),(24,1,'Percent','Cost',100,-1,9,291),(25,1,'Percent','Cost',100,-1,4,291),(26,1,'Percent','Cost',100,-1,20,291),(27,4,'Percent','Cost',100,-1,7,202),(28,1,'Percent','Cost',50,-1,-1,137),(29,2,'Percent','Cost',100,-1,4,354),(30,2,'Percent','Cost',100,-1,9,137),(93,2,'Cost','Cost',-1,10000000,-1,-1);
CREATE TABLE t2 (
id int(10) unsigned NOT NULL auto_increment,
name varchar(255) default NULL,
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,'s1'),(2,'s2'),(3,'s3'),(4,'s4'),(5,'s5');
select t1.*, t2.* from t1, t2 where t2.id=t1.t2_id limit 2;
drop table t1,t2;
@@ -256,7 +256,7 @@ CREATE TABLE t1 (
rate_code varchar(10) default NULL,
UNIQUE KEY site_emp (siteid,emp_id),
KEY siteid (siteid)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('rivercats','psmith','cust'), ('rivercats','KWalker','cust');
CREATE TABLE t2 (
siteid varchar(25) NOT NULL default '',
@@ -264,7 +264,7 @@ CREATE TABLE t2 (
base_rate float NOT NULL default '0',
PRIMARY KEY (siteid,rate_code),
FULLTEXT KEY rate_code (rate_code)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES ('rivercats','cust',20);
SELECT emp.rate_code, lr.base_rate FROM t1 AS emp LEFT JOIN t2 AS lr USING (siteid, rate_code) WHERE emp.emp_id = 'psmith' AND lr.siteid = 'rivercats';
SELECT emp.rate_code, lr.base_rate FROM t1 AS emp LEFT JOIN t2 AS lr USING (siteid, rate_code) WHERE lr.siteid = 'rivercats' AND emp.emp_id = 'psmith';
diff --git a/mysql-test/t/join_crash.test b/mysql-test/t/join_crash.test
index ada6e56e664..2d2222ad67a 100644
--- a/mysql-test/t/join_crash.test
+++ b/mysql-test/t/join_crash.test
@@ -17,7 +17,7 @@ CREATE TABLE t1 (
comments mediumtext,
PRIMARY KEY (project_id),
UNIQUE KEY project (client_ptr,project_name)
-) TYPE=MyISAM PACK_KEYS=1;
+) ENGINE=MyISAM PACK_KEYS=1;
INSERT INTO t1 VALUES (1,0,'Rejected Time',1,NULL,NULL,NULL,NULL);
INSERT INTO t1 VALUES (209,0,'MDGRAD Proposal/Investigation',97,NULL,NULL,NULL,'');
@@ -40,7 +40,7 @@ CREATE TABLE t2 (
PRIMARY KEY (period_id),
KEY period_index (period_type,period_key),
KEY date_index (start_date,end_date)
-) TYPE=MyISAM PACK_KEYS=1;
+) ENGINE=MyISAM PACK_KEYS=1;
INSERT INTO t2 VALUES (1,'user_table',98,'2000-01-01 00:00:00',NULL,NULL);
INSERT INTO t2 VALUES (2,'user_table',99,'2000-01-01 00:00:00',NULL,NULL);
@@ -68,7 +68,7 @@ CREATE TABLE t3 (
adjustment float(10,2) default NULL,
PRIMARY KEY (budget_id),
UNIQUE KEY po (project_ptr,po_number)
-) TYPE=MyISAM PACK_KEYS=1;
+) ENGINE=MyISAM PACK_KEYS=1;
CREATE TABLE t4 (
client_id int(11) NOT NULL auto_increment,
@@ -78,7 +78,7 @@ CREATE TABLE t4 (
comments mediumtext,
PRIMARY KEY (client_id),
UNIQUE KEY client_name (client_name)
-) TYPE=MyISAM PACK_KEYS=1;
+) ENGINE=MyISAM PACK_KEYS=1;
INSERT INTO t4 VALUES (1,0,'CPS',NULL,NULL);
diff --git a/mysql-test/t/join_outer.test b/mysql-test/t/join_outer.test
index a63defff540..d048208a8ff 100644
--- a/mysql-test/t/join_outer.test
+++ b/mysql-test/t/join_outer.test
@@ -10,7 +10,7 @@ CREATE TABLE t1 (
grp int(11) default NULL,
a bigint(20) unsigned default NULL,
c char(10) NOT NULL default ''
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,1,'a'),(2,2,'b'),(2,3,'c'),(3,4,'E'),(3,5,'C'),(3,6,'D'),(NULL,NULL,'');
create table t2 (id int, a bigint unsigned not null, c char(10), d int, primary key (a));
insert into t2 values (1,1,"a",1),(3,4,"A",4),(3,5,"B",5),(3,6,"C",6),(4,7,"D",7);
diff --git a/mysql-test/t/key.test b/mysql-test/t/key.test
index 3b4cd7358cc..109cbb91e2f 100644
--- a/mysql-test/t/key.test
+++ b/mysql-test/t/key.test
@@ -158,7 +158,7 @@ CREATE TABLE t1 (
a tinytext NOT NULL,
b tinyint(3) unsigned NOT NULL default '0',
PRIMARY KEY (a(32),b)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('a',1),('a',2);
SELECT * FROM t1 WHERE a='a' AND b=2;
SELECT * FROM t1 WHERE a='a' AND b in (2);
diff --git a/mysql-test/t/lock.test b/mysql-test/t/lock.test
index 0868cf2c4b1..69c453bf60a 100644
--- a/mysql-test/t/lock.test
+++ b/mysql-test/t/lock.test
@@ -5,7 +5,7 @@
--disable_warnings
drop table if exists t1,t2;
--enable_warnings
-CREATE TABLE t1 ( `id` int(11) NOT NULL default '0', `id2` int(11) NOT NULL default '0', `id3` int(11) NOT NULL default '0', `dummy1` char(30) default NULL, PRIMARY KEY (`id`,`id2`), KEY `index_id3` (`id3`)) TYPE=MyISAM;
+CREATE TABLE t1 ( `id` int(11) NOT NULL default '0', `id2` int(11) NOT NULL default '0', `id3` int(11) NOT NULL default '0', `dummy1` char(30) default NULL, PRIMARY KEY (`id`,`id2`), KEY `index_id3` (`id3`)) ENGINE=MyISAM;
insert into t1 (id,id2) values (1,1),(1,2),(1,3);
LOCK TABLE t1 WRITE;
select dummy1,count(distinct id) from t1 group by dummy1;
@@ -33,12 +33,12 @@ CREATE TABLE t1 (
index1 smallint(6) default NULL,
nr smallint(6) default NULL,
KEY index1(index1)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE t2 (
nr smallint(6) default NULL,
name varchar(20) default NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,'item1');
INSERT INTO t2 VALUES (2,'item2');
diff --git a/mysql-test/t/lock_tables_lost_commit.test b/mysql-test/t/lock_tables_lost_commit.test
index d8301017801..22b666cbc86 100644
--- a/mysql-test/t/lock_tables_lost_commit.test
+++ b/mysql-test/t/lock_tables_lost_commit.test
@@ -6,7 +6,7 @@ connect (con2,localhost,root,,);
connection con1;
--disable_warnings
drop table if exists t1;
-create table t1(a int) type=innodb;
+create table t1(a int) engine=innodb;
--enable_warnings
lock tables t1 write;
insert into t1 values(10);
diff --git a/mysql-test/t/merge.test b/mysql-test/t/merge.test
index c3bffa4f2fb..1f61e200613 100644
--- a/mysql-test/t/merge.test
+++ b/mysql-test/t/merge.test
@@ -11,7 +11,7 @@ create table t1 (a int not null primary key auto_increment, message char(20));
create table t2 (a int not null primary key auto_increment, message char(20));
INSERT INTO t1 (message) VALUES ("Testing"),("table"),("t1");
INSERT INTO t2 (message) VALUES ("Testing"),("table"),("t2");
-create table t3 (a int not null, b char(20), key(a)) type=MERGE UNION=(t1,t2);
+create table t3 (a int not null, b char(20), key(a)) engine=MERGE UNION=(t1,t2);
select * from t3;
select * from t3 order by a desc;
drop table t3;
@@ -26,7 +26,7 @@ insert into t2 select NULL,message from t1;
insert into t1 select NULL,message from t2;
insert into t2 select NULL,message from t1;
insert into t1 select NULL,message from t2;
-create table t3 (a int not null, b char(20), key(a)) type=MERGE UNION=(test.t1,test.t2);
+create table t3 (a int not null, b char(20), key(a)) engine=MERGE UNION=(test.t1,test.t2);
explain select * from t3 where a < 10;
explain select * from t3 where a > 10 and a < 20;
select * from t3 where a = 10;
@@ -46,7 +46,7 @@ select * from t3 where a < 10;
show create table t3;
# The following should give errors
-create table t4 (a int not null, b char(10), key(a)) type=MERGE UNION=(t1,t2);
+create table t4 (a int not null, b char(10), key(a)) engine=MERGE UNION=(t1,t2);
--error 1016
select * from t4;
--error 1016
@@ -57,18 +57,18 @@ alter table t4 add column c int;
#
create database mysqltest;
create table mysqltest.t6 (a int not null primary key auto_increment, message char(20));
-create table t5 (a int not null, b char(20), key(a)) type=MERGE UNION=(test.t1,mysqltest.t6);
+create table t5 (a int not null, b char(20), key(a)) engine=MERGE UNION=(test.t1,mysqltest.t6);
show create table t5;
-alter table t5 type=myisam;
+alter table t5 engine=myisam;
drop table t5, mysqltest.t6;
drop database mysqltest;
# Because of windows, it's important that we drop the merge tables first!
drop table t4,t3,t1,t2;
-create table t1 (c char(10)) type=myisam;
-create table t2 (c char(10)) type=myisam;
-create table t3 (c char(10)) union=(t1,t2) type=merge;
+create table t1 (c char(10)) engine=myisam;
+create table t2 (c char(10)) engine=myisam;
+create table t3 (c char(10)) union=(t1,t2) engine=merge;
insert into t1 (c) values ('test1');
insert into t1 (c) values ('test1');
insert into t1 (c) values ('test1');
@@ -89,7 +89,7 @@ drop table t3,t2,t1;
CREATE TABLE t1 (incr int not null, othr int not null, primary key(incr));
CREATE TABLE t2 (incr int not null, othr int not null, primary key(incr));
CREATE TABLE t3 (incr int not null, othr int not null, primary key(incr))
-TYPE=MERGE UNION=(t1,t2);
+ENGINE=MERGE UNION=(t1,t2);
SELECT * from t3;
@@ -103,14 +103,14 @@ alter table t3 UNION=(t1);
select count(*) from t3;
alter table t3 UNION=(t1,t2);
select count(*) from t3;
-alter table t3 TYPE=MYISAM;
+alter table t3 ENGINE=MYISAM;
select count(*) from t3;
# Test that ALTER TABLE rembers the old UNION
drop table t3;
CREATE TABLE t3 (incr int not null, othr int not null, primary key(incr))
-TYPE=MERGE UNION=(t1,t2);
+ENGINE=MERGE UNION=(t1,t2);
show create table t3;
alter table t3 drop primary key;
show create table t3;
@@ -120,7 +120,7 @@ drop table t3,t2,t1;
#
# Test table without unions
#
-create table t1 (a int not null, key(a)) type=merge;
+create table t1 (a int not null, key(a)) engine=merge;
select * from t1;
drop table t1;
@@ -130,7 +130,7 @@ drop table t1;
create table t1 (a int not null, b int not null, key(a,b));
create table t2 (a int not null, b int not null, key(a,b));
-create table t3 (a int not null, b int not null, key(a,b)) TYPE=MERGE UNION=(t1,t2);
+create table t3 (a int not null, b int not null, key(a,b)) ENGINE=MERGE UNION=(t1,t2);
insert into t1 values (1,2),(2,1),(0,0),(4,4),(5,5),(6,6);
insert into t2 values (1,1),(2,2),(0,0),(4,4),(5,5),(6,6);
flush tables;
@@ -145,9 +145,9 @@ drop table t3,t1,t2;
create table t1 (a int not null, b int not null auto_increment, primary key(a,b));
create table t2 (a int not null, b int not null auto_increment, primary key(a,b));
create table t3 (a int not null, b int not null, key(a,b)) UNION=(t1,t2) INSERT_METHOD=NO;
-create table t4 (a int not null, b int not null, key(a,b)) TYPE=MERGE UNION=(t1,t2) INSERT_METHOD=NO;
-create table t5 (a int not null, b int not null auto_increment, primary key(a,b)) TYPE=MERGE UNION=(t1,t2) INSERT_METHOD=FIRST;
-create table t6 (a int not null, b int not null auto_increment, primary key(a,b)) TYPE=MERGE UNION=(t1,t2) INSERT_METHOD=LAST;
+create table t4 (a int not null, b int not null, key(a,b)) ENGINE=MERGE UNION=(t1,t2) INSERT_METHOD=NO;
+create table t5 (a int not null, b int not null auto_increment, primary key(a,b)) ENGINE=MERGE UNION=(t1,t2) INSERT_METHOD=FIRST;
+create table t6 (a int not null, b int not null auto_increment, primary key(a,b)) ENGINE=MERGE UNION=(t1,t2) INSERT_METHOD=LAST;
show create table t3;
show create table t4;
show create table t5;
@@ -192,11 +192,11 @@ insert into t1 values (99,NULL);
select * from t4 where a+0 > 90;
drop table t6, t5, t4, t3, t2, t1;
-CREATE TABLE t1 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', PRIMARY KEY (a,b)) TYPE=MyISAM;
+CREATE TABLE t1 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', PRIMARY KEY (a,b)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,1), (2,1);
-CREATE TABLE t2 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', PRIMARY KEY (a,b)) TYPE=MyISAM;
+CREATE TABLE t2 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', PRIMARY KEY (a,b)) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,2), (2,2);
-CREATE TABLE t3 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', KEY a (a,b)) TYPE=MRG_MyISAM UNION=(t1,t2);
+CREATE TABLE t3 ( a int(11) NOT NULL default '0', b int(11) NOT NULL default '0', KEY a (a,b)) ENGINE=MRG_MyISAM UNION=(t1,t2);
select max(b) from t3 where a = 2;
select max(b) from t1 where a = 2;
drop table t3,t1,t2;
@@ -208,13 +208,13 @@ create table t1 (a int not null);
create table t2 (a int not null);
insert into t1 values (1);
insert into t2 values (2);
-create temporary table t3 (a int not null) TYPE=MERGE UNION=(t1,t2);
+create temporary table t3 (a int not null) ENGINE=MERGE UNION=(t1,t2);
select * from t3;
create temporary table t4 (a int not null);
create temporary table t5 (a int not null);
insert into t4 values (1);
insert into t5 values (2);
-create temporary table t6 (a int not null) TYPE=MERGE UNION=(t4,t5);
+create temporary table t6 (a int not null) ENGINE=MERGE UNION=(t4,t5);
select * from t6;
drop table t6, t3, t1, t2, t4, t5;
@@ -228,7 +228,7 @@ CREATE TABLE t1 (
fileset_root_id tinyint(3) unsigned NOT NULL default '0',
PRIMARY KEY (fileset_id,file_code),
KEY files (fileset_id,fileset_root_id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (2, '0000000111', 1), (2, '0000000112', 1), (2, '0000000113', 1),
(2, '0000000114', 1), (2, '0000000115', 1), (2, '0000000116', 1), (2, '0000000117', 1),
(2, '0000000118', 1), (2, '0000000119', 1), (2, '0000000120', 1);
@@ -238,7 +238,7 @@ CREATE TABLE t2 (
fileset_root_id tinyint(3) unsigned NOT NULL default '0',
PRIMARY KEY (fileset_id,file_code),
KEY files (fileset_id,fileset_root_id)
-) TYPE=MRG_MyISAM UNION=(t1);
+) ENGINE=MRG_MyISAM UNION=(t1);
EXPLAIN SELECT * FROM t2 IGNORE INDEX (files) WHERE fileset_id = 2
AND file_code BETWEEN '0000000115' AND '0000000120' LIMIT 1;
@@ -256,7 +256,7 @@ DROP TABLE t2, t1;
create table t1 (x int, y int, index xy(x, y));
create table t2 (x int, y int, index xy(x, y));
-create table t3 (x int, y int, index xy(x, y)) type=merge union=(t1,t2);
+create table t3 (x int, y int, index xy(x, y)) engine=merge union=(t1,t2);
insert into t1 values(1, 2);
insert into t2 values(1, 3);
select * from t3 where x = 1 and y < 5 order by y;
diff --git a/mysql-test/t/mix_innodb_myisam_binlog.test b/mysql-test/t/mix_innodb_myisam_binlog.test
index 26f7cbf22a0..9c576b080ca 100644
--- a/mysql-test/t/mix_innodb_myisam_binlog.test
+++ b/mysql-test/t/mix_innodb_myisam_binlog.test
@@ -15,8 +15,8 @@ connect (con1,localhost,root,,);
connect (con2,localhost,root,,);
connection con1;
-create table t1 (a int) type=innodb;
-create table t2 (a int) type=myisam;
+create table t1 (a int) engine=innodb;
+create table t2 (a int) engine=myisam;
reset master;
@@ -118,7 +118,7 @@ show binlog events from 79;
# Check that things work like before this BEGIN/ROLLBACK code was added,
# when t2 is INNODB
-alter table t2 type=INNODB;
+alter table t2 engine=INNODB;
delete from t1;
delete from t2;
diff --git a/mysql-test/t/multi_update.test b/mysql-test/t/multi_update.test
index b3c742e0b30..115007d9e63 100644
--- a/mysql-test/t/multi_update.test
+++ b/mysql-test/t/multi_update.test
@@ -85,19 +85,19 @@ CREATE TABLE t1 (
id int(11) NOT NULL default '0',
name varchar(10) default NULL,
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,'aaa'),(2,'aaa'),(3,'aaa');
CREATE TABLE t2 (
id int(11) NOT NULL default '0',
name varchar(10) default NULL,
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (2,'bbb'),(3,'bbb'),(4,'bbb');
CREATE TABLE t3 (
id int(11) NOT NULL default '0',
mydate datetime default NULL,
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t3 VALUES (1,'2002-02-04 00:00:00'),(3,'2002-05-12 00:00:00'),(5,'2002-05-12 00:00:00'),(6,'2002-06-22
00:00:00'),(7,'2002-07-22 00:00:00');
delete t1,t2,t3 from t1,t2,t3 where to_days(now())-to_days(t3.mydate)>=30 and t3.id=t1.id and t3.id=t2.id;
@@ -109,7 +109,7 @@ CREATE TABLE IF NOT EXISTS `t1` (
`tst` text,
`tst1` text,
PRIMARY KEY (`id`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE IF NOT EXISTS `t2` (
`ID` int(11) NOT NULL auto_increment,
@@ -119,7 +119,7 @@ CREATE TABLE IF NOT EXISTS `t2` (
PRIMARY KEY (`ID`),
KEY `IX_ParId_t2` (`ParId`),
FOREIGN KEY (`ParId`) REFERENCES `t1` (`id`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1(tst,tst1) VALUES("MySQL","MySQL AB"), ("MSSQL","Microsoft"), ("ORACLE","ORACLE");
@@ -223,11 +223,11 @@ select * from t1;
select * from t2;
drop table t1,t2;
-CREATE TABLE t1 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) TYPE=MyISAM;
+CREATE TABLE t1 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,'jedan'),(2,'dva'),(3,'tri'),(4,'xxxxxxxxxx'),(5,'a'),(10,''),(11,''),(12,''),(13,'');
-CREATE TABLE t2 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) TYPE=MyISAM;
+CREATE TABLE t2 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,'jedan'),(2,'dva'),(3,'tri'),(4,'xxxxxxxxxx'),(5,'a');
-CREATE TABLE t3 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) TYPE=MyISAM;
+CREATE TABLE t3 ( broj int(4) unsigned NOT NULL default '0', naziv char(25) NOT NULL default 'NEPOZNAT', PRIMARY KEY (broj)) ENGINE=MyISAM;
INSERT INTO t3 VALUES (1,'jedan'),(2,'dva');
update t1,t2 set t1.naziv="aaaa" where t1.broj=t2.broj;
update t1,t2,t3 set t1.naziv="bbbb", t2.naziv="aaaa" where t1.broj=t2.broj and t2.broj=t3.broj;
@@ -260,7 +260,7 @@ select * from t1;
select * from t2;
drop table t1,t2;
-CREATE TABLE t3 ( KEY1 varchar(50) NOT NULL default '', PARAM_CORR_DISTANCE_RUSH double default NULL, PARAM_CORR_DISTANCE_GEM double default NULL, PARAM_AVG_TARE double default NULL, PARAM_AVG_NB_DAYS double default NULL, PARAM_DEFAULT_PROP_GEM_SRVC varchar(50) default NULL, PARAM_DEFAULT_PROP_GEM_NO_ETIK varchar(50) default NULL, PARAM_SCENARIO_COSTS varchar(50) default NULL, PARAM_DEFAULT_WAGON_COST double default NULL, tmp int(11) default NULL, PRIMARY KEY (KEY1)) TYPE=MyISAM;
+CREATE TABLE t3 ( KEY1 varchar(50) NOT NULL default '', PARAM_CORR_DISTANCE_RUSH double default NULL, PARAM_CORR_DISTANCE_GEM double default NULL, PARAM_AVG_TARE double default NULL, PARAM_AVG_NB_DAYS double default NULL, PARAM_DEFAULT_PROP_GEM_SRVC varchar(50) default NULL, PARAM_DEFAULT_PROP_GEM_NO_ETIK varchar(50) default NULL, PARAM_SCENARIO_COSTS varchar(50) default NULL, PARAM_DEFAULT_WAGON_COST double default NULL, tmp int(11) default NULL, PRIMARY KEY (KEY1)) ENGINE=MyISAM;
INSERT INTO t3 VALUES ('A',1,1,22,3.2,'R','R','BASE2',0.24,NULL);
create table t1 (A varchar(1));
insert into t1 values ("A") ,("B"),("C"),("D");
diff --git a/mysql-test/t/myisam.test b/mysql-test/t/myisam.test
index 5dceb2b4598..85e5c7a7751 100644
--- a/mysql-test/t/myisam.test
+++ b/mysql-test/t/myisam.test
@@ -15,7 +15,7 @@ SET SQL_WARNINGS=1;
CREATE TABLE t1 (
STRING_DATA char(255) default NULL,
KEY string_data (STRING_DATA)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA');
INSERT INTO t1 VALUES ('DDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDDD');
@@ -68,7 +68,7 @@ drop table t1;
# Test of how ORDER BY works when doing it on the whole table
#
-create table t1 (a int not null, b int not null, c int not null, primary key (a),key(b)) type=myisam;
+create table t1 (a int not null, b int not null, c int not null, primary key (a),key(b)) engine=myisam;
insert into t1 values (3,3,3),(1,1,1),(2,2,2),(4,4,4);
explain select * from t1 order by a;
explain select * from t1 order by b;
@@ -324,7 +324,7 @@ CREATE TABLE `t1` (
KEY `poster_login` (`poster_login`),
KEY `topic_id` (`topic_id`),
FULLTEXT KEY `post_text` (`post_text`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (post_text) VALUES ('ceci est un test'),('ceci est un test'),('ceci est un test'),('ceci est un test'),('ceci est un test');
@@ -402,7 +402,7 @@ drop table t1;
# Test RTREE index
#
--error 1235
-CREATE TABLE t1 (`a` int(11) NOT NULL default '0', `b` int(11) NOT NULL default '0', UNIQUE KEY `a` USING RTREE (`a`,`b`)) TYPE=MyISAM;
+CREATE TABLE t1 (`a` int(11) NOT NULL default '0', `b` int(11) NOT NULL default '0', UNIQUE KEY `a` USING RTREE (`a`,`b`)) ENGINE=MyISAM;
# INSERT INTO t1 VALUES (1,1),(1,1);
# DELETE FROM rt WHERE a<1;
# DROP TABLE IF EXISTS t1;
diff --git a/mysql-test/t/null.test b/mysql-test/t/null.test
index 5fa8f8a7651..c11ed78253b 100644
--- a/mysql-test/t/null.test
+++ b/mysql-test/t/null.test
@@ -45,7 +45,7 @@ DROP TABLE t1;
#
# Testing of IFNULL
#
-create table t1 (a int, b int) type=myisam;
+create table t1 (a int, b int) engine=myisam;
insert into t1 values(20,null);
select t2.b, ifnull(t2.b,"this is null") from t1 as t2 left join t1 as t3 on
t2.b=t3.a;
diff --git a/mysql-test/t/null_key.test b/mysql-test/t/null_key.test
index 7d9500e90dd..9b346a181bf 100644
--- a/mysql-test/t/null_key.test
+++ b/mysql-test/t/null_key.test
@@ -5,7 +5,7 @@
drop table if exists t1,t2;
--enable_warnings
-create table t1 (a int, b int not null,unique key (a,b),index(b)) type=myisam;
+create table t1 (a int, b int not null,unique key (a,b),index(b)) engine=myisam;
insert ignore into t1 values (1,1),(2,2),(3,3),(4,4),(5,5),(6,6),(null,7),(9,9),(8,8),(7,7),(null,9),(null,9),(6,6);
explain select * from t1 where a is null;
explain select * from t1 where a is null and b = 2;
@@ -92,13 +92,13 @@ CREATE TABLE t1 (
uniq_id int(10) unsigned default NULL,
PRIMARY KEY (id),
UNIQUE KEY idx1 (uniq_id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE t2 (
id int(10) unsigned NOT NULL auto_increment,
uniq_id int(10) unsigned default NULL,
PRIMARY KEY (id)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (1,NULL),(2,NULL),(3,1),(4,2),(5,NULL),(6,NULL),(7,3),(8,4),(9,NULL),(10,NULL);
INSERT INTO t2 VALUES (1,NULL),(2,NULL),(3,1),(4,2),(5,NULL),(6,NULL),(7,3),(8,4),(9,NULL),(10,NULL);
@@ -136,13 +136,13 @@ CREATE TABLE `t1` (
`product_id` char(32) NOT NULL default '',
`product_type` int(11) NOT NULL default '0',
PRIMARY KEY (`order_id`,`product_id`,`product_type`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
CREATE TABLE `t2` (
`order_id` char(32) NOT NULL default '',
`product_id` char(32) NOT NULL default '',
`product_type` int(11) NOT NULL default '0',
PRIMARY KEY (`order_id`,`product_id`,`product_type`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (order_id, product_id, product_type) VALUES
('3d7ce39b5d4b3e3d22aaafe9b633de51',1206029, 3),
('3d7ce39b5d4b3e3d22aaafe9b633de51',5880836, 3),
diff --git a/mysql-test/t/order_by.test b/mysql-test/t/order_by.test
index ca4143fa1c9..bb72c5278f9 100644
--- a/mysql-test/t/order_by.test
+++ b/mysql-test/t/order_by.test
@@ -199,7 +199,7 @@ CREATE TABLE t1 (
info text NOT NULL,
ipnr varchar(30) NOT NULL default '',
PRIMARY KEY (member_id)
-) TYPE=MyISAM PACK_KEYS=1;
+) ENGINE=MyISAM PACK_KEYS=1;
insert into t1 (member_id) values (1),(2),(3);
select member_id, nickname, voornaam FROM t1
@@ -261,7 +261,7 @@ CREATE TABLE t1 (
cid smallint(5) unsigned NOT NULL default '0',
PRIMARY KEY (gid),
KEY component_id (cid)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (103853,108),(103867,108),(103962,108),(104505,108),(104619,108),(104620,108);
ALTER TABLE t1 add skr int(10) not null;
@@ -272,13 +272,13 @@ CREATE TABLE t2 (
PRIMARY KEY (gid),
KEY uid (uid),
KEY status_id (sid)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES (103853,250,5),(103867,27,5),(103962,27,5),(104505,117,5),(104619,75,5),(104620,15,5);
CREATE TABLE t3 (
uid smallint(6) NOT NULL auto_increment,
PRIMARY KEY (uid)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t3 VALUES (1),(15),(27),(75),(117),(250);
ALTER TABLE t3 add skr int(10) not null;
diff --git a/mysql-test/t/outfile.test b/mysql-test/t/outfile.test
index a944df01051..a7b81d565e6 100644
--- a/mysql-test/t/outfile.test
+++ b/mysql-test/t/outfile.test
@@ -22,7 +22,7 @@
#select load_file("/tmp/select-test.not-exist");
#drop table t1;
#drop table if exists t;
-#CREATE TABLE t ( t timestamp NOT NULL, c char(200) character set latin1 NOT NULL default '', i int(11), v varchar(200), b blob, KEY t (t)) TYPE=MyISAM;
+#CREATE TABLE t ( t timestamp NOT NULL, c char(200) character set latin1 NOT NULL default '', i int(11), v varchar(200), b blob, KEY t (t)) ENGINE=MyISAM;
#INSERT INTO t VALUES ('2002-12-20 12:01:20','',1,"aaa","bbb");
#select * from t into outfile "check";
#drop table if exists t;
diff --git a/mysql-test/t/query_cache.test b/mysql-test/t/query_cache.test
index 14cbf4c906d..c93d616b379 100644
--- a/mysql-test/t/query_cache.test
+++ b/mysql-test/t/query_cache.test
@@ -45,7 +45,7 @@ create table t1 (a int not null);
insert into t1 values (1),(2),(3);
create table t2 (a int not null);
insert into t2 values (4),(5),(6);
-create table t3 (a int not null) type=MERGE UNION=(t1,t2) INSERT_METHOD=FIRST;
+create table t3 (a int not null) engine=MERGE UNION=(t1,t2) INSERT_METHOD=FIRST;
# insert
select * from t3;
select * from t3;
diff --git a/mysql-test/t/query_cache_merge.test b/mysql-test/t/query_cache_merge.test
index 02e316932a3..fef3f18df60 100644
--- a/mysql-test/t/query_cache_merge.test
+++ b/mysql-test/t/query_cache_merge.test
@@ -25,7 +25,7 @@ while ($1)
}
--enable_warnings
-create table t00 (a int) type=MERGE UNION=(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) INSERT_METHOD=FIRST;
+create table t00 (a int) engine=MERGE UNION=(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) INSERT_METHOD=FIRST;
enable_query_log;
select count(*) from t00;
select count(*) from t00;
diff --git a/mysql-test/t/range.test b/mysql-test/t/range.test
index b1b846221e7..f01d8d4eacf 100644
--- a/mysql-test/t/range.test
+++ b/mysql-test/t/range.test
@@ -128,7 +128,7 @@ CREATE TABLE t1 (
KEY IdxArt (art),
KEY IdxKnr (KNR),
KEY IdxArtnr (ARTNR)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (art) VALUES ('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),
('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),('j'),('J'),
@@ -214,7 +214,7 @@ CREATE TABLE t1 (
b int(11) default NULL,
KEY a (a),
KEY b (b)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES
diff --git a/mysql-test/t/repair_part1.test b/mysql-test/t/repair_part1.test
index 2657f91cd02..e82edb64713 100644
--- a/mysql-test/t/repair_part1.test
+++ b/mysql-test/t/repair_part1.test
@@ -8,7 +8,7 @@ drop table if exists t1;
create table t1 SELECT 1,"table 1";
repair table t1 use_frm;
-alter table t1 TYPE=HEAP;
+alter table t1 ENGINE=HEAP;
repair table t1 use_frm;
drop table t1;
@@ -19,4 +19,4 @@ repair table t1 use_frm;
# Create test table for repair2
# The following must be last in this file
-create table t1 type=myisam SELECT 1,"table 1";
+create table t1 engine=myisam SELECT 1,"table 1";
diff --git a/mysql-test/t/replace.test b/mysql-test/t/replace.test
index 2afce2fcc84..8429d80a4ef 100644
--- a/mysql-test/t/replace.test
+++ b/mysql-test/t/replace.test
@@ -12,14 +12,14 @@ CREATE TABLE t1 (
gesuchnr int(11) DEFAULT '0' NOT NULL,
benutzer_id int(11) DEFAULT '0' NOT NULL,
PRIMARY KEY (gesuchnr,benutzer_id)
-) type=ISAM;
+) engine=ISAM;
replace into t1 (gesuchnr,benutzer_id) values (2,1);
replace into t1 (gesuchnr,benutzer_id) values (1,1);
replace into t1 (gesuchnr,benutzer_id) values (1,1);
-alter table t1 type=myisam;
+alter table t1 engine=myisam;
replace into t1 (gesuchnr,benutzer_id) values (1,1);
-alter table t1 type=heap;
+alter table t1 engine=heap;
replace into t1 (gesuchnr,benutzer_id) values (1,1);
drop table t1;
diff --git a/mysql-test/t/rollback.test b/mysql-test/t/rollback.test
index 1673f1648d3..87f59417d90 100644
--- a/mysql-test/t/rollback.test
+++ b/mysql-test/t/rollback.test
@@ -6,7 +6,7 @@
drop table if exists t1;
--enable_warnings
-create table t1 (n int not null primary key) type=myisam;
+create table t1 (n int not null primary key) engine=myisam;
begin work;
insert into t1 values (4);
insert into t1 values (5);
diff --git a/mysql-test/t/rpl000006.test b/mysql-test/t/rpl000006.test
index c6438062bb7..898ef309f50 100644
--- a/mysql-test/t/rpl000006.test
+++ b/mysql-test/t/rpl000006.test
@@ -30,7 +30,7 @@ set SQL_LOG_BIN=0;
CREATE TABLE t1 (
a int not null
-) TYPE=MyISAM MAX_ROWS=4000 CHECKSUM=1;
+) ENGINE=MyISAM MAX_ROWS=4000 CHECKSUM=1;
INSERT INTO t1 VALUES (1);
save_master_pos;
connection slave;
diff --git a/mysql-test/t/rpl_flush_tables.test b/mysql-test/t/rpl_flush_tables.test
index 67720343e83..b98235fbed8 100644
--- a/mysql-test/t/rpl_flush_tables.test
+++ b/mysql-test/t/rpl_flush_tables.test
@@ -8,7 +8,7 @@ source include/master-slave.inc;
create table t1 (a int);
insert into t1 values (10);
create table t2 (a int);
-create table t3 (a int) type=merge union(t1);
+create table t3 (a int) engine=merge union(t1);
create table t4 (a int);
# We force the slave to open t3 (because we want to try confusing him) with this :
insert into t4 select * from t3;
diff --git a/mysql-test/t/rpl_insert_id.test b/mysql-test/t/rpl_insert_id.test
index b2b92dec7aa..8244c323a0d 100644
--- a/mysql-test/t/rpl_insert_id.test
+++ b/mysql-test/t/rpl_insert_id.test
@@ -23,8 +23,8 @@ connection master;
drop table t1;
drop table t2;
--disable_warnings
-create table t1(a int auto_increment, key(a)) type=innodb;
-create table t2(b int auto_increment, c int, key(b), foreign key(b) references t1(a)) type=innodb;
+create table t1(a int auto_increment, key(a)) engine=innodb;
+create table t2(b int auto_increment, c int, key(b), foreign key(b) references t1(a)) engine=innodb;
--enable_warnings
SET FOREIGN_KEY_CHECKS=0;
insert into t1 values (10);
diff --git a/mysql-test/t/rpl_relayrotate.test b/mysql-test/t/rpl_relayrotate.test
index 7a572740b3a..0e198d23517 100644
--- a/mysql-test/t/rpl_relayrotate.test
+++ b/mysql-test/t/rpl_relayrotate.test
@@ -15,7 +15,7 @@ connection slave;
stop slave;
connection master;
--disable_warnings
-create table t1 (a int) type=innodb;
+create table t1 (a int) engine=innodb;
--enable_warnings
let $1=8000;
disable_query_log;
diff --git a/mysql-test/t/select.test b/mysql-test/t/select.test
index b817544bfb9..446c8768146 100644
--- a/mysql-test/t/select.test
+++ b/mysql-test/t/select.test
@@ -1381,7 +1381,7 @@ INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1009,"gems",447,2374
INSERT INTO t3 (period,name,companynr,price,price2) VALUES (1010,"clinker",512,786542,76234234);
--enable_query_log
-create temporary table tmp type = myisam select * from t3;
+create temporary table tmp engine = myisam select * from t3;
insert into t3 select * from tmp;
insert into tmp select * from t3;
@@ -1498,7 +1498,7 @@ create table t4 (
companyname char(30) NOT NULL default '',
PRIMARY KEY (companynr),
UNIQUE KEY companyname(companyname)
-) TYPE=MyISAM MAX_ROWS=50 PACK_KEYS=1 COMMENT='companynames';
+) ENGINE=MyISAM MAX_ROWS=50 PACK_KEYS=1 COMMENT='companynames';
--disable_query_log
INSERT INTO t4 (companynr, companyname) VALUES (29,'company 1');
@@ -1767,9 +1767,9 @@ DROP TABLE t1;
# Test of bug with SUM(CASE...)
#
-CREATE TABLE t1 (gvid int(10) unsigned default NULL, hmid int(10) unsigned default NULL, volid int(10) unsigned default NULL, mmid int(10) unsigned default NULL, hdid int(10) unsigned default NULL, fsid int(10) unsigned default NULL, ctid int(10) unsigned default NULL, dtid int(10) unsigned default NULL, cost int(10) unsigned default NULL, performance int(10) unsigned default NULL, serialnumber bigint(20) unsigned default NULL, monitored tinyint(3) unsigned default '1', removed tinyint(3) unsigned default '0', target tinyint(3) unsigned default '0', dt_modified timestamp(14) NOT NULL, name varchar(255) binary default NULL, description varchar(255) default NULL, UNIQUE KEY hmid (hmid,volid)) TYPE=MyISAM;
+CREATE TABLE t1 (gvid int(10) unsigned default NULL, hmid int(10) unsigned default NULL, volid int(10) unsigned default NULL, mmid int(10) unsigned default NULL, hdid int(10) unsigned default NULL, fsid int(10) unsigned default NULL, ctid int(10) unsigned default NULL, dtid int(10) unsigned default NULL, cost int(10) unsigned default NULL, performance int(10) unsigned default NULL, serialnumber bigint(20) unsigned default NULL, monitored tinyint(3) unsigned default '1', removed tinyint(3) unsigned default '0', target tinyint(3) unsigned default '0', dt_modified timestamp(14) NOT NULL, name varchar(255) binary default NULL, description varchar(255) default NULL, UNIQUE KEY hmid (hmid,volid)) ENGINE=MyISAM;
INSERT INTO t1 VALUES (200001,2,1,1,100,1,1,1,0,0,0,1,0,1,20020425060057,'\\\\ARKIVIO-TESTPDC\\E$',''),(200002,2,2,1,101,1,1,1,0,0,0,1,0,1,20020425060057,'\\\\ARKIVIO-TESTPDC\\C$',''),(200003,1,3,2,NULL,NULL,NULL,NULL,NULL,NULL,NULL,1,0,1,20020425060427,'c:',NULL);
-CREATE TABLE t2 ( hmid int(10) unsigned default NULL, volid int(10) unsigned default NULL, sampletid smallint(5) unsigned default NULL, sampletime datetime default NULL, samplevalue bigint(20) unsigned default NULL, KEY idx1 (hmid,volid,sampletid,sampletime)) TYPE=MyISAM;
+CREATE TABLE t2 ( hmid int(10) unsigned default NULL, volid int(10) unsigned default NULL, sampletid smallint(5) unsigned default NULL, sampletime datetime default NULL, samplevalue bigint(20) unsigned default NULL, KEY idx1 (hmid,volid,sampletid,sampletime)) ENGINE=MyISAM;
INSERT INTO t2 VALUES (1,3,10,'2002-06-01 08:00:00',35),(1,3,1010,'2002-06-01 12:00:01',35);
SELECT a.gvid, (SUM(CASE b.sampletid WHEN 140 THEN b.samplevalue ELSE 0 END)) as the_success,(SUM(CASE b.sampletid WHEN 141 THEN b.samplevalue ELSE 0 END)) as the_fail,(SUM(CASE b.sampletid WHEN 142 THEN b.samplevalue ELSE 0 END)) as the_size,(SUM(CASE b.sampletid WHEN 143 THEN b.samplevalue ELSE 0 END)) as the_time FROM t1 a, t2 b WHERE a.hmid = b.hmid AND a.volid = b.volid AND b.sampletime >= 'NULL' AND b.sampletime < 'NULL' AND b.sampletid IN (140, 141, 142, 143) GROUP BY a.gvid;
DROP TABLE t1,t2;
@@ -1836,9 +1836,9 @@ select * from t1 natural join (t1 as t2 left join t1 as t3 using (a));
select * from (t1 as t2 left join t1 as t3 using (a)) natural join t1;
drop table t1;
-CREATE TABLE t1 ( aa char(2), id int(11) NOT NULL auto_increment, t2_id int(11) NOT NULL default '0', PRIMARY KEY (id), KEY replace_id (t2_id)) TYPE=MyISAM;
+CREATE TABLE t1 ( aa char(2), id int(11) NOT NULL auto_increment, t2_id int(11) NOT NULL default '0', PRIMARY KEY (id), KEY replace_id (t2_id)) ENGINE=MyISAM;
INSERT INTO t1 VALUES ("1",8264,2506),("2",8299,2517),("3",8301,2518),("4",8302,2519),("5",8303,2520),("6",8304,2521),("7",8305,2522);
-CREATE TABLE t2 ( id int(11) NOT NULL auto_increment, PRIMARY KEY (id)) TYPE=MyISAM;
+CREATE TABLE t2 ( id int(11) NOT NULL auto_increment, PRIMARY KEY (id)) ENGINE=MyISAM;
INSERT INTO t2 VALUES (2517), (2518), (2519), (2520), (2521), (2522);
select * from t1, t2 WHERE t1.t2_id = t2.id and t1.t2_id > 0 order by t1.id LIMIT 0, 5;
drop table t1,t2;
diff --git a/mysql-test/t/select_found.test b/mysql-test/t/select_found.test
index e8be902606c..f787cec6533 100644
--- a/mysql-test/t/select_found.test
+++ b/mysql-test/t/select_found.test
@@ -81,7 +81,7 @@ CREATE TABLE `t1` (
`maxnumrep` int(10) unsigned NOT NULL default '0',
PRIMARY KEY (`numeropost`),
KEY `maxnumrep` (`maxnumrep`)
-) TYPE=MyISAM ROW_FORMAT=FIXED;
+) ENGINE=MyISAM ROW_FORMAT=FIXED;
INSERT INTO t1 (titre,maxnumrep) VALUES
('test1','1'),('test2','2'),('test3','3');
SELECT SQL_CALC_FOUND_ROWS titre,numeropost,maxnumrep FROM t1 WHERE numeropost IN (1,2) ORDER BY maxnumrep DESC LIMIT 0, 1;
diff --git a/mysql-test/t/show_check.test b/mysql-test/t/show_check.test
index 633826186be..4ab39e3ccbc 100644
--- a/mysql-test/t/show_check.test
+++ b/mysql-test/t/show_check.test
@@ -73,7 +73,7 @@ insert into t1 values (1);
show open tables;
drop table t1;
-create table t1 (a int not null, b VARCHAR(10), INDEX (b) ) AVG_ROW_LENGTH=10 CHECKSUM=1 COMMENT="test" TYPE=MYISAM MIN_ROWS=10 MAX_ROWS=100 PACK_KEYS=1 DELAY_KEY_WRITE=1 ROW_FORMAT=fixed;
+create table t1 (a int not null, b VARCHAR(10), INDEX (b) ) AVG_ROW_LENGTH=10 CHECKSUM=1 COMMENT="test" ENGINE=MYISAM MIN_ROWS=10 MAX_ROWS=100 PACK_KEYS=1 DELAY_KEY_WRITE=1 ROW_FORMAT=fixed;
show create table t1;
alter table t1 MAX_ROWS=200 ROW_FORMAT=dynamic PACK_KEYS=0;
show create table t1;
@@ -112,7 +112,7 @@ type_blob blob,
type_medium_blob mediumblob,
type_long_blob longblob,
index(type_short)
-) AVG_ROW_LENGTH=10 CHECKSUM=1 COMMENT="test" TYPE=MYISAM MIN_ROWS=10 MAX_ROWS=100 PACK_KEYS=1 DELAY_KEY_WRITE=1 ROW_FORMAT=fixed CHARSET=latin1;
+) AVG_ROW_LENGTH=10 CHECKSUM=1 COMMENT="test" ENGINE=MYISAM MIN_ROWS=10 MAX_ROWS=100 PACK_KEYS=1 DELAY_KEY_WRITE=1 ROW_FORMAT=fixed CHARSET=latin1;
# Not tested above: RAID_# UNION INSERT_METHOD DATA DIRECTORY INDEX DIRECTORY
show create table t1;
diff --git a/mysql-test/t/sql_mode.test b/mysql-test/t/sql_mode.test
index d96fd030207..95e83b4b9e2 100644
--- a/mysql-test/t/sql_mode.test
+++ b/mysql-test/t/sql_mode.test
@@ -8,7 +8,7 @@ CREATE TABLE `t1` (
`email` varchar(60) character set latin2 NOT NULL default '',
PRIMARY KEY (a),
UNIQUE KEY `email` USING BTREE (`email`)
-) TYPE=HEAP CHARSET=latin1 ROW_FORMAT DYNAMIC;
+) ENGINE=HEAP CHARSET=latin1 ROW_FORMAT DYNAMIC;
set @@sql_mode="";
show variables like 'sql_mode';
show create table t1;
diff --git a/mysql-test/t/status.test b/mysql-test/t/status.test
index 30edcc79d9e..7be494bd0e7 100644
--- a/mysql-test/t/status.test
+++ b/mysql-test/t/status.test
@@ -17,7 +17,7 @@ SET SQL_LOG_BIN=0;
drop table if exists t1;
--enable_warnings
-create table t1(n int) type=myisam;
+create table t1(n int) engine=myisam;
insert into t1 values(1);
connection con2;
lock tables t1 read;
diff --git a/mysql-test/t/subselect.test b/mysql-test/t/subselect.test
index e53679b444e..95e4f022f2d 100644
--- a/mysql-test/t/subselect.test
+++ b/mysql-test/t/subselect.test
@@ -152,7 +152,7 @@ CREATE TABLE `t8` (
`email` varchar(60) character set latin1 NOT NULL default '',
PRIMARY KEY (`pseudo`),
UNIQUE KEY `email` (`email`)
-) TYPE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
INSERT INTO t8 (pseudo,email) VALUES ('joce','test');
INSERT INTO t8 (pseudo,email) VALUES ('joce1','test1');
@@ -177,7 +177,7 @@ CREATE TABLE `t1` (
`pseudo` varchar(35) character set latin1 NOT NULL default '',
PRIMARY KEY (`pseudo`,`date`,`topic`),
KEY `topic` (`topic`)
-) TYPE=MyISAM ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM ROW_FORMAT=DYNAMIC;
INSERT INTO t1 (topic,date,pseudo) VALUES
('43506','2002-10-02','joce'),('40143','2002-08-03','joce');
EXPLAIN EXTENDED SELECT DISTINCT date FROM t1 WHERE date='2002-08-03';
@@ -196,7 +196,7 @@ CREATE TABLE `t1` (
`maxnumrep` int(10) unsigned NOT NULL default '0',
PRIMARY KEY (`numeropost`),
UNIQUE KEY `maxnumrep` (`maxnumrep`)
-) TYPE=MyISAM ROW_FORMAT=FIXED;
+) ENGINE=MyISAM ROW_FORMAT=FIXED;
INSERT INTO t1 (numeropost,maxnumrep) VALUES (40143,1),(43506,2);
@@ -206,7 +206,7 @@ CREATE TABLE `t2` (
`date` date NOT NULL default '0000-00-00',
`pseudo` varchar(35) NOT NULL default '',
PRIMARY KEY (`mot`,`pseudo`,`date`,`topic`)
- ) TYPE=MyISAM ROW_FORMAT=DYNAMIC;
+ ) ENGINE=MyISAM ROW_FORMAT=DYNAMIC;
INSERT INTO t2 (mot,topic,date,pseudo) VALUES ('joce','40143','2002-10-22','joce'), ('joce','43506','2002-10-22','joce');
select numeropost as a FROM t1 GROUP BY (SELECT 1 FROM t1 HAVING a=1);
@@ -239,7 +239,7 @@ CREATE TABLE `t1` (
`maxnumrep` int(10) unsigned NOT NULL default '0',
PRIMARY KEY (`numeropost`),
UNIQUE KEY `maxnumrep` (`maxnumrep`)
-) TYPE=MyISAM ROW_FORMAT=FIXED;
+) ENGINE=MyISAM ROW_FORMAT=FIXED;
INSERT INTO t1 (numeropost,maxnumrep) VALUES (1,0),(2,1);
-- error 1241
@@ -268,7 +268,7 @@ CREATE TABLE `t1` (
PRIMARY KEY (`numeropost`,`numreponse`),
UNIQUE KEY `numreponse` (`numreponse`),
KEY `pseudo` (`pseudo`,`numeropost`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
-- error 1246
SELECT (SELECT numeropost FROM t1 HAVING numreponse=a),numreponse FROM (SELECT * FROM t1) as a;
-- error 1054
@@ -392,7 +392,7 @@ drop table t1, t2, t3;
-- error 1096
SELECT * FROM (SELECT 1) b WHERE 1 IN (SELECT *);
-CREATE TABLE t2 (id int(11) default NULL, KEY id (id)) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t2 (id int(11) default NULL, KEY id (id)) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t2 VALUES (1),(2);
SELECT * FROM t2 WHERE id IN (SELECT 1);
EXPLAIN EXTENDED SELECT * FROM t2 WHERE id IN (SELECT 1);
@@ -407,7 +407,7 @@ INSERT INTO t2 VALUES ((SELECT * FROM t2));
-- error 1093
INSERT INTO t2 VALUES ((SELECT id FROM t2));
SELECT * FROM t2;
-CREATE TABLE t1 (id int(11) default NULL, KEY id (id)) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t1 (id int(11) default NULL, KEY id (id)) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 values (1),(1);
-- error 1241
UPDATE t2 SET id=(SELECT * FROM t1);
@@ -541,7 +541,7 @@ insert into t2 values (1,2),(1,3);
select * from t1 where row(a,b) in (select a,b from t2);
drop table t1, t2;
-CREATE TABLE `t1` (`i` int(11) NOT NULL default '0',PRIMARY KEY (`i`)) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE `t1` (`i` int(11) NOT NULL default '0',PRIMARY KEY (`i`)) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES (1);
-- error 1111
UPDATE t1 SET i=i+1 WHERE i=(SELECT MAX(i));
@@ -563,7 +563,7 @@ CREATE TABLE `t1` (
PRIMARY KEY (`mot`,`pseudo`,`date`,`topic`),
KEY `pseudo` (`pseudo`,`date`,`topic`),
KEY `topic` (`topic`)
-) TYPE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
CREATE TABLE `t2` (
`mot` varchar(30) character set latin1 NOT NULL default '',
@@ -573,14 +573,14 @@ CREATE TABLE `t2` (
PRIMARY KEY (`mot`,`pseudo`,`date`,`topic`),
KEY `pseudo` (`pseudo`,`date`,`topic`),
KEY `topic` (`topic`)
-) TYPE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM CHARSET=latin1 ROW_FORMAT=DYNAMIC;
CREATE TABLE `t3` (
`numeropost` mediumint(8) unsigned NOT NULL auto_increment,
`maxnumrep` int(10) unsigned NOT NULL default '0',
PRIMARY KEY (`numeropost`),
UNIQUE KEY `maxnumrep` (`maxnumrep`)
-) TYPE=MyISAM CHARSET=latin1;
+) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES ('joce','1','','joce'),('test','2','','test');
INSERT INTO t2 VALUES ('joce','1','','joce'),('test','2','','test');
@@ -634,7 +634,7 @@ CREATE TABLE t1 (
District char(20) NOT NULL default '',
Population int(11) NOT NULL default '0',
PRIMARY KEY (ID)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (130,'Sydney','AUS','New South Wales',3276207);
INSERT INTO t1 VALUES (131,'Melbourne','AUS','Victoria',2865329);
@@ -657,7 +657,7 @@ CREATE TABLE t2 (
Capital int(11) default NULL,
Code2 char(2) NOT NULL default '',
PRIMARY KEY (Code)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t2 VALUES ('AUS','Australia','Oceania','Australia and New Zealand',7741220.00,1901,18886000,79.8,351182.00,392911.00,'Australia','Constitutional Monarchy, Federation','Elisabeth II',135,'AU');
INSERT INTO t2 VALUES ('AZE','Azerbaijan','Asia','Middle East',86600.00,1991,7734000,62.9,4127.00,4100.00,'Azärbaycan','Federal Republic','Heydär Äliyev',144,'AZ');
@@ -674,7 +674,7 @@ CREATE TABLE `t1` (
`pseudo` varchar(35) character set latin1 NOT NULL default '',
PRIMARY KEY (`id`),
UNIQUE KEY `pseudo` (`pseudo`),
-) TYPE=MyISAM PACK_KEYS=1 ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM PACK_KEYS=1 ROW_FORMAT=DYNAMIC;
INSERT INTO t1 (pseudo) VALUES ('test');
SELECT 0 IN (SELECT 1 FROM t1 a);
EXPLAIN EXTENDED SELECT 0 IN (SELECT 1 FROM t1 a);
@@ -686,7 +686,7 @@ drop table t1;
CREATE TABLE `t1` (
`i` int(11) NOT NULL default '0',
PRIMARY KEY (`i`)
-) TYPE=MyISAM CHARSET=latin1;
+) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES (1);
-- error 1111
@@ -702,12 +702,12 @@ drop table t1;
#
CREATE TABLE t1 (
id int(11) default NULL
-) TYPE=MyISAM CHARSET=latin1;
+) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES (1),(1),(2),(2),(1),(3);
CREATE TABLE t2 (
id int(11) default NULL,
name varchar(15) default NULL
-) TYPE=MyISAM CHARSET=latin1;
+) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t2 VALUES (4,'vita'), (1,'vita'), (2,'vita'), (1,'vita');
update t1, t2 set t2.name='lenka' where t2.id in (select id from t1);
@@ -739,7 +739,7 @@ CREATE TABLE t1 (
UNIQUE KEY t1_PK (ID,SUB_ID),
KEY t1_FK (REF_ID,REF_SUB),
KEY t1_REFID (REF_ID)
-) TYPE=MyISAM CHARSET=cp1251;
+) ENGINE=MyISAM CHARSET=cp1251;
INSERT INTO t1 VALUES (1,0,NULL,NULL),(2,0,NULL,NULL);
SELECT DISTINCT REF_ID FROM t1 WHERE ID= (SELECT DISTINCT REF_ID FROM t1 WHERE ID=2);
DROP TABLE t1;
@@ -777,7 +777,7 @@ CREATE TABLE `t1` (
PRIMARY KEY (`id`),
UNIQUE KEY `email` (`email`),
UNIQUE KEY `pseudo` (`pseudo`),
-) TYPE=MyISAM CHARSET=latin1 PACK_KEYS=1 ROW_FORMAT=DYNAMIC;
+) ENGINE=MyISAM CHARSET=latin1 PACK_KEYS=1 ROW_FORMAT=DYNAMIC;
INSERT INTO t1 (id,pseudo,email) VALUES (1,'test','test'),(2,'test1','test1');
SELECT pseudo as a, pseudo as b FROM t1 GROUP BY (SELECT a) ORDER BY (SELECT id*1);
drop table if exists t1;
@@ -933,13 +933,13 @@ drop table t2, t3;
# correct used_tables()
#
-CREATE TABLE `t1` ( `id` mediumint(9) NOT NULL auto_increment, `taskid` bigint(20) NOT NULL default '0', `dbid` int(11) NOT NULL default '0', `create_date` datetime NOT NULL default '0000-00-00 00:00:00', `last_update` datetime NOT NULL default '0000-00-00 00:00:00', PRIMARY KEY (`id`)) TYPE=MyISAM CHARSET=latin1 AUTO_INCREMENT=3 ;
+CREATE TABLE `t1` ( `id` mediumint(9) NOT NULL auto_increment, `taskid` bigint(20) NOT NULL default '0', `dbid` int(11) NOT NULL default '0', `create_date` datetime NOT NULL default '0000-00-00 00:00:00', `last_update` datetime NOT NULL default '0000-00-00 00:00:00', PRIMARY KEY (`id`)) ENGINE=MyISAM CHARSET=latin1 AUTO_INCREMENT=3 ;
INSERT INTO `t1` (`id`, `taskid`, `dbid`, `create_date`,`last_update`) VALUES (1, 1, 15, '2003-09-29 10:31:36', '2003-09-29 10:31:36'), (2, 1, 21, now(), now());
-CREATE TABLE `t2` (`db_id` int(11) NOT NULL auto_increment,`name` varchar(200) NOT NULL default '',`primary_uid` smallint(6) NOT NULL default '0',`secondary_uid` smallint(6) NOT NULL default '0',PRIMARY KEY (`db_id`),UNIQUE KEY `name_2` (`name`),FULLTEXT KEY `name` (`name`)) TYPE=MyISAM CHARSET=latin1 AUTO_INCREMENT=2147483647;
+CREATE TABLE `t2` (`db_id` int(11) NOT NULL auto_increment,`name` varchar(200) NOT NULL default '',`primary_uid` smallint(6) NOT NULL default '0',`secondary_uid` smallint(6) NOT NULL default '0',PRIMARY KEY (`db_id`),UNIQUE KEY `name_2` (`name`),FULLTEXT KEY `name` (`name`)) ENGINE=MyISAM CHARSET=latin1 AUTO_INCREMENT=2147483647;
INSERT INTO `t2` (`db_id`, `name`, `primary_uid`, `secondary_uid`) VALUES (18, 'Not Set 1', 0, 0),(19, 'Valid', 1, 2),(20, 'Valid 2', 1, 2),(21, 'Should Not Return', 1, 2),(26, 'Not Set 2', 0, 0),(-1, 'ALL DB\'S', 0, 0);
-CREATE TABLE `t3` (`taskgenid` mediumint(9) NOT NULL auto_increment,`dbid` int(11) NOT NULL default '0',`taskid` int(11) NOT NULL default '0',`mon` tinyint(4) NOT NULL default '1',`tues` tinyint(4) NOT NULL default '1',`wed` tinyint(4) NOT NULL default '1',`thur` tinyint(4) NOT NULL default '1',`fri` tinyint(4) NOT NULL default '1',`sat` tinyint(4) NOT NULL default '0',`sun` tinyint(4) NOT NULL default '0',`how_often` smallint(6) NOT NULL default '1',`userid` smallint(6) NOT NULL default '0',`active` tinyint(4) NOT NULL default '1',PRIMARY KEY (`taskgenid`)) TYPE=MyISAM CHARSET=latin1 AUTO_INCREMENT=2 ;
+CREATE TABLE `t3` (`taskgenid` mediumint(9) NOT NULL auto_increment,`dbid` int(11) NOT NULL default '0',`taskid` int(11) NOT NULL default '0',`mon` tinyint(4) NOT NULL default '1',`tues` tinyint(4) NOT NULL default '1',`wed` tinyint(4) NOT NULL default '1',`thur` tinyint(4) NOT NULL default '1',`fri` tinyint(4) NOT NULL default '1',`sat` tinyint(4) NOT NULL default '0',`sun` tinyint(4) NOT NULL default '0',`how_often` smallint(6) NOT NULL default '1',`userid` smallint(6) NOT NULL default '0',`active` tinyint(4) NOT NULL default '1',PRIMARY KEY (`taskgenid`)) ENGINE=MyISAM CHARSET=latin1 AUTO_INCREMENT=2 ;
INSERT INTO `t3` (`taskgenid`, `dbid`, `taskid`, `mon`, `tues`,`wed`, `thur`, `fri`, `sat`, `sun`, `how_often`, `userid`, `active`) VALUES (1,-1, 1, 1, 1, 1, 1, 1, 0, 0, 1, 0, 1);
-CREATE TABLE `t4` (`task_id` smallint(6) NOT NULL default '0',`description` varchar(200) NOT NULL default '') TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE `t4` (`task_id` smallint(6) NOT NULL default '0',`description` varchar(200) NOT NULL default '') ENGINE=MyISAM CHARSET=latin1;
INSERT INTO `t4` (`task_id`, `description`) VALUES (1, 'Daily Check List'),(2, 'Weekly Status');
select dbid, name, (date_format(now() , '%Y-%m-%d') - INTERVAL how_often DAY) >= ifnull((SELECT date_format(max(create_date),'%Y-%m-%d') FROM t1 WHERE dbid = b.db_id AND taskid = a.taskgenid), '1950-01-01') from t3 a, t2 b, t4 WHERE dbid = - 1 AND primary_uid = '1' AND t4.task_id = taskid;
SELECT dbid, name FROM t3 a, t2 b, t4 WHERE dbid = - 1 AND primary_uid = '1' AND ((date_format(now() , '%Y-%m-%d') - INTERVAL how_often DAY) >= ifnull((SELECT date_format(max(create_date),'%Y-%m-%d') FROM t1 WHERE dbid = b.db_id AND taskid = a.taskgenid), '1950-01-01')) AND t4.task_id = taskid;
@@ -948,9 +948,9 @@ drop table t1,t2,t3,t4;
#
# cardinality check
#
-CREATE TABLE t1 (id int(11) default NULL) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t1 (id int(11) default NULL) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES (1),(5);
-CREATE TABLE t2 (id int(11) default NULL) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t2 (id int(11) default NULL) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t2 VALUES (2),(6);
-- error 1240
select * from t1 where (1,2,6) in (select * from t2);
@@ -980,9 +980,9 @@ drop table t1;
#
# filesort in subquery (restoring join_tab)
#
-CREATE TABLE t1 (number char(11) NOT NULL default '') TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t1 (number char(11) NOT NULL default '') ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t1 VALUES ('69294728265'),('18621828126'),('89356874041'),('95895001874');
-CREATE TABLE t2 (code char(5) NOT NULL default '',UNIQUE KEY code (code)) TYPE=MyISAM CHARSET=latin1;
+CREATE TABLE t2 (code char(5) NOT NULL default '',UNIQUE KEY code (code)) ENGINE=MyISAM CHARSET=latin1;
INSERT INTO t2 VALUES ('1'),('1226'),('1245'),('1862'),('18623'),('1874'),('1967'),('6');
select c.number as phone,(select p.code from t2 p where c.number like concat(p.code, '%') order by length(p.code) desc limit 1) as code from t1 c;
drop table t1, t2;
diff --git a/mysql-test/t/subselect2.test b/mysql-test/t/subselect2.test
index 151e285e6d4..2d42320334a 100644
--- a/mysql-test/t/subselect2.test
+++ b/mysql-test/t/subselect2.test
@@ -22,7 +22,7 @@ DOCID VARCHAR(32)BINARY NOT NULL
, ORIGINATOR INTEGER
, PRIMARY KEY ( DOCID )
-) TYPE=InnoDB
+) ENGINE=InnoDB
;
CREATE TABLE t2
@@ -48,7 +48,7 @@ DOCID VARCHAR(32)BINARY NOT NULL
, ORIGINATOR INTEGER
, PRIMARY KEY ( DOCID )
-) TYPE=InnoDB
+) ENGINE=InnoDB
;
CREATE INDEX DDOCTYPEID_IDX ON t2 (DOCTYPEID);
CREATE INDEX DFOLDERID_IDX ON t2 (FOLDERID);
@@ -68,7 +68,7 @@ FOLDERID VARCHAR(32)BINARY NOT NULL
, ORIGINATOR INTEGER
, PRIMARY KEY ( FOLDERID )
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
CREATE INDEX FFOLDERID_IDX ON t3 (FOLDERID);
CREATE INDEX CMFLDRPARNT_IDX ON t3 (PARENTID);
@@ -84,7 +84,7 @@ DOCTYPEID VARCHAR(32)BINARY NOT NULL
, ORIGINATOR INTEGER
, PRIMARY KEY ( DOCTYPEID )
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t2 VALUES("c373e9f59cf15a6c3e57444553544200", "c373e9f59cf15a6c3e57444553544200", "340d243d45f111d497b00010a4ef934d", "2f6161e879db43c1a5b82c21ddc49089", NULL, "2003-06-06 07:48:42", NULL, NULL, NULL, "2003-06-06 07:48:42", "2003-06-06 07:48:42", NULL, NULL, NULL, "03eea05112b845949f3fd03278b5fe43", "2003-06-06 07:48:42", "admin", "0", NULL);
diff --git a/mysql-test/t/subselect_innodb.test b/mysql-test/t/subselect_innodb.test
index 5e274ecbd5c..9eb35ffc0fd 100644
--- a/mysql-test/t/subselect_innodb.test
+++ b/mysql-test/t/subselect_innodb.test
@@ -23,7 +23,7 @@ FOLDERID VARCHAR(32)BINARY NOT NULL
, ORIGINATOR INTEGER
, PRIMARY KEY ( FOLDERID )
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
CREATE INDEX FFOLDERID_IDX ON t1 (FOLDERID);
CREATE INDEX CMFLDRPARNT_IDX ON t1 (PARENTID);
INSERT INTO t1 VALUES("0c9aab05b15048c59bc35c8461507deb", "System", "System", "2003-06-05 16:30:00", "The system content repository folder.", "3", "2003-06-05 16:30:00", "System", "0", NULL, "9c9aab05b15048c59bc35c8461507deb", "1");
@@ -35,9 +35,9 @@ drop table t1;
#
# UNION unlocking test
#
-create table t1 (a int) type=innodb;
-create table t2 (a int) type=innodb;
-create table t3 (a int) type=innodb;
+create table t1 (a int) engine=innodb;
+create table t2 (a int) engine=innodb;
+create table t3 (a int) engine=innodb;
insert into t1 values (1),(2),(3),(4);
insert into t2 values (10),(20),(30),(40);
insert into t3 values (1),(2),(10),(50);
@@ -48,12 +48,12 @@ drop table t1,t2,t3;
CREATE TABLE t1 (
processor_id INTEGER NOT NULL,
PRIMARY KEY (processor_id)
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
CREATE TABLE t3 (
yod_id BIGINT UNSIGNED AUTO_INCREMENT NOT NULL,
login_processor INTEGER UNSIGNED ,
PRIMARY KEY (yod_id)
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
CREATE TABLE t2 (
processor_id INTEGER NOT NULL,
yod_id BIGINT UNSIGNED NOT NULL,
@@ -62,7 +62,7 @@ CREATE TABLE t2 (
INDEX (yod_id),
FOREIGN KEY (processor_id) REFERENCES t1(processor_id),
FOREIGN KEY (yod_id) REFERENCES t3(yod_id)
-) TYPE=InnoDB;
+) ENGINE=InnoDB;
INSERT INTO t1 VALUES (1),(2),(3);
INSERT INTO t3 VALUES (1,1),(2,2),(3,3);
INSERT INTO t2 VALUES (1,1),(2,2),(3,3);
diff --git a/mysql-test/t/symlink.test b/mysql-test/t/symlink.test
index f618c342936..716eed7abc0 100644
--- a/mysql-test/t/symlink.test
+++ b/mysql-test/t/symlink.test
@@ -41,7 +41,7 @@ drop table t2;
#
disable_query_log;
-eval create table t9 (a int not null auto_increment, b char(16) not null, primary key (a)) type=myisam data directory="$MYSQL_TEST_DIR/var/tmp" index directory="$MYSQL_TEST_DIR/var/run";
+eval create table t9 (a int not null auto_increment, b char(16) not null, primary key (a)) engine=myisam data directory="$MYSQL_TEST_DIR/var/tmp" index directory="$MYSQL_TEST_DIR/var/run";
enable_query_log;
insert into t9 select * from t1;
@@ -66,23 +66,23 @@ drop table t1;
disable_query_log;
--error 1103,1103
-create table t1 (a int not null auto_increment, b char(16) not null, primary key (a)) type=myisam data directory="tmp";
+create table t1 (a int not null auto_increment, b char(16) not null, primary key (a)) engine=myisam data directory="tmp";
# Check that we cannot link over a table from another database.
create database mysqltest;
--error 1,1
-create table mysqltest.t9 (a int not null auto_increment, b char(16) not null, primary key (a)) type=myisam index directory="/this-dir-does-not-exist";
+create table mysqltest.t9 (a int not null auto_increment, b char(16) not null, primary key (a)) engine=myisam index directory="/this-dir-does-not-exist";
--error 1103,1103
-create table mysqltest.t9 (a int not null auto_increment, b char(16) not null, primary key (a)) type=myisam index directory="not-hard-path";
+create table mysqltest.t9 (a int not null auto_increment, b char(16) not null, primary key (a)) engine=myisam index directory="not-hard-path";
--error 1,1
-eval create table mysqltest.t9 (a int not null auto_increment, b char(16) not null, primary key (a)) type=myisam index directory="$MYSQL_TEST_DIR/var/run";
+eval create table mysqltest.t9 (a int not null auto_increment, b char(16) not null, primary key (a)) engine=myisam index directory="$MYSQL_TEST_DIR/var/run";
--error 1,1
-eval create table mysqltest.t9 (a int not null auto_increment, b char(16) not null, primary key (a)) type=myisam data directory="$MYSQL_TEST_DIR/var/tmp";
+eval create table mysqltest.t9 (a int not null auto_increment, b char(16) not null, primary key (a)) engine=myisam data directory="$MYSQL_TEST_DIR/var/tmp";
enable_query_log;
# Check moving table t9 from default database to mysqltest;
diff --git a/mysql-test/t/temp_table.test b/mysql-test/t/temp_table.test
index 03b6fa35bfa..2181d3eb74c 100644
--- a/mysql-test/t/temp_table.test
+++ b/mysql-test/t/temp_table.test
@@ -16,8 +16,8 @@ select * from t2;
CREATE TABLE t2 (x int not null, y int not null);
alter table t2 rename t1;
select * from t1;
-create TEMPORARY TABLE t2 type=heap select * from t1;
-create TEMPORARY TABLE IF NOT EXISTS t2 (a int) type=heap;
+create TEMPORARY TABLE t2 engine=heap select * from t1;
+create TEMPORARY TABLE IF NOT EXISTS t2 (a int) engine=heap;
# This should give errors
!$1050 CREATE TEMPORARY TABLE t1 (a int not null, b char (10) not null);
@@ -78,7 +78,7 @@ drop table t1;
CREATE TABLE t1 (
d datetime default NULL
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES ('2002-10-24 14:50:32'),('2002-10-24 14:50:33'),('2002-10-24 14:50:34'),('2002-10-24 14:50:34'),('2002-10-24 14:50:34'),('2002-10-24 14:50:35'),('2002-10-24 14:50:35'),('2002-10-24 14:50:35'),('2002-10-24 14:50:35'),('2002-10-24 14:50:36'),('2002-10-24 14:50:36'),('2002-10-24 14:50:36'),('2002-10-24 14:50:36'),('2002-10-24 14:50:37'),('2002-10-24 14:50:37'),('2002-10-24 14:50:37'),('2002-10-24 14:50:37'),('2002-10-24 14:50:38'),('2002-10-24 14:50:38'),('2002-10-24 14:50:38'),('2002-10-24 14:50:39'),('2002-10-24 14:50:39'),('2002-10-24 14:50:39'),('2002-10-24 14:50:39'),('2002-10-24 14:50:40'),('2002-10-24 14:50:40'),('2002-10-24 14:50:40');
diff --git a/mysql-test/t/type_datetime.test b/mysql-test/t/type_datetime.test
index d2611973101..7cedbc087e4 100644
--- a/mysql-test/t/type_datetime.test
+++ b/mysql-test/t/type_datetime.test
@@ -57,7 +57,7 @@ CREATE TABLE `t1` (
PRIMARY KEY (`numfacture`),
KEY `date` (`date`),
KEY `expedition` (`expedition`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (expedition) VALUES ('0001-00-00 00:00:00');
SELECT * FROM t1 WHERE expedition='0001-00-00 00:00:00';
diff --git a/mysql-test/t/type_set.test b/mysql-test/t/type_set.test
index 6c0f162dc86..60aa8dcfcf2 100644
--- a/mysql-test/t/type_set.test
+++ b/mysql-test/t/type_set.test
@@ -12,5 +12,5 @@ drop table t1;
create table t1 (a set (' ','a','b ') not null default 'b ');
show create table t1;
drop table t1;
-CREATE TABLE t1 ( user varchar(64) NOT NULL default '', path varchar(255) NOT NULL default '', privilege set('select','RESERVED30','RESERVED29','RESERVED28','RESERVED27','RESERVED26', 'RESERVED25','RESERVED24','data.delete','RESERVED22','RESERVED21', 'RESERVED20','data.insert.none','data.insert.approve', 'data.insert.delete','data.insert.move','data.insert.propose', 'data.insert.reject','RESERVED13','RESERVED12','RESERVED11','RESERVED10', 'RESERVED09','data.update','RESERVED07','RESERVED06','RESERVED05', 'RESERVED04','metadata.delete','metadata.put','RESERVED01','RESERVED00') NOT NULL default '', KEY user (user) ) TYPE=MyISAM CHARSET=utf8;
+CREATE TABLE t1 ( user varchar(64) NOT NULL default '', path varchar(255) NOT NULL default '', privilege set('select','RESERVED30','RESERVED29','RESERVED28','RESERVED27','RESERVED26', 'RESERVED25','RESERVED24','data.delete','RESERVED22','RESERVED21', 'RESERVED20','data.insert.none','data.insert.approve', 'data.insert.delete','data.insert.move','data.insert.propose', 'data.insert.reject','RESERVED13','RESERVED12','RESERVED11','RESERVED10', 'RESERVED09','data.update','RESERVED07','RESERVED06','RESERVED05', 'RESERVED04','metadata.delete','metadata.put','RESERVED01','RESERVED00') NOT NULL default '', KEY user (user) ) ENGINE=MyISAM CHARSET=utf8;
DROP TABLE t1;
diff --git a/mysql-test/t/union.test b/mysql-test/t/union.test
index a5cb1ce6b6e..6138bba5a31 100644
--- a/mysql-test/t/union.test
+++ b/mysql-test/t/union.test
@@ -97,7 +97,7 @@ CREATE TABLE t1 (
`same` tinyint(1) unsigned NOT NULL default '1',
PRIMARY KEY (`pseudo1`),
KEY `pseudo` (`pseudo`)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 (pseudo,pseudo1,same) VALUES ('joce', 'testtt', 1),('joce', 'tsestset', 1),('dekad', 'joce', 1);
SELECT pseudo FROM t1 WHERE pseudo1='joce' UNION SELECT pseudo FROM t1 WHERE pseudo='joce';
SELECT pseudo1 FROM t1 WHERE pseudo1='joce' UNION SELECT pseudo1 FROM t1 WHERE pseudo='joce';
@@ -252,9 +252,9 @@ drop table t1,t2;
#
# Test for another bug with UNION and LEFT JOIN
#
-CREATE TABLE t1 ( id int(3) unsigned default '0') TYPE=MyISAM;
+CREATE TABLE t1 ( id int(3) unsigned default '0') ENGINE=MyISAM;
INSERT INTO t1 (id) VALUES("1");
-CREATE TABLE t2 ( id int(3) unsigned default '0', id_master int(5) default '0', text1 varchar(5) default NULL, text2 varchar(5) default NULL) TYPE=MyISAM;
+CREATE TABLE t2 ( id int(3) unsigned default '0', id_master int(5) default '0', text1 varchar(5) default NULL, text2 varchar(5) default NULL) ENGINE=MyISAM;
INSERT INTO t2 (id, id_master, text1, text2) VALUES("1", "1",
"foo1", "bar1");
INSERT INTO t2 (id, id_master, text1, text2) VALUES("2", "1",
diff --git a/mysql-test/t/update.test b/mysql-test/t/update.test
index 485af981fb4..8e50fee56fd 100644
--- a/mysql-test/t/update.test
+++ b/mysql-test/t/update.test
@@ -71,7 +71,7 @@ CREATE TABLE t1 (
KEY k3 (parent),
KEY k4 (assignment),
KEY ticket (ticket)
-) TYPE=MyISAM;
+) ENGINE=MyISAM;
INSERT INTO t1 VALUES (773,773,'','','',980257344,20010318180652,0,'Open',10,0,0,0,1,'','','','','');
@@ -107,7 +107,7 @@ CREATE TABLE t1 (
`nom_option` char(40) NOT NULL default '',
`valid` tinyint(1) NOT NULL default '0',
KEY `id_param` (`id_param`,`nom_option`)
- ) TYPE=MyISAM;
+ ) ENGINE=MyISAM;
INSERT INTO t1 (id_param,nom_option,valid) VALUES (185,'600x1200',1);
diff --git a/mysql-test/t/warnings.test b/mysql-test/t/warnings.test
index 050449f0f5b..a94380db221 100644
--- a/mysql-test/t/warnings.test
+++ b/mysql-test/t/warnings.test
@@ -80,6 +80,14 @@ select @@warning_count;
# Test for handler type
#
drop table t1;
-create table t1 (id int) type=isam;
-alter table t1 type=isam;
+create table t1 (id int) engine=isam;
+alter table t1 engine=isam;
drop table t1;
+
+#
+# Test for deprecated TYPE= syntax
+#
+create table t1 (id int) type=heap;
+alter table t1 type=myisam;
+drop table t1;
+
diff --git a/sql/lex.h b/sql/lex.h
index 9dd3ede7f44..a7c8735e193 100644
--- a/sql/lex.h
+++ b/sql/lex.h
@@ -49,30 +49,30 @@ static SYMBOL symbols[] = {
{ "<=>", SYM(EQUAL_SYM),0,0},
{ "ACTION", SYM(ACTION),0,0},
{ "ADD", SYM(ADD),0,0},
+ { "AFTER", SYM(AFTER_SYM),0,0},
+ { "AGAINST", SYM(AGAINST),0,0},
{ "AGGREGATE", SYM(AGGREGATE_SYM),0,0},
{ "ALL", SYM(ALL),0,0},
{ "ALTER", SYM(ALTER),0,0},
- { "AFTER", SYM(AFTER_SYM),0,0},
- { "AGAINST", SYM(AGAINST),0,0},
{ "ANALYZE", SYM(ANALYZE_SYM),0,0},
{ "AND", SYM(AND),0,0},
{ "ANY", SYM(ANY_SYM),0,0},
{ "AS", SYM(AS),0,0},
{ "ASC", SYM(ASC),0,0},
{ "ASCII", SYM(ASCII_SYM),0,0},
+ { "AUTO_INCREMENT", SYM(AUTO_INC),0,0},
{ "AVG", SYM(AVG_SYM),0,0},
{ "AVG_ROW_LENGTH", SYM(AVG_ROW_LENGTH),0,0},
- { "AUTO_INCREMENT", SYM(AUTO_INC),0,0},
{ "BACKUP", SYM(BACKUP_SYM),0,0},
+ { "BDB", SYM(BERKELEY_DB_SYM),0,0},
{ "BEFORE", SYM(BEFORE_SYM),0,0},
{ "BEGIN", SYM(BEGIN_SYM),0,0},
{ "BERKELEYDB", SYM(BERKELEY_DB_SYM),0,0},
- { "BDB", SYM(BERKELEY_DB_SYM),0,0},
{ "BETWEEN", SYM(BETWEEN_SYM),0,0},
{ "BIGINT", SYM(BIGINT),0,0},
- { "BIT", SYM(BIT_SYM),0,0},
{ "BINARY", SYM(BINARY),0,0},
{ "BINLOG", SYM(BINLOG_SYM),0,0},
+ { "BIT", SYM(BIT_SYM),0,0},
{ "BLOB", SYM(BLOB_SYM),0,0},
{ "BOOL", SYM(BOOL_SYM),0,0},
{ "BOOLEAN", SYM(BOOLEAN_SYM),0,0},
@@ -83,11 +83,11 @@ static SYMBOL symbols[] = {
{ "CACHE", SYM(CACHE_SYM),0,0},
{ "CASCADE", SYM(CASCADE),0,0},
{ "CASE", SYM(CASE_SYM),0,0},
+ { "CHANGE", SYM(CHANGE),0,0},
+ { "CHANGED", SYM(CHANGED),0,0},
{ "CHAR", SYM(CHAR_SYM),0,0},
{ "CHARACTER", SYM(CHAR_SYM),0,0},
{ "CHARSET", SYM(CHARSET),0,0},
- { "CHANGE", SYM(CHANGE),0,0},
- { "CHANGED", SYM(CHANGED),0,0},
{ "CHECK", SYM(CHECK_SYM),0,0},
{ "CHECKSUM", SYM(CHECKSUM_SYM),0,0},
{ "CIPHER", SYM(CIPHER_SYM),0,0},
@@ -121,13 +121,13 @@ static SYMBOL symbols[] = {
{ "DAY_SECOND", SYM(DAY_SECOND_SYM),0,0},
{ "DEC", SYM(DECIMAL_SYM),0,0},
{ "DECIMAL", SYM(DECIMAL_SYM),0,0},
- { "DES_KEY_FILE", SYM(DES_KEY_FILE),0,0},
{ "DEFAULT", SYM(DEFAULT),0,0},
{ "DELAYED", SYM(DELAYED_SYM),0,0},
{ "DELAY_KEY_WRITE", SYM(DELAY_KEY_WRITE_SYM),0,0},
{ "DELETE", SYM(DELETE_SYM),0,0},
{ "DESC", SYM(DESC),0,0},
{ "DESCRIBE", SYM(DESCRIBE),0,0},
+ { "DES_KEY_FILE", SYM(DES_KEY_FILE),0,0},
{ "DIRECTORY", SYM(DIRECTORY_SYM),0,0},
{ "DISABLE", SYM(DISABLE_SYM),0,0},
{ "DISCARD", SYM(DISCARD),0,0},
@@ -136,25 +136,27 @@ static SYMBOL symbols[] = {
{ "DIV", SYM(DIV_SYM),0,0},
{ "DO", SYM(DO_SYM),0,0},
{ "DOUBLE", SYM(DOUBLE_SYM),0,0},
- { "DUAL", SYM(DUAL_SYM),0,0},
{ "DROP", SYM(DROP),0,0},
+ { "DUAL", SYM(DUAL_SYM),0,0},
{ "DUMPFILE", SYM(DUMPFILE),0,0},
- { "DYNAMIC", SYM(DYNAMIC_SYM),0,0},
{ "DUPLICATE", SYM(DUPLICATE_SYM),0,0},
- { "ERRORS", SYM(ERRORS),0,0},
- { "END", SYM(END),0,0},
+ { "DYNAMIC", SYM(DYNAMIC_SYM),0,0},
{ "ELSE", SYM(ELSE),0,0},
- { "ESCAPE", SYM(ESCAPE_SYM),0,0},
- { "ESCAPED", SYM(ESCAPED),0,0},
{ "ENABLE", SYM(ENABLE_SYM),0,0},
{ "ENCLOSED", SYM(ENCLOSED),0,0},
+ { "END", SYM(END),0,0},
+ { "ENGINE", SYM(ENGINE_SYM),0,0},
{ "ENUM", SYM(ENUM),0,0},
+ { "ERRORS", SYM(ERRORS),0,0},
+ { "ESCAPE", SYM(ESCAPE_SYM),0,0},
+ { "ESCAPED", SYM(ESCAPED),0,0},
{ "EVENTS", SYM(EVENTS_SYM),0,0},
{ "EXECUTE", SYM(EXECUTE_SYM),0,0},
- { "EXPLAIN", SYM(DESCRIBE),0,0},
{ "EXISTS", SYM(EXISTS),0,0},
{ "EXPANSION", SYM(EXPANSION_SYM),0,0},
+ { "EXPLAIN", SYM(DESCRIBE),0,0},
{ "EXTENDED", SYM(EXTENDED_SYM),0,0},
+ { "FALSE", SYM(FALSE_SYM),0,0},
{ "FAST", SYM(FAST_SYM),0,0},
{ "FIELDS", SYM(COLUMNS),0,0},
{ "FILE", SYM(FILE_SYM),0,0},
@@ -164,15 +166,10 @@ static SYMBOL symbols[] = {
{ "FLOAT4", SYM(FLOAT_SYM),0,0},
{ "FLOAT8", SYM(DOUBLE_SYM),0,0},
{ "FLUSH", SYM(FLUSH_SYM),0,0},
- { "FALSE", SYM(FALSE_SYM),0,0},
- { "FOREIGN", SYM(FOREIGN),0,0},
+ { "FOR", SYM(FOR_SYM),0,0},
{ "FORCE", SYM(FORCE_SYM),0,0},
- { "RAID_TYPE", SYM(RAID_TYPE),0,0},
- { "RAID_CHUNKS", SYM(RAID_CHUNKS),0,0},
- { "RAID_CHUNKSIZE", SYM(RAID_CHUNKSIZE),0,0},
- { "ROW_FORMAT", SYM(ROW_FORMAT_SYM),0,0},
+ { "FOREIGN", SYM(FOREIGN),0,0},
{ "FROM", SYM(FROM),0,0},
- { "FOR", SYM(FOR_SYM),0,0},
{ "FULL", SYM(FULL),0,0},
{ "FULLTEXT", SYM(FULLTEXT_SYM),0,0},
{ "FUNCTION", SYM(UDF_SYM),0,0},
@@ -183,18 +180,20 @@ static SYMBOL symbols[] = {
{ "GRANT", SYM(GRANT),0,0},
{ "GRANTS", SYM(GRANTS),0,0},
{ "GROUP", SYM(GROUP),0,0},
- { "HAVING", SYM(HAVING),0,0},
{ "HANDLER", SYM(HANDLER_SYM),0,0},
{ "HASH", SYM(HASH_SYM),0,0},
+ { "HAVING", SYM(HAVING),0,0},
{ "HELP", SYM(HELP_SYM),0,0},
{ "HIGH_PRIORITY", SYM(HIGH_PRIORITY),0,0},
+ { "HOSTS", SYM(HOSTS_SYM),0,0},
{ "HOUR", SYM(HOUR_SYM),0,0},
{ "HOUR_MICROSECOND", SYM(HOUR_MICROSECOND_SYM),0,0},
{ "HOUR_MINUTE", SYM(HOUR_MINUTE_SYM),0,0},
{ "HOUR_SECOND", SYM(HOUR_SECOND_SYM),0,0},
- { "HOSTS", SYM(HOSTS_SYM),0,0},
{ "IDENTIFIED", SYM(IDENTIFIED_SYM),0,0},
+ { "IF", SYM(IF),0,0},
{ "IGNORE", SYM(IGNORE_SYM),0,0},
+ { "IMPORT", SYM(IMPORT),0,0},
{ "IN", SYM(IN_SYM),0,0},
{ "INDEX", SYM(INDEX),0,0},
{ "INDEXES", SYM(INDEXES),0,0},
@@ -202,20 +201,18 @@ static SYMBOL symbols[] = {
{ "INNER", SYM(INNER_SYM),0,0},
{ "INNOBASE", SYM(INNOBASE_SYM),0,0},
{ "INNODB", SYM(INNOBASE_SYM),0,0},
- { "IMPORT", SYM(IMPORT),0,0},
{ "INSERT", SYM(INSERT),0,0},
{ "INSERT_METHOD", SYM(INSERT_METHOD),0,0},
{ "INT", SYM(INT_SYM),0,0},
- { "INTEGER", SYM(INT_SYM),0,0},
- { "INTERVAL", SYM(INTERVAL_SYM),0,0},
{ "INT1", SYM(TINYINT),0,0},
{ "INT2", SYM(SMALLINT),0,0},
{ "INT3", SYM(MEDIUMINT),0,0},
{ "INT4", SYM(INT_SYM),0,0},
{ "INT8", SYM(BIGINT),0,0},
+ { "INTEGER", SYM(INT_SYM),0,0},
+ { "INTERVAL", SYM(INTERVAL_SYM),0,0},
{ "INTO", SYM(INTO),0,0},
{ "IO_THREAD", SYM(RELAY_THREAD),0,0},
- { "IF", SYM(IF),0,0},
{ "IS", SYM(IS),0,0},
{ "ISOLATION", SYM(ISOLATION),0,0},
{ "ISSUER", SYM(ISSUER_SYM),0,0},
@@ -229,9 +226,9 @@ static SYMBOL symbols[] = {
{ "LEFT", SYM(LEFT),0,0},
{ "LEVEL", SYM(LEVEL_SYM),0,0},
{ "LIKE", SYM(LIKE),0,0},
+ { "LIMIT", SYM(LIMIT),0,0},
{ "LINES", SYM(LINES),0,0},
{ "LINESTRING", SYM(LINESTRING),0,0},
- { "LIMIT", SYM(LIMIT),0,0},
{ "LOAD", SYM(LOAD),0,0},
{ "LOCAL", SYM(LOCAL_SYM),0,0},
{ "LOCALTIME", SYM(NOW_SYM),0,0},
@@ -258,21 +255,21 @@ static SYMBOL symbols[] = {
{ "MASTER_SSL_CIPHER",SYM(MASTER_SSL_CIPHER_SYM),0,0},
{ "MASTER_SSL_KEY", SYM(MASTER_SSL_KEY_SYM),0,0},
{ "MASTER_USER", SYM(MASTER_USER_SYM),0,0},
- { "MAX_ROWS", SYM(MAX_ROWS),0,0},
+ { "MATCH", SYM(MATCH),0,0},
+ { "MAX_CONNECTIONS_PER_HOUR", SYM(MAX_CONNECTIONS_PER_HOUR), 0,0},
{ "MAX_QUERIES_PER_HOUR", SYM(MAX_QUERIES_PER_HOUR), 0,0},
+ { "MAX_ROWS", SYM(MAX_ROWS),0,0},
{ "MAX_UPDATES_PER_HOUR", SYM(MAX_UPDATES_PER_HOUR), 0,0},
- { "MAX_CONNECTIONS_PER_HOUR", SYM(MAX_CONNECTIONS_PER_HOUR), 0,0},
- { "MATCH", SYM(MATCH),0,0},
+ { "MEDIUM", SYM(MEDIUM_SYM),0,0},
{ "MEDIUMBLOB", SYM(MEDIUMBLOB),0,0},
- { "MEDIUMTEXT", SYM(MEDIUMTEXT),0,0},
{ "MEDIUMINT", SYM(MEDIUMINT),0,0},
- { "MEDIUM", SYM(MEDIUM_SYM),0,0},
+ { "MEDIUMTEXT", SYM(MEDIUMTEXT),0,0},
{ "MICROSECOND", SYM(MICROSECOND_SYM),0,0},
{ "MIDDLEINT", SYM(MEDIUMINT),0,0}, /* For powerbuilder */
- { "MIN_ROWS", SYM(MIN_ROWS),0,0},
{ "MINUTE", SYM(MINUTE_SYM),0,0},
{ "MINUTE_MICROSECOND", SYM(MINUTE_MICROSECOND_SYM),0,0},
{ "MINUTE_SECOND", SYM(MINUTE_SECOND_SYM),0,0},
+ { "MIN_ROWS", SYM(MIN_ROWS),0,0},
{ "MOD", SYM(MOD_SYM),0,0},
{ "MODE", SYM(MODE_SYM),0,0},
{ "MODIFY", SYM(MODIFY_SYM),0,0},
@@ -281,14 +278,15 @@ static SYMBOL symbols[] = {
{ "MULTIPOINT", SYM(MULTIPOINT),0,0},
{ "MULTIPOLYGON", SYM(MULTIPOLYGON),0,0},
{ "NAMES", SYM(NAMES_SYM),0,0},
- { "NATURAL", SYM(NATURAL),0,0},
{ "NATIONAL", SYM(NATIONAL_SYM),0,0},
- { "NEXT", SYM(NEXT_SYM),0,0},
- { "NEW", SYM(NEW_SYM),0,0},
+ { "NATURAL", SYM(NATURAL),0,0},
{ "NCHAR", SYM(NCHAR_SYM),0,0},
+ { "NEW", SYM(NEW_SYM),0,0},
+ { "NEXT", SYM(NEXT_SYM),0,0},
{ "NO", SYM(NO_SYM),0,0},
{ "NONE", SYM(NONE_SYM),0,0},
{ "NOT", SYM(NOT),0,0},
+ { "NO_WRITE_TO_BINLOG", SYM(NO_WRITE_TO_BINLOG),0,0},
{ "NULL", SYM(NULL_SYM),0,0},
{ "NUMERIC", SYM(NUMERIC_SYM),0,0},
{ "NVARCHAR", SYM(NVARCHAR_SYM),0,0},
@@ -308,33 +306,35 @@ static SYMBOL symbols[] = {
{ "PASSWORD", SYM(PASSWORD),0,0},
{ "POINT", SYM(POINT_SYM),0,0},
{ "POLYGON", SYM(POLYGON),0,0},
- { "PURGE", SYM(PURGE),0,0},
{ "PRECISION", SYM(PRECISION),0,0},
{ "PREV", SYM(PREV_SYM),0,0},
{ "PRIMARY", SYM(PRIMARY_SYM),0,0},
+ { "PRIVILEGES", SYM(PRIVILEGES),0,0},
{ "PROCEDURE", SYM(PROCEDURE),0,0},
{ "PROCESS" , SYM(PROCESS),0,0},
{ "PROCESSLIST", SYM(PROCESSLIST_SYM),0,0},
- { "PRIVILEGES", SYM(PRIVILEGES),0,0},
+ { "PURGE", SYM(PURGE),0,0},
{ "QUERY", SYM(QUERY_SYM),0,0},
{ "QUICK", SYM(QUICK),0,0},
{ "RAID0", SYM(RAID_0_SYM),0,0},
+ { "RAID_CHUNKS", SYM(RAID_CHUNKS),0,0},
+ { "RAID_CHUNKSIZE", SYM(RAID_CHUNKSIZE),0,0},
+ { "RAID_TYPE", SYM(RAID_TYPE),0,0},
{ "READ", SYM(READ_SYM),0,0},
{ "REAL", SYM(REAL),0,0},
{ "REFERENCES", SYM(REFERENCES),0,0},
+ { "REGEXP", SYM(REGEXP),0,0},
{ "RELAY_LOG_FILE", SYM(RELAY_LOG_FILE_SYM),0,0},
{ "RELAY_LOG_POS", SYM(RELAY_LOG_POS_SYM),0,0},
{ "RELAY_THREAD", SYM(RELAY_THREAD),0,0},
{ "RELOAD", SYM(RELOAD),0,0},
- { "REGEXP", SYM(REGEXP),0,0},
{ "RENAME", SYM(RENAME),0,0},
{ "REPAIR", SYM(REPAIR),0,0},
+ { "REPEATABLE", SYM(REPEATABLE_SYM),0,0},
{ "REPLACE", SYM(REPLACE),0,0},
{ "REPLICATION", SYM(REPLICATION),0,0},
- { "REPEATABLE", SYM(REPEATABLE_SYM),0,0},
{ "REQUIRE", SYM(REQUIRE_SYM),0,0},
{ "RESET", SYM(RESET_SYM),0,0},
- { "USER_RESOURCES", SYM(RESOURCES),0,0},
{ "RESTORE", SYM(RESTORE_SYM),0,0},
{ "RESTRICT", SYM(RESTRICT),0,0},
{ "RETURNS", SYM(UDF_RETURNS_SYM),0,0},
@@ -345,25 +345,27 @@ static SYMBOL symbols[] = {
{ "ROLLUP", SYM(ROLLUP_SYM),0,0},
{ "ROW", SYM(ROW_SYM),0,0},
{ "ROWS", SYM(ROWS_SYM),0,0},
+ { "ROW_FORMAT", SYM(ROW_FORMAT_SYM),0,0},
{ "RTREE", SYM(RTREE_SYM),0,0},
{ "SAVEPOINT", SYM(SAVEPOINT_SYM),0,0},
{ "SECOND", SYM(SECOND_SYM),0,0},
{ "SECOND_MICROSECOND", SYM(SECOND_MICROSECOND_SYM),0,0},
- { "SEPARATOR", SYM(SEPARATOR_SYM),0,0},
{ "SELECT", SYM(SELECT_SYM),0,0},
+ { "SEPARATOR", SYM(SEPARATOR_SYM),0,0},
{ "SERIAL", SYM(SERIAL_SYM),0,0},
{ "SERIALIZABLE", SYM(SERIALIZABLE_SYM),0,0},
{ "SESSION", SYM(SESSION_SYM),0,0},
{ "SET", SYM(SET),0,0},
- { "SIGNED", SYM(SIGNED_SYM),0,0},
- { "SIMPLE", SYM(SIMPLE_SYM),0,0},
{ "SHARE", SYM(SHARE_SYM),0,0},
{ "SHOW", SYM(SHOW),0,0},
{ "SHUTDOWN", SYM(SHUTDOWN),0,0},
+ { "SIGNED", SYM(SIGNED_SYM),0,0},
+ { "SIMPLE", SYM(SIMPLE_SYM),0,0},
{ "SLAVE", SYM(SLAVE),0,0},
{ "SMALLINT", SYM(SMALLINT),0,0},
{ "SOME", SYM(ANY_SYM),0,0},
{ "SONAME", SYM(UDF_SONAME_SYM),0,0},
+ { "SOUNDS", SYM(SOUNDS_SYM),0,0},
{ "SPATIAL", SYM(SPATIAL_SYM),0,0},
{ "SQL_BIG_RESULT", SYM(SQL_BIG_RESULT),0,0},
{ "SQL_BUFFER_RESULT", SYM(SQL_BUFFER_RESULT),0,0},
@@ -372,14 +374,13 @@ static SYMBOL symbols[] = {
{ "SQL_NO_CACHE", SYM(SQL_NO_CACHE_SYM), 0, 0},
{ "SQL_SMALL_RESULT", SYM(SQL_SMALL_RESULT),0,0},
{ "SQL_THREAD", SYM(SQL_THREAD),0,0},
- { "SOUNDS", SYM(SOUNDS_SYM),0,0},
{ "SSL", SYM(SSL_SYM),0,0},
- { "STRAIGHT_JOIN", SYM(STRAIGHT_JOIN),0,0},
{ "START", SYM(START_SYM),0,0},
{ "STARTING", SYM(STARTING),0,0},
{ "STATUS", SYM(STATUS_SYM),0,0},
- { "STRING", SYM(STRING_SYM),0,0},
{ "STOP", SYM(STOP_SYM),0,0},
+ { "STRAIGHT_JOIN", SYM(STRAIGHT_JOIN),0,0},
+ { "STRING", SYM(STRING_SYM),0,0},
{ "STRIPED", SYM(RAID_STRIPED_SYM),0,0},
{ "SUBJECT", SYM(SUBJECT_SYM),0,0},
{ "SUPER", SYM(SUPER_SYM),0,0},
@@ -393,13 +394,13 @@ static SYMBOL symbols[] = {
{ "TIME", SYM(TIME_SYM),0,0},
{ "TIMESTAMP", SYM(TIMESTAMP),0,0},
{ "TINYBLOB", SYM(TINYBLOB),0,0},
- { "TINYTEXT", SYM(TINYTEXT),0,0},
{ "TINYINT", SYM(TINYINT),0,0},
+ { "TINYTEXT", SYM(TINYTEXT),0,0},
+ { "TO", SYM(TO_SYM),0,0},
{ "TRAILING", SYM(TRAILING),0,0},
{ "TRANSACTION", SYM(TRANSACTION_SYM),0,0},
- { "TRUNCATE", SYM(TRUNCATE_SYM),0,0},
{ "TRUE", SYM(TRUE_SYM),0,0},
- { "TO", SYM(TO_SYM),0,0},
+ { "TRUNCATE", SYM(TRUNCATE_SYM),0,0},
{ "TYPE", SYM(TYPE_SYM),0,0},
{ "TYPES", SYM(TYPES_SYM),0,0},
{ "UNCOMMITTED", SYM(UNCOMMITTED_SYM),0,0},
@@ -408,32 +409,32 @@ static SYMBOL symbols[] = {
{ "UNIQUE", SYM(UNIQUE_SYM),0,0},
{ "UNLOCK", SYM(UNLOCK_SYM),0,0},
{ "UNSIGNED", SYM(UNSIGNED),0,0},
+ { "UNTIL", SYM(UNTIL_SYM),0,0},
+ { "UPDATE", SYM(UPDATE_SYM),0,0},
+ { "USAGE", SYM(USAGE),0,0},
{ "USE", SYM(USE_SYM),0,0},
- { "USE_FRM", SYM(USE_FRM),0,0},
{ "USER", SYM(USER),0,0},
- { "UNTIL", SYM(UNTIL_SYM),0,0},
+ { "USER_RESOURCES", SYM(RESOURCES),0,0},
+ { "USE_FRM", SYM(USE_FRM),0,0},
{ "USING", SYM(USING),0,0},
{ "UTC_DATE", SYM(UTC_DATE_SYM),0,0},
{ "UTC_TIME", SYM(UTC_TIME_SYM),0,0},
{ "UTC_TIMESTAMP", SYM(UTC_TIMESTAMP_SYM),0,0},
- { "UPDATE", SYM(UPDATE_SYM),0,0},
- { "USAGE", SYM(USAGE),0,0},
{ "VALUE", SYM(VALUE_SYM),0,0},
{ "VALUES", SYM(VALUES),0,0},
+ { "VARBINARY", SYM(VARBINARY),0,0},
{ "VARCHAR", SYM(VARCHAR),0,0},
{ "VARCHARACTER", SYM(VARCHAR),0,0},
{ "VARIABLES", SYM(VARIABLES),0,0},
{ "VARYING", SYM(VARYING),0,0},
- { "VARBINARY", SYM(VARBINARY),0,0},
{ "WARNINGS", SYM(WARNINGS),0,0},
+ { "WHEN", SYM(WHEN_SYM),0,0},
+ { "WHERE", SYM(WHERE),0,0},
{ "WITH", SYM(WITH),0,0},
{ "WORK", SYM(WORK_SYM),0,0},
{ "WRITE", SYM(WRITE_SYM),0,0},
- { "WHEN", SYM(WHEN_SYM),0,0},
- { "WHERE", SYM(WHERE),0,0},
- { "NO_WRITE_TO_BINLOG", SYM(NO_WRITE_TO_BINLOG),0,0},
- { "XOR", SYM(XOR),0,0},
{ "X509", SYM(X509_SYM),0,0},
+ { "XOR", SYM(XOR),0,0},
{ "YEAR", SYM(YEAR_SYM),0,0},
{ "YEAR_MONTH", SYM(YEAR_MONTH_SYM),0,0},
{ "ZEROFILL", SYM(ZEROFILL),0,0},
diff --git a/sql/share/czech/errmsg.txt b/sql/share/czech/errmsg.txt
index a77e6e4333b..d6a0c51bdff 100644
--- a/sql/share/czech/errmsg.txt
+++ b/sql/share/czech/errmsg.txt
@@ -298,3 +298,4 @@ character-set=latin2
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/danish/errmsg.txt b/sql/share/danish/errmsg.txt
index 1e04ef7340b..1d889e6258e 100644
--- a/sql/share/danish/errmsg.txt
+++ b/sql/share/danish/errmsg.txt
@@ -292,3 +292,4 @@ character-set=latin1
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/dutch/errmsg.txt b/sql/share/dutch/errmsg.txt
index e9b0ac12e29..4798ea55b42 100644
--- a/sql/share/dutch/errmsg.txt
+++ b/sql/share/dutch/errmsg.txt
@@ -300,3 +300,4 @@ character-set=latin1
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/english/errmsg.txt b/sql/share/english/errmsg.txt
index 233f57cec28..920ec433da0 100644
--- a/sql/share/english/errmsg.txt
+++ b/sql/share/english/errmsg.txt
@@ -289,3 +289,4 @@ character-set=latin1
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/estonian/errmsg.txt b/sql/share/estonian/errmsg.txt
index fa6201f9097..0c9b5c96308 100644
--- a/sql/share/estonian/errmsg.txt
+++ b/sql/share/estonian/errmsg.txt
@@ -294,3 +294,4 @@ character-set=latin7
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/french/errmsg.txt b/sql/share/french/errmsg.txt
index dbc4cfeae5e..a9d3f9b049a 100644
--- a/sql/share/french/errmsg.txt
+++ b/sql/share/french/errmsg.txt
@@ -289,3 +289,4 @@ character-set=latin1
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/german/errmsg.txt b/sql/share/german/errmsg.txt
index 1fa25990fc9..74f50289d86 100644
--- a/sql/share/german/errmsg.txt
+++ b/sql/share/german/errmsg.txt
@@ -301,3 +301,4 @@ character-set=latin1
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/greek/errmsg.txt b/sql/share/greek/errmsg.txt
index 4d8a6d44099..5dfd1173467 100644
--- a/sql/share/greek/errmsg.txt
+++ b/sql/share/greek/errmsg.txt
@@ -289,3 +289,4 @@ character-set=greek
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/hungarian/errmsg.txt b/sql/share/hungarian/errmsg.txt
index 3a6e309435c..d454c51caba 100644
--- a/sql/share/hungarian/errmsg.txt
+++ b/sql/share/hungarian/errmsg.txt
@@ -291,3 +291,4 @@ character-set=latin2
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/italian/errmsg.txt b/sql/share/italian/errmsg.txt
index fcc3379e138..18715b4930b 100644
--- a/sql/share/italian/errmsg.txt
+++ b/sql/share/italian/errmsg.txt
@@ -289,3 +289,4 @@ character-set=latin1
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/japanese/errmsg.txt b/sql/share/japanese/errmsg.txt
index c4bd5dab028..b034c8f657f 100644
--- a/sql/share/japanese/errmsg.txt
+++ b/sql/share/japanese/errmsg.txt
@@ -291,3 +291,4 @@ character-set=ujis
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/korean/errmsg.txt b/sql/share/korean/errmsg.txt
index 14112e5b6bd..df15d77c075 100644
--- a/sql/share/korean/errmsg.txt
+++ b/sql/share/korean/errmsg.txt
@@ -289,3 +289,4 @@ character-set=euckr
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/norwegian-ny/errmsg.txt b/sql/share/norwegian-ny/errmsg.txt
index 9b0274965a7..b46a52ae2de 100644
--- a/sql/share/norwegian-ny/errmsg.txt
+++ b/sql/share/norwegian-ny/errmsg.txt
@@ -291,3 +291,4 @@ character-set=latin1
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/norwegian/errmsg.txt b/sql/share/norwegian/errmsg.txt
index 906e4702cab..3727e49d2ad 100644
--- a/sql/share/norwegian/errmsg.txt
+++ b/sql/share/norwegian/errmsg.txt
@@ -291,3 +291,4 @@ character-set=latin1
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/polish/errmsg.txt b/sql/share/polish/errmsg.txt
index c9229d0c522..1cb5b384e4b 100644
--- a/sql/share/polish/errmsg.txt
+++ b/sql/share/polish/errmsg.txt
@@ -293,3 +293,4 @@ character-set=latin2
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/portuguese/errmsg.txt b/sql/share/portuguese/errmsg.txt
index 9ff6325f935..ad845aac932 100644
--- a/sql/share/portuguese/errmsg.txt
+++ b/sql/share/portuguese/errmsg.txt
@@ -290,3 +290,4 @@ character-set=latin1
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/romanian/errmsg.txt b/sql/share/romanian/errmsg.txt
index 34dd64daa2d..519f86e284c 100644
--- a/sql/share/romanian/errmsg.txt
+++ b/sql/share/romanian/errmsg.txt
@@ -293,3 +293,4 @@ character-set=latin2
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/russian/errmsg.txt b/sql/share/russian/errmsg.txt
index 6f22d1b87fd..ae186929898 100644
--- a/sql/share/russian/errmsg.txt
+++ b/sql/share/russian/errmsg.txt
@@ -291,3 +291,4 @@ character-set=koi8r
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/serbian/errmsg.txt b/sql/share/serbian/errmsg.txt
index 98308190587..0719b88bec0 100644
--- a/sql/share/serbian/errmsg.txt
+++ b/sql/share/serbian/errmsg.txt
@@ -284,3 +284,4 @@ character-set=cp1250
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/slovak/errmsg.txt b/sql/share/slovak/errmsg.txt
index 5decce35dfd..cb5957fb892 100644
--- a/sql/share/slovak/errmsg.txt
+++ b/sql/share/slovak/errmsg.txt
@@ -297,3 +297,4 @@ character-set=latin2
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/spanish/errmsg.txt b/sql/share/spanish/errmsg.txt
index 00f31d351df..0e95efff5aa 100644
--- a/sql/share/spanish/errmsg.txt
+++ b/sql/share/spanish/errmsg.txt
@@ -291,3 +291,4 @@ character-set=latin1
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/swedish/errmsg.txt b/sql/share/swedish/errmsg.txt
index a53b6e4df3a..5edf41e0202 100644
--- a/sql/share/swedish/errmsg.txt
+++ b/sql/share/swedish/errmsg.txt
@@ -289,3 +289,4 @@ character-set=latin1
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/share/ukrainian/errmsg.txt b/sql/share/ukrainian/errmsg.txt
index e3a496831a2..8dbc2b582c9 100644
--- a/sql/share/ukrainian/errmsg.txt
+++ b/sql/share/ukrainian/errmsg.txt
@@ -294,3 +294,4 @@ character-set=koi8u
"Unknown key cache '%-.100s'",
"MySQL is started in --skip-name-resolve mode. You need to restart it without this switch for this grant to work",
"Unknown table engine '%s'",
+"'%s' is deprecated. Use '%s' instead.",
diff --git a/sql/sql_show.cc b/sql/sql_show.cc
index ac193736be5..2ef7262f45c 100644
--- a/sql/sql_show.cc
+++ b/sql/sql_show.cc
@@ -1217,7 +1217,7 @@ store_create_info(THD *thd, TABLE *table, String *packet)
packet->append("\n)", 2);
if (!(thd->variables.sql_mode & MODE_NO_TABLE_OPTIONS) && !foreign_db_mode)
{
- packet->append(" TYPE=", 6);
+ packet->append(" ENGINE=", 8);
packet->append(file->table_type());
if (table->table_charset &&
diff --git a/sql/sql_yacc.yy b/sql/sql_yacc.yy
index 0d22df1be0f..0aa7e4c2738 100644
--- a/sql/sql_yacc.yy
+++ b/sql/sql_yacc.yy
@@ -42,6 +42,11 @@ int yylex(void *yylval, void *yythd);
#define yyoverflow(A,B,C,D,E,F) if (my_yyoverflow((B),(D),(int*) (F))) { yyerror((char*) (A)); return 2; }
+#define WARN_DEPRECATED(A,B) \
+ push_warning_printf(((THD *)yythd), MYSQL_ERROR::WARN_LEVEL_WARN, \
+ ER_WARN_DEPRECATED_SYNTAX, \
+ ER(ER_WARN_DEPRECATED_SYNTAX), (A), (B));
+
inline Item *or_or_concat(THD *thd, Item* A, Item* B)
{
return (thd->variables.sql_mode & MODE_PIPES_AS_CONCAT ?
@@ -467,6 +472,7 @@ bool my_yyoverflow(short **a, YYSTYPE **b,int *yystacksize);
%token ELSE
%token ELT_FUNC
%token ENCODE_SYM
+%token ENGINE_SYM
%token ENCRYPT
%token EXPORT_SET
%token EXTRACT_SYM
@@ -1067,7 +1073,8 @@ create_table_options:
| create_table_option ',' create_table_options;
create_table_option:
- TYPE_SYM opt_equal table_types { Lex->create_info.db_type= $3; }
+ ENGINE_SYM opt_equal table_types { Lex->create_info.db_type= $3; }
+ | TYPE_SYM opt_equal table_types { Lex->create_info.db_type= $3; WARN_DEPRECATED("TYPE=database_engine","ENGINE=database_engine"); }
| MAX_ROWS opt_equal ulonglong_num { Lex->create_info.max_rows= $3; Lex->create_info.used_fields|= HA_CREATE_USED_MAX_ROWS;}
| MIN_ROWS opt_equal ulonglong_num { Lex->create_info.min_rows= $3; Lex->create_info.used_fields|= HA_CREATE_USED_MIN_ROWS;}
| AVG_ROW_LENGTH opt_equal ULONG_NUM { Lex->create_info.avg_row_length=$3; Lex->create_info.used_fields|= HA_CREATE_USED_AVG_ROW_LENGTH;}
@@ -3963,6 +3970,9 @@ show_param:
lex->select_lex.db= $3;
lex->select_lex.options= 0;
}
+ | ENGINE_SYM table_types
+ { Lex->create_info.db_type= $2; }
+ show_engine_param
| opt_full COLUMNS from_or_in table_ident opt_db wild
{
Lex->sql_command= SQLCOM_SHOW_FIELDS;
@@ -4028,7 +4038,7 @@ show_param:
| STATUS_SYM wild
{ Lex->sql_command= SQLCOM_SHOW_STATUS; }
| INNOBASE_SYM STATUS_SYM
- { Lex->sql_command = SQLCOM_SHOW_INNODB_STATUS;}
+ { Lex->sql_command = SQLCOM_SHOW_INNODB_STATUS; WARN_DEPRECATED("SHOW INNODB STATUS", "SHOW ENGINE INNODB STATUS"); }
| opt_full PROCESSLIST_SYM
{ Lex->sql_command= SQLCOM_SHOW_PROCESSLIST;}
| opt_var_type VARIABLES wild
@@ -4042,9 +4052,9 @@ show_param:
| COLLATION_SYM wild
{ Lex->sql_command= SQLCOM_SHOW_COLLATIONS; }
| BERKELEY_DB_SYM LOGS_SYM
- { Lex->sql_command= SQLCOM_SHOW_LOGS; }
+ { Lex->sql_command= SQLCOM_SHOW_LOGS; WARN_DEPRECATED("SHOW BDB LOGS", "SHOW ENGINE BDB LOGS"); }
| LOGS_SYM
- { Lex->sql_command= SQLCOM_SHOW_LOGS; }
+ { Lex->sql_command= SQLCOM_SHOW_LOGS; WARN_DEPRECATED("SHOW LOGS", "SHOW ENGINE BDB LOGS"); }
| GRANTS FOR_SYM user
{
LEX *lex=Lex;
@@ -4073,6 +4083,30 @@ show_param:
Lex->sql_command = SQLCOM_SHOW_SLAVE_STAT;
};
+show_engine_param:
+ STATUS_SYM
+ {
+ switch (Lex->create_info.db_type) {
+ case DB_TYPE_INNODB:
+ Lex->sql_command = SQLCOM_SHOW_INNODB_STATUS;
+ break;
+ default:
+ net_printf(YYTHD, ER_NOT_SUPPORTED_YET, "STATUS");
+ YYABORT;
+ }
+ }
+ | LOGS_SYM
+ {
+ switch (Lex->create_info.db_type) {
+ case DB_TYPE_BERKELEY_DB:
+ Lex->sql_command = SQLCOM_SHOW_LOGS;
+ break;
+ default:
+ net_printf(YYTHD, ER_NOT_SUPPORTED_YET, "LOGS");
+ YYABORT;
+ }
+ };
+
master_or_binary:
MASTER_SYM
| BINARY;
@@ -4617,6 +4651,7 @@ keyword:
| DYNAMIC_SYM {}
| END {}
| ENUM {}
+ | ENGINE_SYM {}
| ERRORS {}
| ESCAPE_SYM {}
| EVENTS_SYM {}