Bug #36735 | disable option 'new' can break partitioned ndb tables | ||
---|---|---|---|
Submitted: | 15 May 2008 11:53 | Modified: | 1 Nov 2009 20:12 |
Reporter: | Mattias Jonsson | Email Updates: | |
Status: | Verified | Impact on me: | |
Category: | MySQL Cluster: Cluster (NDB) storage engine | Severity: | S3 (Non-critical) |
Version: | mysql-5.1 | OS: | Any |
Assigned to: | CPU Architecture: | Any | |
Tags: | disabled |
[15 May 2008 11:53]
Mattias Jonsson
[15 May 2008 20:18]
Mattias Jonsson
Here is another test that fails when using option 'new' (range partitioning and alter delete rows, it works on myisam): set new=on; create table t1 (a int) engine=ndb partition by range (a) (partition p0 values less than (15), partition p1 values less than maxvalue); insert into t1 values (13), (15); select * from t1; a 13 15 alter table t1 reorganize partition p0,p1 into (partition s1 values less than maxvalue); select * from t1; a 13 show create table t1; Table Create Table t1 CREATE TABLE `t1` ( `a` int(11) DEFAULT NULL ) ENGINE=ndbcluster DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (a) (PARTITION s1 VALUES LESS THAN MAXVALUE ENGINE = ndbcluster) */ drop table t1;
[15 May 2008 23:10]
Mattias Jonsson
Here is another test case that shows problem with range partitioning ndb tables (possible to insert and select values outside specified partition): set new=on; CREATE TABLE t1 ( f_int1 INTEGER, f_int2 INTEGER, f_char1 CHAR(20), f_char2 CHAR(20), f_charbig VARCHAR(1000) ) PARTITION BY RANGE(f_int1) SUBPARTITION BY HASH(f_int1) ( PARTITION part1 VALUES LESS THAN (1000) (SUBPARTITION subpart11 STORAGE ENGINE = 'ndbcluster', SUBPARTITION subpart12 STORAGE ENGINE = 'ndbcluster')); insert into t1 set f_int1 = 2147483647, f_int2 = 2147483647, f_charbig = '#2147483647##'; insert into t1 values (2147483647, 2147483647, '2147483647', '2147483647', '#2147483647##'); select * from t1; f_int1 f_int2 f_char1 f_char2 f_charbig 2147483647 2147483647 NULL NULL #2147483647## 2147483647 2147483647 2147483647 2147483647 #2147483647## show create table t1; Table Create Table t1 CREATE TABLE `t1` ( `f_int1` int(11) DEFAULT NULL, `f_int2` int(11) DEFAULT NULL, `f_char1` char(20) DEFAULT NULL, `f_char2` char(20) DEFAULT NULL, `f_charbig` varchar(1000) DEFAULT NULL ) ENGINE=ndbcluster DEFAULT CHARSET=latin1 /*!50100 PARTITION BY RANGE (f_int1) SUBPARTITION BY HASH (f_int1) (PARTITION part1 VALUES LESS THAN (1000) (SUBPARTITION subpart11 ENGINE = ndbcluster, SUBPARTITION subpart12 ENGINE = ndbcluster)) */ drop table t1;
[1 Jul 2008 10:54]
Mattias Jonsson
Related to bug#18735.
[12 Feb 2009 17:16]
Mattias Jonsson
What feedback is needed? The issue is still, that one can enable features with --new (or 'set new=on') which is not documented and I cannot find if it is supported or not (and if not, why the ability to enable it?) It would be good if user defined partitioning was documented and supported in NDB.