adding test scripts
[csql.git] / test / sql / Optimizer / test016.ksh
blobd860d2ff5cf9a2019a016c86dbc32cd255f7f81e
1 #!/bin/ksh
2 # Composite hash index on mixed datatypes and testing explain plan
3 # Create table with 6 fields (f1 smallint, f2 int, f3 bigint, f4 char, f5 date, f6 timestamp).
4 # create composite hash indexes in different combinations.
5 # Apply explain plan using select with multiple predicates(Hash lookup).
6 # Apply explain plan using select with multiple predicates(range lookup).
8 QUITFILE=${PWD}/sql/Optimizer/drop.sql
9 REL_PATH=.
10 if [ -s "$QUITFILE" ]
11 then
12 REL_PATH=`pwd`/sql/Optimizer
15 echo "drop table t1;" >${REL_PATH}/dropt1.sql
17 $CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/dropt1.sql >/dev/null 2>&1
19 if [ "$VALGRIND" = "true" ]
20 then
21 valgrind --tool=memcheck --leak-check=full $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/composite_mixdatatype.sql
22 else
23 $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/composite_mixdatatype.sql
24 if [ $? -ne 0 ]
25 then
26 rm -f ${REL_PATH}/dropt1.sql
27 exit 1;
31 $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1.sql
32 rm -f ${REL_PATH}/dropt1.sql
33 exit 0;