Commit 9ce98dd1 authored by Horst Hunger's avatar Horst Hunger

due to merge

parents 6e96dd31 22b70190
...@@ -996,6 +996,22 @@ SELECT * FROM t1; ...@@ -996,6 +996,22 @@ SELECT * FROM t1;
v b v b
abc 5 abc 5
DROP TABLE t1; DROP TABLE t1;
create table t1 (a tinytext character set latin1);
alter table t1 convert to character set utf8;
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` text
) ENGINE=MyISAM DEFAULT CHARSET=utf8
drop table t1;
create table t1 (a mediumtext character set latin1);
alter table t1 convert to character set utf8;
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` longtext
) ENGINE=MyISAM DEFAULT CHARSET=utf8
drop table t1;
End of 5.0 tests End of 5.0 tests
drop table if exists t1, t2, t3; drop table if exists t1, t2, t3;
create table t1 (i int); create table t1 (i int);
......
...@@ -723,6 +723,32 @@ CREATE TABLE IF NOT EXISTS t1 ( ...@@ -723,6 +723,32 @@ CREATE TABLE IF NOT EXISTS t1 (
f1 bit(2) NOT NULL default b'' f1 bit(2) NOT NULL default b''
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci; ) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci;
ERROR 42000: Invalid default value for 'f1' ERROR 42000: Invalid default value for 'f1'
create table t1bit7 (a1 bit(7) not null) engine=MyISAM;
create table t2bit7 (b1 bit(7)) engine=MyISAM;
insert into t1bit7 values (b'1100000');
insert into t1bit7 values (b'1100001');
insert into t1bit7 values (b'1100010');
insert into t2bit7 values (b'1100001');
insert into t2bit7 values (b'1100010');
insert into t2bit7 values (b'1100110');
select bin(a1) from t1bit7, t2bit7 where t1bit7.a1=t2bit7.b1;
bin(a1)
1100001
1100010
drop table t1bit7, t2bit7;
create table t1bit7 (a1 bit(15) not null) engine=MyISAM;
create table t2bit7 (b1 bit(15)) engine=MyISAM;
insert into t1bit7 values (b'110000011111111');
insert into t1bit7 values (b'110000111111111');
insert into t1bit7 values (b'110001011111111');
insert into t2bit7 values (b'110000111111111');
insert into t2bit7 values (b'110001011111111');
insert into t2bit7 values (b'110011011111111');
select bin(a1) from t1bit7, t2bit7 where t1bit7.a1=t2bit7.b1;
bin(a1)
110000111111111
110001011111111
drop table t1bit7, t2bit7;
End of 5.0 tests End of 5.0 tests
create table t1(a bit(7)); create table t1(a bit(7));
insert into t1 values(0x40); insert into t1 values(0x40);
......
# Disabled by hhunger (2008-03-03) due to WL4204 # Disabled by hhunger (2008-03-03) due to WL4204
innodb_charset : Due to bug#20447 innodb_charset : Bug#20447 Problem with prefix keys with contractions and expansions
myisam_charset : Due to bug#20477 myisam_charset : Bug#20447 Problem with prefix keys with contractions and expansions
memory_charset : Due to bug#20447 memory_charset : Bug#20447 Problem with prefix keys with contractions and expansions
ndb_charset : Due to bug#20447 ndb_charset : Bug#20447 Problem with prefix keys with contractions and expansions
...@@ -9,8 +9,7 @@ ...@@ -9,8 +9,7 @@
# Do not use any TAB characters for whitespace. # Do not use any TAB characters for whitespace.
# #
############################################################################## ##############################################################################
partition_03ndb : BUG#16385 2006-03-24 mikael Partitions: crash when updating a range partitioned NDB table
ndb_partition_error2 : HF is not sure if the test can work as internded on all the platforms ndb_partition_error2 : Bug#40989 ndb_partition_error2 needs maintenance
# the below testcase have been reworked to avoid the bug, test contains comment, keep bug open # the below testcase have been reworked to avoid the bug, test contains comment, keep bug open
...@@ -6,7 +6,7 @@ create table t1 (a bit(0), primary key (a)) engine='INNODB' partition by key (a) ...@@ -6,7 +6,7 @@ create table t1 (a bit(0), primary key (a)) engine='INNODB' partition by key (a)
show create table t1; show create table t1;
Table Create Table Table Create Table
t1 CREATE TABLE `t1` ( t1 CREATE TABLE `t1` (
`a` bit(1) NOT NULL DEFAULT '\0', `a` bit(1) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ) ENGINE=InnoDB DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) */ /*!50100 PARTITION BY KEY (a) */
...@@ -18,7 +18,7 @@ partition pa2); ...@@ -18,7 +18,7 @@ partition pa2);
show create table t1; show create table t1;
Table Create Table Table Create Table
t1 CREATE TABLE `t1` ( t1 CREATE TABLE `t1` (
`a` bit(1) NOT NULL DEFAULT '\0', `a` bit(1) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ) ENGINE=InnoDB DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
...@@ -30,7 +30,7 @@ partition by key (a) partitions 2; ...@@ -30,7 +30,7 @@ partition by key (a) partitions 2;
show create table t1; show create table t1;
Table Create Table Table Create Table
t1 CREATE TABLE `t1` ( t1 CREATE TABLE `t1` (
`a` bit(64) NOT NULL DEFAULT '\0\0\0\0\0\0\0\0', `a` bit(64) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ) ENGINE=InnoDB DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
...@@ -58,7 +58,7 @@ partition pa4 max_rows=40 min_rows=2); ...@@ -58,7 +58,7 @@ partition pa4 max_rows=40 min_rows=2);
show create table t1; show create table t1;
Table Create Table Table Create Table
t1 CREATE TABLE `t1` ( t1 CREATE TABLE `t1` (
`a` bit(64) NOT NULL DEFAULT '\0\0\0\0\0\0\0\0', `a` bit(64) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ) ENGINE=InnoDB DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
...@@ -88,7 +88,7 @@ partition by key (a) partitions 4; ...@@ -88,7 +88,7 @@ partition by key (a) partitions 4;
show create table t2; show create table t2;
Table Create Table Table Create Table
t2 CREATE TABLE `t2` ( t2 CREATE TABLE `t2` (
`a` bit(1) NOT NULL DEFAULT '\0', `a` bit(1) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ) ENGINE=InnoDB DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
...@@ -102,7 +102,7 @@ alter table t2 drop primary key; ...@@ -102,7 +102,7 @@ alter table t2 drop primary key;
show create table t2; show create table t2;
Table Create Table Table Create Table
t2 CREATE TABLE `t2` ( t2 CREATE TABLE `t2` (
`a` bit(1) NOT NULL DEFAULT '\0' `a` bit(1) NOT NULL DEFAULT b'0'
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ) ENGINE=InnoDB DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
PARTITIONS 4 */ PARTITIONS 4 */
...@@ -114,7 +114,7 @@ alter table t2 add primary key (a); ...@@ -114,7 +114,7 @@ alter table t2 add primary key (a);
show create table t2; show create table t2;
Table Create Table Table Create Table
t2 CREATE TABLE `t2` ( t2 CREATE TABLE `t2` (
`a` bit(1) NOT NULL DEFAULT '\0', `a` bit(1) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ) ENGINE=InnoDB DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
...@@ -133,7 +133,7 @@ partition pa4 values less than (256)); ...@@ -133,7 +133,7 @@ partition pa4 values less than (256));
show create table t3; show create table t3;
Table Create Table Table Create Table
t3 CREATE TABLE `t3` ( t3 CREATE TABLE `t3` (
`a` bit(8) NOT NULL DEFAULT '\0', `a` bit(8) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ) ENGINE=InnoDB DEFAULT CHARSET=latin1
/*!50100 PARTITION BY RANGE (a) /*!50100 PARTITION BY RANGE (a)
...@@ -416,7 +416,7 @@ partition pa3 values in (17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32)); ...@@ -416,7 +416,7 @@ partition pa3 values in (17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32));
show create table t4; show create table t4;
Table Create Table Table Create Table
t4 CREATE TABLE `t4` ( t4 CREATE TABLE `t4` (
`a` bit(8) NOT NULL DEFAULT '\0', `a` bit(8) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=InnoDB DEFAULT CHARSET=latin1 ) ENGINE=InnoDB DEFAULT CHARSET=latin1
/*!50100 PARTITION BY LIST (a) /*!50100 PARTITION BY LIST (a)
......
...@@ -6,7 +6,7 @@ create table t1 (a bit(0), primary key (a)) engine='MyISAM' partition by key (a) ...@@ -6,7 +6,7 @@ create table t1 (a bit(0), primary key (a)) engine='MyISAM' partition by key (a)
show create table t1; show create table t1;
Table Create Table Table Create Table
t1 CREATE TABLE `t1` ( t1 CREATE TABLE `t1` (
`a` bit(1) NOT NULL DEFAULT '\0', `a` bit(1) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 ) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) */ /*!50100 PARTITION BY KEY (a) */
...@@ -18,7 +18,7 @@ partition pa2); ...@@ -18,7 +18,7 @@ partition pa2);
show create table t1; show create table t1;
Table Create Table Table Create Table
t1 CREATE TABLE `t1` ( t1 CREATE TABLE `t1` (
`a` bit(1) NOT NULL DEFAULT '\0', `a` bit(1) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 ) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
...@@ -30,7 +30,7 @@ partition by key (a) partitions 2; ...@@ -30,7 +30,7 @@ partition by key (a) partitions 2;
show create table t1; show create table t1;
Table Create Table Table Create Table
t1 CREATE TABLE `t1` ( t1 CREATE TABLE `t1` (
`a` bit(64) NOT NULL DEFAULT '\0\0\0\0\0\0\0\0', `a` bit(64) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 ) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
...@@ -58,7 +58,7 @@ partition pa4 max_rows=40 min_rows=2); ...@@ -58,7 +58,7 @@ partition pa4 max_rows=40 min_rows=2);
show create table t1; show create table t1;
Table Create Table Table Create Table
t1 CREATE TABLE `t1` ( t1 CREATE TABLE `t1` (
`a` bit(64) NOT NULL DEFAULT '\0\0\0\0\0\0\0\0', `a` bit(64) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 ) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
...@@ -88,7 +88,7 @@ partition by key (a) partitions 4; ...@@ -88,7 +88,7 @@ partition by key (a) partitions 4;
show create table t2; show create table t2;
Table Create Table Table Create Table
t2 CREATE TABLE `t2` ( t2 CREATE TABLE `t2` (
`a` bit(1) NOT NULL DEFAULT '\0', `a` bit(1) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 ) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
...@@ -102,7 +102,7 @@ alter table t2 drop primary key; ...@@ -102,7 +102,7 @@ alter table t2 drop primary key;
show create table t2; show create table t2;
Table Create Table Table Create Table
t2 CREATE TABLE `t2` ( t2 CREATE TABLE `t2` (
`a` bit(1) NOT NULL DEFAULT '\0' `a` bit(1) NOT NULL DEFAULT b'0'
) ENGINE=MyISAM DEFAULT CHARSET=latin1 ) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
PARTITIONS 4 */ PARTITIONS 4 */
...@@ -114,7 +114,7 @@ alter table t2 add primary key (a); ...@@ -114,7 +114,7 @@ alter table t2 add primary key (a);
show create table t2; show create table t2;
Table Create Table Table Create Table
t2 CREATE TABLE `t2` ( t2 CREATE TABLE `t2` (
`a` bit(1) NOT NULL DEFAULT '\0', `a` bit(1) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 ) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) /*!50100 PARTITION BY KEY (a)
...@@ -133,7 +133,7 @@ partition pa4 values less than (256)); ...@@ -133,7 +133,7 @@ partition pa4 values less than (256));
show create table t3; show create table t3;
Table Create Table Table Create Table
t3 CREATE TABLE `t3` ( t3 CREATE TABLE `t3` (
`a` bit(8) NOT NULL DEFAULT '\0', `a` bit(8) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 ) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY RANGE (a) /*!50100 PARTITION BY RANGE (a)
...@@ -416,7 +416,7 @@ partition pa3 values in (17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32)); ...@@ -416,7 +416,7 @@ partition pa3 values in (17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32));
show create table t4; show create table t4;
Table Create Table Table Create Table
t4 CREATE TABLE `t4` ( t4 CREATE TABLE `t4` (
`a` bit(8) NOT NULL DEFAULT '\0', `a` bit(8) NOT NULL DEFAULT b'0',
PRIMARY KEY (`a`) PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 ) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY LIST (a) /*!50100 PARTITION BY LIST (a)
......
SET @max_row = 20;
create table t1 (a bit(65), primary key (a)) partition by key (a);
ERROR 42000: Display width out of range for column 'a' (max = 64)
create table t1 (a bit(0), primary key (a)) partition by key (a);
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` bit(1) NOT NULL DEFAULT '\0',
PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) */
drop table t1;
create table t1 (a bit(0), primary key (a)) partition by key (a) (
partition pa1 DATA DIRECTORY =
'/tmp' INDEX DIRECTORY =
'/tmp',
partition pa2 DATA DIRECTORY =
'/tmp' INDEX DIRECTORY =
'/tmp');
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` bit(1) NOT NULL DEFAULT '\0',
PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 DATA DIRECTORY='/tmp/' INDEX DIRECTORY='/tmp/'
/*!50100 PARTITION BY KEY (a)
(PARTITION pa1 DATA DIRECTORY = '/tmp' INDEX DIRECTORY = '/tmp' ENGINE = MyISAM,
PARTITION pa2 DATA DIRECTORY = '/tmp' INDEX DIRECTORY = '/tmp' ENGINE = MyISAM) */
drop table t1;
create table t1 (a bit(64), primary key (a)) partition by key (a);
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` bit(64) NOT NULL DEFAULT '\0\0\0\0\0\0\0\0',
PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) */
insert into t1 values
(b'1111111111111111111111111111111111111111111111111111111111111111'),
(b'1000000000000000000000000000000000000000000000000000000000000000'),
(b'0000000000000000000000000000000000000000000000000000000000000001'),
(b'1010101010101010101010101010101010101010101010101010101010101010'),
(b'0101010101010101010101010101010101010101010101010101010101010101');
select hex(a) from t1;
hex(a)
1
5555555555555555
8000000000000000
AAAAAAAAAAAAAAAA
FFFFFFFFFFFFFFFF
drop table t1;
create table t1 (a bit(64), primary key (a)) partition by key (a)(
partition pa1 DATA DIRECTORY =
'/tmp' INDEX DIRECTORY =
'/tmp' max_rows=20 min_rows=2,
partition pa2 DATA DIRECTORY =
'/tmp' INDEX DIRECTORY =
'/tmp' max_rows=30 min_rows=3,
partition pa3 DATA DIRECTORY =
'/tmp' INDEX DIRECTORY =
'/tmp' max_rows=30 min_rows=4,
partition pa4 DATA DIRECTORY =
'/tmp' INDEX DIRECTORY =
'/tmp' max_rows=40 min_rows=2);
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` bit(64) NOT NULL DEFAULT '\0\0\0\0\0\0\0\0',
PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1 DATA DIRECTORY='/tmp/' INDEX DIRECTORY='/tmp/'
/*!50100 PARTITION BY KEY (a)
(PARTITION pa1 MAX_ROWS = 20 MIN_ROWS = 2 DATA DIRECTORY = '/tmp' INDEX DIRECTORY = '/tmp' ENGINE = MyISAM,
PARTITION pa2 MAX_ROWS = 30 MIN_ROWS = 3 DATA DIRECTORY = '/tmp' INDEX DIRECTORY = '/tmp' ENGINE = MyISAM,
PARTITION pa3 MAX_ROWS = 30 MIN_ROWS = 4 DATA DIRECTORY = '/tmp' INDEX DIRECTORY = '/tmp' ENGINE = MyISAM,
PARTITION pa4 MAX_ROWS = 40 MIN_ROWS = 2 DATA DIRECTORY = '/tmp' INDEX DIRECTORY = '/tmp' ENGINE = MyISAM) */
insert into t1 values
(b'1111111111111111111111111111111111111111111111111111111111111111'),
(b'1000000000000000000000000000000000000000000000000000000000000000'),
(b'0000000000000000000000000000000000000000000000000000000000000001'),
(b'1010101010101010101010101010101010101010101010101010101010101010'),
(b'0101010101010101010101010101010101010101010101010101010101010101');
select hex(a) from t1;
hex(a)
1
5555555555555555
8000000000000000
AAAAAAAAAAAAAAAA
FFFFFFFFFFFFFFFF
drop table t1;
create table t1 (a bit, primary key (a)) partition by key (a);
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` bit(1) NOT NULL DEFAULT '\0',
PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) */
insert into t1 values (b'0'), (b'1');
select hex(a) from t1;
hex(a)
0
1
alter table t1 drop primary key;
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` bit(1) NOT NULL DEFAULT '\0'
) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) */
select hex(a) from t1;
hex(a)
0
1
alter table t1 add primary key (a);
show create table t1;
Table Create Table
t1 CREATE TABLE `t1` (
`a` bit(1) NOT NULL DEFAULT '\0',
PRIMARY KEY (`a`)
) ENGINE=MyISAM DEFAULT CHARSET=latin1
/*!50100 PARTITION BY KEY (a) */
select hex(a) from t1;
hex(a)
0
1
drop table t1;
partition_basic_ndb : Bug#19899 Crashing the server partition_basic_ndb : Bug#19899 Crashing the server
# http://dev.mysql.com/doc/refman/5.1/en/mysql-cluster-limitations-syntax.html # http://dev.mysql.com/doc/refman/5.1/en/mysql-cluster-limitations-syntax.html
partition_bit_ndb : NDB does not support bit column in index
partition_sessions : needs system_3_init.inc
partition_syntax_ndb : Bug#36735 Not supported partition_syntax_ndb : Bug#36735 Not supported
partition_value_innodb : Bug#30581 partition_value tests use disallowed CAST() function
partition_value_myisam : Bug#30581 partition_value tests use disallowed CAST() function
partition_value_ndb : Bug#30581 partition_value tests use disallowed CAST() function
################################################################################
# t/partition_bit_ndb.test #
# #
# Purpose: #
# Tests around bit type #
# NDB branch #
# #
#------------------------------------------------------------------------------#
# Original Author: HH #
# Original Date: 2006-08-01 #
# Change Author: #
# Change Date: #
# Change: #
################################################################################
#
# NOTE: PLEASE DO NOT ADD NOT MYISAM SPECIFIC TESTCASES HERE !
# TESTCASES WHICH MUST BE APPLIED TO ALL STORAGE ENGINES MUST BE ADDED IN
# THE SOURCED FILES ONLY.
#
# Please read the README at the end of inc/partition.pre before changing
# any of the variables.
#
#------------------------------------------------------------------------------#
# General not engine specific settings and requirements
##### Options, for debugging support #####
let $debug= 0;
let $with_partitioning= 1;
##### Option, for displaying files #####
let $ls= 1;
##### Number of rows for the INSERT/UPDATE/DELETE/SELECT experiments #####
# on partioned tables
SET @max_row = 20;
# The server must support partitioning.
--source include/have_partition.inc
#------------------------------------------------------------------------------#
# Engine specific settings and requirements
##### Storage engine to be tested
--source include/have_ndb.inc
let $engine= 'NDB';
connection default;
# range, list and hash partitioning in ndb requires new_mode
--disable_query_log
set new=on;
--enable_query_log
##### Assign a big number smaller than the maximum value for partitions #####
# and smaller than the maximum value of SIGNED INTEGER
let $MAX_VALUE= (2147483646);
#------------------------------------------------------------------------------#
# Execute the tests to be applied to all storage engines
--source suite/parts/inc/partition_bit.inc
This diff is collapsed.
...@@ -8,9 +8,9 @@ ...@@ -8,9 +8,9 @@
#------------------------------------------------------------------------------# #------------------------------------------------------------------------------#
# Original Author: mleich # # Original Author: mleich #
# Original Date: 2006-04-11 # # Original Date: 2006-04-11 #
# Change Author: # # Change Author: mleich #
# Change Date: # # Change Date: 2008-12-08 #
# Change: # # Change: Remove test from disabled.def + change test that it gets skipped #
################################################################################ ################################################################################
# #
...@@ -22,6 +22,12 @@ ...@@ -22,6 +22,12 @@
# any of the variables. # any of the variables.
# #
#
# CAST() within the partitioning function si no more supported, but we get
# this functionality probably soon again. Therefor we do not delete this test.
--skip # CAST() in partitioning function is currently not supported.
#------------------------------------------------------------------------------# #------------------------------------------------------------------------------#
# General not engine specific settings and requirements # General not engine specific settings and requirements
......
...@@ -8,9 +8,9 @@ ...@@ -8,9 +8,9 @@
#------------------------------------------------------------------------------# #------------------------------------------------------------------------------#
# Original Author: mleich # # Original Author: mleich #
# Original Date: 2006-04-11 # # Original Date: 2006-04-11 #
# Change Author: # # Change Author: mleich #
# Change Date: # # Change Date: 2008-12-08 #
# Change: # # Change: Remove test from disabled.def + change test that it gets skipped #
################################################################################ ################################################################################
# #
...@@ -22,6 +22,12 @@ ...@@ -22,6 +22,12 @@
# any of the variables. # any of the variables.
# #
#
# CAST() within the partitioning function si no more supported, but we get
# this functionality probably soon again. Therefor we do not delete this test.
--skip # CAST() in partitioning function is currently not supported.
#------------------------------------------------------------------------------# #------------------------------------------------------------------------------#
# General not engine specific settings and requirements # General not engine specific settings and requirements
......
...@@ -8,9 +8,9 @@ ...@@ -8,9 +8,9 @@
#------------------------------------------------------------------------------# #------------------------------------------------------------------------------#
# Original Author: mleich # # Original Author: mleich #
# Original Date: 2006-04-11 # # Original Date: 2006-04-11 #
# Change Author: # # Change Author: mleich #
# Change Date: # # Change Date: 2008-12-08 #
# Change: # # Change: Remove test from disabled.def + change test that it gets skipped #
################################################################################ ################################################################################
# #
...@@ -22,6 +22,12 @@ ...@@ -22,6 +22,12 @@
# any of the variables. # any of the variables.
# #
#
# CAST() within the partitioning function si no more supported, but we get
# this functionality probably soon again. Therefor we do not delete this test.
--skip # CAST() in partitioning function is currently not supported.
#------------------------------------------------------------------------------# #------------------------------------------------------------------------------#
# General not engine specific settings and requirements # General not engine specific settings and requirements
......
...@@ -10,7 +10,7 @@ ...@@ -10,7 +10,7 @@
# #
############################################################################## ##############################################################################
rpl_ndb_circular : Bug#33849 COMMIT event missing in cluster circular replication. rpl_ndb_circular : Bug#41183 rpl_ndb_circular, rpl_ndb_circular_simplex need maintenance, crash
rpl_ndb_circular_simplex : Bug#33849 COMMIT event missing in cluster circular replication. rpl_ndb_circular_simplex : Bug#41183 rpl_ndb_circular, rpl_ndb_circular_simplex need maintenance, crash
# the below testcase have been reworked to avoid the bug, test contains comment, keep bug open # the below testcase have been reworked to avoid the bug, test contains comment, keep bug open
...@@ -751,6 +751,19 @@ ALTER TABLE t1 MODIFY COLUMN v VARCHAR(4); ...@@ -751,6 +751,19 @@ ALTER TABLE t1 MODIFY COLUMN v VARCHAR(4);
SELECT * FROM t1; SELECT * FROM t1;
DROP TABLE t1; DROP TABLE t1;
#
# Bug#31291 ALTER TABLE CONVERT TO CHARACTER SET does not change some data types
#
create table t1 (a tinytext character set latin1);
alter table t1 convert to character set utf8;
show create table t1;
drop table t1;
create table t1 (a mediumtext character set latin1);
alter table t1 convert to character set utf8;
show create table t1;
drop table t1;
--echo End of 5.0 tests --echo End of 5.0 tests
# #
......
...@@ -10,7 +10,6 @@ ...@@ -10,7 +10,6 @@
# #
############################################################################## ##############################################################################
federated_transactions : Bug#29523 Transactions do not work federated_transactions : Bug#29523 Transactions do not work
log_tables : Bug #37798: main.log_tables fails randomly on powermacg5 and windows
slow_query_log_func : Bug #37962: *_func tests containing sleeps/race conditions slow_query_log_func : Bug #37962: *_func tests containing sleeps/race conditions
wait_timeout_func : Bug #41225 joro wait_timeout_func fails wait_timeout_func : Bug #41225 joro wait_timeout_func fails
kill : Bug#37780 2008-12-03 HHunger need some changes to be robust enoiugh for pushbuild. kill : Bug#37780 2008-12-03 HHunger need some changes to be robust enoiugh for pushbuild.
...@@ -367,6 +367,36 @@ CREATE TABLE IF NOT EXISTS t1 ( ...@@ -367,6 +367,36 @@ CREATE TABLE IF NOT EXISTS t1 (
f1 bit(2) NOT NULL default b'' f1 bit(2) NOT NULL default b''
) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci; ) ENGINE=MyISAM DEFAULT CHARSET=latin1 COLLATE=latin1_general_ci;
#
# Bug#31399 Wrong query result when doing join buffering over BIT fields
#
create table t1bit7 (a1 bit(7) not null) engine=MyISAM;
create table t2bit7 (b1 bit(7)) engine=MyISAM;
insert into t1bit7 values (b'1100000');
insert into t1bit7 values (b'1100001');
insert into t1bit7 values (b'1100010');
insert into t2bit7 values (b'1100001');
insert into t2bit7 values (b'1100010');
insert into t2bit7 values (b'1100110');
select bin(a1) from t1bit7, t2bit7 where t1bit7.a1=t2bit7.b1;
drop table t1bit7, t2bit7;
create table t1bit7 (a1 bit(15) not null) engine=MyISAM;
create table t2bit7 (b1 bit(15)) engine=MyISAM;
insert into t1bit7 values (b'110000011111111');
insert into t1bit7 values (b'110000111111111');
insert into t1bit7 values (b'110001011111111');
insert into t2bit7 values (b'110000111111111');
insert into t2bit7 values (b'110001011111111');
insert into t2bit7 values (b'110011011111111');
select bin(a1) from t1bit7, t2bit7 where t1bit7.a1=t2bit7.b1;
drop table t1bit7, t2bit7;
--echo End of 5.0 tests --echo End of 5.0 tests
# #
......
...@@ -13856,6 +13856,7 @@ join_init_cache(THD *thd,JOIN_TAB *tables,uint table_count) ...@@ -13856,6 +13856,7 @@ join_init_cache(THD *thd,JOIN_TAB *tables,uint table_count)
length=0; length=0;
for (i=0 ; i < table_count ; i++) for (i=0 ; i < table_count ; i++)
{ {
bool have_bit_fields= FALSE;
uint null_fields=0,used_fields; uint null_fields=0,used_fields;
Field **f_ptr,*field; Field **f_ptr,*field;
MY_BITMAP *read_set= tables[i].table->read_set; MY_BITMAP *read_set= tables[i].table->read_set;
...@@ -13870,13 +13871,16 @@ join_init_cache(THD *thd,JOIN_TAB *tables,uint table_count) ...@@ -13870,13 +13871,16 @@ join_init_cache(THD *thd,JOIN_TAB *tables,uint table_count)
length+=field->fill_cache_field(copy); length+=field->fill_cache_field(copy);
if (copy->blob_field) if (copy->blob_field)
(*blob_ptr++)=copy; (*blob_ptr++)=copy;
if (field->maybe_null()) if (field->real_maybe_null())
null_fields++; null_fields++;
if (field->type() == MYSQL_TYPE_BIT &&
((Field_bit*)field)->bit_len)
have_bit_fields= TRUE;
copy++; copy++;
} }
} }
/* Copy null bits from table */ /* Copy null bits from table */
if (null_fields && tables[i].table->s->null_fields) if (null_fields || have_bit_fields)
{ /* must copy null bits */ { /* must copy null bits */
copy->str= tables[i].table->null_flags; copy->str= tables[i].table->null_flags;
copy->length= tables[i].table->s->null_bytes; copy->length= tables[i].table->s->null_bytes;
......
...@@ -3114,7 +3114,9 @@ static bool prepare_blob_field(THD *thd, Create_field *sql_field) ...@@ -3114,7 +3114,9 @@ static bool prepare_blob_field(THD *thd, Create_field *sql_field)
if ((sql_field->flags & BLOB_FLAG) && sql_field->length) if ((sql_field->flags & BLOB_FLAG) && sql_field->length)
{ {
if (sql_field->sql_type == MYSQL_TYPE_BLOB) if (sql_field->sql_type == FIELD_TYPE_BLOB ||
sql_field->sql_type == FIELD_TYPE_TINY_BLOB ||
sql_field->sql_type == FIELD_TYPE_MEDIUM_BLOB)
{ {
/* The user has given a length to the blob column */ /* The user has given a length to the blob column */
sql_field->sql_type= get_blob_type_from_length(sql_field->length); sql_field->sql_type= get_blob_type_from_length(sql_field->length);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment