adding test scripts
[csql.git] / test / tools / csql / comp2.sql
blob3982d0c2af99528d67255806c1e874e950222307
1 CREATE TABLE t1 (f1 INT NOT NULL,f2 INT NOT NULL,f3 INT);
2 CREATE INDEX idx on t1 (f1,f2);
3 INSERT INTO t1 VALUES(1,1,1);
4 INSERT INTO t1 VALUES(2,1,2);
5 INSERT INTO t1 VALUES(3,1,3);
6 INSERT INTO t1 VALUES(1,1,3);
7 INSERT INTO t1 VALUES(5,2,5);
8 INSERT INTO t1 VALUES(10,2,10);
9 INSERT INTO t1 VALUES(100,3,100);
10 echo select count(f1) from t1;
11 select count(f1) from t1;
12 echo select * from t1 where f1=1 and f2=1;
13 select * from t1 where f1=1 and f2=1;
14 echo select * from t1 where f1=5 and f2=1;
15 select * from t1 where f1=5 and f2=1;
16 echo select * from t1 where f1=5;
17 select * from t1 where f1=5;
18 echo select * from t1 where f1=7;
19 select * from t1 where f1=7;
20 echo select * from t1 where f1=10 and f2=2 and f3=10;
21 select * from t1 where f1=10 and f2=2 and f3=10;
22 echo select * from t1 where f1=10 and f2=6 and f3=10;
23 select * from t1 where f1=10 and f2=6 and f3=10;
24 echo test over