~drizzle-trunk/drizzle/development

« back to all changes in this revision

Viewing changes to tests/r/heap.result

Remove PLUGIN and MODULES.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
drop table if exists t1,t2,t3;
2
 
create temporary table t1 (a int not null,b int not null, primary key (a)) engine=heap comment="testing heaps";
 
2
create temporary table t1 (a int not null,b int not null, primary key (a)) engine=MEMORY comment="testing heaps";
3
3
insert into t1 values(1,1),(2,2),(3,3),(4,4);
4
4
delete from t1 where a=1 or a=0;
5
5
show keys from t1;
29
29
select * from t1;
30
30
a       b
31
31
drop table t1;
32
 
create temporary table t1 (a int not null,b int not null, primary key (a)) engine=heap comment="testing heaps";
 
32
create temporary table t1 (a int not null,b int not null, primary key (a)) engine=MEMORY comment="testing heaps";
33
33
insert into t1 values(1,1),(2,2),(3,3),(4,4);
34
34
alter table t1 modify a int not null auto_increment, engine=innodb, comment="new innodb table";
35
35
select * from t1;
39
39
3       3
40
40
4       4
41
41
drop table t1;
42
 
create temporary table t1 (a int not null) engine=heap;
 
42
create temporary table t1 (a int not null) engine=MEMORY;
43
43
insert into t1 values (869751),(736494),(226312),(802616),(728912);
44
44
select * from t1 where a > 736494;
45
45
a
69
69
1       SIMPLE  t2      ALL     NULL    NULL    NULL    NULL    5       Using where
70
70
drop table t1,t2;
71
71
create temporary table t1 (x int not null, y int not null, key x (x), unique y (y))
72
 
engine=heap;
 
72
engine=MEMORY;
73
73
insert into t1 values (1,1),(2,2),(1,3),(2,4),(2,5),(2,6);
74
74
select * from t1 where x=1;
75
75
x       y
80
80
explain select * from t1,t1 as t2 where t1.x=t2.y;
81
81
ERROR HY000: Can't reopen table: 't1'
82
82
drop table t1;
83
 
create temporary table t1 (a int) engine=heap;
 
83
create temporary table t1 (a int) engine=MEMORY;
84
84
insert into t1 values(1);
85
85
select max(a) from t1;
86
86
max(a)
87
87
1
88
88
drop table t1;
89
 
CREATE TEMPORARY TABLE t1 ( a int not null default 0, b int not null default 0,  key(a),  key(b)  ) ENGINE=HEAP;
 
89
CREATE TEMPORARY TABLE t1 ( a int not null default 0, b int not null default 0,  key(a),  key(b)  ) ENGINE=MEMORY;
90
90
insert into t1 values(1,1),(1,2),(2,3),(1,3),(1,4),(1,5),(1,6);
91
91
select * from t1 where a=1;
92
92
a       b
112
112
1       2
113
113
1       1
114
114
drop table t1;
115
 
create temporary table t1 (id int not null, primary key (id)) engine=HEAP;
 
115
create temporary table t1 (id int not null, primary key (id)) engine=MEMORY;
116
116
insert into t1 values(1);
117
117
select max(id) from t1;
118
118
max(id)
123
123
2
124
124
replace into t1 values(1);
125
125
drop table t1;
126
 
create temporary table t1 (n int) engine=heap;
 
126
create temporary table t1 (n int) engine=MEMORY;
127
127
drop table t1;
128
 
create temporary table t1 (n int) engine=heap;
 
128
create temporary table t1 (n int) engine=MEMORY;
129
129
drop table if exists t1;
130
130
CREATE TEMPORARY table t1(f1 int not null,f2 char(20) not 
131
 
null,index(f2)) engine=heap;
 
131
null,index(f2)) engine=MEMORY;
132
132
INSERT into t1 set f1=12,f2="bill";
133
133
INSERT into t1 set f1=13,f2="bill";
134
134
INSERT into t1 set f1=14,f2="bill";
147
147
12      ted
148
148
12      ted
149
149
drop table t1;
150
 
create temporary table t1 (btn char(10) not null, key(btn)) engine=heap;
 
150
create temporary table t1 (btn char(10) not null, key(btn)) engine=MEMORY;
151
151
insert into t1 values ("hello"),("hello"),("hello"),("hello"),("hello"),("a"),("b"),("c"),("d"),("e"),("f"),("g"),("h"),("i");
152
152
explain select * from t1 where btn like "q%";
153
153
id      select_type     table   type    possible_keys   key     key_len ref     rows    Extra
168
168
b int default NULL,
169
169
KEY a (a),
170
170
UNIQUE b (b)
171
 
) engine=heap;
 
171
) engine=MEMORY;
172
172
INSERT INTO t1 VALUES (NULL,99),(99,NULL),(1,1),(2,2),(1,3);
173
173
SELECT * FROM t1 WHERE a=NULL;
174
174
a       b
192
192
CREATE TEMPORARY TABLE t1 (
193
193
a int default NULL,
194
194
key a (a)
195
 
) ENGINE=HEAP;
 
195
) ENGINE=MEMORY;
196
196
INSERT INTO t1 VALUES (10), (10), (10);
197
197
EXPLAIN SELECT * FROM t1 WHERE a=10;
198
198
id      select_type     table   type    possible_keys   key     key_len ref     rows    Extra
203
203
10
204
204
10
205
205
DROP TABLE t1;
206
 
CREATE TEMPORARY TABLE t1 (a int not null, primary key(a)) engine=heap;
 
206
CREATE TEMPORARY TABLE t1 (a int not null, primary key(a)) engine=MEMORY;
207
207
INSERT into t1 values (1),(2),(3),(4),(5),(6),(7),(8),(9),(10),(11);
208
208
DELETE from t1 where a < 100;
209
209
SELECT * from t1;
214
214
`job_title` char(18) NOT NULL default '',
215
215
PRIMARY KEY  (`job_title_id`),
216
216
UNIQUE KEY `job_title_id` (`job_title_id`,`job_title`)
217
 
) ENGINE=HEAP;
 
217
) ENGINE=MEMORY;
218
218
SELECT MAX(job_title_id) FROM job_titles;
219
219
MAX(job_title_id)
220
220
NULL
221
221
DROP TABLE job_titles;
222
 
CREATE TEMPORARY TABLE t1 (a INT NOT NULL, B INT, KEY(B)) ENGINE=HEAP;
 
222
CREATE TEMPORARY TABLE t1 (a INT NOT NULL, B INT, KEY(B)) ENGINE=MEMORY;
223
223
INSERT INTO t1 VALUES(1,1), (1,NULL);
224
224
SELECT * FROM t1 WHERE B is not null;
225
225
a       B
226
226
1       1
227
227
DROP TABLE t1;
228
 
CREATE TEMPORARY TABLE t1 (pseudo char(35) PRIMARY KEY, date int NOT NULL) ENGINE=HEAP;
 
228
CREATE TEMPORARY TABLE t1 (pseudo char(35) PRIMARY KEY, date int NOT NULL) ENGINE=MEMORY;
229
229
INSERT INTO t1 VALUES ('massecot',1101106491),('altec',1101106492),('stitch+',1101106304),('Seb Corgan',1101106305),('beerfilou',1101106263),('flaker',1101106529),('joce8',5),('M4vrick',1101106418),('gabay008',1101106525),('Vamp irX',1101106291),('ZoomZip',1101106546),('rip666',1101106502),('CBP ',1101106397),('guezpard',1101106496);
230
230
DELETE FROM t1 WHERE date<1101106546;
231
231
SELECT * FROM t1;
241
241
3
242
242
2
243
243
drop table t1;
244
 
set storage_engine=HEAP;
 
244
set storage_engine=MEMORY;
245
245
create temporary table t1 (v varchar(10), c char(10), t varchar(50));
246
246
insert into t1 values('+ ', '+ ', '+ ');
247
247
set @a=repeat(' ',20);
603
603
id      select_type     table   type    possible_keys   key     key_len ref     rows    Extra
604
604
1       SIMPLE  t1      ref     v       v       43      const   #       Using where
605
605
drop table t1;
606
 
create temporary table t1 (a char(10), unique using btree (a)) engine=heap;
 
606
create temporary table t1 (a char(10), unique using btree (a)) engine=MEMORY;
607
607
insert into t1 values ('a');
608
608
insert into t1 values ('a ');
609
609
ERROR 23000: Duplicate entry 'a ' for key 'a'
645
645
drop table t1;
646
646
set storage_engine=InnoDB;
647
647
create temporary table t1 (a bigint auto_increment primary key, b int,
648
 
key (b, a)) engine=heap;
 
648
key (b, a)) engine=MEMORY;
649
649
insert t1 (b) values (1),(1),(1),(1),(1),(1),(1),(1);
650
650
select * from t1;
651
651
a       b
659
659
8       1
660
660
drop table t1;
661
661
create temporary table t1 (a int not null, b int not null auto_increment,
662
 
primary key(a, b), key(b)) engine=heap;
 
662
primary key(a, b), key(b)) engine=MEMORY;
663
663
insert t1 (a) values (1),(1),(1),(1),(1),(1),(1),(1);
664
664
select * from t1;
665
665
a       b
673
673
1       8
674
674
drop table t1;
675
675
create temporary table t1 (a int not null, b int not null auto_increment,
676
 
primary key(a, b)) engine=heap;
 
676
primary key(a, b)) engine=MEMORY;
677
677
ERROR 42000: Incorrect table definition; there can be only one auto column and it must be defined as a key
678
678
create temporary table t1 (c char(255), primary key(c(90)));
679
679
insert into t1 values ("abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz");
680
680
insert into t1 values ("abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyz");
681
681
ERROR 23000: Duplicate entry 'abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxyzabcdefghijkl' for key 'PRIMARY'
682
682
drop table t1;
683
 
CREATE TEMPORARY TABLE t1 (a int, key(a)) engine=heap;
 
683
CREATE TEMPORARY TABLE t1 (a int, key(a)) engine=MEMORY;
684
684
insert into t1 values (0);
685
685
delete from t1;
686
686
select * from t1;
693
693
create temporary table t1 (c char(10)) engine=memory;
694
694
create temporary table t2 (c varchar(10)) engine=memory;
695
695
show table status like 't_';
696
 
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
 
696
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 Plugin_name
697
697
drop table t1, t2;
698
698
CREATE TEMPORARY TABLE t1(a VARCHAR(1), b VARCHAR(2), c VARCHAR(256),
699
699
KEY(a), KEY(b), KEY(c)) ENGINE=MEMORY;