adding test scripts
[csql.git] / test / sql / Optimizer / time_composite.sql
blob25dbca03683b564ac4f88d31ff322eb3496bb55f
1 echo create table t1(f1 time, f2 time, f3 time, f4 time);
2 create table t1(f1 time, f2 time, f3 time, f4 time);
3 echo create index hashtimef1f2f3 on t1(f2,f3,f1) hash;
4 create index hashtimef1f2f3 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 = '03:03:03';
8 explain plan select * from t1 where f1 = '03:03:03';
9 echo explain plan select * from t1 where f1 = '03:03:03' and f2='03:03:03';
10 explain plan select * from t1 where f1 = '03:03:03' and f2='03:03:03';
11 echo explain plan select * from t1 where f1 = '03:03:03' and f2='03:03:03' and f3='03:03:03';
12 explain plan select * from t1 where f1 = '03:03:03' and f2='03:03:03' and f3='03:03:03';
13 echo explain plan select * from t1 where f1 = '03:03:03' or f2='03:03:03' or f3='03:03:03';
14 explain plan select * from t1 where f1 = '03:03:03' or f2='03:03:03' or f3='03:03:03';
15 echo explain plan select * from t1 where f1 = '03:03:03' and f2='03:03:03' or f3='03:03:03';
16 explain plan select * from t1 where f1 = '03:03:03' and f2='03:03:03' or f3='03:03:03';
17 echo explain plan select * from t1 where f1 = '03:03:03' and f2='03:03:03' and not(f3='03:03:03');
18 explain plan select * from t1 where f1 = '03:03:03' and f2='03:03:03' and not(f3='03:03:03');
19 echo explain plan select * from t1 where f1 in('03:03:03','03:03:03','03:03:03') and f2='03:03:03' and not(f3='03:03:03');
20 explain plan select * from t1 where f1 in('03:03:03','03:03:03','03:03:03') and f2='03:03:03' and not(f3='03:03:03');
21 echo explain plan select * from t1 where f1 in('03:03:03','05:05:05','06:06:06') and (f2 between '03:03:03' and '03:03:03') and not(f3='03:03:03');
22 explain plan select * from t1 where f1 in('03:03:03','05:05:05','06:06:06') and (f2 between '03:03:03' and '03:03:03') and not(f3='03:03:03');
23 echo explain plan select * from t1 where f1 in('05:05:05','06:06:06','03:03:03') or (f2 between '03:03:03' and '03:03:03') or not(f3='03:03:03');
24 explain plan select * from t1 where f1 in('05:05:05','06:06:06','03:03:03') or (f2 between '03:03:03' and '03:03:03') or not(f3='03:03:03');
25 echo explain plan select * from t1 where f1 in('03:03:03','06:06:06','05:05:05') or (f2 between '03:03:03' and '03:03:03') and not(f3='03:03:03');
26 explain plan select * from t1 where f1 in('03:03:03','06:06:06','05:05:05') or (f2 between '03:03:03' and '03:03:03') and not(f3='03:03:03');