1 #### suite/funcs_1/datadict/datadict_load.inc
3 # The sub testcases are nearly independend. That is the reason why we do not
4 # want to abort after the first error.
5 --disable_abort_on_error
7 ################################################################################
9 # prepare variables for --replace_result
11 ################################################################################
14 # ------------------------------------------------------------------------------
15 # Get the size of ONE known colum and check the size against some values to
16 # be able to use the correct --replace_result statement. Using this only the
17 # one pair of 'wrong' values is replaced and not all occurrencies of all
18 # possible pairs of values. See bug #12777 for details.
19 SELECT character_maximum_length INTO @CML
20 FROM information_schema.columns
21 WHERE table_schema =
'information_schema'
23 AND column_name =
'table_catalog';
25 let $bug_12777_0512= `SELECT @CML = 512`;
26 let $bug_12777_1023= `SELECT @CML = 1023`;
27 let $bug_12777_1024= `SELECT @CML = 1024`;
28 let $bug_12777_2048= `SELECT @CML = 2048`;
29 # 4096 is the value used in the .results
30 let $bug_12777_4095= `SELECT @CML = 4095`;
34 # enable this for debugging only, but NOT in a pushed version, as then the
35 # result changes from OS to OS ...
36 eval SELECT @CML AS
'CML',
37 $bug_12777_0512 AS
'512',
38 $bug_12777_1023 AS
'1023',
39 $bug_12777_1024 AS
'1024',
40 $bug_12777_2048 AS
'2048',
41 $bug_12777_4095 AS
'4095';
44 # ------------------------------------------------------------------------------
45 # prepare a variable to be able to suppress machine dependant diffs
46 # this can be used in: --replace_result $SERVER_NAME <SERVER_NAME>
47 # let $SERVER_NAME= `SELECT DISTINCT host FROM mysql.user WHERE host LIKE "%\%" AND host NOT In ("localhost", "127.0.0.1", "%")`;
48 let $SERVER_NAME= `SELECT DISTINCT host FROM mysql.user WHERE host NOT In (
"localhost",
"127.0.0.1",
"%")`;
51 ################################################################################
56 # this was part of the 4 files $<engine>_datadict.test, but it has been moved
57 # here to have only one place where all preparation for the test is done.
59 ################################################################################
61 eval SET @ENGINE_INNODB = IF(
'$engine_type' =
'innodb', 1, 0);
62 eval SET @ENGINE_MEMORY = IF(
'$engine_type' =
'memory', 1, 0);
63 eval SET @ENGINE_MYISAM = IF(
'$engine_type' =
'myisam', 1, 0);
64 eval SET @ENGINE_NDB = IF(
'$engine_type' =
'ndb', 1, 0);
67 let $engine_myisam= `SELECT @ENGINE_MYISAM = 1`;
68 let $engine_innodb= `SELECT @ENGINE_INNODB = 1`;
69 let $engine_memory= `SELECT @ENGINE_MEMORY = 1`;
70 let $engine_ndb= `SELECT @ENGINE_NDB = 1`;
71 # Note: The NDB variant with their own tb1 - tb4 tables is not ready for use.
75 DROP DATABASE IF EXISTS test1;
77 CREATE DATABASE test1;
82 --source suite/funcs_1/include/innodb_tb1.inc
83 --source suite/funcs_1/include/innodb_tb2.inc
84 --source suite/funcs_1/include/innodb_tb3.inc
85 --source suite/funcs_1/include/innodb_tb4.inc
87 --source suite/funcs_1/include/innodb_tb2.inc
92 --source suite/funcs_1/include/memory_tb1.inc
93 --source suite/funcs_1/include/memory_tb2.inc
94 --source suite/funcs_1/include/memory_tb3.inc
95 --source suite/funcs_1/include/memory_tb4.inc
97 --source suite/funcs_1/include/memory_tb2.inc
102 --source suite/funcs_1/include/myisam_tb1.inc
103 --source suite/funcs_1/include/myisam_tb2.inc
104 --source suite/funcs_1/include/myisam_tb3.inc
105 --source suite/funcs_1/include/myisam_tb4.inc
107 --source suite/funcs_1/include/myisam_tb2.inc
112 --source suite/funcs_1/include/ndb_tb1.inc
113 --source suite/funcs_1/include/ndb_tb2.inc
114 --source suite/funcs_1/include/ndb_tb3.inc
115 --source suite/funcs_1/include/ndb_tb4.inc
117 --source suite/funcs_1/include/ndb_tb2.inc
121 --source suite/funcs_1/include/sp_tb.inc