Skip to content

Commit 88fbfc4

Browse files
Import ndb varsize
1 parent 0a160a8 commit 88fbfc4

File tree

229 files changed

+35997
-18763
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

229 files changed

+35997
-18763
lines changed

configure.in

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1864,7 +1864,8 @@ AC_CHECK_FUNCS(alarm bcmp bfill bmove bzero chsize cuserid fchmod fcntl \
18641864
shmget shmat shmdt shmctl sigaction sigemptyset sigaddset \
18651865
sighold sigset sigthreadmask \
18661866
snprintf socket stpcpy strcasecmp strerror strsignal strnlen strpbrk strstr strtol \
1867-
strtoll strtoul strtoull tell tempnam thr_setconcurrency vidattr)
1867+
strtoll strtoul strtoull tell tempnam thr_setconcurrency vidattr \
1868+
posix_fallocate)
18681869

18691870
#
18701871
#

mysql-test/ndb/ndbcluster.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -181,7 +181,7 @@ fi
181181

182182
# Edit file system path and ports in config file
183183
if [ $initial_ndb ] ; then
184-
rm -f $fs_ndb/ndb_* 2>&1 | cat > /dev/null
184+
rm -rf $fs_ndb/ndb_* 2>&1 | cat > /dev/null
185185
sed \
186186
-e s,"CHOOSE_MaxNoOfOrderedIndexes","$ndb_no_ord",g \
187187
-e s,"CHOOSE_MaxNoOfConcurrentOperations","$ndb_con_op",g \

mysql-test/r/ndb_alter_table.result

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -34,13 +34,13 @@ col5 enum('PENDING', 'ACTIVE', 'DISABLED') not null,
3434
col6 int not null, to_be_deleted int) ENGINE=ndbcluster;
3535
show table status;
3636
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
37-
t1 NDBCLUSTER 10 Dynamic 0 0 # # 0 # 1 # # # latin1_swedish_ci NULL #
37+
t1 NDBCLUSTER 10 Dynamic 0 # # # 0 # 1 # # # latin1_swedish_ci NULL #
3838
SET SQL_MODE=NO_AUTO_VALUE_ON_ZERO;
3939
insert into t1 values
4040
(0,4,3,5,"PENDING",1,7),(NULL,4,3,5,"PENDING",1,7),(31,4,3,5,"PENDING",1,7), (7,4,3,5,"PENDING",1,7), (NULL,4,3,5,"PENDING",1,7), (100,4,3,5,"PENDING",1,7), (99,4,3,5,"PENDING",1,7), (8,4,3,5,"PENDING",1,7), (NULL,4,3,5,"PENDING",1,7);
4141
show table status;
4242
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
43-
t1 NDBCLUSTER 10 Dynamic 9 96 # # 0 # 102 # # # latin1_swedish_ci NULL #
43+
t1 NDBCLUSTER 10 Dynamic 9 # # # 0 # 102 # # # latin1_swedish_ci NULL #
4444
select * from t1 order by col1;
4545
col1 col2 col3 col4 col5 col6 to_be_deleted
4646
0 4 3 5 PENDING 1 7
@@ -60,7 +60,7 @@ change column col2 fourth varchar(30) not null after col3,
6060
modify column col6 int not null first;
6161
show table status;
6262
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
63-
t1 NDBCLUSTER 10 Dynamic 9 152 # # 0 # 102 # # # latin1_swedish_ci NULL #
63+
t1 NDBCLUSTER 10 Dynamic 9 # # # 0 # 102 # # # latin1_swedish_ci NULL #
6464
select * from t1 order by col1;
6565
col6 col1 col3 fourth col4 col4_5 col5 col7 col8
6666
1 0 3 4 5 PENDING 0000-00-00 00:00:00
@@ -75,7 +75,7 @@ col6 col1 col3 fourth col4 col4_5 col5 col7 col8
7575
insert into t1 values (2, NULL,4,3,5,99,"PENDING","EXTRA",'2004-01-01 00:00:00');
7676
show table status;
7777
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
78-
t1 NDBCLUSTER 10 Dynamic 10 152 # # 0 # 103 # # # latin1_swedish_ci NULL #
78+
t1 NDBCLUSTER 10 Dynamic 10 # # # 0 # 103 # # # latin1_swedish_ci NULL #
7979
select * from t1 order by col1;
8080
col6 col1 col3 fourth col4 col4_5 col5 col7 col8
8181
1 0 3 4 5 PENDING 0000-00-00 00:00:00

mysql-test/r/ndb_autodiscover.result

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -146,8 +146,8 @@ Handler_discover 1
146146
flush tables;
147147
show table status;
148148
Name Engine Version Row_format Rows Avg_row_length Data_length Max_data_length Index_length Data_free Auto_increment Create_time Update_time Check_time Collation Checksum Create_options Comment
149-
t6 MyISAM 10 Fixed 1 260 # # # 0 NULL # # NULL # NULL #
150-
t7 NDBCLUSTER 10 Fixed 1 276 # # # 0 NULL # # NULL # NULL #
149+
t6 MyISAM 10 Fixed 1 # # # # 0 NULL # # NULL # NULL #
150+
t7 NDBCLUSTER 10 Fixed 1 # # # # 0 NULL # # NULL # NULL #
151151
show status like 'handler_discover%';
152152
Variable_name Value
153153
Handler_discover 2

mysql-test/r/ndb_partition_key.result

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -57,10 +57,10 @@ Number of primary keys: 3
5757
Length of frm data: #
5858
TableStatus: Retrieved
5959
-- Attributes --
60-
a Int PRIMARY KEY
61-
b Char(10;latin1_bin) PRIMARY KEY DISTRIBUTION KEY
62-
c Int PRIMARY KEY
63-
d Int NULL
60+
a Int PRIMARY KEY AT=FIXED ST=MEMORY
61+
b Char(10;latin1_bin) PRIMARY KEY DISTRIBUTION KEY AT=FIXED ST=MEMORY
62+
c Int PRIMARY KEY AT=FIXED ST=MEMORY
63+
d Int NULL AT=FIXED ST=MEMORY
6464

6565
-- Indexes --
6666
PRIMARY KEY(a, b, c) - UniqueHashIndex

mysql-test/r/ndb_restore.result

Lines changed: 0 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -126,26 +126,6 @@ create table t7 engine=myisam as select * from t7_c;
126126
create table t8 engine=myisam as select * from t8_c;
127127
create table t9 engine=myisam as select * from t9_c;
128128
drop table t1_c,t2_c,t3_c,t4_c,t5_c,t6_c,t7_c,t8_c,t9_c;
129-
show tables;
130-
Tables_in_test
131-
t1
132-
t2
133-
t3
134-
t4
135-
t5
136-
t6
137-
t7
138-
t8
139-
t9
140-
t8_c
141-
t9_c
142-
t1_c
143-
t7_c
144-
t6_c
145-
t5_c
146-
t4_c
147-
t3_c
148-
t2_c
149129
select count(*) from t1;
150130
count(*)
151131
5

mysql-test/t/ndb_alter_table.test

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -56,12 +56,12 @@ col3 varchar (20) not null,
5656
col4 varchar(4) not null,
5757
col5 enum('PENDING', 'ACTIVE', 'DISABLED') not null,
5858
col6 int not null, to_be_deleted int) ENGINE=ndbcluster;
59-
--replace_column 7 # 8 # 10 # 12 # 13 # 14 # 18 #
59+
--replace_column 6 # 7 # 8 # 10 # 12 # 13 # 14 # 18 #
6060
show table status;
6161
SET SQL_MODE=NO_AUTO_VALUE_ON_ZERO;
6262
insert into t1 values
6363
(0,4,3,5,"PENDING",1,7),(NULL,4,3,5,"PENDING",1,7),(31,4,3,5,"PENDING",1,7), (7,4,3,5,"PENDING",1,7), (NULL,4,3,5,"PENDING",1,7), (100,4,3,5,"PENDING",1,7), (99,4,3,5,"PENDING",1,7), (8,4,3,5,"PENDING",1,7), (NULL,4,3,5,"PENDING",1,7);
64-
--replace_column 7 # 8 # 10 # 12 # 13 # 14 # 18 #
64+
--replace_column 6 # 7 # 8 # 10 # 12 # 13 # 14 # 18 #
6565
show table status;
6666
select * from t1 order by col1;
6767
alter table t1
@@ -70,11 +70,11 @@ add column col7 varchar(30) not null after col5,
7070
add column col8 datetime not null, drop column to_be_deleted,
7171
change column col2 fourth varchar(30) not null after col3,
7272
modify column col6 int not null first;
73-
--replace_column 7 # 8 # 10 # 12 # 13 # 14 # 18 #
73+
--replace_column 6 # 7 # 8 # 10 # 12 # 13 # 14 # 18 #
7474
show table status;
7575
select * from t1 order by col1;
7676
insert into t1 values (2, NULL,4,3,5,99,"PENDING","EXTRA",'2004-01-01 00:00:00');
77-
--replace_column 7 # 8 # 10 # 12 # 13 # 14 # 18 #
77+
--replace_column 6 # 7 # 8 # 10 # 12 # 13 # 14 # 18 #
7878
show table status;
7979
select * from t1 order by col1;
8080
delete from t1;

mysql-test/t/ndb_autodiscover.test

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -177,7 +177,7 @@ show status like 'handler_discover%';
177177
flush tables;
178178
system rm var/master-data/test/t7.frm ;
179179

180-
--replace_column 7 # 8 # 9 # 12 # 13 # 15 # 18 #
180+
--replace_column 6 # 7 # 8 # 9 # 12 # 13 # 15 # 18 #
181181
show table status;
182182
show status like 'handler_discover%';
183183

@@ -543,6 +543,6 @@ create table t10 (
543543

544544
insert into t10 values (1, 'kalle');
545545

546-
--exec $NDB_TOOLS_DIR/ndb_drop_table --no-defaults -d test `$NDB_TOOLS_DIR/ndb_show_tables --no-defaults | grep BLOB` >> $NDB_TOOLS_OUTPUT 2>&1 || true
546+
--exec $NDB_TOOLS_DIR/ndb_drop_table --no-defaults -d test `$NDB_TOOLS_DIR/ndb_show_tables --no-defaults | grep BLOB | while read a b c d e f g; do echo $g; done` >> $NDB_TOOLS_OUTPUT 2>&1 || true
547547

548548
# End of 4.1 tests

mysql-test/t/ndb_restore.test

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -148,7 +148,8 @@ drop table t1_c,t2_c,t3_c,t4_c,t5_c,t6_c,t7_c,t8_c,t9_c;
148148
--exec $NDB_TOOLS_DIR/ndb_restore --no-defaults -b 1 -n 1 -m -r --print --print_meta $NDB_BACKUP_DIR/BACKUP/BACKUP-1 >> $NDB_TOOLS_OUTPUT
149149
--exec $NDB_TOOLS_DIR/ndb_restore --no-defaults -b 1 -n 2 -r --print --print_meta $NDB_BACKUP_DIR/BACKUP/BACKUP-1 >> $NDB_TOOLS_OUTPUT
150150

151-
show tables;
151+
# random output order??
152+
#show tables;
152153

153154
select count(*) from t1;
154155
select count(*) from t1_c;

0 commit comments

Comments
 (0)