mirror of
https://github.com/MariaDB/server.git
synced 2025-11-21 06:21:35 +03:00
testsuite funcs_1
1. Fix the following bugs
Bug#30440 "datadict" tests (all engines) fail: Character sets depend on configuration
Solution: Test variants charset_collation_* adjusted to different builds
Bug#32603 "datadict" tests (all engines) fail in "community" tree: "PROFILING" table
Solution: Excluding "PROFILING" table from queries
Bug#33654 "slow log" is missing a line
Solution: Unify the content of the fields TABLES.TABLE_ROWS and
STATISTICS.CARDINALITY within result sets
Bug#34532 Some funcs_1 tests do not clean up at end of testing
Solution: DROP objects/reset global server variables modified during testing
+ let tests missing implementation end before loading of tables
Bug#31421 funcs_1: ndb__datadict fails, discrepancy between scripts and expected results
Solution: Cut <engine>__datadict tests into smaller tests + generate new results.
Bug#33599 INFORMATION_SCHEMA.STATISTICS got a new column INDEX_COMMENT: tests fail (2)
Generation of new results during post merge fix
Bug#33600 CHARACTER_OCTET_LENGTH is now CHARACTER_MAXIMUM_LENGTH * 4
Generation of new results during post merge fix
Bug#33631 Platform-specific replace of CHARACTER_MAXIMUM_LENGTH broken by 4-byte encoding
Generation of new results during post merge fix
+ removal of platform-specific replace routine (no more needed)
2. Restructure the tests
- Test not more than one INFORMATION_SCHEMA view per testscript
- Separate tests of I_S view layout+functionality from content related to the
all time existing databases "information_schema", "mysql" and "test"
- Avoid storage engine related variants of tests which are not sensible to
storage engines at all.
3. Reimplement or add some subtests + cleanup
There is a some probability that even the reviewed changeset
- does not fix all bugs from above or
- contains new bugs which show up on some platforms <> Linux or on one of
the various build types
4. The changeset contains fixes according to
- one code review
- minor bugs within testing code found after code review (accepted by reviewer)
- problems found during tests with 5.0.56 in build environment
mysql-test/suite/funcs_1/t/innodb_storedproc_02.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/innodb_storedproc_03.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/innodb_storedproc_06.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/innodb_storedproc_07.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/innodb_storedproc_08.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/innodb_storedproc_10.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/memory_storedproc_02.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/memory_storedproc_03.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/memory_storedproc_06.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/memory_storedproc_07.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/memory_storedproc_08.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/memory_storedproc_10.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/myisam_storedproc_02.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/myisam_storedproc_03.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/myisam_storedproc_06.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/myisam_storedproc_07.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/myisam_storedproc_08.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/t/myisam_storedproc_10.test:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/storedproc/storedproc_02.inc:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/storedproc/storedproc_03.inc:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/storedproc/storedproc_06.inc:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/storedproc/storedproc_07.inc:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/storedproc/storedproc_08.inc:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/storedproc/storedproc_08_show.inc:
Change mode to -rw-rw-r--
mysql-test/suite/funcs_1/storedproc/storedproc_10.inc:
Change mode to -rw-rw-r--
BitKeeper/deleted/.del-innodb__load.test:
Delete: mysql-test/suite/funcs_1/t/innodb__load.test
BitKeeper/deleted/.del-innodb__load.result:
Delete: mysql-test/suite/funcs_1/r/innodb__load.result
BitKeeper/deleted/.del-myisam__load.test:
Delete: mysql-test/suite/funcs_1/t/myisam__load.test
BitKeeper/deleted/.del-memory__load.test:
Delete: mysql-test/suite/funcs_1/t/memory__load.test
BitKeeper/deleted/.del-memory__load.result:
Delete: mysql-test/suite/funcs_1/r/memory__load.result
BitKeeper/deleted/.del-myisam__load.result:
Delete: mysql-test/suite/funcs_1/r/myisam__load.result
BitKeeper/deleted/.del-create_database.inc:
Delete: mysql-test/suite/funcs_1/include/create_database.inc
BitKeeper/deleted/.del-create_user_lowest_priv.inc:
Delete: mysql-test/suite/funcs_1/include/create_user_lowest_priv.inc
BitKeeper/deleted/.del-create_user_no_super.inc:
Delete: mysql-test/suite/funcs_1/include/create_user_no_super.inc
BitKeeper/deleted/.del-datadict_help_tables_build.result:
Delete: mysql-test/suite/funcs_1/r/datadict_help_tables_build.result
BitKeeper/deleted/.del-datadict_help_tables_build.test:
Delete: mysql-test/suite/funcs_1/t/datadict_help_tables_build.test
BitKeeper/deleted/.del-datadict_help_tables_dev.result:
Delete: mysql-test/suite/funcs_1/r/datadict_help_tables_dev.result
BitKeeper/deleted/.del-datadict_help_tables_dev.test:
Delete: mysql-test/suite/funcs_1/t/datadict_help_tables_dev.test
BitKeeper/deleted/.del-datadict_master.inc:
Delete: mysql-test/suite/funcs_1/datadict/datadict_master.inc
BitKeeper/deleted/.del-datadict_show_schema.inc:
Delete: mysql-test/suite/funcs_1/datadict/datadict_show_schema.inc
BitKeeper/deleted/.del-datadict_show_table_design.inc:
Delete: mysql-test/suite/funcs_1/datadict/datadict_show_table_design.inc
BitKeeper/deleted/.del-datadict_tables.inc:
Delete: mysql-test/suite/funcs_1/datadict/datadict_tables.inc
BitKeeper/deleted/.del-datadict_tables_error.inc:
Delete: mysql-test/suite/funcs_1/datadict/datadict_tables_error.inc
BitKeeper/deleted/.del-datadict_tables_error_1.inc:
Delete: mysql-test/suite/funcs_1/datadict/datadict_tables_error_1.inc
BitKeeper/deleted/.del-datadict_tables_error_1044.inc:
Delete: mysql-test/suite/funcs_1/datadict/datadict_tables_error_1044.inc
BitKeeper/deleted/.del-datadict_tables_error_1049.inc:
Delete: mysql-test/suite/funcs_1/datadict/datadict_tables_error_1049.inc
BitKeeper/deleted/.del-datadict_tables_error_1051.inc:
Delete: mysql-test/suite/funcs_1/datadict/datadict_tables_error_1051.inc
BitKeeper/deleted/.del-datadict_tables_error_1146.inc:
Delete: mysql-test/suite/funcs_1/datadict/datadict_tables_error_1146.inc
BitKeeper/deleted/.del-datadict_tables_error_1288.inc:
Delete: mysql-test/suite/funcs_1/datadict/datadict_tables_error_1288.inc
BitKeeper/deleted/.del-innodb__datadict.result:
Delete: mysql-test/suite/funcs_1/r/innodb__datadict.result
BitKeeper/deleted/.del-innodb__datadict.test:
Delete: mysql-test/suite/funcs_1/t/innodb__datadict.test
BitKeeper/deleted/.del-memory__datadict.test:
Delete: mysql-test/suite/funcs_1/t/memory__datadict.test
BitKeeper/deleted/.del-myisam__datadict.result:
Delete: mysql-test/suite/funcs_1/r/myisam__datadict.result
BitKeeper/deleted/.del-myisam__datadict.test:
Delete: mysql-test/suite/funcs_1/t/myisam__datadict.test
BitKeeper/deleted/.del-memory__datadict.result:
Delete: mysql-test/suite/funcs_1/r/memory__datadict.result
mysql-test/suite/funcs_1/README.txt:
Cleanup in description
mysql-test/suite/funcs_1/include/memory_tb1.inc:
Move setting of variables into the caller scripts
mysql-test/suite/funcs_1/include/memory_tb2.inc:
Move setting of variables into the caller scripts
mysql-test/suite/funcs_1/include/memory_tb3.inc:
Move setting of variables into the caller scripts
mysql-test/suite/funcs_1/include/memory_tb4.inc:
Move setting of variables into the caller scripts
mysql-test/suite/funcs_1/include/sp_tb.inc:
Remove outdated comment
mysql-test/suite/funcs_1/r/innodb_bitdata.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_cursors.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_storedproc_02.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_storedproc_03.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_storedproc_06.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_storedproc_07.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_storedproc_08.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_storedproc_10.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_trig_0102.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_trig_03.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_trig_0407.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_trig_08.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_trig_09.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_trig_1011ext.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_trig_frkey.result:
Updated results
mysql-test/suite/funcs_1/r/innodb_views.result:
Updated results
mysql-test/suite/funcs_1/r/memory_bitdata.result:
Updated results
mysql-test/suite/funcs_1/r/memory_cursors.result:
Updated results
mysql-test/suite/funcs_1/r/memory_storedproc_02.result:
Updated results
mysql-test/suite/funcs_1/r/memory_storedproc_03.result:
Updated results
mysql-test/suite/funcs_1/r/memory_storedproc_06.result:
Updated results
mysql-test/suite/funcs_1/r/memory_storedproc_07.result:
Updated results
mysql-test/suite/funcs_1/r/memory_storedproc_08.result:
Updated results
mysql-test/suite/funcs_1/r/memory_storedproc_10.result:
Updated results
mysql-test/suite/funcs_1/r/memory_trig_0102.result:
Updated results
mysql-test/suite/funcs_1/r/memory_trig_03.result:
Updated results
mysql-test/suite/funcs_1/r/memory_trig_0407.result:
Updated results
mysql-test/suite/funcs_1/r/memory_trig_08.result:
Updated results
mysql-test/suite/funcs_1/r/memory_trig_09.result:
Updated results
mysql-test/suite/funcs_1/r/memory_trig_1011ext.result:
Updated results
mysql-test/suite/funcs_1/r/memory_views.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_bitdata.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_cursors.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_storedproc_02.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_storedproc_03.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_storedproc_06.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_storedproc_07.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_storedproc_08.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_storedproc_10.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_trig_0102.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_trig_03.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_trig_0407.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_trig_08.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_trig_09.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_trig_1011ext.result:
Updated results
mysql-test/suite/funcs_1/r/myisam_views.result:
Updated results
mysql-test/suite/funcs_1/storedproc/load_sp_tb.inc:
Move setting of variables into the caller scripts
mysql-test/suite/funcs_1/t/innodb_bitdata.test:
Cleanup
mysql-test/suite/funcs_1/t/innodb_cursors.test:
Cleanup
mysql-test/suite/funcs_1/t/innodb_trig_0102.test:
Cleanup
mysql-test/suite/funcs_1/t/innodb_trig_03.test:
Cleanup
mysql-test/suite/funcs_1/t/innodb_trig_0407.test:
Cleanup
mysql-test/suite/funcs_1/t/innodb_trig_08.test:
Cleanup
mysql-test/suite/funcs_1/t/innodb_trig_09.test:
Cleanup
mysql-test/suite/funcs_1/t/innodb_trig_1011ext.test:
Cleanup
mysql-test/suite/funcs_1/t/innodb_trig_frkey.test:
Cleanup
mysql-test/suite/funcs_1/t/innodb_views.test:
Cleanup
mysql-test/suite/funcs_1/t/memory_bitdata.test:
Cleanup
mysql-test/suite/funcs_1/t/memory_cursors.test:
Cleanup
mysql-test/suite/funcs_1/t/memory_trig_0102.test:
Cleanup
mysql-test/suite/funcs_1/t/memory_trig_03.test:
Cleanup
mysql-test/suite/funcs_1/t/memory_trig_0407.test:
Cleanup
mysql-test/suite/funcs_1/t/memory_trig_08.test:
Cleanup
mysql-test/suite/funcs_1/t/memory_trig_09.test:
Cleanup
mysql-test/suite/funcs_1/t/memory_trig_1011ext.test:
Cleanup
mysql-test/suite/funcs_1/t/memory_views.test:
Cleanup
mysql-test/suite/funcs_1/t/myisam_bitdata.test:
Cleanup
mysql-test/suite/funcs_1/t/myisam_cursors.test:
Cleanup
mysql-test/suite/funcs_1/t/myisam_trig_0102.test:
Cleanup
mysql-test/suite/funcs_1/t/myisam_trig_03.test:
Cleanup
mysql-test/suite/funcs_1/t/myisam_trig_0407.test:
Cleanup
mysql-test/suite/funcs_1/t/myisam_trig_08.test:
Cleanup
mysql-test/suite/funcs_1/t/myisam_trig_09.test:
Cleanup
mysql-test/suite/funcs_1/t/myisam_trig_1011ext.test:
Cleanup
mysql-test/suite/funcs_1/t/myisam_views.test:
Cleanup
mysql-test/suite/funcs_1/t/charset_collation_1.test:
Check content of information_schema views
character_sets, collations,
collation_character_set_applicability
Build variant 1
mysql-test/suite/funcs_1/t/charset_collation_2.test:
Check content of information_schema views
character_sets, collations,
collation_character_set_applicability
Build variant 2
mysql-test/suite/funcs_1/t/charset_collation_3.test:
Check content of information_schema views
character_sets, collations,
collation_character_set_applicability
Build variant 3
mysql-test/suite/funcs_1/t/is_basics_mixed.test:
Test some basic properties which are independend of the storage
engine used for the creation of tables.
mysql-test/suite/funcs_1/t/is_character_sets.test:
Tests related to functionality of
information_schema.character_sets
mysql-test/suite/funcs_1/t/is_collation_character_set_applicability.test:
Tests related to functionality of
information_schema.collation_character_set_applicability
mysql-test/suite/funcs_1/t/is_collations.test:
Tests related to functionality of
information_schema.collations
mysql-test/suite/funcs_1/t/is_column_privileges.test:
Tests related to functionality of
information_schema.column_privileges
mysql-test/suite/funcs_1/t/is_column_privileges_is_mysql_test.test:
Check content of information_schema.column_privileges about databases
mysql and test
mysql-test/suite/funcs_1/t/is_columns.test:
Tests related to functionality of
information_schema.columns
mysql-test/suite/funcs_1/t/is_columns_innodb.test:
Check content of information_schema.columns when some
tables are preloaded
Variant for InnoDB
mysql-test/suite/funcs_1/t/is_columns_is.test:
Check content of information_schema.columns about schema
information_schema
mysql-test/suite/funcs_1/t/is_columns_memory.test:
Check content of information_schema.columns when some
tables are preloaded
Variant for MEMORY
mysql-test/suite/funcs_1/t/is_columns_myisam.test:
Check content of information_schema.columns when some
tables are preloaded
Variant for MyISAM
mysql-test/suite/funcs_1/t/is_columns_mysql.test:
Check content of information_schema.columns about schema
mysql
mysql-test/suite/funcs_1/t/is_columns_ndb.test:
Check content of information_schema.columns when some
tables are preloaded
Variant for NDB
mysql-test/suite/funcs_1/t/is_key_column_usage.test:
Tests related to functionality of
information_schema.key_column_usage
mysql-test/suite/funcs_1/t/is_routines.test:
Tests related to functionality of
information_schema.routines
mysql-test/suite/funcs_1/t/is_schema_privileges.test:
Tests related to functionality of
information_schema.schema_privileges
mysql-test/suite/funcs_1/t/is_schema_privileges_is_mysql_test.test:
Check content of information_schema.schema_privileges about schemas
information_schema, mysql and test
mysql-test/suite/funcs_1/t/is_schemata.test:
Tests related to functionality of
information_schema.schemata
mysql-test/suite/funcs_1/t/is_schemata_is_mysql_test.test:
Check content of information_schema.schemata about schemas
information_schema, mysql and test
mysql-test/suite/funcs_1/t/is_statistics.test:
Tests related to functionality of
information_schema.statistics
mysql-test/suite/funcs_1/t/is_statistics_is.test:
Check content of information_schema.statistics about schema
information_schema
mysql-test/suite/funcs_1/t/is_statistics_mysql.test:
Check content of information_schema.statistics about schema
mysql
mysql-test/suite/funcs_1/t/is_table_constraints.test:
Tests related to functionality of
information_schema.table_constraints
mysql-test/suite/funcs_1/t/is_table_constraints_is.test:
Check content of information_schema.table_constraints about schema
information_schema
mysql-test/suite/funcs_1/t/is_table_constraints_mysql.test:
Check content of information_schema.table_constraints about schema
mysql
mysql-test/suite/funcs_1/t/is_table_privileges.test:
Tests related to functionality of
information_schema.table_privileges
mysql-test/suite/funcs_1/datadict/basics_mixed1.inc:
Auxiliary script
mysql-test/suite/funcs_1/datadict/basics_mixed2.inc:
Auxiliary script
mysql-test/suite/funcs_1/include/cleanup.inc:
Auxiliary script
mysql-test/suite/funcs_1/r/charset_collation_1.result:
Expected result for new test
mysql-test/suite/funcs_1/r/charset_collation_2.result:
Expected result for new test
mysql-test/suite/funcs_1/r/charset_collation_3.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_basics_mixed.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_character_sets.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_collation_character_set_applicability.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_collations.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_column_privileges.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_column_privileges_is_mysql_test.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_columns.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_columns_innodb.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_columns_is.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_columns_memory.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_columns_myisam.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_columns_mysql.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_columns_ndb.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_key_column_usage.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_routines.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_schema_privileges.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_schema_privileges_is_mysql_test.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_schemata.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_schemata_is_mysql_test.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_statistics.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_statistics_is.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_statistics_mysql.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_table_constraints.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_table_constraints_is.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_table_constraints_mysql.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_table_privileges.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_tables.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_tables_innodb.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_tables_is.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_tables_memory.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_tables_myisam.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_tables_mysql.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_tables_ndb.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_triggers.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_user_privileges.result:
Expected result for new test
mysql-test/suite/funcs_1/r/is_views.result:
Expected result for new test
mysql-test/suite/funcs_1/t/is_tables.test:
Tests related to functionality of
information_schema.tables
mysql-test/suite/funcs_1/t/is_tables_innodb.test:
Check content of information_schema.tables when some
tables are preloaded
Variant for InnoDB
mysql-test/suite/funcs_1/t/is_tables_is.test:
Check content of information_schema.tables about schema
information_schema
mysql-test/suite/funcs_1/t/is_tables_memory.test:
Check content of information_schema.tables when some
tables are preloaded
Variant for MEMORY
mysql-test/suite/funcs_1/t/is_tables_myisam.test:
Check content of information_schema.tables when some
tables are preloaded
Variant for MyISAM
mysql-test/suite/funcs_1/t/is_tables_mysql.test:
Check content of information_schema.tables about schema
mysql
mysql-test/suite/funcs_1/t/is_tables_ndb.test:
Check content of information_schema.tables when some
tables are preloaded
Variant for NDB
mysql-test/suite/funcs_1/t/is_triggers.test:
Tests related to functionality of
information_schema.triggers
mysql-test/suite/funcs_1/t/is_user_privileges.test:
Tests related to functionality of
information_schema.user_privileges
mysql-test/suite/funcs_1/t/is_views.test:
Tests related to functionality of
information_schema.views
mysql-test/suite/funcs_1/datadict/basics_mixed3.inc:
Auxiliary script
mysql-test/suite/funcs_1/datadict/charset_collation.inc:
Auxiliary script
mysql-test/suite/funcs_1/datadict/columns.inc:
Auxiliary script
mysql-test/suite/funcs_1/datadict/datadict.pre:
Auxiliary script
mysql-test/suite/funcs_1/datadict/is_table_query.inc:
Auxiliary script
mysql-test/suite/funcs_1/datadict/statistics.inc:
Auxiliary script
mysql-test/suite/funcs_1/datadict/table_constraints.inc:
Auxiliary script
mysql-test/suite/funcs_1/datadict/tables1.inc:
Auxiliary script
mysql-test/suite/funcs_1/datadict/tables2.inc:
Auxiliary script
359 lines
14 KiB
Plaintext
359 lines
14 KiB
Plaintext
USE test;
|
|
drop table if exists tb3;
|
|
create table tb3 (
|
|
f118 char not null DEFAULT 'a',
|
|
f119 char binary not null DEFAULT b'101',
|
|
f120 char ascii not null DEFAULT b'101',
|
|
f121 char(50),
|
|
f122 char(50),
|
|
f129 binary not null DEFAULT b'101',
|
|
f130 tinyint not null DEFAULT 99,
|
|
f131 tinyint unsigned not null DEFAULT 99,
|
|
f132 tinyint zerofill not null DEFAULT 99,
|
|
f133 tinyint unsigned zerofill not null DEFAULT 99,
|
|
f134 smallint not null DEFAULT 999,
|
|
f135 smallint unsigned not null DEFAULT 999,
|
|
f136 smallint zerofill not null DEFAULT 999,
|
|
f137 smallint unsigned zerofill not null DEFAULT 999,
|
|
f138 mediumint not null DEFAULT 9999,
|
|
f139 mediumint unsigned not null DEFAULT 9999,
|
|
f140 mediumint zerofill not null DEFAULT 9999,
|
|
f141 mediumint unsigned zerofill not null DEFAULT 9999,
|
|
f142 int not null DEFAULT 99999,
|
|
f143 int unsigned not null DEFAULT 99999,
|
|
f144 int zerofill not null DEFAULT 99999,
|
|
f145 int unsigned zerofill not null DEFAULT 99999,
|
|
f146 bigint not null DEFAULT 999999,
|
|
f147 bigint unsigned not null DEFAULT 999999,
|
|
f148 bigint zerofill not null DEFAULT 999999,
|
|
f149 bigint unsigned zerofill not null DEFAULT 999999,
|
|
f150 decimal not null DEFAULT 999.999,
|
|
f151 decimal unsigned not null DEFAULT 999.17,
|
|
f152 decimal zerofill not null DEFAULT 999.999,
|
|
f153 decimal unsigned zerofill,
|
|
f154 decimal (0),
|
|
f155 decimal (64),
|
|
f156 decimal (0) unsigned,
|
|
f157 decimal (64) unsigned,
|
|
f158 decimal (0) zerofill,
|
|
f159 decimal (64) zerofill,
|
|
f160 decimal (0) unsigned zerofill,
|
|
f161 decimal (64) unsigned zerofill,
|
|
f162 decimal (0,0),
|
|
f163 decimal (63,30),
|
|
f164 decimal (0,0) unsigned,
|
|
f165 decimal (63,30) unsigned,
|
|
f166 decimal (0,0) zerofill,
|
|
f167 decimal (63,30) zerofill,
|
|
f168 decimal (0,0) unsigned zerofill,
|
|
f169 decimal (63,30) unsigned zerofill,
|
|
f170 numeric,
|
|
f171 numeric unsigned,
|
|
f172 numeric zerofill,
|
|
f173 numeric unsigned zerofill,
|
|
f174 numeric (0),
|
|
f175 numeric (64)
|
|
) engine = memory;
|
|
Warnings:
|
|
Note 1265 Data truncated for column 'f150' at row 1
|
|
Note 1265 Data truncated for column 'f151' at row 1
|
|
Note 1265 Data truncated for column 'f152' at row 1
|
|
load data infile 'MYSQL_TEST_DIR/suite/funcs_1/data/memory_tb3.txt' into table tb3 ;
|
|
|
|
Testcase: 3.5.1.1:
|
|
------------------
|
|
use test;
|
|
Create trigger trg1_1 BEFORE INSERT
|
|
on tb3 for each row set @test_before = 2, new.f142 = @test_before;
|
|
Create trigger trg1_2 AFTER INSERT
|
|
on tb3 for each row set @test_after = 6;
|
|
Create trigger trg1_4 BEFORE UPDATE
|
|
on tb3 for each row set @test_before = 27,
|
|
new.f142 = @test_before,
|
|
new.f122 = 'Before Update Trigger';
|
|
Create trigger trg1_3 AFTER UPDATE
|
|
on tb3 for each row set @test_after = '15';
|
|
Create trigger trg1_5 BEFORE DELETE on tb3 for each row
|
|
select count(*) into @test_before from tb3 as tr_tb3
|
|
where f121 = 'Test 3.5.1.1';
|
|
Create trigger trg1_6 AFTER DELETE on tb3 for each row
|
|
select count(*) into @test_after from tb3 as tr_tb3
|
|
where f121 = 'Test 3.5.1.1';
|
|
set @test_before = 1;
|
|
set @test_after = 5;
|
|
select @test_before, @test_after;
|
|
@test_before @test_after
|
|
1 5
|
|
Insert into tb3 (f121, f122, f142, f144, f134)
|
|
values ('Test 3.5.1.1', 'First Row', @test_before, @test_after, 1);
|
|
select f121, f122, f142, f144, f134 from tb3 where f121 = 'Test 3.5.1.1';
|
|
f121 f122 f142 f144 f134
|
|
Test 3.5.1.1 First Row 2 0000000005 1
|
|
select @test_before, @test_after;
|
|
@test_before @test_after
|
|
2 6
|
|
set @test_before = 18;
|
|
set @test_after = 8;
|
|
select @test_before, @test_after;
|
|
@test_before @test_after
|
|
18 8
|
|
Update tb3 set tb3.f122 = 'Update',
|
|
tb3.f142 = @test_before,
|
|
tb3.f144 = @test_after
|
|
where tb3.f121 = 'Test 3.5.1.1';
|
|
select f121, f122, f142, f144, f134 from tb3 where f121 = 'Test 3.5.1.1';
|
|
f121 f122 f142 f144 f134
|
|
Test 3.5.1.1 Before Update Trigger 27 0000000008 1
|
|
select @test_before, @test_after;
|
|
@test_before @test_after
|
|
27 15
|
|
Insert into tb3 (f121, f122, f142, f144, f134)
|
|
values ('Test 3.5.1.1', 'Second Row', 5, 6, 2);
|
|
set @test_before = 0;
|
|
set @test_after = 0;
|
|
select f121, f122, f142, f144, f134 from tb3 where f121 = 'Test 3.5.1.1';
|
|
f121 f122 f142 f144 f134
|
|
Test 3.5.1.1 Before Update Trigger 27 0000000008 1
|
|
Test 3.5.1.1 Second Row 2 0000000006 2
|
|
select @test_before, @test_after;
|
|
@test_before @test_after
|
|
0 0
|
|
Delete from tb3 where f121 = 'Test 3.5.1.1' and f134 = 2;
|
|
select f121, f122, f142, f144, f134 from tb3 where f121 = 'Test 3.5.1.1';
|
|
f121 f122 f142 f144 f134
|
|
Test 3.5.1.1 Before Update Trigger 27 0000000008 1
|
|
select @test_before, @test_after;
|
|
@test_before @test_after
|
|
2 1
|
|
drop trigger trg1_1;
|
|
drop trigger trg1_2;
|
|
drop trigger trg1_3;
|
|
drop trigger trg1_4;
|
|
drop trigger trg1_5;
|
|
drop trigger trg1_6;
|
|
delete from tb3 where f121='Test 3.5.1.1';
|
|
|
|
Testcase: 3.5.1.2:
|
|
------------------
|
|
Create trigger trg_1 after insert
|
|
on tb3 for each statement set @x= 1;
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'statement set @x= 1' at line 2
|
|
drop trigger trg_1;
|
|
|
|
Testcase 3.5.1.3:
|
|
-----------------
|
|
CREATE TRIGGER trg3_1 on tb3 BEFORE INSERT for each row set new.f120 = 't';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'on tb3 BEFORE INSERT for each row set new.f120 = 't'' at line 1
|
|
CREATE trg3_2 TRIGGER AFTER INSERT on tb3 for each row set new.f120 = 's';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'trg3_2 TRIGGER AFTER INSERT on tb3 for each row set new.f120 = 's'' at line 1
|
|
CREATE TRIGGER trg3_3 Before DELETE on tb3 set @ret1 = 'test' for each row;
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'set @ret1 = 'test' for each row' at line 1
|
|
CREATE TRIGGER trg3_4 DELETE AFTER on tb3 set @ret1 = 'test' for each row;
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'DELETE AFTER on tb3 set @ret1 = 'test' for each row' at line 1
|
|
CREATE for each row TRIGGER trg3_5 AFTER UPDATE on tb3 set @ret1 = 'test';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'for each row TRIGGER trg3_5 AFTER UPDATE on tb3 set @ret1 = 'test'' at line 1
|
|
drop trigger trg3_1;
|
|
drop trigger trg3_2;
|
|
drop trigger trg3_3;
|
|
drop trigger trg3_4;
|
|
drop trigger trg3_5;
|
|
|
|
Testcase: 3.5.1.5:
|
|
------------------
|
|
CREATE TRIGGER trg4_1 AFTER on tb3 for each row set new.f120 = 'e';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'on tb3 for each row set new.f120 = 'e'' at line 1
|
|
CREATE TRIGGER trg4_2 INSERT on tb3 for each set row new.f120 = 'f';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'INSERT on tb3 for each set row new.f120 = 'f'' at line 1
|
|
CREATE TRIGGER trg4_3 BEFORE INSERT tb3 for each row set new.f120 = 'g';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'tb3 for each row set new.f120 = 'g'' at line 1
|
|
CREATE TRIGGER trg4_4 AFTER UPDATE on tb3 for each set new.f120 = 'g';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'set new.f120 = 'g'' at line 1
|
|
CREATE trg4_5 AFTER DELETE on tb3 for each set new.f120 = 'g';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'trg4_5 AFTER DELETE on tb3 for each set new.f120 = 'g'' at line 1
|
|
CREATE TRIGGER trg4_6 BEFORE DELETE for each row set new.f120 = 'g';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'for each row set new.f120 = 'g'' at line 1
|
|
drop trigger trg4_1;
|
|
drop trigger trg4_2;
|
|
drop trigger trg4_3;
|
|
drop trigger trg4_4;
|
|
drop trigger trg4_5;
|
|
drop trigger trg4_6;
|
|
|
|
Testcase 3.5.1.6: - Need to fix
|
|
-------------------------------
|
|
|
|
Testcase 3.5.1.7: - need to fix
|
|
-------------------------------
|
|
drop table if exists t1;
|
|
Warnings:
|
|
Note 1051 Unknown table 't1'
|
|
create table t1 (f1 int, f2 char(25),f3 int) engine=memory;
|
|
CREATE TRIGGER trg5_1 BEFORE INSERT on test.t1
|
|
for each row set new.f3 = '14';
|
|
CREATE TRIGGER trg_abcdefghijklmnopqrstuvwxyz1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ
|
|
BEFORE UPDATE on test.t1 for each row set new.f3 = '42';
|
|
insert into t1 (f2) values ('insert 3.5.1.7');
|
|
select * from t1;
|
|
f1 f2 f3
|
|
NULL insert 3.5.1.7 14
|
|
update t1 set f2='update 3.5.1.7';
|
|
select * from t1;
|
|
f1 f2 f3
|
|
NULL update 3.5.1.7 42
|
|
select trigger_name from information_schema.triggers;
|
|
trigger_name
|
|
trg5_1
|
|
trg_abcdefghijklmnopqrstuvwxyz1234567890ABCDEFGHIJKLMNOPQRSTUVWX
|
|
drop trigger trg5_1;
|
|
drop trigger trg_abcdefghijklmnopqrstuvwxyz1234567890ABCDEFGHIJKLMNOPQRSTUVWXYZ;
|
|
drop table t1;
|
|
|
|
Testcase 3.5.1.8:
|
|
-----------------
|
|
CREATE TRIGGER trg12* before insert on tb3 for each row set new.f120 = 't';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '* before insert on tb3 for each row set new.f120 = 't'' at line 1
|
|
CREATE TRIGGER trigger before insert on tb3 for each row set new.f120 = 't';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near 'trigger before insert on tb3 for each row set new.f120 = 't'' at line 1
|
|
CREATE TRIGGER 100 before insert on tb3 for each row set new.f120 = 't';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '100 before insert on tb3 for each row set new.f120 = 't'' at line 1
|
|
CREATE TRIGGER @@view before insert on tb3 for each row set new.f120 = 't';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '@@view before insert on tb3 for each row set new.f120 = 't'' at line 1
|
|
CREATE TRIGGER @name before insert on tb3 for each row set new.f120 = 't';
|
|
ERROR 42000: You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '@name before insert on tb3 for each row set new.f120 = 't'' at line 1
|
|
CREATE TRIGGER tb3.trg6_1 BEFORE INSERT on test.tb3
|
|
for each row set new.f120 ='X';
|
|
ERROR HY000: Trigger in wrong schema
|
|
drop database if exists trig_db;
|
|
create database trig_db;
|
|
use trig_db;
|
|
create table t1 (f1 integer) engine = memory;
|
|
use test;
|
|
CREATE TRIGGER trig_db.trg6_2 AFTER INSERT on tb3
|
|
for each row set @ret_trg6_2 = 5;
|
|
ERROR 42S02: Table 'trig_db.tb3' doesn't exist
|
|
use trig_db;
|
|
CREATE TRIGGER trg6_3 AFTER INSERT on test.tb3
|
|
for each row set @ret_trg6_3 = 18;
|
|
ERROR HY000: Trigger in wrong schema
|
|
use test;
|
|
drop database trig_db;
|
|
drop trigger trg6_1;
|
|
drop trigger trg6_3;
|
|
|
|
Testcase 3.5.1.9:(cannot be inplemented at this point)
|
|
------------------------------------------------------
|
|
|
|
Testcase 3.5.1.10:
|
|
------------------
|
|
CREATE TRIGGER trg7_1 BEFORE UPDATE on tb3 for each row set new.f120 ='X';
|
|
CREATE TRIGGER trg7_1 AFTER INSERT on tb3 for each row set @x ='Y';
|
|
ERROR HY000: Trigger already exists
|
|
drop trigger trg7_1;
|
|
|
|
Testcase 3.5.1.?:
|
|
-----------------
|
|
drop table if exists t1;
|
|
drop table if exists t2;
|
|
create table t1 (f1 char(50), f2 integer) engine = memory;
|
|
create table t2 (f1 char(50), f2 integer) engine = memory;
|
|
create trigger trig before insert on t1
|
|
for each row set new.f1 ='trig t1';
|
|
create trigger trig before update on t2
|
|
for each row set new.f1 ='trig t2';
|
|
ERROR HY000: Trigger already exists
|
|
insert into t1 value ('insert to t1',1);
|
|
select * from t1;
|
|
f1 f2
|
|
trig t1 1
|
|
update t1 set f1='update to t1';
|
|
select * from t1;
|
|
f1 f2
|
|
update to t1 1
|
|
insert into t2 value ('insert to t2',2);
|
|
update t2 set f1='update to t1';
|
|
select * from t2;
|
|
f1 f2
|
|
update to t1 2
|
|
drop table t1;
|
|
drop table t2;
|
|
drop trigger trig;
|
|
|
|
Testcase 3.5.1.11:
|
|
------------------
|
|
drop database if exists trig_db1;
|
|
drop database if exists trig_db2;
|
|
drop database if exists trig_db3;
|
|
create database trig_db1;
|
|
create database trig_db2;
|
|
create database trig_db3;
|
|
use trig_db1;
|
|
create table t1 (f1 char(50), f2 integer) engine = memory;
|
|
create trigger trig before insert on t1
|
|
for each row set new.f1 ='trig1', @test_var1='trig1';
|
|
use trig_db2;
|
|
create table t2 (f1 char(50), f2 integer) engine = memory;
|
|
create trigger trig before insert on t2
|
|
for each row set new.f1 ='trig2', @test_var2='trig2';
|
|
use trig_db3;
|
|
create table t1 (f1 char(50), f2 integer) engine = memory;
|
|
create trigger trig before insert on t1
|
|
for each row set new.f1 ='trig3', @test_var3='trig3';
|
|
set @test_var1= '', @test_var2= '', @test_var3= '';
|
|
use trig_db1;
|
|
insert into t1 (f1,f2) values ('insert to db1 t1',1);
|
|
insert into trig_db1.t1 (f1,f2) values ('insert to db1 t1 from db1',2);
|
|
insert into trig_db2.t2 (f1,f2) values ('insert to db2 t2 from db1',3);
|
|
insert into trig_db3.t1 (f1,f2) values ('insert to db3 t1 from db1',4);
|
|
select @test_var1, @test_var2, @test_var3;
|
|
@test_var1 @test_var2 @test_var3
|
|
trig1 trig2 trig3
|
|
select * from t1;
|
|
f1 f2
|
|
trig1 1
|
|
trig1 2
|
|
select * from trig_db2.t2;
|
|
f1 f2
|
|
trig2 3
|
|
select * from trig_db3.t1;
|
|
f1 f2
|
|
trig3 4
|
|
select * from t1;
|
|
f1 f2
|
|
trig1 1
|
|
trig1 2
|
|
use test;
|
|
drop database trig_db1;
|
|
drop database trig_db2;
|
|
drop database trig_db3;
|
|
|
|
Testcase 3.5.2.1/2/3:
|
|
---------------------
|
|
drop database if exists trig_db1;
|
|
drop database if exists trig_db2;
|
|
create database trig_db1;
|
|
create database trig_db2;
|
|
use trig_db1;
|
|
create table t1 (f1 char(50), f2 integer) engine = memory;
|
|
create table trig_db2.t1 (f1 char(50), f2 integer) engine = memory;
|
|
create trigger trig1_b before insert on t1
|
|
for each row set @test_var1='trig1_b';
|
|
create trigger trig_db1.trig1_a after insert on t1
|
|
for each row set @test_var2='trig1_a';
|
|
create trigger trig_db2.trig2 before insert on trig_db2.t1
|
|
for each row set @test_var3='trig2';
|
|
select trigger_schema, trigger_name, event_object_table
|
|
from information_schema.triggers;
|
|
trigger_schema trigger_name event_object_table
|
|
trig_db1 trig1_b t1
|
|
trig_db1 trig1_a t1
|
|
trig_db2 trig2 t1
|
|
set @test_var1= '', @test_var2= '', @test_var3= '';
|
|
insert into t1 (f1,f2) values ('insert to db1 t1 from db1',352);
|
|
insert into trig_db2.t1 (f1,f2) values ('insert to db2 t1 from db1',352);
|
|
select @test_var1, @test_var2, @test_var3;
|
|
@test_var1 @test_var2 @test_var3
|
|
trig1_b trig1_a trig2
|
|
drop database trig_db1;
|
|
drop database trig_db2;
|
|
DROP TABLE test.tb3;
|