1 ################################################################################
2 # inc/partition_basic.inc #
5 # Basic tests around create partitioned table with/without PRIMARY KEY and #
8 #------------------------------------------------------------------------------#
9 # Original Author: mleich #
10 # Original Date: 2006-03-05 #
14 ################################################################################
15 --enable_abort_on_error
18 --echo #========================================================================
19 --echo #
Check partitioning methods on just created tables
20 --echo # The tables should be defined without/with PRIMARY
KEY and
21 --echo # UNIQUE INDEXes.
22 --echo # Every
test round has
to check
24 --echo # PARTITION BY RANGE/
LIST ... SUBPARTITION BY
HASH/
KEY ...
25 --echo #========================================================================
26 --echo #------------------------------------------------------------------------
27 --echo # 1 Tables without PRIMARY
KEY or UNIQUE INDEXes
28 --echo #------------------------------------------------------------------------
29 --echo # 1.1 The partitioning
function contains one column.
31 --source suite/parts/inc/partition_methods1.inc
33 --echo # 1.2 The partitioning
function contains two columns.
35 --source suite/parts/inc/partition_methods2.inc
37 --echo #------------------------------------------------------------------------
38 --echo # 2 Tables with PRIMARY
KEY and/or UNIQUE INDEXes
39 --echo # The partitioning
function contains one column.
40 --echo #------------------------------------------------------------------------
41 if ($more_pk_ui_tests)
45 --echo # 2.1 PRIMARY
KEY consisting of one column
46 let $unique= , PRIMARY
KEY(f_int1);
47 --source suite/parts/inc/partition_methods1.inc
49 --echo # 2.2 UNIQUE INDEX consisting of one column
50 let $unique= , UNIQUE INDEX uidx1 (f_int1);
51 --source suite/parts/inc/partition_methods1.inc
55 --echo # 2.3 PRIMARY
KEY consisting of two columns
56 let $unique= , PRIMARY
KEY(f_int1,f_int2);
57 --source suite/parts/inc/partition_methods1.inc
58 let $unique= , PRIMARY
KEY(f_int2,f_int1);
59 --source suite/parts/inc/partition_methods1.inc
62 --echo # 2.4 UNIQUE INDEX consisting of two columns
63 let $unique= , UNIQUE INDEX uidx1 (f_int1,f_int2);
64 --source suite/parts/inc/partition_methods1.inc
65 let $unique= , UNIQUE INDEX uidx1 (f_int2,f_int1);
66 --source suite/parts/inc/partition_methods1.inc
69 --echo # 2.5 PRIMARY
KEY + UNIQUE INDEX consisting of two columns
72 let $unique= , UNIQUE INDEX uidx1 (f_int1,f_int2), PRIMARY
KEY(f_int2,f_int1);
73 --source suite/parts/inc/partition_methods1.inc
74 let $unique= , UNIQUE INDEX uidx1 (f_int2,f_int1), PRIMARY
KEY(f_int1,f_int2);
75 --source suite/parts/inc/partition_methods1.inc
77 let $unique= , UNIQUE INDEX uidx1 (f_int1,f_int2), UNIQUE INDEX uidx2 (f_int2,f_int1);
78 --source suite/parts/inc/partition_methods1.inc
80 --echo #------------------------------------------------------------------------
81 --echo # 3 Tables with PRIMARY
KEY and/or UNIQUE INDEXes
82 --echo # The partitioning
function contains two columns.
83 --echo #------------------------------------------------------------------------
85 if ($more_pk_ui_tests)
89 --echo # 3.1 PRIMARY
KEY consisting of two columns
90 let $unique= , PRIMARY
KEY(f_int1,f_int2);
91 --source suite/parts/inc/partition_methods2.inc
93 let $unique= , PRIMARY
KEY(f_int2,f_int1);
94 --source suite/parts/inc/partition_methods2.inc
97 --echo # 3.2 UNIQUE INDEX consisting of two columns
98 let $unique= , UNIQUE INDEX uidx1 (f_int1,f_int2);
99 --source suite/parts/inc/partition_methods2.inc
100 let $unique= , UNIQUE INDEX uidx1 (f_int2,f_int1);
101 --source suite/parts/inc/partition_methods2.inc
104 --echo # 3.3 PRIMARY
KEY and UNIQUE INDEX consisting of two columns
107 let $unique= , UNIQUE INDEX uidx1 (f_int1,f_int2), PRIMARY
KEY(f_int2,f_int1);
108 --source suite/parts/inc/partition_methods2.inc
109 let $unique= , UNIQUE INDEX uidx1 (f_int2,f_int1), PRIMARY
KEY(f_int1,f_int2);
110 --source suite/parts/inc/partition_methods2.inc
112 let $unique= , UNIQUE INDEX uidx1 (f_int1,f_int2), UNIQUE INDEX uidx2 (f_int2,f_int1);
113 --source suite/parts/inc/partition_methods2.inc