3 # create table t1 (f1, f2) , index t1idx1 on t1(f1), index t1idx2 on t1(f2)
4 # create table t2 (f1, f2) , index t2idx1 on t2(f1)
5 # insert 10 tuples in both t1 and t2
6 # Check -T option with table having 1 index
7 # Check -T option with table having 2 index
8 # Check -I option on index t1idx2
11 #Run this test only under csql/test or on this directory.
12 #Otherwise, it may fail
13 EXECUTABLE
=${PWD}/tools
/catalog
/create
15 if [ -s "$EXECUTABLE" ]
17 REL_PATH
=${PWD}/tools
/catalog
25 echo "Tables and Indexes are created"
31 echo "Tuples inserted into table"
32 echo "Case 1: -T option for t1: with two index, with tuples"
33 $CSQL_INSTALL_ROOT/bin
/catalog
-u root
-p manager
-T t1
39 echo "Case 2: -T option for t2: with one index, with tuples"
40 $CSQL_INSTALL_ROOT/bin
/catalog
-u root
-p manager
-T t2
46 echo "Case 3: -I option for idx2 of t1, with tuples"
47 $CSQL_INSTALL_ROOT/bin
/catalog
-u root
-p manager
-I t1idx2
58 echo "Tables and Indexes are dropped"