~drizzle-trunk/drizzle/development

1 by brian
clean slate
1
#
2
# This test does a create-select with ORDER BY, where there is so many
3
# rows MySQL needs to use a merge during the sort phase.
4
#
5
6
--disable_warnings
7
drop table if exists t1,t2;
8
--enable_warnings
9
10
CREATE TABLE `t1` (
500 by Brian Aker
Re-enabled more tests.
11
  `id` int NOT NULL default '0',
12
  `id2` int NOT NULL default '0',
13
  `id3` int NOT NULL default '0');
1 by brian
clean slate
14
let $1=4000;
15
disable_query_log;
910.4.13 by Stewart Smith
batch up more INSERTs into transactions to help tests run quicker.
16
begin;
1 by brian
clean slate
17
while ($1)
18
 {
19
   eval insert into t1 (id,id2,id3) values ($1,$1,$1);
20
   dec $1;
21
 }
910.4.13 by Stewart Smith
batch up more INSERTs into transactions to help tests run quicker.
22
commit;
1 by brian
clean slate
23
enable_query_log;
24
create table t2 select id2 from t1 order by id3;
25
select count(*) from t2;
26
drop table t1,t2;
27
28
# End of 4.1 tests