code reorg for Transactionw!
[csql.git] / test / sql / Optimizer / big_composite.sql
blob643141526bd7253cf8c3d29f9ac9abd6d9748611
1 echo create table t1(f1 bigint, f2 bigint, f3 bigint, f4 bigint);
2 create table t1(f1 bigint, f2 bigint, f3 bigint, f4 bigint);
3 echo create index hashbigf1f2f3 on t1(f2,f3,f1) hash;
4 create index hashbigf1f2f3 on t1(f2,f3,f1) hash;
5 echo explain plan select * from t1;
6 explain plan select * from t1;
7 echo explain plan select * from t1 where f1 = 2;
8 explain plan select * from t1 where f1 = 2;
9 echo explain plan select * from t1 where f1 = 2 and f2=2;
10 explain plan select * from t1 where f1 = 2 and f2=2;
11 echo explain plan select * from t1 where f1 = 2 and f2=2 and f3=2;
12 explain plan select * from t1 where f1 = 2 and f2=2 and f3=2;
13 echo explain plan select * from t1 where f1 = 2 or f2=2 or f3=2;
14 explain plan select * from t1 where f1 = 2 or f2=2 or f3=2;
15 echo explain plan select * from t1 where f1 = 2 and f2=2 or f3=2;
16 explain plan select * from t1 where f1 = 2 and f2=2 or f3=2;
17 echo explain plan select * from t1 where f1 = 2 and f2=2 and not(f3=2);
18 explain plan select * from t1 where f1 = 2 and f2=2 and not(f3=2);
19 echo explain plan select * from t1 where f1 in(1,2,3) and f2=2 and not(f3=2);
20 explain plan select * from t1 where f1 in(1,2,3) and f2=2 and not(f3=2);
21 echo explain plan select * from t1 where f1 in(1,2,3) and (f2 between 2 and 4) and not(f3=2);
22 explain plan select * from t1 where f1 in(1,2,3) and (f2 between 2 and 4) and not(f3=2);
23 echo explain plan select * from t1 where f1 in(1,2,3) or (f2 between 2 and 4) or not(f3=2);
24 explain plan select * from t1 where f1 in(1,2,3) or (f2 between 2 and 4) or not(f3=2);
25 echo explain plan select * from t1 where f1 in(1,2,3) or (f2 between 2 and 4) and not(f3=2);
26 explain plan select * from t1 where f1 in(1,2,3) or (f2 between 2 and 4) and not(f3=2);