From 9a331a71b5f1b34bfba1fe053976d93170984c5e Mon Sep 17 00:00:00 2001 From: bijaya Date: Thu, 8 Oct 2009 06:07:57 +0000 Subject: [PATCH] Files removed --- test/CacheTestModules | 13 - test/Makefile | 38 - test/TestModules | 31 - test/csql.conf | 81 -- test/execCacheTests.ksh | 219 ----- test/execTests.ksh | 227 ----- test/genReport.ksh | 50 - test/jdbc/Connection/ConnTest1.java | 21 - test/jdbc/Connection/ConnTest10.java | 19 - test/jdbc/Connection/ConnTest11.java | 19 - test/jdbc/Connection/ConnTest12.java | 19 - test/jdbc/Connection/ConnTest13.java | 19 - test/jdbc/Connection/ConnTest14.java | 19 - test/jdbc/Connection/ConnTest15.java | 18 - test/jdbc/Connection/ConnTest16.java | 26 - test/jdbc/Connection/ConnTest17.java | 25 - test/jdbc/Connection/ConnTest18.java | 25 - test/jdbc/Connection/ConnTest19.java | 27 - test/jdbc/Connection/ConnTest2.java | 58 -- test/jdbc/Connection/ConnTest20.java | 24 - test/jdbc/Connection/ConnTest22.java | 47 - test/jdbc/Connection/ConnTest24.java | 48 - test/jdbc/Connection/ConnTest25.java | 48 - test/jdbc/Connection/ConnTest26.java | 47 - test/jdbc/Connection/ConnTest27.java | 48 - test/jdbc/Connection/ConnTest29.java | 57 -- test/jdbc/Connection/ConnTest3.java | 55 -- test/jdbc/Connection/ConnTest34.java | 56 -- test/jdbc/Connection/ConnTest4.java | 54 -- test/jdbc/Connection/ConnTest5.java | 51 - test/jdbc/Connection/ConnTest6.java | 51 - test/jdbc/Connection/ConnTest8.java | 19 - test/jdbc/Connection/ConnTest9.java | 19 - test/jdbc/Connection/IsoTest1.java | 23 - test/jdbc/Connection/IsoTest2.java | 53 -- test/jdbc/Connection/Makefile | 16 - test/jdbc/Connection/exp.test006.ksh | 11 - test/jdbc/Connection/exp.test030.ksh | 1 - test/jdbc/Connection/exp.test031.ksh | 2 - test/jdbc/Connection/exp.test032.ksh | 2 - test/jdbc/Connection/exp.test033.ksh | 1 - test/jdbc/Connection/test001.ksh | 14 - test/jdbc/Connection/test002.ksh | 14 - test/jdbc/Connection/test003.ksh | 14 - test/jdbc/Connection/test004.ksh | 14 - test/jdbc/Connection/test005.ksh | 14 - test/jdbc/Connection/test006.ksh | 14 - test/jdbc/Connection/test008.ksh | 14 - test/jdbc/Connection/test009.ksh | 14 - test/jdbc/Connection/test010.ksh | 14 - test/jdbc/Connection/test011.ksh | 14 - test/jdbc/Connection/test012.ksh | 14 - test/jdbc/Connection/test013.ksh | 14 - test/jdbc/Connection/test014.ksh | 14 - test/jdbc/Connection/test015.ksh | 14 - test/jdbc/Connection/test016.ksh | 14 - test/jdbc/Connection/test017.ksh | 14 - test/jdbc/Connection/test018.ksh | 14 - test/jdbc/Connection/test019.ksh | 14 - test/jdbc/Connection/test020.ksh | 14 - test/jdbc/Connection/test022.ksh | 14 - test/jdbc/Connection/test024.ksh | 14 - test/jdbc/Connection/test025.ksh | 14 - test/jdbc/Connection/test026.ksh | 14 - test/jdbc/Connection/test027.ksh | 14 - test/jdbc/Connection/test029.ksh | 14 - test/jdbc/Connection/test030.ksh | 14 - test/jdbc/Connection/test031.ksh | 14 - test/jdbc/Connection/test034.ksh | 14 - test/jdbc/Gateway/ConnTest01.java | 23 - test/jdbc/Gateway/ConnTest02.java | 18 - test/jdbc/Gateway/ConnTest03.java | 19 - test/jdbc/Gateway/ConnTest04.java | 18 - test/jdbc/Gateway/ConnTest05.java | 19 - test/jdbc/Gateway/ConnTest06.java | 27 - test/jdbc/Gateway/ConnTest07.java | 27 - test/jdbc/Gateway/ConnTest08.java | 24 - test/jdbc/Gateway/ConnTest09.java | 27 - test/jdbc/Gateway/ConnTest10.java | 54 -- test/jdbc/Gateway/GwStmt1.java | 91 -- test/jdbc/Gateway/GwStmt10.java | 101 -- test/jdbc/Gateway/GwStmt2.java | 62 -- test/jdbc/Gateway/GwStmt3.java | 61 -- test/jdbc/Gateway/GwStmt4.java | 60 -- test/jdbc/Gateway/GwStmt5.java | 64 -- test/jdbc/Gateway/GwStmt6.java | 94 -- test/jdbc/Gateway/GwStmt7.java | 91 -- test/jdbc/Gateway/GwStmt8.java | 72 -- test/jdbc/Gateway/GwStmt9.java | 84 -- test/jdbc/Gateway/GwTest1.java | 31 - test/jdbc/Gateway/GwTest10.java | 92 -- test/jdbc/Gateway/GwTest11.java | 63 -- test/jdbc/Gateway/GwTest12.java | 61 -- test/jdbc/Gateway/GwTest13.java | 60 -- test/jdbc/Gateway/GwTest14.java | 63 -- test/jdbc/Gateway/GwTest15.java | 95 -- test/jdbc/Gateway/GwTest16.java | 92 -- test/jdbc/Gateway/GwTest2.java | 22 - test/jdbc/Gateway/GwTest3.java | 23 - test/jdbc/Gateway/GwTest4.java | 37 - test/jdbc/Gateway/GwTest6.java | 32 - test/jdbc/Gateway/GwTest7.java | 37 - test/jdbc/Gateway/GwTest8.java | 39 - test/jdbc/Gateway/GwTest9.java | 30 - test/jdbc/Gateway/Makefile | 10 - test/jdbc/Gateway/test001.ksh | 14 - test/jdbc/Gateway/test002.ksh | 14 - test/jdbc/Gateway/test003.ksh | 14 - test/jdbc/Gateway/test004.ksh | 14 - test/jdbc/Gateway/test005.ksh | 14 - test/jdbc/Gateway/test006.ksh | 14 - test/jdbc/Gateway/test007.ksh | 14 - test/jdbc/Gateway/test008.ksh | 14 - test/jdbc/Gateway/test009.ksh | 14 - test/jdbc/Gateway/test010.ksh | 14 - test/jdbc/Gateway/test031.ksh | 40 - test/jdbc/Gateway/test032.ksh | 41 - test/jdbc/Gateway/test033.ksh | 41 - test/jdbc/Gateway/test034.ksh | 41 - test/jdbc/Gateway/test035.ksh | 41 - test/jdbc/Gateway/test036.ksh | 41 - test/jdbc/Gateway/test037.ksh | 41 - test/jdbc/Gateway/test038.ksh | 41 - test/jdbc/Gateway/test039.ksh | 41 - test/jdbc/Gateway/test040.ksh | 41 - test/jdbc/Gateway/test041.ksh | 21 - test/jdbc/Gateway/test042.ksh | 20 - test/jdbc/Gateway/test043.ksh | 21 - test/jdbc/Gateway/test044.ksh | 20 - test/jdbc/Gateway/test046.ksh | 22 - test/jdbc/Gateway/test047.ksh | 23 - test/jdbc/Gateway/test048.ksh | 22 - test/jdbc/Gateway/test049.ksh | 22 - test/jdbc/Gateway/test050.ksh | 33 - test/jdbc/Gateway/test051.ksh | 31 - test/jdbc/Gateway/test052.ksh | 31 - test/jdbc/Gateway/test053.ksh | 34 - test/jdbc/Gateway/test054.ksh | 32 - test/jdbc/Gateway/test055.ksh | 31 - test/jdbc/Gateway/test056.ksh | 31 - test/jdbc/Makefile | 35 - test/jdbc/ParameterMetadata/Makefile | 9 - test/jdbc/ParameterMetadata/ParaMetaTest1.java | 114 --- test/jdbc/ParameterMetadata/ParaMetaTest2.java | 115 --- test/jdbc/ParameterMetadata/ParaMetaTest3.java | 106 --- test/jdbc/ParameterMetadata/test001.ksh | 14 - test/jdbc/ParameterMetadata/test002.ksh | 14 - test/jdbc/ParameterMetadata/test003.ksh | 14 - test/jdbc/ResultSetMetaData/Makefile | 8 - test/jdbc/ResultSetMetaData/RSMetadata1.java | 99 -- test/jdbc/ResultSetMetaData/RSMetadata2.java | 137 --- test/jdbc/ResultSetMetaData/test001.ksh | 14 - test/jdbc/ResultSetMetaData/test002.ksh | 14 - test/jdbc/Statement/Makefile | 11 - test/jdbc/Statement/StmtTest1.java | 87 -- test/jdbc/Statement/StmtTest2.java | 61 -- test/jdbc/Statement/StmtTest3.java | 63 -- test/jdbc/Statement/StmtTest4.java | 19 - test/jdbc/Statement/StmtTest5.java | 56 -- test/jdbc/Statement/StmtTest6.java | 63 -- test/jdbc/Statement/StmtTest7.java | 93 -- test/jdbc/Statement/StmtTest8.java | 64 -- test/jdbc/Statement/StmtTest9.java | 93 -- test/jdbc/Statement/TestScript1.java | 91 -- test/jdbc/Statement/TestScript10.java | 66 -- test/jdbc/Statement/TestScript11.java | 58 -- test/jdbc/Statement/TestScript2.java | 53 -- test/jdbc/Statement/TestScript3.java | 99 -- test/jdbc/Statement/TestScript4.java | 58 -- test/jdbc/Statement/TestScript5.java | 61 -- test/jdbc/Statement/TestScript6.java | 96 -- test/jdbc/Statement/TestScript7.java | 91 -- test/jdbc/Statement/TestScript8.java | 87 -- test/jdbc/Statement/TestScript9.java | 70 -- test/jdbc/Statement/exp.test001.ksh | 28 - test/jdbc/Statement/exp.test002.ksh | 4 - test/jdbc/Statement/exp.test005.ksh | 1 - test/jdbc/Statement/exp.test006.ksh | 2 - test/jdbc/Statement/exp.test007.ksh | 21 - test/jdbc/Statement/exp.test008.ksh | 11 - test/jdbc/Statement/test001.ksh | 14 - test/jdbc/Statement/test002.ksh | 14 - test/jdbc/Statement/test003.ksh | 14 - test/jdbc/Statement/test004.ksh | 14 - test/jdbc/Statement/test005.ksh | 14 - test/jdbc/Statement/test006.ksh | 15 - test/jdbc/Statement/test007.ksh | 14 - test/jdbc/Statement/test008.ksh | 14 - test/jdbc/Statement/test009.ksh | 14 - test/jdbc/Statement/test010.ksh | 19 - test/jdbc/Statement/test011.ksh | 17 - test/jdbc/Statement/test012.ksh | 17 - test/jdbc/Statement/test013.ksh | 22 - test/jdbc/Statement/test014.ksh | 22 - test/jdbc/Statement/test015.ksh | 17 - test/jdbc/Statement/test016.ksh | 17 - test/jdbc/Statement/test017.ksh | 17 - test/jdbc/Statement/test018.ksh | 17 - test/jdbc/Statement/test019.ksh | 22 - test/jdbc/Statement/test020.ksh | 22 - test/jdbc/Statement/test021.ksh | 22 - test/odbc/Connect/Makefile | 51 - test/odbc/Connect/odbcconnect1.c | 83 -- test/odbc/Connect/odbcconnect2.c | 120 --- test/odbc/Connect/odbcconnect3.c | 94 -- test/odbc/Connect/odbcconnect4.c | 99 -- test/odbc/Connect/odbcconnect5.c | 99 -- test/odbc/Connect/odbcconnect6.c | 186 ---- test/odbc/Connect/odbcconnect7.c | 106 --- test/odbc/Makefile | 35 - test/odbc/NonSelectDML/Makefile | 40 - test/odbc/NonSelectDML/nonselectdml1.c | 234 ----- test/odbc/Parameters/Makefile | 45 - test/odbc/Parameters/exp.test002 | 17 - test/odbc/Parameters/exp.test004 | 19 - test/odbc/Parameters/parameter1.c | 227 ----- test/odbc/Parameters/parameter2.c | 345 ------- test/odbc/Parameters/parameter3.c | 320 ------- test/odbc/Parameters/parameter4.c | 342 ------- test/odbc/Parameters/parameter5.c | 234 ----- test/odbc/Select/Makefile | 53 -- test/odbc/Select/exp.test001 | 18 - test/odbc/Select/exp.test004 | 14 - test/odbc/Select/odbcselect1.c | 312 ------ test/odbc/Select/odbcselect2.c | 311 ------ test/odbc/Select/odbcselect3.c | 292 ------ test/odbc/Select/odbcselect4.c | 301 ------ test/odbc/Select/odbcselect5.c | 105 --- test/odbc/Select/odbcselect6.c | 191 ---- test/odbc/Select/odbcselect7.c | 206 ---- test/odbc/Select/odbcselect8.c | 107 --- test/odbc/Transaction/Makefile | 41 - test/odbc/Transaction/transact1.c | 157 ---- test/odbc/Transaction/transact2.c | 174 ---- test/performance/DMLTest.c | 169 ---- test/performance/DMLThreadTest.c | 237 ----- test/performance/DMLThroughput.c | 114 --- test/performance/JDBCTest.java | 132 --- test/performance/Makefile | 61 -- test/performance/ODBCTest.c | 349 ------- test/performance/SQLAdapterTest.c | 121 --- test/performance/SQLGWTest.c | 121 --- test/performance/SQLTest.c | 144 --- test/performance/wisc/JDBCBench.java | 413 -------- test/performance/wisc/JDBCPopulate.java | 120 --- test/performance/wisc/Makefile | 19 - test/performance/wisc/README | 30 - test/performance/wisc/odbcBench.c | 612 ------------ test/performance/wisc/wbench.c | 685 -------------- test/sql/Aggregate/agg1.sql | 1 - test/sql/Aggregate/aggmin4.sql | 1 - test/sql/Aggregate/aggregate1.sql | 17 - test/sql/Aggregate/aggregate2.sql | 23 - test/sql/Aggregate/aggregate4.sql | 11 - test/sql/Aggregate/aggregate5.sql | 15 - test/sql/Aggregate/aggregate6.sql | 17 - test/sql/Aggregate/aggsum3.sql | 1 - test/sql/Aggregate/createt1.sql | 6 - test/sql/Aggregate/createt1t2.sql | 13 - test/sql/Aggregate/dropt1.sql | 2 - test/sql/Aggregate/dropt1t2.sql | 2 - test/sql/Aggregate/exp.test001.ksh | 32 - test/sql/Aggregate/exp.test002.ksh | 48 - test/sql/Aggregate/exp.test003.ksh | 6 - test/sql/Aggregate/exp.test004.ksh | 17 - test/sql/Aggregate/exp.test005.ksh | 1 - test/sql/Aggregate/exp.test006.ksh | 36 - test/sql/Aggregate/exp.test007.ksh | 6 - test/sql/Aggregate/exp.test008.ksh | 2 - test/sql/Aggregate/exp.test009.ksh | 2 - test/sql/Aggregate/quit.sql | 1 - test/sql/Aggregate/test001.ksh | 30 - test/sql/Aggregate/test002.ksh | 29 - test/sql/Aggregate/test004.ksh | 29 - test/sql/Aggregate/test005.ksh | 29 - test/sql/Aggregate/test006.ksh | 30 - test/sql/Aggregate/test007.ksh | 34 - test/sql/Aggregate/test008.ksh | 33 - test/sql/Aggregate/test009.ksh | 36 - test/sql/Join/createt1.sql | 6 - test/sql/Join/createt1t2.sql | 14 - test/sql/Join/createt1t2t3.sql | 12 - test/sql/Join/createt1t2t3t4t5.sql | 27 - test/sql/Join/drop_emp_dept.sql | 4 - test/sql/Join/dropt1.sql | 1 - test/sql/Join/dropt11.sql | 1 - test/sql/Join/dropt11t12.sql | 2 - test/sql/Join/dropt11t12t13.sql | 4 - test/sql/Join/dropt11t13.sql | 2 - test/sql/Join/dropt1t2.sql | 2 - test/sql/Join/dropt1t2t3.sql | 3 - test/sql/Join/dropt1t2t3t4t5.sql | 5 - test/sql/Join/exp.test001.ksh | 15 - test/sql/Join/exp.test002.ksh | 37 - test/sql/Join/exp.test003.ksh | 892 ------------------ test/sql/Join/exp.test004.ksh | 25 - test/sql/Join/exp.test005.ksh | 21 - test/sql/Join/exp.test006.ksh | 3 - test/sql/Join/exp.test007.ksh | 14 - test/sql/Join/exp.test008.ksh | 42 - test/sql/Join/exp.test009.ksh | 27 - test/sql/Join/exp.test010.ksh | 19 - test/sql/Join/exp.test011.ksh | 13 - test/sql/Join/exp.test012.ksh | 102 -- test/sql/Join/exp.test013.ksh | 87 -- test/sql/Join/exp.test014.ksh | 82 -- test/sql/Join/exp.test015.ksh | 76 -- test/sql/Join/exp.test016.ksh | 60 -- test/sql/Join/exp.test017.ksh | 60 -- test/sql/Join/exp.test018.ksh | 60 -- test/sql/Join/exp1.test004.ksh | 8 - test/sql/Join/join1.sql | 11 - test/sql/Join/join10.sql | 6 - test/sql/Join/join11.sql | 6 - test/sql/Join/join2.sql | 5 - test/sql/Join/join3.sql | 7 - test/sql/Join/join31.sql | 41 - test/sql/Join/join32.sql | 18 - test/sql/Join/join33.sql | 11 - test/sql/Join/join34.sql | 16 - test/sql/Join/join4.sql | 7 - test/sql/Join/join5.sql | 4 - test/sql/Join/join6.sql | 2 - test/sql/Join/join7.sql | 5 - test/sql/Join/join8.sql | 15 - test/sql/Join/join9.sql | 11 - test/sql/Join/join_between.sql | 9 - test/sql/Join/join_between_notexist.sql | 4 - test/sql/Join/join_in.sql | 12 - test/sql/Join/join_in_notexist.sql | 4 - test/sql/Join/join_like.sql | 10 - test/sql/Join/join_like_notexist1.sql | 2 - test/sql/Join/join_like_notexist2.sql | 2 - test/sql/Join/quit.sql | 2 - test/sql/Join/tablet11.sql | 5 - test/sql/Join/tablet11t12.sql | 10 - test/sql/Join/tablet11t12t13.sql | 15 - test/sql/Join/tablet11t13.sql | 9 - test/sql/Join/tablet12.sql | 6 - test/sql/Join/tablet13.sql | 4 - test/sql/Join/test001.ksh | 34 - test/sql/Join/test002.ksh | 33 - test/sql/Join/test003.ksh | 31 - test/sql/Join/test004.ksh | 34 - test/sql/Join/test005.ksh | 33 - test/sql/Join/test006.ksh | 33 - test/sql/Join/test007.ksh | 37 - test/sql/Join/test008.ksh | 41 - test/sql/Join/test009.ksh | 41 - test/sql/Join/test010.ksh | 38 - test/sql/Join/test011.ksh | 37 - test/sql/Join/test012.ksh | 23 - test/sql/Join/test013.ksh | 33 - test/sql/Join/test014.ksh | 33 - test/sql/Join/test015.ksh | 33 - test/sql/Join/test016.ksh | 25 - test/sql/Join/test017.ksh | 25 - test/sql/Join/test018.ksh | 32 - test/sqlapi/Connect/Makefile | 87 -- test/sqlapi/Connect/common.h | 37 - test/sqlapi/Connect/conntest1.c | 26 - test/sqlapi/Connect/conntest10.c | 72 -- test/sqlapi/Connect/conntest11.c | 72 -- test/sqlapi/Connect/conntest2.c | 28 - test/sqlapi/Connect/conntest3.c | 32 - test/sqlapi/Connect/conntest4.c | 34 - test/sqlapi/Connect/conntest5.c | 67 -- test/sqlapi/Connect/conntest6.c | 24 - test/sqlapi/Connect/conntest7.c | 20 - test/sqlapi/Connect/conntest8.c | 20 - test/sqlapi/Connect/conntest9.c | 20 - test/sqlapi/Connect/exp.test010 | 9 - test/sqlapi/Connect/exp.test010n | 9 - test/sqlapi/Connect/exp.test011 | 6 - test/sqlapi/Connect/exp.test011n | 6 - test/sqlapi/Makefile | 35 - test/sqlapi/Parameter/Makefile | 56 -- test/sqlapi/Parameter/common.h | 37 - test/sqlapi/Parameter/exp.test001 | 146 --- test/sqlapi/Parameter/exp.test001n | 146 --- test/sqlapi/Parameter/exp.test002 | 14 - test/sqlapi/Parameter/exp.test002n | 14 - test/sqlapi/Parameter/exp.test003 | 10 - test/sqlapi/Parameter/exp.test003n | 10 - test/sqlapi/Parameter/exp.test004 | 17 - test/sqlapi/Parameter/exp.test004n | 17 - test/sqlapi/Parameter/paratest1.c | 141 --- test/sqlapi/Parameter/paratest100.c | 157 ---- test/sqlapi/Parameter/paratest2.c | 133 --- test/sqlapi/Parameter/paratest3.c | 153 --- test/sqlapi/Parameter/paratest4.c | 155 --- test/sqlapi/Select/Makefile | 84 -- test/sqlapi/Select/common.h | 37 - test/sqlapi/Select/create.sql | 61 -- test/sqlapi/Select/csql.conf | 70 -- test/sqlapi/Select/exp.test001 | 11 - test/sqlapi/Select/exp.test002 | 62 -- test/sqlapi/Select/exp.test005.ksh | 97 -- test/sqlapi/Select/exp.test010 | 62 -- test/sqlapi/Select/exp.test010n | 62 -- test/sqlapi/Select/exp.test011 | 9 - test/sqlapi/Select/paratest1.c | 196 ---- test/sqlapi/Select/selecttest1.c | 110 --- test/sqlapi/Select/selecttest10.c | 130 --- test/sqlapi/Select/selecttest11.c | 112 --- test/sqlapi/Select/selecttest2.c | 130 --- test/sqlapi/Select/selecttest3.c | 79 -- test/sqlapi/Select/selecttest4.c | 66 -- test/sqlapi/Select/selecttest5.c | 28 - test/sqlapi/Select/selecttest6.c | 73 -- test/sqlapi/Select/selecttest7.c | 79 -- test/sqlapi/Select/selecttest8.c | 42 - test/sqlapi/Select/selecttest9.c | 37 - test/sqlapi/Select/test005.ksh | 28 - test/sqlnetwork/Connect/Makefile | 67 -- test/sqlnetwork/Connect/conntest1.c | 33 - test/sqlnetwork/Connect/conntest10.c | 95 -- test/sqlnetwork/Connect/conntest11.c | 87 -- test/sqlnetwork/Connect/conntest2.c | 38 - test/sqlnetwork/Connect/conntest3.c | 46 - test/sqlnetwork/Connect/conntest4.c | 41 - test/sqlnetwork/Connect/conntest5.c | 86 -- test/sqlnetwork/Connect/conntest6.c | 28 - test/sqlnetwork/Connect/conntest7.c | 24 - test/sqlnetwork/Connect/conntest8.c | 24 - test/sqlnetwork/Connect/conntest9.c | 24 - test/sqlnetwork/Connect/exp.test010 | 96 -- test/sqlnetwork/Connect/exp.test011 | 88 -- test/sqlnetwork/Jdbcnetwork/ConnTest1.java | 20 - test/sqlnetwork/Jdbcnetwork/ConnTest10.java | 19 - test/sqlnetwork/Jdbcnetwork/ConnTest11.java | 19 - test/sqlnetwork/Jdbcnetwork/ConnTest12.java | 18 - test/sqlnetwork/Jdbcnetwork/ConnTest13.java | 18 - test/sqlnetwork/Jdbcnetwork/ConnTest14.java | 18 - test/sqlnetwork/Jdbcnetwork/ConnTest15.java | 18 - test/sqlnetwork/Jdbcnetwork/ConnTest16.java | 25 - test/sqlnetwork/Jdbcnetwork/ConnTest17.java | 24 - test/sqlnetwork/Jdbcnetwork/ConnTest18.java | 24 - test/sqlnetwork/Jdbcnetwork/ConnTest19.java | 26 - test/sqlnetwork/Jdbcnetwork/ConnTest2.java | 18 - test/sqlnetwork/Jdbcnetwork/ConnTest20.java | 23 - test/sqlnetwork/Jdbcnetwork/ConnTest3.java | 18 - test/sqlnetwork/Jdbcnetwork/ConnTest4.java | 19 - test/sqlnetwork/Jdbcnetwork/ConnTest5.java | 18 - test/sqlnetwork/Jdbcnetwork/ConnTest6.java | 18 - test/sqlnetwork/Jdbcnetwork/ConnTest7.java | 18 - test/sqlnetwork/Jdbcnetwork/ConnTest8.java | 18 - test/sqlnetwork/Jdbcnetwork/ConnTest9.java | 18 - test/sqlnetwork/Jdbcnetwork/Makefile | 13 - test/sqlnetwork/Jdbcnetwork/StmtTest1.java | 87 -- test/sqlnetwork/Jdbcnetwork/StmtTest10.java | 91 -- test/sqlnetwork/Jdbcnetwork/StmtTest11.java | 53 -- test/sqlnetwork/Jdbcnetwork/StmtTest12.java | 99 -- test/sqlnetwork/Jdbcnetwork/StmtTest13.java | 58 -- test/sqlnetwork/Jdbcnetwork/StmtTest2.java | 61 -- test/sqlnetwork/Jdbcnetwork/StmtTest3.java | 63 -- test/sqlnetwork/Jdbcnetwork/StmtTest4.java | 19 - test/sqlnetwork/Jdbcnetwork/StmtTest5.java | 57 -- test/sqlnetwork/Jdbcnetwork/StmtTest6.java | 63 -- test/sqlnetwork/Jdbcnetwork/StmtTest7.java | 93 -- test/sqlnetwork/Jdbcnetwork/StmtTest8.java | 64 -- test/sqlnetwork/Jdbcnetwork/StmtTest9.java | 93 -- test/sqlnetwork/Jdbcnetwork/test001.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test002.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test003.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test004.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test005.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test006.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test007.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test008.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test009.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test010.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test011.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test012.ksh | 16 - test/sqlnetwork/Jdbcnetwork/test013.ksh | 16 - test/sqlnetwork/Jdbcnetwork/test014.ksh | 16 - test/sqlnetwork/Jdbcnetwork/test015.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test016.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test017.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test018.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test019.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test020.ksh | 16 - test/sqlnetwork/Jdbcnetwork/test021.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test022.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test023.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test024.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test025.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test026.ksh | 16 - test/sqlnetwork/Jdbcnetwork/test027.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test028.ksh | 15 - test/sqlnetwork/Jdbcnetwork/test029.ksh | 16 - test/sqlnetwork/Jdbcnetwork/test030.ksh | 19 - test/sqlnetwork/Jdbcnetwork/test031.ksh | 16 - test/sqlnetwork/Jdbcnetwork/test032.ksh | 17 - test/sqlnetwork/Jdbcnetwork/test033.ksh | 19 - test/sqlnetwork/Parameter/Makefile | 54 -- test/sqlnetwork/Parameter/exp.test001 | 207 ---- test/sqlnetwork/Parameter/exp.test002 | 208 ---- test/sqlnetwork/Parameter/exp.test003 | 227 ----- test/sqlnetwork/Parameter/exp.test004 | 258 ----- test/sqlnetwork/Parameter/paratest1.c | 170 ---- test/sqlnetwork/Parameter/paratest100.c | 189 ---- test/sqlnetwork/Parameter/paratest2.c | 166 ---- test/sqlnetwork/Parameter/paratest3.c | 192 ---- test/sqlnetwork/Parameter/paratest4.c | 198 ---- test/sqlnetwork/Select/Makefile | 66 -- test/sqlnetwork/Select/exp.test001 | 179 ---- test/sqlnetwork/Select/exp.test002 | 177 ---- test/sqlnetwork/Select/exp.test010 | 177 ---- test/sqlnetwork/Select/selecttest1.c | 151 --- test/sqlnetwork/Select/selecttest10.c | 212 ----- test/sqlnetwork/Select/selecttest2.c | 177 ---- test/sqlnetwork/Select/selecttest3.c | 144 --- test/sqlnetwork/Select/selecttest4.c | 94 -- test/sqlnetwork/Select/selecttest5.c | 51 - test/sqlnetwork/Select/selecttest6.c | 124 --- test/sqlnetwork/Select/selecttest7.c | 125 --- test/sqlnetwork/Select/selecttest8.c | 49 - test/sqlnetwork/Select/selecttest9.c | 47 - test/system/Allocator/Makefile | 69 -- test/system/Allocator/TODO | 2 - test/system/Allocator/common.h | 153 --- test/system/Allocator/create.c | 17 - test/system/Allocator/createNoIndex.c | 15 - test/system/Allocator/dbsizelimit.c | 47 - test/system/Allocator/delete1.c | 15 - test/system/Allocator/delete100.c | 15 - test/system/Allocator/delete1000.c | 15 - test/system/Allocator/deleteAll.c | 15 - test/system/Allocator/drop.c | 15 - test/system/Allocator/exp.test001.ksh | 61 -- test/system/Allocator/exp.test002.ksh | 61 -- test/system/Allocator/exp.test003.ksh | 61 -- test/system/Allocator/exp.test004.ksh | 61 -- test/system/Allocator/exp.test005.ksh | 114 --- test/system/Allocator/exp.test006.ksh | 115 --- test/system/Allocator/exp.test007.ksh | 375 -------- test/system/Allocator/exp.test008.ksh | 1 - test/system/Allocator/exp.test021 | 10 - test/system/Allocator/exp.test022 | 10 - test/system/Allocator/exp.test023 | 10 - test/system/Allocator/exp.test024 | 10 - test/system/Allocator/exp.test025 | 10 - test/system/Allocator/insert1.c | 15 - test/system/Allocator/insert100.c | 15 - test/system/Allocator/insert1000.c | 14 - test/system/Allocator/test001.ksh | 79 -- test/system/Allocator/test002.ksh | 68 -- test/system/Allocator/test003.ksh | 77 -- test/system/Allocator/test004.ksh | 72 -- test/system/Allocator/test005.ksh | 52 - test/system/Allocator/test006.ksh | 53 -- test/system/Allocator/test007.ksh | 52 - test/system/Allocator/test008.ksh | 17 - test/system/Allocator/tuplesize1.c | 32 - test/system/Allocator/tuplesize2.c | 33 - test/system/Allocator/tuplesize3.c | 34 - test/system/Allocator/tuplesize4.c | 35 - test/system/Allocator/tuplesize5.c | 36 - test/system/Makefile | 35 - test/system/config/Makefile | 42 - test/system/config/conftest1.c | 10 - test/system/config/conftest2.c | 20 - test/system/config/connect.c | 10 - test/system/config/csql.conf | 45 - test/system/config/exp.test002 | 23 - test/system/config/exp.test003.ksh | 3 - test/system/config/exp.test004.ksh | 3 - test/system/config/exp.test005.ksh | 3 - test/system/config/exp.test006.ksh | 3 - test/system/config/exp.test007.ksh | 3 - test/system/config/exp.test008.ksh | 3 - test/system/config/exp.test009.ksh | 3 - test/system/config/exp.test010.ksh | 3 - test/system/config/exp.test011.ksh | 3 - test/system/config/exp.test012.ksh | 3 - test/system/config/exp.test013.ksh | 3 - test/system/config/exp.test014.ksh | 3 - test/system/config/exp.test015.ksh | 3 - test/system/config/exp.test016.ksh | 3 - test/system/config/exp.test017.ksh | 3 - test/system/config/exp.test018.ksh | 3 - test/system/config/exp.test019.ksh | 3 - test/system/config/exp.test021.ksh | 3 - test/system/config/exp.test022.ksh | 3 - test/system/config/exp.test023.ksh | 3 - test/system/config/exp.test024.ksh | 3 - test/system/config/exp.test027.ksh | 3 - test/system/config/exp.test028.ksh | 3 - test/system/config/exp.test029.ksh | 3 - test/system/config/exp.test030.ksh | 3 - test/system/config/test003.ksh | 16 - test/system/config/test004.ksh | 18 - test/system/config/test005.ksh | 19 - test/system/config/test006.ksh | 18 - test/system/config/test007.ksh | 19 - test/system/config/test008.ksh | 18 - test/system/config/test009.ksh | 18 - test/system/config/test010.ksh | 18 - test/system/config/test011.ksh | 18 - test/system/config/test012.ksh | 18 - test/system/config/test013.ksh | 18 - test/system/config/test014.ksh | 18 - test/system/config/test015.ksh | 18 - test/system/config/test016.ksh | 18 - test/system/config/test017.ksh | 19 - test/system/config/test018.ksh | 18 - test/system/config/test019.ksh | 18 - test/system/config/test020.ksh | 18 - test/system/config/test021.ksh | 18 - test/system/config/test022.ksh | 18 - test/system/config/test023.ksh | 18 - test/system/config/test024.ksh | 18 - test/system/config/test025.ksh | 18 - test/system/config/test026.ksh | 18 - test/system/config/test027.ksh | 18 - test/system/config/test028.ksh | 18 - test/system/config/test029.ksh | 18 - test/system/config/test030.ksh | 18 - test/system/config/test031.ksh | 18 - test/system/config/test032.ksh | 18 - test/system/index/TODO | 24 - test/system/lock/Makefile | 78 -- test/system/lock/TODO | 2 - test/system/lock/common.h | 153 --- test/system/lock/exp.test001 | 0 test/system/lock/exp.test001a | 114 --- test/system/lock/exp.test002 | 113 --- test/system/lock/exp.test002a | 114 --- test/system/lock/exp.test003 | 14 - test/system/lock/exp.test003a | 15 - test/system/lock/exp.test004 | 114 --- test/system/lock/exp.test004a | 115 --- test/system/lock/exp.test005 | 114 --- test/system/lock/exp.test005a | 115 --- test/system/lock/exp.test006 | 114 --- test/system/lock/exp.test006a | 115 --- test/system/lock/exp.test007 | 114 --- test/system/lock/exp.test007a | 115 --- test/system/lock/exp.test008 | 114 --- test/system/lock/exp.test008a | 115 --- test/system/lock/exp.test009 | 114 --- test/system/lock/exp.test009a | 115 --- test/system/lock/locktest001.c | 36 - test/system/lock/locktest002.c | 36 - test/system/lock/locktest003.c | 43 - test/system/lock/locktest004.c | 43 - test/system/lock/locktest005.c | 43 - test/system/lock/locktest006.c | 43 - test/system/lock/locktest007.c | 43 - test/system/lock/locktest008.c | 43 - test/system/lock/locktest009.c | 43 - test/system/proc/TODO | 25 - test/system/proc/exp.test001.ksh | 6 - test/system/proc/test001.ksh | 36 - test/system/trans/Makefile | 83 -- test/system/trans/common.h | 153 --- test/system/trans/create.c | 16 - test/system/trans/drop.c | 15 - test/system/trans/exp.test001.ksh | 20 - test/system/trans/exp.test002.ksh | 20 - test/system/trans/exp.test003 | 141 --- test/system/trans/exp.test003a | 192 ---- test/system/trans/exp.test004 | 141 --- test/system/trans/exp.test004a | 192 ---- test/system/trans/exp.test005 | 32 - test/system/trans/exp.test005a | 33 - test/system/trans/exp.test006 | 32 - test/system/trans/exp.test006a | 33 - test/system/trans/exp.test007 | 142 --- test/system/trans/exp.test007a | 143 --- test/system/trans/exp.test008 | 142 --- test/system/trans/exp.test008a | 143 --- test/system/trans/exp.test009 | 142 --- test/system/trans/exp.test009a | 193 ---- test/system/trans/exp.test010 | 142 --- test/system/trans/exp.test010a | 193 ---- test/system/trans/insert1andAbort.c | 17 - test/system/trans/insert1andCommit.c | 17 - test/system/trans/locktest009.c | 44 - test/system/trans/test001.ksh | 56 -- test/system/trans/test002.ksh | 56 -- test/system/trans/transtest003.c | 36 - test/system/trans/transtest004.c | 36 - test/system/trans/transtest005.c | 45 - test/system/trans/transtest006.c | 45 - test/system/trans/transtest007.c | 45 - test/system/trans/transtest008.c | 45 - test/system/trans/transtest009.c | 45 - test/system/trans/transtest010.c | 45 - test/tools/Durability/auto.sql | 1 - test/tools/Durability/compo_index2_10.sql | 20 - test/tools/Durability/create_10.sql | 20 - test/tools/Durability/create_pri_10.sql | 20 - test/tools/Durability/create_t1.sql | 2 - test/tools/Durability/create_t2.sql | 2 - test/tools/Durability/csql.conf | 103 -- test/tools/Durability/delete_10.sql | 20 - test/tools/Durability/delete_t1.sql | 2 - test/tools/Durability/drop_10.sql | 20 - test/tools/Durability/drop_t1.sql | 2 - test/tools/Durability/exp.test001.ksh | 12 - test/tools/Durability/exp.test002.ksh | 9 - test/tools/Durability/exp.test003.ksh | 12 - test/tools/Durability/exp.test004.ksh | 12 - test/tools/Durability/exp.test005.ksh | 39 - test/tools/Durability/exp.test006.ksh | 51 - test/tools/Durability/exp.test007.ksh | 64 -- test/tools/Durability/exp.test008.ksh | 31 - test/tools/Durability/exp.test009.ksh | 675 ------------- test/tools/Durability/exp.test010.ksh | 318 ------- test/tools/Durability/exp.test011.ksh | 318 ------- test/tools/Durability/exp.test012.ksh | 596 ------------ test/tools/Durability/index_10.sql | 20 - test/tools/Durability/ins_commit.sql | 26 - test/tools/Durability/ins_rollback.sql | 26 - test/tools/Durability/insert_10.sql | 169 ---- test/tools/Durability/insert_a.sql | 4 - test/tools/Durability/insert_b.sql | 8 - test/tools/Durability/insert_t1.sql | 4 - test/tools/Durability/rollback.sql | 1 - test/tools/Durability/select_10.sql | 20 - test/tools/Durability/select_t1.sql | 2 - test/tools/Durability/show_t1.sql | 2 - test/tools/Durability/test001.ksh | 68 -- test/tools/Durability/test002.ksh | 67 -- test/tools/Durability/test003.ksh | 68 -- test/tools/Durability/test004.ksh | 68 -- test/tools/Durability/test005.ksh | 151 --- test/tools/Durability/test006.ksh | 83 -- test/tools/Durability/test007.ksh | 88 -- test/tools/Durability/test008.ksh | 115 --- test/tools/Durability/test009.ksh | 123 --- test/tools/Durability/test010.ksh | 191 ---- test/tools/Durability/test011.ksh | 192 ---- test/tools/Durability/test012.ksh | 160 ---- test/tools/Durability/update_10.sql | 40 - test/tools/Durability/update_t1.sql | 2 - test/tools/Makefile | 35 - test/tools/catalog/Makefile | 40 - test/tools/catalog/common.h | 135 --- test/tools/catalog/create.c | 20 - test/tools/catalog/create.sql | 14 - test/tools/catalog/create1.sql | 3 - test/tools/catalog/createPriFlagTest.sql | 5 - test/tools/catalog/csql.conf | 70 -- test/tools/catalog/delete.sql | 3 - test/tools/catalog/drop.c | 17 - test/tools/catalog/dropIndex.sql | 2 - test/tools/catalog/dropt1.sql | 3 - test/tools/catalog/dropt2.sql | 3 - test/tools/catalog/dropt4t5.sql | 2 - test/tools/catalog/exp.test001.ksh | 20 - test/tools/catalog/exp.test005.ksh | 276 ------ test/tools/catalog/exp.test006.ksh | 0 test/tools/catalog/exp.test007.ksh | 65 -- test/tools/catalog/insert.c | 16 - test/tools/catalog/insert.sql | 22 - test/tools/catalog/test001.ksh | 39 - test/tools/catalog/test002.ksh | 66 -- test/tools/catalog/test003.ksh | 53 -- test/tools/catalog/test004.ksh | 60 -- test/tools/catalog/test005.ksh | 57 -- test/tools/catalog/test006.ksh | 91 -- test/tools/catalog/test007.ksh | 48 - test/tools/csql/TODO | 17 - test/tools/csql/agg1.sql | 42 - test/tools/csql/autocommit1.sql | 9 - test/tools/csql/autocommit10.sql | 20 - test/tools/csql/autocommit11.sql | 22 - test/tools/csql/autocommit12.sql | 18 - test/tools/csql/autocommit13.sql | 20 - test/tools/csql/autocommit14.sql | 20 - test/tools/csql/autocommit15.sql | 20 - test/tools/csql/autocommit16.sql | 20 - test/tools/csql/autocommit17.sql | 22 - test/tools/csql/autocommit18.sql | 18 - test/tools/csql/autocommit2.sql | 21 - test/tools/csql/autocommit3.sql | 24 - test/tools/csql/autocommit4.sql | 25 - test/tools/csql/autocommit5.sql | 28 - test/tools/csql/autocommit6.sql | 14 - test/tools/csql/autocommit7.sql | 20 - test/tools/csql/autocommit8.sql | 22 - test/tools/csql/autocommit9.sql | 22 - test/tools/csql/bit_test024.ksh | 17 - test/tools/csql/comp1.sql | 23 - test/tools/csql/comp2.sql | 24 - test/tools/csql/comp3.sql | 24 - test/tools/csql/comp4.sql | 7 - test/tools/csql/composite1.sql | 62 -- test/tools/csql/composite2.sql | 62 -- test/tools/csql/composite3.sql | 10 - test/tools/csql/csql1.sql | 28 - test/tools/csql/csql10.sql | 26 - test/tools/csql/csql11.sql | 6 - test/tools/csql/csql12.sql | 24 - test/tools/csql/csql2.sql | 34 - test/tools/csql/csql3.sql | 52 - test/tools/csql/csql4.sql | 7 - test/tools/csql/csql5.sql | 5 - test/tools/csql/csql6.sql | 11 - test/tools/csql/csql7.sql | 8 - test/tools/csql/csql8.sql | 14 - test/tools/csql/csql9.sql | 33 - test/tools/csql/datatype1.sql | 48 - test/tools/csql/datatype10.sql | 50 - test/tools/csql/datatype11.sql | 46 - test/tools/csql/datatype12.sql | 48 - test/tools/csql/datatype2.sql | 51 - test/tools/csql/datatype3.sql | 48 - test/tools/csql/datatype4.sql | 39 - test/tools/csql/datatype5.sql | 36 - test/tools/csql/datatype6.sql | 29 - test/tools/csql/datatype7.sql | 49 - test/tools/csql/datatype8.sql | 38 - test/tools/csql/datatype9.sql | 48 - test/tools/csql/dbobjname.sql | 39 - test/tools/csql/ddl.sql | 8 - test/tools/csql/diffintindex.sql | 409 -------- test/tools/csql/drop.sql | 1 - test/tools/csql/drop1.sql | 9 - test/tools/csql/drop2.sql | 2 - test/tools/csql/exp.test001.ksh | 17 - test/tools/csql/exp.test002.ksh | 51 - test/tools/csql/exp.test003.ksh | 71 -- test/tools/csql/exp.test004.ksh | 157 ---- test/tools/csql/exp.test005.ksh | 11 - test/tools/csql/exp.test006.ksh | 5 - test/tools/csql/exp.test007.ksh | 9 - test/tools/csql/exp.test008.ksh | 7 - test/tools/csql/exp.test009.ksh | 21 - test/tools/csql/exp.test010.ksh | 72 -- test/tools/csql/exp.test011.ksh | 10 - test/tools/csql/exp.test012.ksh | 49 - test/tools/csql/exp.test021.ksh | 146 --- test/tools/csql/exp.test022.ksh | 181 ---- test/tools/csql/exp.test023.ksh | 148 --- test/tools/csql/exp.test024.ksh | 2 - test/tools/csql/exp.test025.ksh | 71 -- test/tools/csql/exp.test026.ksh | 55 -- test/tools/csql/exp.test027.ksh | 146 --- test/tools/csql/exp.test028.ksh | 80 -- test/tools/csql/exp.test029.ksh | 130 --- test/tools/csql/exp.test030.ksh | 58 -- test/tools/csql/exp.test031.ksh | 61 -- test/tools/csql/exp.test032.ksh | 59 -- test/tools/csql/exp.test033.ksh | 17 - test/tools/csql/exp.test034.ksh | 1162 ----------------------- test/tools/csql/exp.test034a.ksh | 1107 ---------------------- test/tools/csql/exp.test035.ksh | 17 - test/tools/csql/exp.test036.ksh | 256 ----- test/tools/csql/exp.test037.ksh | 146 --- test/tools/csql/exp.test038.ksh | 84 -- test/tools/csql/exp.test039.ksh | 84 -- test/tools/csql/exp.test040.ksh | 165 ---- test/tools/csql/exp.test041.ksh | 142 --- test/tools/csql/exp.test042.ksh | 153 --- test/tools/csql/exp.test043.ksh | 6 - test/tools/csql/exp.test044.ksh | 6 - test/tools/csql/exp.test045.ksh | 288 ------ test/tools/csql/exp.test046.ksh | 288 ------ test/tools/csql/exp.test047.ksh | 109 --- test/tools/csql/exp.test048.ksh | 148 --- test/tools/csql/exp.test049.ksh | 101 -- test/tools/csql/exp.test050.ksh | 42 - test/tools/csql/exp.test051.ksh | 76 -- test/tools/csql/exp.test052.ksh | 13 - test/tools/csql/exp.test053.ksh | 9 - test/tools/csql/exp.test054.ksh | 9 - test/tools/csql/exp.test055.ksh | 9 - test/tools/csql/exp.test056.ksh | 11 - test/tools/csql/exp.test057.ksh | 11 - test/tools/csql/exp.test058.ksh | 10 - test/tools/csql/exp.test059.ksh | 10 - test/tools/csql/exp.test060.ksh | 7 - test/tools/csql/exp.test061.ksh | 8 - test/tools/csql/exp.test062.ksh | 9 - test/tools/csql/exp.test063.ksh | 11 - test/tools/csql/exp.test064.ksh | 26 - test/tools/csql/exp.test065.ksh | 25 - test/tools/csql/exp.test066.ksh | 28 - test/tools/csql/exp.test067.ksh | 25 - test/tools/csql/exp.test068.ksh | 28 - test/tools/csql/exp.test069.ksh | 28 - test/tools/csql/exp.test070.ksh | 31 - test/tools/csql/exp.test071.ksh | 30 - test/tools/csql/exp.test072.ksh | 39 - test/tools/csql/exp.test073.ksh | 35 - test/tools/csql/exp.test074.ksh | 43 - test/tools/csql/exp.test075.ksh | 44 - test/tools/csql/exp.test076.ksh | 38 - test/tools/csql/exp.test077.ksh | 39 - test/tools/csql/exp.test078.ksh | 31 - test/tools/csql/exp.test079.ksh | 33 - test/tools/csql/exp.test080.ksh | 41 - test/tools/csql/exp.test081.ksh | 42 - test/tools/csql/exp.test082.ksh | 36 - test/tools/csql/exp.test083.ksh | 43 - test/tools/csql/exp.test084.ksh | 55 -- test/tools/csql/exp.test085.ksh | 52 - test/tools/csql/exp.test086.ksh | 59 -- test/tools/csql/exp.test087.ksh | 40 - test/tools/csql/exp.test088.ksh | 193 ---- test/tools/csql/exp.test089.ksh | 39 - test/tools/csql/exp.test090.ksh | 170 ---- test/tools/csql/exp.test091.ksh | 1198 ------------------------ test/tools/csql/expresion.sql | 51 - test/tools/csql/fieldlimit.sql | 221 ----- test/tools/csql/indexontuples.sql | 441 --------- test/tools/csql/indextran1.sql | 104 -- test/tools/csql/indextran2.sql | 135 --- test/tools/csql/indextran3.sql | 135 --- test/tools/csql/indextran4.sql | 134 --- test/tools/csql/null1.sql | 25 - test/tools/csql/null2.sql | 26 - test/tools/csql/null3.sql | 25 - test/tools/csql/null4.sql | 25 - test/tools/csql/null5.sql | 25 - test/tools/csql/null6.sql | 17 - test/tools/csql/null7.sql | 9 - test/tools/csql/quit.sql | 1 - test/tools/csql/rowsizelimit.sql | 4 - test/tools/csql/selcond.sql | 26 - test/tools/csql/selectstar.sql | 3 - test/tools/csql/selecttest.sql | 32 - test/tools/csql/singleandcompind.sql | 41 - test/tools/csql/test001.ksh | 59 -- test/tools/csql/test002.ksh | 17 - test/tools/csql/test003.ksh | 17 - test/tools/csql/test004.ksh | 17 - test/tools/csql/test005.ksh | 17 - test/tools/csql/test006.ksh | 17 - test/tools/csql/test007.ksh | 17 - test/tools/csql/test008.ksh | 17 - test/tools/csql/test009.ksh | 17 - test/tools/csql/test010.ksh | 17 - test/tools/csql/test011.ksh | 17 - test/tools/csql/test012.ksh | 17 - test/tools/csql/test021.ksh | 17 - test/tools/csql/test022.ksh | 17 - test/tools/csql/test023.ksh | 17 - test/tools/csql/test025.ksh | 17 - test/tools/csql/test026.ksh | 17 - test/tools/csql/test027.ksh | 17 - test/tools/csql/test028.ksh | 17 - test/tools/csql/test029.ksh | 23 - test/tools/csql/test030.ksh | 23 - test/tools/csql/test031.ksh | 23 - test/tools/csql/test032.ksh | 23 - test/tools/csql/test033.ksh | 23 - test/tools/csql/test034.ksh | 20 - test/tools/csql/test034a.ksh | 21 - test/tools/csql/test035.ksh | 26 - test/tools/csql/test036.ksh | 31 - test/tools/csql/test037.ksh | 17 - test/tools/csql/test038.ksh | 17 - test/tools/csql/test039.ksh | 17 - test/tools/csql/test040.ksh | 17 - test/tools/csql/test041.ksh | 17 - test/tools/csql/test042.ksh | 17 - test/tools/csql/test043.ksh | 23 - test/tools/csql/test044.ksh | 23 - test/tools/csql/test045.ksh | 36 - test/tools/csql/test046.ksh | 36 - test/tools/csql/test047.ksh | 24 - test/tools/csql/test048.ksh | 23 - test/tools/csql/test049.ksh | 17 - test/tools/csql/test050.ksh | 24 - test/tools/csql/test051.ksh | 31 - test/tools/csql/test052.ksh | 26 - test/tools/csql/test053.ksh | 26 - test/tools/csql/test054.ksh | 26 - test/tools/csql/test055.ksh | 26 - test/tools/csql/test056.ksh | 27 - test/tools/csql/test057.ksh | 27 - test/tools/csql/test058.ksh | 26 - test/tools/csql/test059.ksh | 26 - test/tools/csql/test060.ksh | 25 - test/tools/csql/test061.ksh | 25 - test/tools/csql/test062.ksh | 26 - test/tools/csql/test063.ksh | 27 - test/tools/csql/test064.ksh | 25 - test/tools/csql/test065.ksh | 24 - test/tools/csql/test066.ksh | 24 - test/tools/csql/test067.ksh | 24 - test/tools/csql/test068.ksh | 24 - test/tools/csql/test069.ksh | 24 - test/tools/csql/test070.ksh | 25 - test/tools/csql/test071.ksh | 26 - test/tools/csql/test072.ksh | 26 - test/tools/csql/test073.ksh | 26 - test/tools/csql/test074.ksh | 26 - test/tools/csql/test075.ksh | 26 - test/tools/csql/test076.ksh | 26 - test/tools/csql/test077.ksh | 26 - test/tools/csql/test078.ksh | 26 - test/tools/csql/test079.ksh | 26 - test/tools/csql/test080.ksh | 26 - test/tools/csql/test081.ksh | 26 - test/tools/csql/test082.ksh | 26 - test/tools/csql/test083.ksh | 28 - test/tools/csql/test084.ksh | 29 - test/tools/csql/test085.ksh | 29 - test/tools/csql/test086.ksh | 29 - test/tools/csql/test087.ksh | 23 - test/tools/csql/test088.ksh | 48 - test/tools/csql/test089.ksh | 26 - test/tools/csql/test090.ksh | 31 - test/tools/csql/test091.ksh | 34 - test/tools/csql/tree0.sql | 9 - test/tools/csql/tree1.sql | 9 - test/tools/csql/tree10.sql | 6 - test/tools/csql/tree11.sql | 8 - test/tools/csql/tree12.sql | 8 - test/tools/csql/tree13.sql | 6 - test/tools/csql/tree14.sql | 6 - test/tools/csql/tree15.sql | 4 - test/tools/csql/tree16.sql | 4 - test/tools/csql/tree17.sql | 6 - test/tools/csql/tree18.sql | 8 - test/tools/csql/tree19.sql | 12 - test/tools/csql/tree2.sql | 53 -- test/tools/csql/tree20.sql | 14 - test/tools/csql/tree21.sql | 14 - test/tools/csql/tree22.sql | 14 - test/tools/csql/tree23.sql | 14 - test/tools/csql/tree24.sql | 14 - test/tools/csql/tree3.sql | 53 -- test/tools/csql/tree4.sql | 75 -- test/tools/csql/tree5.sql | 32 - test/tools/csql/tree6.sql | 3 - test/tools/csql/tree7.sql | 9 - test/tools/csql/tree8.sql | 6 - test/tools/csql/tree9.sql | 6 - test/tools/csql/uniqueindontuples.sql | 8 - test/tools/csql/uniquetreeindontuples.sql | 6 - test/tools/csql/updatetest.sql | 53 -- test/tools/csqldump/Makefile | 36 - test/tools/csqldump/csql.conf | 62 -- test/tools/csqldump/drop.sql | 1 - test/tools/csqldump/dropall.sql | 11 - test/tools/csqldump/exp.test002.ksh | 31 - test/tools/csqldump/exp.test003.ksh | 108 --- test/tools/csqldump/exp.test004.ksh | 106 --- test/tools/csqldump/exp.test005.ksh | 109 --- test/tools/csqldump/exp.test006.ksh | 105 --- test/tools/csqldump/exp.test007.ksh | 23 - test/tools/csqldump/exp.test008.ksh | 131 --- test/tools/csqldump/exp.test010.ksh | 32 - test/tools/csqldump/exp.test011.ksh | 17 - test/tools/csqldump/exp.test012.ksh | 167 ---- test/tools/csqldump/inputtest002.sql | 26 - test/tools/csqldump/inputtest003.sql | 101 -- test/tools/csqldump/inputtest004.sql | 100 -- test/tools/csqldump/inputtest005.sql | 102 -- test/tools/csqldump/inputtest006.sql | 103 -- test/tools/csqldump/inputtest008.sql | 110 --- test/tools/csqldump/inputtest012.sql | 158 ---- test/tools/csqldump/insert.c | 73 -- test/tools/csqldump/test001.ksh | 19 - test/tools/csqldump/test002.ksh | 34 - test/tools/csqldump/test003.ksh | 39 - test/tools/csqldump/test004.ksh | 39 - test/tools/csqldump/test005.ksh | 39 - test/tools/csqldump/test006.ksh | 32 - test/tools/csqldump/test007.ksh | 43 - test/tools/csqldump/test008.ksh | 32 - test/tools/csqldump/test009.ksh | 20 - test/tools/csqldump/test010.ksh | 34 - test/tools/csqldump/test011.ksh | 36 - test/tools/csqldump/test012.ksh | 34 - 1072 files changed, 58369 deletions(-) delete mode 100644 test/CacheTestModules delete mode 100644 test/Makefile delete mode 100644 test/TestModules delete mode 100644 test/csql.conf delete mode 100755 test/execCacheTests.ksh delete mode 100755 test/execTests.ksh delete mode 100755 test/genReport.ksh delete mode 100755 test/jdbc/Connection/ConnTest1.java delete mode 100644 test/jdbc/Connection/ConnTest10.java delete mode 100644 test/jdbc/Connection/ConnTest11.java delete mode 100644 test/jdbc/Connection/ConnTest12.java delete mode 100644 test/jdbc/Connection/ConnTest13.java delete mode 100644 test/jdbc/Connection/ConnTest14.java delete mode 100644 test/jdbc/Connection/ConnTest15.java delete mode 100644 test/jdbc/Connection/ConnTest16.java delete mode 100644 test/jdbc/Connection/ConnTest17.java delete mode 100644 test/jdbc/Connection/ConnTest18.java delete mode 100644 test/jdbc/Connection/ConnTest19.java delete mode 100755 test/jdbc/Connection/ConnTest2.java delete mode 100644 test/jdbc/Connection/ConnTest20.java delete mode 100644 test/jdbc/Connection/ConnTest22.java delete mode 100644 test/jdbc/Connection/ConnTest24.java delete mode 100644 test/jdbc/Connection/ConnTest25.java delete mode 100644 test/jdbc/Connection/ConnTest26.java delete mode 100644 test/jdbc/Connection/ConnTest27.java delete mode 100644 test/jdbc/Connection/ConnTest29.java delete mode 100755 test/jdbc/Connection/ConnTest3.java delete mode 100644 test/jdbc/Connection/ConnTest34.java delete mode 100755 test/jdbc/Connection/ConnTest4.java delete mode 100755 test/jdbc/Connection/ConnTest5.java delete mode 100755 test/jdbc/Connection/ConnTest6.java delete mode 100644 test/jdbc/Connection/ConnTest8.java delete mode 100644 test/jdbc/Connection/ConnTest9.java delete mode 100644 test/jdbc/Connection/IsoTest1.java delete mode 100644 test/jdbc/Connection/IsoTest2.java delete mode 100644 test/jdbc/Connection/Makefile delete mode 100644 test/jdbc/Connection/exp.test006.ksh delete mode 100755 test/jdbc/Connection/exp.test030.ksh delete mode 100755 test/jdbc/Connection/exp.test031.ksh delete mode 100755 test/jdbc/Connection/exp.test032.ksh delete mode 100755 test/jdbc/Connection/exp.test033.ksh delete mode 100644 test/jdbc/Connection/test001.ksh delete mode 100755 test/jdbc/Connection/test002.ksh delete mode 100755 test/jdbc/Connection/test003.ksh delete mode 100755 test/jdbc/Connection/test004.ksh delete mode 100755 test/jdbc/Connection/test005.ksh delete mode 100755 test/jdbc/Connection/test006.ksh delete mode 100755 test/jdbc/Connection/test008.ksh delete mode 100755 test/jdbc/Connection/test009.ksh delete mode 100755 test/jdbc/Connection/test010.ksh delete mode 100755 test/jdbc/Connection/test011.ksh delete mode 100755 test/jdbc/Connection/test012.ksh delete mode 100755 test/jdbc/Connection/test013.ksh delete mode 100755 test/jdbc/Connection/test014.ksh delete mode 100755 test/jdbc/Connection/test015.ksh delete mode 100755 test/jdbc/Connection/test016.ksh delete mode 100755 test/jdbc/Connection/test017.ksh delete mode 100755 test/jdbc/Connection/test018.ksh delete mode 100755 test/jdbc/Connection/test019.ksh delete mode 100755 test/jdbc/Connection/test020.ksh delete mode 100755 test/jdbc/Connection/test022.ksh delete mode 100755 test/jdbc/Connection/test024.ksh delete mode 100755 test/jdbc/Connection/test025.ksh delete mode 100755 test/jdbc/Connection/test026.ksh delete mode 100755 test/jdbc/Connection/test027.ksh delete mode 100755 test/jdbc/Connection/test029.ksh delete mode 100755 test/jdbc/Connection/test030.ksh delete mode 100755 test/jdbc/Connection/test031.ksh delete mode 100644 test/jdbc/Connection/test034.ksh delete mode 100644 test/jdbc/Gateway/ConnTest01.java delete mode 100644 test/jdbc/Gateway/ConnTest02.java delete mode 100644 test/jdbc/Gateway/ConnTest03.java delete mode 100644 test/jdbc/Gateway/ConnTest04.java delete mode 100644 test/jdbc/Gateway/ConnTest05.java delete mode 100644 test/jdbc/Gateway/ConnTest06.java delete mode 100644 test/jdbc/Gateway/ConnTest07.java delete mode 100644 test/jdbc/Gateway/ConnTest08.java delete mode 100644 test/jdbc/Gateway/ConnTest09.java delete mode 100644 test/jdbc/Gateway/ConnTest10.java delete mode 100644 test/jdbc/Gateway/GwStmt1.java delete mode 100644 test/jdbc/Gateway/GwStmt10.java delete mode 100644 test/jdbc/Gateway/GwStmt2.java delete mode 100644 test/jdbc/Gateway/GwStmt3.java delete mode 100644 test/jdbc/Gateway/GwStmt4.java delete mode 100644 test/jdbc/Gateway/GwStmt5.java delete mode 100644 test/jdbc/Gateway/GwStmt6.java delete mode 100644 test/jdbc/Gateway/GwStmt7.java delete mode 100644 test/jdbc/Gateway/GwStmt8.java delete mode 100644 test/jdbc/Gateway/GwStmt9.java delete mode 100644 test/jdbc/Gateway/GwTest1.java delete mode 100644 test/jdbc/Gateway/GwTest10.java delete mode 100644 test/jdbc/Gateway/GwTest11.java delete mode 100644 test/jdbc/Gateway/GwTest12.java delete mode 100644 test/jdbc/Gateway/GwTest13.java delete mode 100644 test/jdbc/Gateway/GwTest14.java delete mode 100644 test/jdbc/Gateway/GwTest15.java delete mode 100644 test/jdbc/Gateway/GwTest16.java delete mode 100644 test/jdbc/Gateway/GwTest2.java delete mode 100644 test/jdbc/Gateway/GwTest3.java delete mode 100644 test/jdbc/Gateway/GwTest4.java delete mode 100644 test/jdbc/Gateway/GwTest6.java delete mode 100644 test/jdbc/Gateway/GwTest7.java delete mode 100644 test/jdbc/Gateway/GwTest8.java delete mode 100644 test/jdbc/Gateway/GwTest9.java delete mode 100644 test/jdbc/Gateway/Makefile delete mode 100755 test/jdbc/Gateway/test001.ksh delete mode 100755 test/jdbc/Gateway/test002.ksh delete mode 100755 test/jdbc/Gateway/test003.ksh delete mode 100755 test/jdbc/Gateway/test004.ksh delete mode 100755 test/jdbc/Gateway/test005.ksh delete mode 100755 test/jdbc/Gateway/test006.ksh delete mode 100755 test/jdbc/Gateway/test007.ksh delete mode 100755 test/jdbc/Gateway/test008.ksh delete mode 100755 test/jdbc/Gateway/test009.ksh delete mode 100755 test/jdbc/Gateway/test010.ksh delete mode 100755 test/jdbc/Gateway/test031.ksh delete mode 100755 test/jdbc/Gateway/test032.ksh delete mode 100755 test/jdbc/Gateway/test033.ksh delete mode 100755 test/jdbc/Gateway/test034.ksh delete mode 100755 test/jdbc/Gateway/test035.ksh delete mode 100755 test/jdbc/Gateway/test036.ksh delete mode 100755 test/jdbc/Gateway/test037.ksh delete mode 100755 test/jdbc/Gateway/test038.ksh delete mode 100755 test/jdbc/Gateway/test039.ksh delete mode 100755 test/jdbc/Gateway/test040.ksh delete mode 100755 test/jdbc/Gateway/test041.ksh delete mode 100755 test/jdbc/Gateway/test042.ksh delete mode 100755 test/jdbc/Gateway/test043.ksh delete mode 100755 test/jdbc/Gateway/test044.ksh delete mode 100755 test/jdbc/Gateway/test046.ksh delete mode 100755 test/jdbc/Gateway/test047.ksh delete mode 100755 test/jdbc/Gateway/test048.ksh delete mode 100755 test/jdbc/Gateway/test049.ksh delete mode 100755 test/jdbc/Gateway/test050.ksh delete mode 100755 test/jdbc/Gateway/test051.ksh delete mode 100755 test/jdbc/Gateway/test052.ksh delete mode 100755 test/jdbc/Gateway/test053.ksh delete mode 100755 test/jdbc/Gateway/test054.ksh delete mode 100755 test/jdbc/Gateway/test055.ksh delete mode 100755 test/jdbc/Gateway/test056.ksh delete mode 100644 test/jdbc/Makefile delete mode 100644 test/jdbc/ParameterMetadata/Makefile delete mode 100644 test/jdbc/ParameterMetadata/ParaMetaTest1.java delete mode 100644 test/jdbc/ParameterMetadata/ParaMetaTest2.java delete mode 100644 test/jdbc/ParameterMetadata/ParaMetaTest3.java delete mode 100755 test/jdbc/ParameterMetadata/test001.ksh delete mode 100755 test/jdbc/ParameterMetadata/test002.ksh delete mode 100755 test/jdbc/ParameterMetadata/test003.ksh delete mode 100644 test/jdbc/ResultSetMetaData/Makefile delete mode 100644 test/jdbc/ResultSetMetaData/RSMetadata1.java delete mode 100644 test/jdbc/ResultSetMetaData/RSMetadata2.java delete mode 100755 test/jdbc/ResultSetMetaData/test001.ksh delete mode 100755 test/jdbc/ResultSetMetaData/test002.ksh delete mode 100644 test/jdbc/Statement/Makefile delete mode 100644 test/jdbc/Statement/StmtTest1.java delete mode 100755 test/jdbc/Statement/StmtTest2.java delete mode 100644 test/jdbc/Statement/StmtTest3.java delete mode 100644 test/jdbc/Statement/StmtTest4.java delete mode 100644 test/jdbc/Statement/StmtTest5.java delete mode 100644 test/jdbc/Statement/StmtTest6.java delete mode 100644 test/jdbc/Statement/StmtTest7.java delete mode 100644 test/jdbc/Statement/StmtTest8.java delete mode 100644 test/jdbc/Statement/StmtTest9.java delete mode 100644 test/jdbc/Statement/TestScript1.java delete mode 100644 test/jdbc/Statement/TestScript10.java delete mode 100644 test/jdbc/Statement/TestScript11.java delete mode 100644 test/jdbc/Statement/TestScript2.java delete mode 100644 test/jdbc/Statement/TestScript3.java delete mode 100644 test/jdbc/Statement/TestScript4.java delete mode 100644 test/jdbc/Statement/TestScript5.java delete mode 100644 test/jdbc/Statement/TestScript6.java delete mode 100644 test/jdbc/Statement/TestScript7.java delete mode 100644 test/jdbc/Statement/TestScript8.java delete mode 100644 test/jdbc/Statement/TestScript9.java delete mode 100644 test/jdbc/Statement/exp.test001.ksh delete mode 100644 test/jdbc/Statement/exp.test002.ksh delete mode 100755 test/jdbc/Statement/exp.test005.ksh delete mode 100755 test/jdbc/Statement/exp.test006.ksh delete mode 100755 test/jdbc/Statement/exp.test007.ksh delete mode 100644 test/jdbc/Statement/exp.test008.ksh delete mode 100644 test/jdbc/Statement/test001.ksh delete mode 100755 test/jdbc/Statement/test002.ksh delete mode 100755 test/jdbc/Statement/test003.ksh delete mode 100755 test/jdbc/Statement/test004.ksh delete mode 100755 test/jdbc/Statement/test005.ksh delete mode 100755 test/jdbc/Statement/test006.ksh delete mode 100755 test/jdbc/Statement/test007.ksh delete mode 100755 test/jdbc/Statement/test008.ksh delete mode 100755 test/jdbc/Statement/test009.ksh delete mode 100755 test/jdbc/Statement/test010.ksh delete mode 100755 test/jdbc/Statement/test011.ksh delete mode 100755 test/jdbc/Statement/test012.ksh delete mode 100755 test/jdbc/Statement/test013.ksh delete mode 100755 test/jdbc/Statement/test014.ksh delete mode 100755 test/jdbc/Statement/test015.ksh delete mode 100755 test/jdbc/Statement/test016.ksh delete mode 100755 test/jdbc/Statement/test017.ksh delete mode 100755 test/jdbc/Statement/test018.ksh delete mode 100755 test/jdbc/Statement/test019.ksh delete mode 100755 test/jdbc/Statement/test020.ksh delete mode 100755 test/jdbc/Statement/test021.ksh delete mode 100644 test/odbc/Connect/Makefile delete mode 100644 test/odbc/Connect/odbcconnect1.c delete mode 100644 test/odbc/Connect/odbcconnect2.c delete mode 100644 test/odbc/Connect/odbcconnect3.c delete mode 100644 test/odbc/Connect/odbcconnect4.c delete mode 100644 test/odbc/Connect/odbcconnect5.c delete mode 100644 test/odbc/Connect/odbcconnect6.c delete mode 100644 test/odbc/Connect/odbcconnect7.c delete mode 100644 test/odbc/Makefile delete mode 100644 test/odbc/NonSelectDML/Makefile delete mode 100644 test/odbc/NonSelectDML/nonselectdml1.c delete mode 100644 test/odbc/Parameters/Makefile delete mode 100644 test/odbc/Parameters/exp.test002 delete mode 100644 test/odbc/Parameters/exp.test004 delete mode 100644 test/odbc/Parameters/parameter1.c delete mode 100644 test/odbc/Parameters/parameter2.c delete mode 100644 test/odbc/Parameters/parameter3.c delete mode 100644 test/odbc/Parameters/parameter4.c delete mode 100644 test/odbc/Parameters/parameter5.c delete mode 100644 test/odbc/Select/Makefile delete mode 100644 test/odbc/Select/exp.test001 delete mode 100644 test/odbc/Select/exp.test004 delete mode 100644 test/odbc/Select/odbcselect1.c delete mode 100644 test/odbc/Select/odbcselect2.c delete mode 100644 test/odbc/Select/odbcselect3.c delete mode 100644 test/odbc/Select/odbcselect4.c delete mode 100644 test/odbc/Select/odbcselect5.c delete mode 100644 test/odbc/Select/odbcselect6.c delete mode 100644 test/odbc/Select/odbcselect7.c delete mode 100644 test/odbc/Select/odbcselect8.c delete mode 100644 test/odbc/Transaction/Makefile delete mode 100644 test/odbc/Transaction/transact1.c delete mode 100644 test/odbc/Transaction/transact2.c delete mode 100644 test/performance/DMLTest.c delete mode 100644 test/performance/DMLThreadTest.c delete mode 100644 test/performance/DMLThroughput.c delete mode 100644 test/performance/JDBCTest.java delete mode 100644 test/performance/Makefile delete mode 100644 test/performance/ODBCTest.c delete mode 100644 test/performance/SQLAdapterTest.c delete mode 100644 test/performance/SQLGWTest.c delete mode 100644 test/performance/SQLTest.c delete mode 100644 test/performance/wisc/JDBCBench.java delete mode 100644 test/performance/wisc/JDBCPopulate.java delete mode 100644 test/performance/wisc/Makefile delete mode 100644 test/performance/wisc/README delete mode 100644 test/performance/wisc/odbcBench.c delete mode 100644 test/performance/wisc/wbench.c delete mode 100644 test/sql/Aggregate/agg1.sql delete mode 100644 test/sql/Aggregate/aggmin4.sql delete mode 100644 test/sql/Aggregate/aggregate1.sql delete mode 100644 test/sql/Aggregate/aggregate2.sql delete mode 100644 test/sql/Aggregate/aggregate4.sql delete mode 100644 test/sql/Aggregate/aggregate5.sql delete mode 100644 test/sql/Aggregate/aggregate6.sql delete mode 100644 test/sql/Aggregate/aggsum3.sql delete mode 100644 test/sql/Aggregate/createt1.sql delete mode 100644 test/sql/Aggregate/createt1t2.sql delete mode 100644 test/sql/Aggregate/dropt1.sql delete mode 100644 test/sql/Aggregate/dropt1t2.sql delete mode 100644 test/sql/Aggregate/exp.test001.ksh delete mode 100644 test/sql/Aggregate/exp.test002.ksh delete mode 100644 test/sql/Aggregate/exp.test003.ksh delete mode 100644 test/sql/Aggregate/exp.test004.ksh delete mode 100644 test/sql/Aggregate/exp.test005.ksh delete mode 100644 test/sql/Aggregate/exp.test006.ksh delete mode 100644 test/sql/Aggregate/exp.test007.ksh delete mode 100644 test/sql/Aggregate/exp.test008.ksh delete mode 100644 test/sql/Aggregate/exp.test009.ksh delete mode 100644 test/sql/Aggregate/quit.sql delete mode 100755 test/sql/Aggregate/test001.ksh delete mode 100755 test/sql/Aggregate/test002.ksh delete mode 100755 test/sql/Aggregate/test004.ksh delete mode 100755 test/sql/Aggregate/test005.ksh delete mode 100755 test/sql/Aggregate/test006.ksh delete mode 100755 test/sql/Aggregate/test007.ksh delete mode 100755 test/sql/Aggregate/test008.ksh delete mode 100755 test/sql/Aggregate/test009.ksh delete mode 100644 test/sql/Join/createt1.sql delete mode 100644 test/sql/Join/createt1t2.sql delete mode 100644 test/sql/Join/createt1t2t3.sql delete mode 100644 test/sql/Join/createt1t2t3t4t5.sql delete mode 100644 test/sql/Join/drop_emp_dept.sql delete mode 100644 test/sql/Join/dropt1.sql delete mode 100644 test/sql/Join/dropt11.sql delete mode 100644 test/sql/Join/dropt11t12.sql delete mode 100644 test/sql/Join/dropt11t12t13.sql delete mode 100644 test/sql/Join/dropt11t13.sql delete mode 100644 test/sql/Join/dropt1t2.sql delete mode 100644 test/sql/Join/dropt1t2t3.sql delete mode 100644 test/sql/Join/dropt1t2t3t4t5.sql delete mode 100644 test/sql/Join/exp.test001.ksh delete mode 100644 test/sql/Join/exp.test002.ksh delete mode 100644 test/sql/Join/exp.test003.ksh delete mode 100644 test/sql/Join/exp.test004.ksh delete mode 100644 test/sql/Join/exp.test005.ksh delete mode 100644 test/sql/Join/exp.test006.ksh delete mode 100644 test/sql/Join/exp.test007.ksh delete mode 100644 test/sql/Join/exp.test008.ksh delete mode 100644 test/sql/Join/exp.test009.ksh delete mode 100644 test/sql/Join/exp.test010.ksh delete mode 100644 test/sql/Join/exp.test011.ksh delete mode 100644 test/sql/Join/exp.test012.ksh delete mode 100644 test/sql/Join/exp.test013.ksh delete mode 100644 test/sql/Join/exp.test014.ksh delete mode 100644 test/sql/Join/exp.test015.ksh delete mode 100644 test/sql/Join/exp.test016.ksh delete mode 100644 test/sql/Join/exp.test017.ksh delete mode 100644 test/sql/Join/exp.test018.ksh delete mode 100644 test/sql/Join/exp1.test004.ksh delete mode 100644 test/sql/Join/join1.sql delete mode 100644 test/sql/Join/join10.sql delete mode 100644 test/sql/Join/join11.sql delete mode 100644 test/sql/Join/join2.sql delete mode 100644 test/sql/Join/join3.sql delete mode 100644 test/sql/Join/join31.sql delete mode 100644 test/sql/Join/join32.sql delete mode 100644 test/sql/Join/join33.sql delete mode 100644 test/sql/Join/join34.sql delete mode 100644 test/sql/Join/join4.sql delete mode 100644 test/sql/Join/join5.sql delete mode 100644 test/sql/Join/join6.sql delete mode 100644 test/sql/Join/join7.sql delete mode 100644 test/sql/Join/join8.sql delete mode 100644 test/sql/Join/join9.sql delete mode 100644 test/sql/Join/join_between.sql delete mode 100644 test/sql/Join/join_between_notexist.sql delete mode 100644 test/sql/Join/join_in.sql delete mode 100644 test/sql/Join/join_in_notexist.sql delete mode 100644 test/sql/Join/join_like.sql delete mode 100644 test/sql/Join/join_like_notexist1.sql delete mode 100644 test/sql/Join/join_like_notexist2.sql delete mode 100644 test/sql/Join/quit.sql delete mode 100644 test/sql/Join/tablet11.sql delete mode 100644 test/sql/Join/tablet11t12.sql delete mode 100644 test/sql/Join/tablet11t12t13.sql delete mode 100644 test/sql/Join/tablet11t13.sql delete mode 100644 test/sql/Join/tablet12.sql delete mode 100644 test/sql/Join/tablet13.sql delete mode 100755 test/sql/Join/test001.ksh delete mode 100755 test/sql/Join/test002.ksh delete mode 100755 test/sql/Join/test003.ksh delete mode 100755 test/sql/Join/test004.ksh delete mode 100755 test/sql/Join/test005.ksh delete mode 100755 test/sql/Join/test006.ksh delete mode 100755 test/sql/Join/test007.ksh delete mode 100755 test/sql/Join/test008.ksh delete mode 100755 test/sql/Join/test009.ksh delete mode 100755 test/sql/Join/test010.ksh delete mode 100755 test/sql/Join/test011.ksh delete mode 100755 test/sql/Join/test012.ksh delete mode 100755 test/sql/Join/test013.ksh delete mode 100755 test/sql/Join/test014.ksh delete mode 100755 test/sql/Join/test015.ksh delete mode 100755 test/sql/Join/test016.ksh delete mode 100755 test/sql/Join/test017.ksh delete mode 100755 test/sql/Join/test018.ksh delete mode 100644 test/sqlapi/Connect/Makefile delete mode 100644 test/sqlapi/Connect/common.h delete mode 100644 test/sqlapi/Connect/conntest1.c delete mode 100644 test/sqlapi/Connect/conntest10.c delete mode 100644 test/sqlapi/Connect/conntest11.c delete mode 100644 test/sqlapi/Connect/conntest2.c delete mode 100644 test/sqlapi/Connect/conntest3.c delete mode 100644 test/sqlapi/Connect/conntest4.c delete mode 100644 test/sqlapi/Connect/conntest5.c delete mode 100644 test/sqlapi/Connect/conntest6.c delete mode 100644 test/sqlapi/Connect/conntest7.c delete mode 100644 test/sqlapi/Connect/conntest8.c delete mode 100644 test/sqlapi/Connect/conntest9.c delete mode 100644 test/sqlapi/Connect/exp.test010 delete mode 100644 test/sqlapi/Connect/exp.test010n delete mode 100644 test/sqlapi/Connect/exp.test011 delete mode 100644 test/sqlapi/Connect/exp.test011n delete mode 100644 test/sqlapi/Makefile delete mode 100644 test/sqlapi/Parameter/Makefile delete mode 100644 test/sqlapi/Parameter/common.h delete mode 100644 test/sqlapi/Parameter/exp.test001 delete mode 100644 test/sqlapi/Parameter/exp.test001n delete mode 100644 test/sqlapi/Parameter/exp.test002 delete mode 100644 test/sqlapi/Parameter/exp.test002n delete mode 100644 test/sqlapi/Parameter/exp.test003 delete mode 100644 test/sqlapi/Parameter/exp.test003n delete mode 100644 test/sqlapi/Parameter/exp.test004 delete mode 100644 test/sqlapi/Parameter/exp.test004n delete mode 100644 test/sqlapi/Parameter/paratest1.c delete mode 100644 test/sqlapi/Parameter/paratest100.c delete mode 100644 test/sqlapi/Parameter/paratest2.c delete mode 100644 test/sqlapi/Parameter/paratest3.c delete mode 100644 test/sqlapi/Parameter/paratest4.c delete mode 100644 test/sqlapi/Select/Makefile delete mode 100644 test/sqlapi/Select/common.h delete mode 100644 test/sqlapi/Select/create.sql delete mode 100644 test/sqlapi/Select/csql.conf delete mode 100644 test/sqlapi/Select/exp.test001 delete mode 100644 test/sqlapi/Select/exp.test002 delete mode 100644 test/sqlapi/Select/exp.test005.ksh delete mode 100644 test/sqlapi/Select/exp.test010 delete mode 100644 test/sqlapi/Select/exp.test010n delete mode 100644 test/sqlapi/Select/exp.test011 delete mode 100644 test/sqlapi/Select/paratest1.c delete mode 100644 test/sqlapi/Select/selecttest1.c delete mode 100644 test/sqlapi/Select/selecttest10.c delete mode 100644 test/sqlapi/Select/selecttest11.c delete mode 100644 test/sqlapi/Select/selecttest2.c delete mode 100644 test/sqlapi/Select/selecttest3.c delete mode 100644 test/sqlapi/Select/selecttest4.c delete mode 100644 test/sqlapi/Select/selecttest5.c delete mode 100644 test/sqlapi/Select/selecttest6.c delete mode 100644 test/sqlapi/Select/selecttest7.c delete mode 100644 test/sqlapi/Select/selecttest8.c delete mode 100644 test/sqlapi/Select/selecttest9.c delete mode 100755 test/sqlapi/Select/test005.ksh delete mode 100644 test/sqlnetwork/Connect/Makefile delete mode 100644 test/sqlnetwork/Connect/conntest1.c delete mode 100644 test/sqlnetwork/Connect/conntest10.c delete mode 100644 test/sqlnetwork/Connect/conntest11.c delete mode 100644 test/sqlnetwork/Connect/conntest2.c delete mode 100644 test/sqlnetwork/Connect/conntest3.c delete mode 100644 test/sqlnetwork/Connect/conntest4.c delete mode 100644 test/sqlnetwork/Connect/conntest5.c delete mode 100644 test/sqlnetwork/Connect/conntest6.c delete mode 100644 test/sqlnetwork/Connect/conntest7.c delete mode 100644 test/sqlnetwork/Connect/conntest8.c delete mode 100644 test/sqlnetwork/Connect/conntest9.c delete mode 100644 test/sqlnetwork/Connect/exp.test010 delete mode 100644 test/sqlnetwork/Connect/exp.test011 delete mode 100755 test/sqlnetwork/Jdbcnetwork/ConnTest1.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest10.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest11.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest12.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest13.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest14.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest15.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest16.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest17.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest18.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest19.java delete mode 100755 test/sqlnetwork/Jdbcnetwork/ConnTest2.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest20.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest3.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest4.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest5.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest6.java delete mode 100755 test/sqlnetwork/Jdbcnetwork/ConnTest7.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest8.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/ConnTest9.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/Makefile delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest1.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest10.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest11.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest12.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest13.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest2.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest3.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest4.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest5.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest6.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest7.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest8.java delete mode 100644 test/sqlnetwork/Jdbcnetwork/StmtTest9.java delete mode 100755 test/sqlnetwork/Jdbcnetwork/test001.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test002.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test003.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test004.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test005.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test006.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test007.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test008.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test009.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test010.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test011.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test012.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test013.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test014.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test015.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test016.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test017.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test018.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test019.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test020.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test021.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test022.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test023.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test024.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test025.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test026.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test027.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test028.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test029.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test030.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test031.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test032.ksh delete mode 100755 test/sqlnetwork/Jdbcnetwork/test033.ksh delete mode 100644 test/sqlnetwork/Parameter/Makefile delete mode 100644 test/sqlnetwork/Parameter/exp.test001 delete mode 100644 test/sqlnetwork/Parameter/exp.test002 delete mode 100644 test/sqlnetwork/Parameter/exp.test003 delete mode 100644 test/sqlnetwork/Parameter/exp.test004 delete mode 100644 test/sqlnetwork/Parameter/paratest1.c delete mode 100644 test/sqlnetwork/Parameter/paratest100.c delete mode 100644 test/sqlnetwork/Parameter/paratest2.c delete mode 100644 test/sqlnetwork/Parameter/paratest3.c delete mode 100644 test/sqlnetwork/Parameter/paratest4.c delete mode 100644 test/sqlnetwork/Select/Makefile delete mode 100644 test/sqlnetwork/Select/exp.test001 delete mode 100644 test/sqlnetwork/Select/exp.test002 delete mode 100644 test/sqlnetwork/Select/exp.test010 delete mode 100644 test/sqlnetwork/Select/selecttest1.c delete mode 100644 test/sqlnetwork/Select/selecttest10.c delete mode 100644 test/sqlnetwork/Select/selecttest2.c delete mode 100644 test/sqlnetwork/Select/selecttest3.c delete mode 100644 test/sqlnetwork/Select/selecttest4.c delete mode 100644 test/sqlnetwork/Select/selecttest5.c delete mode 100644 test/sqlnetwork/Select/selecttest6.c delete mode 100644 test/sqlnetwork/Select/selecttest7.c delete mode 100644 test/sqlnetwork/Select/selecttest8.c delete mode 100644 test/sqlnetwork/Select/selecttest9.c delete mode 100644 test/system/Allocator/Makefile delete mode 100644 test/system/Allocator/TODO delete mode 100644 test/system/Allocator/common.h delete mode 100644 test/system/Allocator/create.c delete mode 100644 test/system/Allocator/createNoIndex.c delete mode 100644 test/system/Allocator/dbsizelimit.c delete mode 100644 test/system/Allocator/delete1.c delete mode 100644 test/system/Allocator/delete100.c delete mode 100644 test/system/Allocator/delete1000.c delete mode 100644 test/system/Allocator/deleteAll.c delete mode 100644 test/system/Allocator/drop.c delete mode 100644 test/system/Allocator/exp.test001.ksh delete mode 100644 test/system/Allocator/exp.test002.ksh delete mode 100644 test/system/Allocator/exp.test003.ksh delete mode 100644 test/system/Allocator/exp.test004.ksh delete mode 100644 test/system/Allocator/exp.test005.ksh delete mode 100644 test/system/Allocator/exp.test006.ksh delete mode 100644 test/system/Allocator/exp.test007.ksh delete mode 100644 test/system/Allocator/exp.test008.ksh delete mode 100644 test/system/Allocator/exp.test021 delete mode 100644 test/system/Allocator/exp.test022 delete mode 100644 test/system/Allocator/exp.test023 delete mode 100644 test/system/Allocator/exp.test024 delete mode 100644 test/system/Allocator/exp.test025 delete mode 100644 test/system/Allocator/insert1.c delete mode 100644 test/system/Allocator/insert100.c delete mode 100644 test/system/Allocator/insert1000.c delete mode 100755 test/system/Allocator/test001.ksh delete mode 100755 test/system/Allocator/test002.ksh delete mode 100755 test/system/Allocator/test003.ksh delete mode 100755 test/system/Allocator/test004.ksh delete mode 100755 test/system/Allocator/test005.ksh delete mode 100755 test/system/Allocator/test006.ksh delete mode 100755 test/system/Allocator/test007.ksh delete mode 100755 test/system/Allocator/test008.ksh delete mode 100644 test/system/Allocator/tuplesize1.c delete mode 100644 test/system/Allocator/tuplesize2.c delete mode 100644 test/system/Allocator/tuplesize3.c delete mode 100644 test/system/Allocator/tuplesize4.c delete mode 100644 test/system/Allocator/tuplesize5.c delete mode 100644 test/system/Makefile delete mode 100644 test/system/config/Makefile delete mode 100644 test/system/config/conftest1.c delete mode 100644 test/system/config/conftest2.c delete mode 100644 test/system/config/connect.c delete mode 100644 test/system/config/csql.conf delete mode 100644 test/system/config/exp.test002 delete mode 100644 test/system/config/exp.test003.ksh delete mode 100644 test/system/config/exp.test004.ksh delete mode 100644 test/system/config/exp.test005.ksh delete mode 100644 test/system/config/exp.test006.ksh delete mode 100644 test/system/config/exp.test007.ksh delete mode 100644 test/system/config/exp.test008.ksh delete mode 100644 test/system/config/exp.test009.ksh delete mode 100644 test/system/config/exp.test010.ksh delete mode 100644 test/system/config/exp.test011.ksh delete mode 100644 test/system/config/exp.test012.ksh delete mode 100644 test/system/config/exp.test013.ksh delete mode 100644 test/system/config/exp.test014.ksh delete mode 100644 test/system/config/exp.test015.ksh delete mode 100644 test/system/config/exp.test016.ksh delete mode 100644 test/system/config/exp.test017.ksh delete mode 100644 test/system/config/exp.test018.ksh delete mode 100644 test/system/config/exp.test019.ksh delete mode 100644 test/system/config/exp.test021.ksh delete mode 100644 test/system/config/exp.test022.ksh delete mode 100644 test/system/config/exp.test023.ksh delete mode 100644 test/system/config/exp.test024.ksh delete mode 100644 test/system/config/exp.test027.ksh delete mode 100644 test/system/config/exp.test028.ksh delete mode 100644 test/system/config/exp.test029.ksh delete mode 100644 test/system/config/exp.test030.ksh delete mode 100755 test/system/config/test003.ksh delete mode 100755 test/system/config/test004.ksh delete mode 100755 test/system/config/test005.ksh delete mode 100755 test/system/config/test006.ksh delete mode 100755 test/system/config/test007.ksh delete mode 100755 test/system/config/test008.ksh delete mode 100755 test/system/config/test009.ksh delete mode 100755 test/system/config/test010.ksh delete mode 100755 test/system/config/test011.ksh delete mode 100755 test/system/config/test012.ksh delete mode 100755 test/system/config/test013.ksh delete mode 100755 test/system/config/test014.ksh delete mode 100755 test/system/config/test015.ksh delete mode 100755 test/system/config/test016.ksh delete mode 100755 test/system/config/test017.ksh delete mode 100755 test/system/config/test018.ksh delete mode 100755 test/system/config/test019.ksh delete mode 100755 test/system/config/test020.ksh delete mode 100755 test/system/config/test021.ksh delete mode 100755 test/system/config/test022.ksh delete mode 100755 test/system/config/test023.ksh delete mode 100755 test/system/config/test024.ksh delete mode 100755 test/system/config/test025.ksh delete mode 100755 test/system/config/test026.ksh delete mode 100755 test/system/config/test027.ksh delete mode 100755 test/system/config/test028.ksh delete mode 100755 test/system/config/test029.ksh delete mode 100755 test/system/config/test030.ksh delete mode 100755 test/system/config/test031.ksh delete mode 100755 test/system/config/test032.ksh delete mode 100644 test/system/index/TODO delete mode 100644 test/system/lock/Makefile delete mode 100644 test/system/lock/TODO delete mode 100644 test/system/lock/common.h delete mode 100644 test/system/lock/exp.test001 delete mode 100644 test/system/lock/exp.test001a delete mode 100644 test/system/lock/exp.test002 delete mode 100644 test/system/lock/exp.test002a delete mode 100644 test/system/lock/exp.test003 delete mode 100644 test/system/lock/exp.test003a delete mode 100644 test/system/lock/exp.test004 delete mode 100644 test/system/lock/exp.test004a delete mode 100644 test/system/lock/exp.test005 delete mode 100644 test/system/lock/exp.test005a delete mode 100644 test/system/lock/exp.test006 delete mode 100644 test/system/lock/exp.test006a delete mode 100644 test/system/lock/exp.test007 delete mode 100644 test/system/lock/exp.test007a delete mode 100644 test/system/lock/exp.test008 delete mode 100644 test/system/lock/exp.test008a delete mode 100644 test/system/lock/exp.test009 delete mode 100644 test/system/lock/exp.test009a delete mode 100644 test/system/lock/locktest001.c delete mode 100644 test/system/lock/locktest002.c delete mode 100644 test/system/lock/locktest003.c delete mode 100644 test/system/lock/locktest004.c delete mode 100644 test/system/lock/locktest005.c delete mode 100644 test/system/lock/locktest006.c delete mode 100644 test/system/lock/locktest007.c delete mode 100644 test/system/lock/locktest008.c delete mode 100644 test/system/lock/locktest009.c delete mode 100644 test/system/proc/TODO delete mode 100644 test/system/proc/exp.test001.ksh delete mode 100755 test/system/proc/test001.ksh delete mode 100644 test/system/trans/Makefile delete mode 100644 test/system/trans/common.h delete mode 100644 test/system/trans/create.c delete mode 100644 test/system/trans/drop.c delete mode 100644 test/system/trans/exp.test001.ksh delete mode 100644 test/system/trans/exp.test002.ksh delete mode 100644 test/system/trans/exp.test003 delete mode 100644 test/system/trans/exp.test003a delete mode 100644 test/system/trans/exp.test004 delete mode 100644 test/system/trans/exp.test004a delete mode 100644 test/system/trans/exp.test005 delete mode 100644 test/system/trans/exp.test005a delete mode 100644 test/system/trans/exp.test006 delete mode 100644 test/system/trans/exp.test006a delete mode 100644 test/system/trans/exp.test007 delete mode 100644 test/system/trans/exp.test007a delete mode 100644 test/system/trans/exp.test008 delete mode 100644 test/system/trans/exp.test008a delete mode 100644 test/system/trans/exp.test009 delete mode 100644 test/system/trans/exp.test009a delete mode 100644 test/system/trans/exp.test010 delete mode 100644 test/system/trans/exp.test010a delete mode 100644 test/system/trans/insert1andAbort.c delete mode 100644 test/system/trans/insert1andCommit.c delete mode 100644 test/system/trans/locktest009.c delete mode 100755 test/system/trans/test001.ksh delete mode 100755 test/system/trans/test002.ksh delete mode 100644 test/system/trans/transtest003.c delete mode 100644 test/system/trans/transtest004.c delete mode 100644 test/system/trans/transtest005.c delete mode 100644 test/system/trans/transtest006.c delete mode 100644 test/system/trans/transtest007.c delete mode 100644 test/system/trans/transtest008.c delete mode 100644 test/system/trans/transtest009.c delete mode 100644 test/system/trans/transtest010.c delete mode 100644 test/tools/Durability/auto.sql delete mode 100644 test/tools/Durability/compo_index2_10.sql delete mode 100644 test/tools/Durability/create_10.sql delete mode 100644 test/tools/Durability/create_pri_10.sql delete mode 100644 test/tools/Durability/create_t1.sql delete mode 100644 test/tools/Durability/create_t2.sql delete mode 100644 test/tools/Durability/csql.conf delete mode 100644 test/tools/Durability/delete_10.sql delete mode 100644 test/tools/Durability/delete_t1.sql delete mode 100644 test/tools/Durability/drop_10.sql delete mode 100644 test/tools/Durability/drop_t1.sql delete mode 100644 test/tools/Durability/exp.test001.ksh delete mode 100644 test/tools/Durability/exp.test002.ksh delete mode 100644 test/tools/Durability/exp.test003.ksh delete mode 100644 test/tools/Durability/exp.test004.ksh delete mode 100644 test/tools/Durability/exp.test005.ksh delete mode 100644 test/tools/Durability/exp.test006.ksh delete mode 100644 test/tools/Durability/exp.test007.ksh delete mode 100644 test/tools/Durability/exp.test008.ksh delete mode 100644 test/tools/Durability/exp.test009.ksh delete mode 100644 test/tools/Durability/exp.test010.ksh delete mode 100644 test/tools/Durability/exp.test011.ksh delete mode 100644 test/tools/Durability/exp.test012.ksh delete mode 100644 test/tools/Durability/index_10.sql delete mode 100644 test/tools/Durability/ins_commit.sql delete mode 100644 test/tools/Durability/ins_rollback.sql delete mode 100644 test/tools/Durability/insert_10.sql delete mode 100644 test/tools/Durability/insert_a.sql delete mode 100644 test/tools/Durability/insert_b.sql delete mode 100644 test/tools/Durability/insert_t1.sql delete mode 100644 test/tools/Durability/rollback.sql delete mode 100644 test/tools/Durability/select_10.sql delete mode 100644 test/tools/Durability/select_t1.sql delete mode 100644 test/tools/Durability/show_t1.sql delete mode 100755 test/tools/Durability/test001.ksh delete mode 100755 test/tools/Durability/test002.ksh delete mode 100755 test/tools/Durability/test003.ksh delete mode 100755 test/tools/Durability/test004.ksh delete mode 100755 test/tools/Durability/test005.ksh delete mode 100755 test/tools/Durability/test006.ksh delete mode 100755 test/tools/Durability/test007.ksh delete mode 100755 test/tools/Durability/test008.ksh delete mode 100755 test/tools/Durability/test009.ksh delete mode 100755 test/tools/Durability/test010.ksh delete mode 100755 test/tools/Durability/test011.ksh delete mode 100755 test/tools/Durability/test012.ksh delete mode 100644 test/tools/Durability/update_10.sql delete mode 100644 test/tools/Durability/update_t1.sql delete mode 100644 test/tools/Makefile delete mode 100644 test/tools/catalog/Makefile delete mode 100644 test/tools/catalog/common.h delete mode 100644 test/tools/catalog/create.c delete mode 100644 test/tools/catalog/create.sql delete mode 100644 test/tools/catalog/create1.sql delete mode 100644 test/tools/catalog/createPriFlagTest.sql delete mode 100644 test/tools/catalog/csql.conf delete mode 100644 test/tools/catalog/delete.sql delete mode 100644 test/tools/catalog/drop.c delete mode 100644 test/tools/catalog/dropIndex.sql delete mode 100644 test/tools/catalog/dropt1.sql delete mode 100644 test/tools/catalog/dropt2.sql delete mode 100644 test/tools/catalog/dropt4t5.sql delete mode 100644 test/tools/catalog/exp.test001.ksh delete mode 100644 test/tools/catalog/exp.test005.ksh delete mode 100644 test/tools/catalog/exp.test006.ksh delete mode 100644 test/tools/catalog/exp.test007.ksh delete mode 100644 test/tools/catalog/insert.c delete mode 100644 test/tools/catalog/insert.sql delete mode 100755 test/tools/catalog/test001.ksh delete mode 100755 test/tools/catalog/test002.ksh delete mode 100755 test/tools/catalog/test003.ksh delete mode 100755 test/tools/catalog/test004.ksh delete mode 100755 test/tools/catalog/test005.ksh delete mode 100755 test/tools/catalog/test006.ksh delete mode 100755 test/tools/catalog/test007.ksh delete mode 100644 test/tools/csql/TODO delete mode 100644 test/tools/csql/agg1.sql delete mode 100644 test/tools/csql/autocommit1.sql delete mode 100644 test/tools/csql/autocommit10.sql delete mode 100644 test/tools/csql/autocommit11.sql delete mode 100644 test/tools/csql/autocommit12.sql delete mode 100644 test/tools/csql/autocommit13.sql delete mode 100644 test/tools/csql/autocommit14.sql delete mode 100644 test/tools/csql/autocommit15.sql delete mode 100644 test/tools/csql/autocommit16.sql delete mode 100644 test/tools/csql/autocommit17.sql delete mode 100644 test/tools/csql/autocommit18.sql delete mode 100644 test/tools/csql/autocommit2.sql delete mode 100644 test/tools/csql/autocommit3.sql delete mode 100644 test/tools/csql/autocommit4.sql delete mode 100644 test/tools/csql/autocommit5.sql delete mode 100644 test/tools/csql/autocommit6.sql delete mode 100644 test/tools/csql/autocommit7.sql delete mode 100644 test/tools/csql/autocommit8.sql delete mode 100644 test/tools/csql/autocommit9.sql delete mode 100755 test/tools/csql/bit_test024.ksh delete mode 100644 test/tools/csql/comp1.sql delete mode 100644 test/tools/csql/comp2.sql delete mode 100644 test/tools/csql/comp3.sql delete mode 100644 test/tools/csql/comp4.sql delete mode 100644 test/tools/csql/composite1.sql delete mode 100644 test/tools/csql/composite2.sql delete mode 100644 test/tools/csql/composite3.sql delete mode 100644 test/tools/csql/csql1.sql delete mode 100644 test/tools/csql/csql10.sql delete mode 100644 test/tools/csql/csql11.sql delete mode 100644 test/tools/csql/csql12.sql delete mode 100644 test/tools/csql/csql2.sql delete mode 100644 test/tools/csql/csql3.sql delete mode 100644 test/tools/csql/csql4.sql delete mode 100644 test/tools/csql/csql5.sql delete mode 100644 test/tools/csql/csql6.sql delete mode 100644 test/tools/csql/csql7.sql delete mode 100644 test/tools/csql/csql8.sql delete mode 100644 test/tools/csql/csql9.sql delete mode 100644 test/tools/csql/datatype1.sql delete mode 100644 test/tools/csql/datatype10.sql delete mode 100644 test/tools/csql/datatype11.sql delete mode 100644 test/tools/csql/datatype12.sql delete mode 100644 test/tools/csql/datatype2.sql delete mode 100644 test/tools/csql/datatype3.sql delete mode 100644 test/tools/csql/datatype4.sql delete mode 100644 test/tools/csql/datatype5.sql delete mode 100644 test/tools/csql/datatype6.sql delete mode 100644 test/tools/csql/datatype7.sql delete mode 100644 test/tools/csql/datatype8.sql delete mode 100644 test/tools/csql/datatype9.sql delete mode 100644 test/tools/csql/dbobjname.sql delete mode 100644 test/tools/csql/ddl.sql delete mode 100644 test/tools/csql/diffintindex.sql delete mode 100644 test/tools/csql/drop.sql delete mode 100644 test/tools/csql/drop1.sql delete mode 100644 test/tools/csql/drop2.sql delete mode 100644 test/tools/csql/exp.test001.ksh delete mode 100644 test/tools/csql/exp.test002.ksh delete mode 100644 test/tools/csql/exp.test003.ksh delete mode 100644 test/tools/csql/exp.test004.ksh delete mode 100644 test/tools/csql/exp.test005.ksh delete mode 100644 test/tools/csql/exp.test006.ksh delete mode 100644 test/tools/csql/exp.test007.ksh delete mode 100644 test/tools/csql/exp.test008.ksh delete mode 100644 test/tools/csql/exp.test009.ksh delete mode 100644 test/tools/csql/exp.test010.ksh delete mode 100644 test/tools/csql/exp.test011.ksh delete mode 100644 test/tools/csql/exp.test012.ksh delete mode 100644 test/tools/csql/exp.test021.ksh delete mode 100644 test/tools/csql/exp.test022.ksh delete mode 100644 test/tools/csql/exp.test023.ksh delete mode 100644 test/tools/csql/exp.test024.ksh delete mode 100644 test/tools/csql/exp.test025.ksh delete mode 100644 test/tools/csql/exp.test026.ksh delete mode 100644 test/tools/csql/exp.test027.ksh delete mode 100644 test/tools/csql/exp.test028.ksh delete mode 100644 test/tools/csql/exp.test029.ksh delete mode 100644 test/tools/csql/exp.test030.ksh delete mode 100644 test/tools/csql/exp.test031.ksh delete mode 100644 test/tools/csql/exp.test032.ksh delete mode 100644 test/tools/csql/exp.test033.ksh delete mode 100644 test/tools/csql/exp.test034.ksh delete mode 100644 test/tools/csql/exp.test034a.ksh delete mode 100644 test/tools/csql/exp.test035.ksh delete mode 100644 test/tools/csql/exp.test036.ksh delete mode 100644 test/tools/csql/exp.test037.ksh delete mode 100644 test/tools/csql/exp.test038.ksh delete mode 100644 test/tools/csql/exp.test039.ksh delete mode 100644 test/tools/csql/exp.test040.ksh delete mode 100644 test/tools/csql/exp.test041.ksh delete mode 100644 test/tools/csql/exp.test042.ksh delete mode 100644 test/tools/csql/exp.test043.ksh delete mode 100644 test/tools/csql/exp.test044.ksh delete mode 100644 test/tools/csql/exp.test045.ksh delete mode 100644 test/tools/csql/exp.test046.ksh delete mode 100644 test/tools/csql/exp.test047.ksh delete mode 100644 test/tools/csql/exp.test048.ksh delete mode 100644 test/tools/csql/exp.test049.ksh delete mode 100644 test/tools/csql/exp.test050.ksh delete mode 100644 test/tools/csql/exp.test051.ksh delete mode 100644 test/tools/csql/exp.test052.ksh delete mode 100644 test/tools/csql/exp.test053.ksh delete mode 100644 test/tools/csql/exp.test054.ksh delete mode 100644 test/tools/csql/exp.test055.ksh delete mode 100644 test/tools/csql/exp.test056.ksh delete mode 100644 test/tools/csql/exp.test057.ksh delete mode 100644 test/tools/csql/exp.test058.ksh delete mode 100644 test/tools/csql/exp.test059.ksh delete mode 100644 test/tools/csql/exp.test060.ksh delete mode 100644 test/tools/csql/exp.test061.ksh delete mode 100644 test/tools/csql/exp.test062.ksh delete mode 100644 test/tools/csql/exp.test063.ksh delete mode 100644 test/tools/csql/exp.test064.ksh delete mode 100644 test/tools/csql/exp.test065.ksh delete mode 100644 test/tools/csql/exp.test066.ksh delete mode 100644 test/tools/csql/exp.test067.ksh delete mode 100644 test/tools/csql/exp.test068.ksh delete mode 100644 test/tools/csql/exp.test069.ksh delete mode 100644 test/tools/csql/exp.test070.ksh delete mode 100644 test/tools/csql/exp.test071.ksh delete mode 100644 test/tools/csql/exp.test072.ksh delete mode 100644 test/tools/csql/exp.test073.ksh delete mode 100644 test/tools/csql/exp.test074.ksh delete mode 100644 test/tools/csql/exp.test075.ksh delete mode 100644 test/tools/csql/exp.test076.ksh delete mode 100644 test/tools/csql/exp.test077.ksh delete mode 100644 test/tools/csql/exp.test078.ksh delete mode 100644 test/tools/csql/exp.test079.ksh delete mode 100644 test/tools/csql/exp.test080.ksh delete mode 100644 test/tools/csql/exp.test081.ksh delete mode 100644 test/tools/csql/exp.test082.ksh delete mode 100644 test/tools/csql/exp.test083.ksh delete mode 100644 test/tools/csql/exp.test084.ksh delete mode 100644 test/tools/csql/exp.test085.ksh delete mode 100644 test/tools/csql/exp.test086.ksh delete mode 100644 test/tools/csql/exp.test087.ksh delete mode 100644 test/tools/csql/exp.test088.ksh delete mode 100644 test/tools/csql/exp.test089.ksh delete mode 100644 test/tools/csql/exp.test090.ksh delete mode 100644 test/tools/csql/exp.test091.ksh delete mode 100644 test/tools/csql/expresion.sql delete mode 100644 test/tools/csql/fieldlimit.sql delete mode 100644 test/tools/csql/indexontuples.sql delete mode 100644 test/tools/csql/indextran1.sql delete mode 100644 test/tools/csql/indextran2.sql delete mode 100644 test/tools/csql/indextran3.sql delete mode 100644 test/tools/csql/indextran4.sql delete mode 100644 test/tools/csql/null1.sql delete mode 100644 test/tools/csql/null2.sql delete mode 100644 test/tools/csql/null3.sql delete mode 100644 test/tools/csql/null4.sql delete mode 100644 test/tools/csql/null5.sql delete mode 100644 test/tools/csql/null6.sql delete mode 100644 test/tools/csql/null7.sql delete mode 100644 test/tools/csql/quit.sql delete mode 100644 test/tools/csql/rowsizelimit.sql delete mode 100644 test/tools/csql/selcond.sql delete mode 100644 test/tools/csql/selectstar.sql delete mode 100644 test/tools/csql/selecttest.sql delete mode 100644 test/tools/csql/singleandcompind.sql delete mode 100755 test/tools/csql/test001.ksh delete mode 100755 test/tools/csql/test002.ksh delete mode 100755 test/tools/csql/test003.ksh delete mode 100755 test/tools/csql/test004.ksh delete mode 100755 test/tools/csql/test005.ksh delete mode 100755 test/tools/csql/test006.ksh delete mode 100755 test/tools/csql/test007.ksh delete mode 100755 test/tools/csql/test008.ksh delete mode 100755 test/tools/csql/test009.ksh delete mode 100755 test/tools/csql/test010.ksh delete mode 100755 test/tools/csql/test011.ksh delete mode 100755 test/tools/csql/test012.ksh delete mode 100755 test/tools/csql/test021.ksh delete mode 100755 test/tools/csql/test022.ksh delete mode 100755 test/tools/csql/test023.ksh delete mode 100755 test/tools/csql/test025.ksh delete mode 100755 test/tools/csql/test026.ksh delete mode 100755 test/tools/csql/test027.ksh delete mode 100755 test/tools/csql/test028.ksh delete mode 100755 test/tools/csql/test029.ksh delete mode 100755 test/tools/csql/test030.ksh delete mode 100755 test/tools/csql/test031.ksh delete mode 100755 test/tools/csql/test032.ksh delete mode 100755 test/tools/csql/test033.ksh delete mode 100755 test/tools/csql/test034.ksh delete mode 100755 test/tools/csql/test034a.ksh delete mode 100755 test/tools/csql/test035.ksh delete mode 100755 test/tools/csql/test036.ksh delete mode 100755 test/tools/csql/test037.ksh delete mode 100755 test/tools/csql/test038.ksh delete mode 100755 test/tools/csql/test039.ksh delete mode 100755 test/tools/csql/test040.ksh delete mode 100755 test/tools/csql/test041.ksh delete mode 100755 test/tools/csql/test042.ksh delete mode 100755 test/tools/csql/test043.ksh delete mode 100755 test/tools/csql/test044.ksh delete mode 100755 test/tools/csql/test045.ksh delete mode 100755 test/tools/csql/test046.ksh delete mode 100755 test/tools/csql/test047.ksh delete mode 100755 test/tools/csql/test048.ksh delete mode 100755 test/tools/csql/test049.ksh delete mode 100755 test/tools/csql/test050.ksh delete mode 100755 test/tools/csql/test051.ksh delete mode 100755 test/tools/csql/test052.ksh delete mode 100755 test/tools/csql/test053.ksh delete mode 100755 test/tools/csql/test054.ksh delete mode 100755 test/tools/csql/test055.ksh delete mode 100755 test/tools/csql/test056.ksh delete mode 100755 test/tools/csql/test057.ksh delete mode 100755 test/tools/csql/test058.ksh delete mode 100755 test/tools/csql/test059.ksh delete mode 100755 test/tools/csql/test060.ksh delete mode 100755 test/tools/csql/test061.ksh delete mode 100755 test/tools/csql/test062.ksh delete mode 100755 test/tools/csql/test063.ksh delete mode 100755 test/tools/csql/test064.ksh delete mode 100755 test/tools/csql/test065.ksh delete mode 100755 test/tools/csql/test066.ksh delete mode 100755 test/tools/csql/test067.ksh delete mode 100755 test/tools/csql/test068.ksh delete mode 100755 test/tools/csql/test069.ksh delete mode 100755 test/tools/csql/test070.ksh delete mode 100755 test/tools/csql/test071.ksh delete mode 100755 test/tools/csql/test072.ksh delete mode 100755 test/tools/csql/test073.ksh delete mode 100755 test/tools/csql/test074.ksh delete mode 100755 test/tools/csql/test075.ksh delete mode 100755 test/tools/csql/test076.ksh delete mode 100755 test/tools/csql/test077.ksh delete mode 100755 test/tools/csql/test078.ksh delete mode 100755 test/tools/csql/test079.ksh delete mode 100755 test/tools/csql/test080.ksh delete mode 100755 test/tools/csql/test081.ksh delete mode 100755 test/tools/csql/test082.ksh delete mode 100755 test/tools/csql/test083.ksh delete mode 100755 test/tools/csql/test084.ksh delete mode 100755 test/tools/csql/test085.ksh delete mode 100755 test/tools/csql/test086.ksh delete mode 100755 test/tools/csql/test087.ksh delete mode 100755 test/tools/csql/test088.ksh delete mode 100755 test/tools/csql/test089.ksh delete mode 100755 test/tools/csql/test090.ksh delete mode 100755 test/tools/csql/test091.ksh delete mode 100644 test/tools/csql/tree0.sql delete mode 100644 test/tools/csql/tree1.sql delete mode 100644 test/tools/csql/tree10.sql delete mode 100644 test/tools/csql/tree11.sql delete mode 100644 test/tools/csql/tree12.sql delete mode 100644 test/tools/csql/tree13.sql delete mode 100644 test/tools/csql/tree14.sql delete mode 100644 test/tools/csql/tree15.sql delete mode 100644 test/tools/csql/tree16.sql delete mode 100644 test/tools/csql/tree17.sql delete mode 100644 test/tools/csql/tree18.sql delete mode 100644 test/tools/csql/tree19.sql delete mode 100644 test/tools/csql/tree2.sql delete mode 100644 test/tools/csql/tree20.sql delete mode 100644 test/tools/csql/tree21.sql delete mode 100644 test/tools/csql/tree22.sql delete mode 100644 test/tools/csql/tree23.sql delete mode 100644 test/tools/csql/tree24.sql delete mode 100644 test/tools/csql/tree3.sql delete mode 100644 test/tools/csql/tree4.sql delete mode 100644 test/tools/csql/tree5.sql delete mode 100644 test/tools/csql/tree6.sql delete mode 100644 test/tools/csql/tree7.sql delete mode 100644 test/tools/csql/tree8.sql delete mode 100644 test/tools/csql/tree9.sql delete mode 100644 test/tools/csql/uniqueindontuples.sql delete mode 100644 test/tools/csql/uniquetreeindontuples.sql delete mode 100644 test/tools/csql/updatetest.sql delete mode 100644 test/tools/csqldump/Makefile delete mode 100644 test/tools/csqldump/csql.conf delete mode 100644 test/tools/csqldump/drop.sql delete mode 100644 test/tools/csqldump/dropall.sql delete mode 100644 test/tools/csqldump/exp.test002.ksh delete mode 100644 test/tools/csqldump/exp.test003.ksh delete mode 100644 test/tools/csqldump/exp.test004.ksh delete mode 100644 test/tools/csqldump/exp.test005.ksh delete mode 100644 test/tools/csqldump/exp.test006.ksh delete mode 100644 test/tools/csqldump/exp.test007.ksh delete mode 100644 test/tools/csqldump/exp.test008.ksh delete mode 100644 test/tools/csqldump/exp.test010.ksh delete mode 100644 test/tools/csqldump/exp.test011.ksh delete mode 100644 test/tools/csqldump/exp.test012.ksh delete mode 100644 test/tools/csqldump/inputtest002.sql delete mode 100644 test/tools/csqldump/inputtest003.sql delete mode 100644 test/tools/csqldump/inputtest004.sql delete mode 100644 test/tools/csqldump/inputtest005.sql delete mode 100644 test/tools/csqldump/inputtest006.sql delete mode 100644 test/tools/csqldump/inputtest008.sql delete mode 100644 test/tools/csqldump/inputtest012.sql delete mode 100644 test/tools/csqldump/insert.c delete mode 100755 test/tools/csqldump/test001.ksh delete mode 100755 test/tools/csqldump/test002.ksh delete mode 100755 test/tools/csqldump/test003.ksh delete mode 100755 test/tools/csqldump/test004.ksh delete mode 100755 test/tools/csqldump/test005.ksh delete mode 100755 test/tools/csqldump/test006.ksh delete mode 100755 test/tools/csqldump/test007.ksh delete mode 100755 test/tools/csqldump/test008.ksh delete mode 100755 test/tools/csqldump/test009.ksh delete mode 100755 test/tools/csqldump/test010.ksh delete mode 100755 test/tools/csqldump/test011.ksh delete mode 100755 test/tools/csqldump/test012.ksh diff --git a/test/CacheTestModules b/test/CacheTestModules deleted file mode 100644 index 1babf3ac..00000000 --- a/test/CacheTestModules +++ /dev/null @@ -1,13 +0,0 @@ -#List of cache module directories which needs to be run by cache test executor -#Note: To exclude modules, comment out using # -cache/Recovery -cache/DDL -cache/Gateway -cache/FailOver -cache/CacheTable -cache/Bidirectional -cache/CacheVerify -adapter/Connect -adapter/Parameter -adapter/Select -jdbc/Gateway diff --git a/test/Makefile b/test/Makefile deleted file mode 100644 index 27ac86e8..00000000 --- a/test/Makefile +++ /dev/null @@ -1,38 +0,0 @@ -OSNAME = $(shell uname -s) -MAKE=make - -ifeq ($(OSNAME), SunOS) -PlatForm=supported -else -ifeq ($(OSNAME), Linux) -PlatForm=supported -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - - -ifeq ($(PlatForm), supported) -all: buildall -endif - -buildall: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE); cd ..;\ - fi;\ - done - -clean: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE) clean; cd ..;\ - fi;\ - done -runall: buildall - ./execTests.ksh - ./genReport.ksh diff --git a/test/TestModules b/test/TestModules deleted file mode 100644 index f2deb21b..00000000 --- a/test/TestModules +++ /dev/null @@ -1,31 +0,0 @@ -#List of test module directories which needs to be run by test executor -#Note: To exclude modules, comment out using # -dbapi/Connection -dbapi/Index -dbapi/DataType -dbapi/Table -dbapi/TableDef -dbapi/DatabaseManager -dbapi/UserManager -dbapi/Predicate -system/config -system/Allocator -system/proc -system/lock -system/trans -tools/catalog -tools/csql -tools/csqldump -tools/Durability -jdbc/Connection -jdbc/Statement -sqlapi/Connect -sqlapi/Parameter -sqlapi/Select -sql/Join -sql/Aggregate -odbc/Connect -odbc/NonSelectDML -odbc/Parameters -odbc/Select -odbc/Transaction diff --git a/test/csql.conf b/test/csql.conf deleted file mode 100644 index da2c61cb..00000000 --- a/test/csql.conf +++ /dev/null @@ -1,81 +0,0 @@ -# CSQL System Configuration File - -#####################################Server Section######################## -#Important: For Server section parameters, make sure that the value is same for the -# server process and all the csql client process which connects to it. otherwise, -# behavior is undefined - -# Page size. Each database is logically divided into pages and allocation happens -# in this unit of pages. Increasing this value will reduce frequent allocation of pages. -PAGE_SIZE= 8192 - -#Total number of client process which can connect and work with the -# database concurrently -MAX_PROCS = 100 - -# Maximum size of the system database. -MAX_SYS_DB_SIZE=1048576 - -#Maximum size of the user database file. -MAX_DB_SIZE=10485760 - -#Shared memory key to be used by the system to create and locate system database. -SYS_DB_KEY=2222 - -#Shared memory key to be used by the system to create and locate user database. -USER_DB_KEY=3333 - -#Give full path for the log file where important system actions are stored. -LOG_FILE=/tmp/log/csql/log.out - -#The virtual memory start address at which the shared memory segment -# will be created and attached. -MAP_ADDRESS=400000000 - -#Give full path for the database file where table and record information will -#be stored for durability -DATABASE_FILE=/tmp/csql/csql.db - -#Important: For Server section parameters, make sure that the value is same for the -# server process and all the csql client process which connects to it. otherwise, -# behavior is undefined -#####################################Client Section######################## - -#Mutex timeout interval seconds -MUTEX_TIMEOUT_SECS=0 -MUTEX_TIMEOUT_USECS=5000 -MUTEX_TIMEOUT_RETRIES=10 - -#Lock timeout interval seconds -LOCK_TIMEOUT_SECS=0 -LOCK_TIMEOUT_USECS=5000 -LOCK_TIMEOUT_RETRIES=10 - -#####################################Cache Section######################## - -#Whether to enable caching of tables from target database -CACHE_TABLE=false - -#Set cache id for multiple bidirectional cache node for single data source -CACHE_ID=1 - -#DSN Name to connect to the target database. -#This should be present in ~/odbc.ini file -DSN=myodbc3 - -ENABLE_BIDIRECTIONAL_CACHE=false - -CACHE_RECEIVER_WAIT_SECS=10 - -#Give full path for the file where all the cached table information is stored -TABLE_CONFIG_FILE=/tmp/csql/csqltable.conf - -##########################SqlNetworkServer Section######################## - -# Whether to enable SqlNetwork server -CSQL_SQL_SERVER=true - -#Set port for Network access -PORT=5678 - -#####################################End Section########################## diff --git a/test/execCacheTests.ksh b/test/execCacheTests.ksh deleted file mode 100755 index 3b02c794..00000000 --- a/test/execCacheTests.ksh +++ /dev/null @@ -1,219 +0,0 @@ -#!/bin/sh - -# First argument is the data source name to be used -# Second argument is the target database name -# valid names: MYSQL, PSQL, ORACLE - -################### Settings ######################################## -#Timeout value for the hanging scripts -HANG_TIMEOUT=150 - -################### TIMEOUT HANDLER ################################# -timeout_handler() { -if [ $CMD_PID != "" ] -then - HANG_FLAG=Yes - echo "HANG_FLAG is set here" - kill -9 $CMD_PID 2>/dev/null -fi -} - -##################### Test Executor main starts here ################## -echo MY pid is $$ -if [ ! "$CSQL_CONFIG_FILE" ] -then - echo "setupenv.ksh script is not run" - exit 1 -fi -#TEST_RUN_DIR should be set before running this -if [ ! "$TEST_RUN_ROOT" ] -then - echo "TEST_RUN_ROOT should be set before running the tests" - exit 1 -fi -if [ ! "$CSQL_INSTALL_ROOT" ] -then - echo "CSQL_INSTALL_ROOT should be set before running the tests" - exit 1 -fi -export DSN=$1 -export TDB=$2 -echo "First argument is " $1 -isql $1 /dev/null 2>/dev/null -if [ $? -ne 0 ] -then - echo "Unable to connect to data source" - exit 1 -fi - -cp $CSQL_CONFIG_FILE /tmp/csql.conf -echo DSN=$1 >>$CSQL_CONFIG_FILE - -ROOT_DIR=`pwd` -mkdir -p $TEST_RUN_ROOT -SERVOUT=$TEST_RUN_ROOT/serv.out -touch $SERVOUT -$CSQL_INSTALL_ROOT/bin/csqlserver >${SERVOUT} & -SERVER_PID=$! -echo "Starting Server" -sleep 5 -while read MODULE -do - echo $MODULE | grep "#" >/dev/null - if [ $? -eq 0 ] - then - continue - fi - echo "MODULE READ is $MODULE" - -TEST_SCRIPT_DIR=${ROOT_DIR}/${MODULE} -TEST_RUN_DIR=${TEST_RUN_ROOT}/${MODULE} -if [ -s "$TEST_RUN_DIR" ] -then - echo "TEST_RUN_ROOT directory is not empty. Clean and try again." - exit 1 -fi -mkdir -p $TEST_RUN_DIR - -# TODO::check whether server is running - -TEST_LOG=$TEST_RUN_DIR/testlog - -if [ -s "$TEST_LOG" ] -then - echo "TEST_RUN_DIR has files in it. Remove before running the tests" - exit 1 -fi - -TEST_EXEC_DIR=$TEST_RUN_DIR/tests -mkdir $TEST_EXEC_DIR - - -echo "Test Executor log file" >$TEST_LOG -echo "----------------------" >>$TEST_LOG - -TestList=`ls ${TEST_SCRIPT_DIR}/test*` -for test in $TestList -do -echo "Running $test" -echo "Running $test" >>$TEST_LOG -echo "Test started at : `date` " -echo "Test started at : `date` " >>$TEST_LOG - -expPresent="no" -EXP_FILE=exp.`basename ${test}` -#echo "EXP_FILE is $EXP_FILE" -if [ -s "${TEST_SCRIPT_DIR}/${EXP_FILE}" ] -then - expPresent="yes" -fi - -HANG_FLAG=No -trap timeout_handler USR1 -sleep ${HANG_TIMEOUT} && kill -s USR1 $$ & -SLEEP_PID=$! - -if [ "$expPresent" = "yes" ] -then - cp ${TEST_SCRIPT_DIR}/${EXP_FILE} ${TEST_EXEC_DIR} - ${test} > ${TEST_EXEC_DIR}/cur.${EXP_FILE} 2>/dev/null & -else - ${test} >> ${TEST_LOG} 2>/dev/null & -fi -CMD_PID=$! -wait ${CMD_PID} 2>/dev/null -ret=$? -echo "Test Ended at : `date` " -echo "Test Ended at : `date` " >>$TEST_LOG -unset CMD_PID -trap "" USR1 -kill -9 ${SLEEP_PID} 2>/dev/null - -if [ "$HANG_FLAG" = "Yes" ] -then - echo "Test Hung. so it is killed." >>$TEST_LOG - echo "FAILED:Test $test failed" >>$TEST_LOG - #TODO::Reinitalize the database, as it may be in corrupted state. - CURTIME=`date +%s` - mv ${SERVOUT} ${SERVOUT}.${SERVER_PID}.${CURTIME} - kill -9 ${SERVER_PID} - ipcrm -M 2222 -M 3333 - echo "csqlserver killed PID=${SERVER_PID}" >>$TEST_LOG - $CSQL_INSTALL_ROOT/bin/csqlserver >${SERVOUT} & - SERVER_PID=$! - echo "csqlserver restarted with PID=${SERVER_PID}" >>$TEST_LOG - echo "Restarting Server" - sleep 5 - continue -fi - -HANG_FLAG=No - -if [ $ret -eq 0 ] -then - if [ "$expPresent" = "yes" ] - then - #compare exp and current output - diff ${TEST_SCRIPT_DIR}/${EXP_FILE} ${TEST_EXEC_DIR}/cur.${EXP_FILE} > ${TEST_EXEC_DIR}/diff.${EXP_FILE} - if [ $? -eq 0 ] - then - - echo "Exp and current output matched." - echo "Test $test passed" - echo "Exp and current output matched." >>$TEST_LOG - echo "PASSED:Test $test passed" >>$TEST_LOG - rm ${TEST_EXEC_DIR}/cur.${EXP_FILE} - rm ${TEST_EXEC_DIR}/diff.${EXP_FILE} - rm ${TEST_EXEC_DIR}/${EXP_FILE} - else - echo "Exp and current output not matched." - echo "Test $test failed" - echo "Exp and current output not matched." >>${TEST_LOG} - echo "FAILED:Test $test failed" >>$TEST_LOG - #TODO::Reinitalize the database, as it may be in corrupted state. - CURTIME=`date +%s` - mv ${SERVOUT} ${SERVOUT}.${SERVER_PID}.${CURTIME} - echo "Refer ${SERVOUT}.${SERVER_PID}.${CURTIME} file for server log" >>$TEST_LOG - kill -9 ${SERVER_PID} - ipcrm -M 2222 -M 3333 - echo "csqlserver killed PID=${SERVER_PID}" >>${TEST_LOG} - $CSQL_INSTALL_ROOT/bin/csqlserver >${SERVOUT} & - SERVER_PID=$! - echo "csqlserver restarted with PID=${SERVER_PID}" >>${TEST_LOG} - echo "Restarting Server" - sleep 5 - fi - else - echo "Returned 0." - echo "Test $test passed" - echo "Returned 0." >>$TEST_LOG - echo "PASSED:Test $test passed" >>$TEST_LOG - fi - -else - echo "Returned $ret " - echo "Test $test failed" - echo "Returned $ret " >>$TEST_LOG - echo "FAILED:Test $test failed" >>$TEST_LOG - #TODO::Reinitalize the database, as it may be in corrupted state. - CURTIME=`date +%s` - mv ${SERVOUT} ${SERVOUT}.${SERVER_PID}.${CURTIME} - echo "Refer ${SERVOUT}.${SERVER_PID}.${CURTIME} file for server log" >>$TEST_LOG - kill -9 ${SERVER_PID} - ipcrm -M 2222 -M 3333 - echo "csqlserver killed PID=${SERVER_PID}" >>$TEST_LOG - $CSQL_INSTALL_ROOT/bin/csqlserver >${SERVOUT} 2>${SERVOUT} & - SERVER_PID=$! - echo "csqlserver restarted with PID=${SERVER_PID}" >>${TEST_LOG} - echo "Restarting Server" - sleep 5 -fi - -done -done < CacheTestModules - -kill -9 ${SERVER_PID} -ipcrm -M 2222 -M 3333 -echo "csqlserver killed PID=${SERVER_PID}" >>${TEST_LOG} -cp /tmp/csql.conf $CSQL_CONFIG_FILE -exit 0 diff --git a/test/execTests.ksh b/test/execTests.ksh deleted file mode 100755 index a5838b1d..00000000 --- a/test/execTests.ksh +++ /dev/null @@ -1,227 +0,0 @@ -#!/bin/sh - -################### Settings ######################################## -#Timeout value for the hanging scripts -HANG_TIMEOUT=150 - -################### TIMEOUT HANDLER ################################# -timeout_handler() { -if [ $CMD_PID != "" ] -then - HANG_FLAG=Yes - echo "HANG_FLAG is set here" - kill -9 $CMD_PID 2>/dev/null -fi -} - -##################### Test Executor main starts here ################## -echo MY pid is $$ -#TEST_RUN_DIR should be set before running this -if [ ! "$TEST_RUN_ROOT" ] -then - echo "TEST_RUN_ROOT should be set before running the tests" - exit 1 -fi -if [ ! "$CSQL_INSTALL_ROOT" ] -then - echo "CSQL_INSTALL_ROOT should be set before running the tests" - exit 1 -fi - -if [ ! "$CSQL_CONFIG_FILE" ] -then - echo "setupenv.ksh should be run before running the tests" - exit 1 -fi -DBFILE=`grep DATABASE_FILE $CSQL_CONFIG_FILE| awk -F= '{ print $2}'` -CACHECONFFILE=`grep TABLE_CONFIG_FILE $CSQL_CONFIG_FILE| awk -F= '{ print $2}'` -rm $DBFILE -rm $CACHECONFFILE -echo $DBFILE -ROOT_DIR=`pwd` -mkdir -p $TEST_RUN_ROOT -SERVOUT=$TEST_RUN_ROOT/serv.out -touch $SERVOUT - -export CSQL_CONFIG_FILE=csql.conf -$CSQL_INSTALL_ROOT/bin/csqlserver >${SERVOUT} & -SERVER_PID=$! -echo "Starting Server" -sleep 5 -while read MODULE -do - echo $MODULE | grep "#" >/dev/null - if [ $? -eq 0 ] - then - continue - fi - echo "MODULE READ is $MODULE" - -if [ "$MODULE" = "system/lock" -o "$MODULE" = "system/Allocator" ] -then - echo "Restarting the server for lock module" - kill -9 ${SERVER_PID} - ipcrm -M 2222 -M 3333 - echo "csqlserver killed PID=${SERVER_PID}" >>$TEST_LOG - rm $DBFILE - $CSQL_INSTALL_ROOT/bin/csqlserver >${SERVOUT} & - SERVER_PID=$! - echo "csqlserver restarted with PID=${SERVER_PID}" >>$TEST_LOG - echo "Restarting Server" - sleep 5 -fi - -TEST_SCRIPT_DIR=${ROOT_DIR}/${MODULE} -TEST_RUN_DIR=${TEST_RUN_ROOT}/${MODULE} -if [ -s "$TEST_RUN_DIR" ] -then - echo "TEST_RUN_ROOT directory is not empty. Clean and try again." - exit 1 -fi -mkdir -p $TEST_RUN_DIR - -# TODO::check whether server is running - -TEST_LOG=$TEST_RUN_DIR/testlog - -if [ -s "$TEST_LOG" ] -then - echo "TEST_RUN_DIR has files in it. Remove before running the tests" - exit 1 -fi - -TEST_EXEC_DIR=$TEST_RUN_DIR/tests -mkdir $TEST_EXEC_DIR - - -echo "Test Executor log file" >$TEST_LOG -echo "----------------------" >>$TEST_LOG - -TestList=`ls ${TEST_SCRIPT_DIR}/test*` -for test in $TestList -do -echo "Running $test" -echo "Running $test" >>$TEST_LOG -echo "Test started at : `date` " -echo "Test started at : `date` " >>$TEST_LOG - -expPresent="no" -EXP_FILE=exp.`basename ${test}` -#echo "EXP_FILE is $EXP_FILE" -if [ -s "${TEST_SCRIPT_DIR}/${EXP_FILE}" ] -then - expPresent="yes" -fi - -HANG_FLAG=No -trap timeout_handler USR1 -sleep ${HANG_TIMEOUT} && kill -s USR1 $$ & -SLEEP_PID=$! - -if [ "$expPresent" = "yes" ] -then - cp ${TEST_SCRIPT_DIR}/${EXP_FILE} ${TEST_EXEC_DIR} - ${test} > ${TEST_EXEC_DIR}/cur.${EXP_FILE} 2>/dev/null & -else - ${test} >> ${TEST_LOG} 2>/dev/null & -fi -CMD_PID=$! -wait ${CMD_PID} 2>/dev/null -ret=$? -echo "Test Ended at : `date` " -echo "Test Ended at : `date` " >>$TEST_LOG -unset CMD_PID -trap "" USR1 -kill -9 ${SLEEP_PID} 2>/dev/null - -if [ "$HANG_FLAG" = "Yes" ] -then - echo "Test Hung. so it is killed." >>$TEST_LOG - echo "FAILED:Test $test failed" >>$TEST_LOG - #TODO::Reinitalize the database, as it may be in corrupted state. - CURTIME=`date +%s` - mv ${SERVOUT} ${SERVOUT}.${SERVER_PID}.${CURTIME} - kill -9 ${SERVER_PID} - ipcrm -M 2222 -M 3333 - echo "csqlserver killed PID=${SERVER_PID}" >>$TEST_LOG - $CSQL_INSTALL_ROOT/bin/csqlserver >${SERVOUT} & - SERVER_PID=$! - echo "csqlserver restarted with PID=${SERVER_PID}" >>$TEST_LOG - echo "Restarting Server" - sleep 5 - continue -fi - -HANG_FLAG=No - -if [ $ret -eq 0 ] -then - if [ "$expPresent" = "yes" ] - then - #compare exp and current output - diff ${TEST_SCRIPT_DIR}/${EXP_FILE} ${TEST_EXEC_DIR}/cur.${EXP_FILE} > ${TEST_EXEC_DIR}/diff.${EXP_FILE} - if [ $? -eq 0 ] - then - - echo "Exp and current output matched." - echo "Test $test passed" - echo "Exp and current output matched." >>$TEST_LOG - echo "PASSED:Test $test passed" >>$TEST_LOG - rm ${TEST_EXEC_DIR}/cur.${EXP_FILE} - rm ${TEST_EXEC_DIR}/diff.${EXP_FILE} - rm ${TEST_EXEC_DIR}/${EXP_FILE} - else - echo "Exp and current output not matched." - echo "Test $test failed" - echo "Exp and current output not matched." >>${TEST_LOG} - echo "FAILED:Test $test failed" >>$TEST_LOG - #TODO::Reinitalize the database, as it may be in corrupted state. - CURTIME=`date +%s` - mv ${SERVOUT} ${SERVOUT}.${SERVER_PID}.${CURTIME} - echo "Refer ${SERVOUT}.${SERVER_PID}.${CURTIME} file for server log" >>$TEST_LOG - kill -9 ${SERVER_PID} - ipcrm -M 2222 -M 3333 - echo "csqlserver killed PID=${SERVER_PID}" >>${TEST_LOG} - rm $DBFILE - $CSQL_INSTALL_ROOT/bin/csqlserver >${SERVOUT} & - SERVER_PID=$! - echo "csqlserver restarted with PID=${SERVER_PID}" >>${TEST_LOG} - echo "Restarting Server" - sleep 5 - fi - else - echo "Returned 0." - echo "Test $test passed" - echo "Returned 0." >>$TEST_LOG - echo "PASSED:Test $test passed" >>$TEST_LOG - fi - -else - echo "Returned $ret " - echo "Test $test failed" - echo "Returned $ret " >>$TEST_LOG - echo "FAILED:Test $test failed" >>$TEST_LOG - #TODO::Reinitalize the database, as it may be in corrupted state. - CURTIME=`date +%s` - mv ${SERVOUT} ${SERVOUT}.${SERVER_PID}.${CURTIME} - echo "Refer ${SERVOUT}.${SERVER_PID}.${CURTIME} file for server log" >>$TEST_LOG - kill -9 ${SERVER_PID} - ipcrm -M 2222 -M 3333 - echo "csqlserver killed PID=${SERVER_PID}" >>$TEST_LOG - rm $DBFILE - $CSQL_INSTALL_ROOT/bin/csqlserver >${SERVOUT} 2>${SERVOUT} & - SERVER_PID=$! - echo "csqlserver restarted with PID=${SERVER_PID}" >>${TEST_LOG} - echo "Restarting Server" - sleep 5 -fi - -done -done < TestModules -kill `ps -e | grep csqlsqlserver | gawk -F" " '{ print $1 }'` -kill -9 ${SERVER_PID} -ipcrm -M 2222 -M 3333 -echo "csqlserver killed PID=${SERVER_PID}" >>${TEST_LOG} -rm $DBFILE - -exit 0 diff --git a/test/genReport.ksh b/test/genReport.ksh deleted file mode 100755 index c6d6c130..00000000 --- a/test/genReport.ksh +++ /dev/null @@ -1,50 +0,0 @@ -#!/bin/sh -##################Test Report Generator main starts here############## -FILE=TestModules -#FILE=CacheTestModules -if [ $1 = "Cache" ] -then - FILE=CacheTestModules -fi - -#TEST_RUN_DIR should be set before running this -if [ ! "$TEST_RUN_ROOT" ] -then - echo "TEST_RUN_ROOT should be set before running the tests" - exit 1 -fi -#if [ -s "$TEST_RUN_ROOT" ] -#then -# echo "TEST_RUN_ROOT directory does not exist. Create it and try again." -# exit 1 -#fi -ROOT_DIR=`pwd` -TOTALPASSED=0 -TOTALFAILED=0 -echo "====================================================================" -echo " MODULE TESTPASSED TESTFAILED " -echo "====================================================================" -while read MODULE -do - echo $MODULE | grep "#" >/dev/null 2>/dev/null - if [ $? -eq 0 ] - then - continue - fi - TEST_RUN_DIR=${TEST_RUN_ROOT}/${MODULE} - TEST_LOG=$TEST_RUN_DIR/testlog - TESTPASSED=`grep PASSED $TEST_LOG 2>/dev/null | wc -l ` - TESTFAILED=`grep FAILED $TEST_LOG 2>/dev/null | wc -l ` - printf "%25s\t\t %5d\t\t %5d\t\t\n" $MODULE $TESTPASSED $TESTFAILED - (( TOTALPASSED = TOTALPASSED + TESTPASSED )) - (( TOTALFAILED = TOTALFAILED + TESTFAILED )) - -done < $FILE - -TOTSTRING=TOTAL -echo "====================================================================" -printf "%25s\t\t %5d\t\t %5d\t\t\n" $TOTSTRING $TOTALPASSED $TOTALFAILED -echo "====================================================================" -(( TOTALEXECUTED= TOTALPASSED + TOTALFAILED )) -echo "TOTAL Executed: $TOTALEXECUTED" -exit 0 diff --git a/test/jdbc/Connection/ConnTest1.java b/test/jdbc/Connection/ConnTest1.java deleted file mode 100755 index faf774dc..00000000 --- a/test/jdbc/Connection/ConnTest1.java +++ /dev/null @@ -1,21 +0,0 @@ -//Try to connect with connectstring "jdbc:csql" and give correct "user" and "password" in properties object. It should pass. -//Author: XieLiang -import java.sql.*; -public class ConnTest1 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - if ( con == null ) System.exit(1); - con.close(); - System.exit(0); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.getStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest10.java b/test/jdbc/Connection/ConnTest10.java deleted file mode 100644 index 2e2bfd7d..00000000 --- a/test/jdbc/Connection/ConnTest10.java +++ /dev/null @@ -1,19 +0,0 @@ -//Try to connect with connectstring "jdbc:sql" and give correct "user" and "password" in properties object. It should fail. -//Author: XieLiang -import java.sql.*; -public class ConnTest10 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:sql", "root", "manager"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Connection/ConnTest11.java b/test/jdbc/Connection/ConnTest11.java deleted file mode 100644 index a7eda080..00000000 --- a/test/jdbc/Connection/ConnTest11.java +++ /dev/null @@ -1,19 +0,0 @@ -//Try to connect with connectstring "odbc:csql" and give correct "user" and "password" in properties object. It should fail. -//Author: XieLiang -import java.sql.*; -public class ConnTest11 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("odbc:csql", "root", "manager"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit (0); - } - } -} diff --git a/test/jdbc/Connection/ConnTest12.java b/test/jdbc/Connection/ConnTest12.java deleted file mode 100644 index 515b2bc0..00000000 --- a/test/jdbc/Connection/ConnTest12.java +++ /dev/null @@ -1,19 +0,0 @@ -//Try to connect with connectstring "jdbc:csql" and give incorrect "user" and "password" in properties object. It should fail. -//Author: XieLiang -import java.sql.*; -public class ConnTest12 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "wrongusertestxieliang", "manager"); - if (con != null) System.exit (1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Connection/ConnTest13.java b/test/jdbc/Connection/ConnTest13.java deleted file mode 100644 index e39a9b8b..00000000 --- a/test/jdbc/Connection/ConnTest13.java +++ /dev/null @@ -1,19 +0,0 @@ -//Try to connect with connectstring "jdbc:csql" and give correct "user" and incorrect "password" in properties object. It should fail. -//Author: XieLiang -import java.sql.*; -public class ConnTest13 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "wrongpasswdtestxieliang"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Connection/ConnTest14.java b/test/jdbc/Connection/ConnTest14.java deleted file mode 100644 index 453f7df4..00000000 --- a/test/jdbc/Connection/ConnTest14.java +++ /dev/null @@ -1,19 +0,0 @@ -//Try to connect with very long connectstring and give correct "user" and "password" in properties object. It should fail but no overflow -//Author: XieLiang -import java.sql.*; -public class ConnTest14 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("testlonglonglongconnectstring111111111111111111111111111111111111111111111111111111111111111111111122222222222222222222222222222222222222222222222222222222222222222233333333333333333333333333333333333333333333333333334444444444444444444444444444444444444444444455555555555555555555555555555555555555555555555555555555556666666666666666666666666666666666666666666677777777777777777777777777777777777777777777777777777777888888888888888888888888888888888888888888888889999999999999999999999999999999999999xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxlllllllllllllllllllllllllllllllllllaaaaaaaaaaaaaaaaaaaaaaaaaabbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbbcccccccccccccccccccccccccccccccccccccccdddddddddddddddddddddddeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeffffffffffffffffffffffffffffffffffffffffffffffffffffff", "root", "manager"); - if (con != null) System.exit (1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit (0); - } - } -} diff --git a/test/jdbc/Connection/ConnTest15.java b/test/jdbc/Connection/ConnTest15.java deleted file mode 100644 index 5f20dd6f..00000000 --- a/test/jdbc/Connection/ConnTest15.java +++ /dev/null @@ -1,18 +0,0 @@ -//Try to connect with connectstring "jdbc:csql" and give very long "user" string and correct "password" in properties object. It should fail but no overflow. -//Author: XieLiang -import java.sql.*; -public class ConnTest15 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "wrongusertestxieliangiiiiiiiiiiisooooooooooooooooooooooooooooooooooooooooooooooooolllllllllllllllllllllllloooooooooooooooonnnnnnnnnnnnnnnnnnnnnggggggggggggggggggggg11111111111111111111111111222222222222222222222222222222233333333333333333333333333444444444444444444444444455555555555555555555555555555556666666666666666666666666666666667777777777777777777777777777777777788888888888888888888888888888888888888899999999999999999999999999999999999999999999999999999999999999999xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiieeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeellllllllllllllllllllllllllllllllllllllllllllllllllllllliiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaannnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnggggggggggggggggggggggggggggggggggghhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaatttttttttttttttttttttttttttteeeeeeeeeeeeeeeeeeeeeeeeesssssssssssssssstttttttttttttttttttttttttttttttttttttttttttttt", "manager"); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Connection/ConnTest16.java b/test/jdbc/Connection/ConnTest16.java deleted file mode 100644 index fd8db5d3..00000000 --- a/test/jdbc/Connection/ConnTest16.java +++ /dev/null @@ -1,26 +0,0 @@ -//Try to open , close , open . it should pass -//Author: XieLiang -import java.sql.*; -public class ConnTest16 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - if ( con == null ) - System.exit(1); - con.close(); - con = DriverManager.getConnection("jdbc:csql","root","manager"); - if ( con == null ) - System.exit(1); - con.close(); - System.exit(0); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest17.java b/test/jdbc/Connection/ConnTest17.java deleted file mode 100644 index 87416121..00000000 --- a/test/jdbc/Connection/ConnTest17.java +++ /dev/null @@ -1,25 +0,0 @@ -//Close the connection and they call commit(). It should fail. -//Author: XieLiang -import java.sql.*; -public class ConnTest17 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - if ( con == null ) - System.exit(1); - con.close(); - con.commit(); - System.exit(1); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - if (e.getMessage().equals("Invalid state")) System.exit(0); - else System.exit(1); - - } - } -} diff --git a/test/jdbc/Connection/ConnTest18.java b/test/jdbc/Connection/ConnTest18.java deleted file mode 100644 index e5445270..00000000 --- a/test/jdbc/Connection/ConnTest18.java +++ /dev/null @@ -1,25 +0,0 @@ -//Close the connection and then call createStatement(). It should fail. -//Author: XieLiang -import java.sql.*; -public class ConnTest18 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - if ( con == null ) - System.exit(1); - con.close(); - Statement cStmt = con.createStatement(); - if (cStmt != null) - System.exit(1); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - if (e.getMessage().equals("Invalid state")) System.exit(0); - else System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest19.java b/test/jdbc/Connection/ConnTest19.java deleted file mode 100644 index dc34a9a9..00000000 --- a/test/jdbc/Connection/ConnTest19.java +++ /dev/null @@ -1,27 +0,0 @@ -//Close the connection and then call preparedStatement(). It should fail -//Author: XieLiang -import java.sql.*; -public class ConnTest19 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - if ( con == null ) - System.exit(1); - con.close(); - PreparedStatement pStmt = null; - pStmt = con.prepareStatement("create table t1(f1 integer);"); - if (pStmt != null) - System.exit(1); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - if (e.getMessage().equals("Invalid state")) System.exit(0); - else System.exit(1); - - } - } -} diff --git a/test/jdbc/Connection/ConnTest2.java b/test/jdbc/Connection/ConnTest2.java deleted file mode 100755 index 2e40158a..00000000 --- a/test/jdbc/Connection/ConnTest2.java +++ /dev/null @@ -1,58 +0,0 @@ -//Test 5000 connections -//Author: XieLiang -import java.sql.*; - -public class ConnTest2 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - int ret =0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - con.close(); - int count =0; - PreparedStatement stmt = null; - for (int i=0; i <5000 ; i++) - { - con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - con.setAutoCommit(false); - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i+100)); - ret = stmt.executeUpdate(); - if (ret != 1) break; - count++; - stmt.close(); - con.commit(); - con.close(); - if (i%100 ==0) {System.out.println("Total Connections made "+ i); System.gc(); Thread.sleep(500);} - } - System.out.println("Total Rows inserted "+ count); - - - con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - cStmt = con.createStatement(); - System.out.println("Listing tuples:"); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - count =0; - while (rs.next()) - { - count++; - } - rs.close(); - con.commit(); - System.out.println("Total rows selected " + count); - cStmt.execute("DROP TABLE T1;"); - con.close(); - if (count !=5000) System.exit(1); else System.exit(0); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest20.java b/test/jdbc/Connection/ConnTest20.java deleted file mode 100644 index d00f5add..00000000 --- a/test/jdbc/Connection/ConnTest20.java +++ /dev/null @@ -1,24 +0,0 @@ -//Open the connection and then call isClosed(). It should return false. -//Close the connection and then call isClosed(). It should return true. -//Author: XieLiang -import java.sql.*; -public class ConnTest20 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - if ( con == null ) - System.exit(1); - if(con.isClosed()) System.exit(1); - con.close(); - if(!con.isClosed()) System.exit(1); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest22.java b/test/jdbc/Connection/ConnTest22.java deleted file mode 100644 index 3418a01b..00000000 --- a/test/jdbc/Connection/ConnTest22.java +++ /dev/null @@ -1,47 +0,0 @@ -//Create connection, setAutocommit(false) , create Statement, insert 10 tuples, close the connection. -//Open another connection and check the number of tuples. It should be Zero. -//Author: XieLiang -import java.sql.*; -public class ConnTest22 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - con.setAutoCommit(false); - Statement cStmt = con.createStatement(); - - int ret = 0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - PreparedStatement stmt = null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - for (int i=0; i <10 ; i++) - { - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i)); - ret = stmt.executeUpdate(); - if (ret !=1) break; - } - stmt.close(); - con.close(); - con = DriverManager.getConnection("jdbc:csql","root","manager"); - int count = 0; - cStmt = con.createStatement(); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - while(rs.next()) - { - count++; - } - rs.close(); - cStmt.execute("DROP TABLE T1;"); - con.close(); - if (count == 0) System.exit(0); else System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest24.java b/test/jdbc/Connection/ConnTest24.java deleted file mode 100644 index 2a5c4fdf..00000000 --- a/test/jdbc/Connection/ConnTest24.java +++ /dev/null @@ -1,48 +0,0 @@ -//Create connection, set auto-commit false, create Statement, insert 10 tuples, rollback the transaction, close connection -//Open another connection and check the number of tuples. It should be Zero. -//Author: XieLiang -import java.sql.*; -public class ConnTest24 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - con.setAutoCommit(false); - Statement cStmt = con.createStatement(); - int ret = 0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - PreparedStatement stmt = null; - for (int i=0; i <10 ; i++) - { - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i)); - ret = stmt.executeUpdate(); - if (ret !=1) break; - stmt.close(); - } - con.rollback(); - con.close(); - con = DriverManager.getConnection("jdbc:csql","root","manager"); - int count = 0; - cStmt = con.createStatement(); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - while(rs.next()) - { - count++; - } - rs.close(); - System.out.println("Total rows selected " + count); - cStmt.execute("DROP TABLE T1;"); - con.close(); - if (count != 0) System.exit(1); else System.exit (0); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest25.java b/test/jdbc/Connection/ConnTest25.java deleted file mode 100644 index e4ddf21f..00000000 --- a/test/jdbc/Connection/ConnTest25.java +++ /dev/null @@ -1,48 +0,0 @@ -//Create connection, set auto-commit false, create Statement, insert 10 tuples, commit the transaction, close connection -//Open another connection and check the number of tuples. It should be Ten. -//Author: XieLiang -import java.sql.*; -public class ConnTest25 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - con.setAutoCommit(false); - Statement cStmt = con.createStatement(); - int ret = 0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - PreparedStatement stmt = null; - for (int i=0; i <10 ; i++) - { - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i)); - ret = stmt.executeUpdate(); - if (ret !=1) break; - stmt.close(); - } - con.commit(); - con.close(); - con = DriverManager.getConnection("jdbc:csql","root","manager"); - int count = 0; - cStmt = con.createStatement(); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - while(rs.next()) - { - count++; - } - rs.close(); - System.out.println("Total rows selected " + count); - cStmt.execute("DROP TABLE T1;"); - con.close(); - if (count ==10 ) System.exit(0); else System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest26.java b/test/jdbc/Connection/ConnTest26.java deleted file mode 100644 index fb454077..00000000 --- a/test/jdbc/Connection/ConnTest26.java +++ /dev/null @@ -1,47 +0,0 @@ -//Create Connection, call commit() 10K times. -//System should be stable, check this by creating new connection and insert 1 tuple. -//Author: XieLiang -import java.sql.*; -public class ConnTest26 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - con.setAutoCommit(false); - Statement cStmt = con.createStatement(); - int ret = 0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - for (int i=0; i <10000; i++) - con.commit(); - con.close(); - Connection con2 = DriverManager.getConnection("jdbc:csql","root","manager"); - int count = 0; - cStmt = con2.createStatement(); - PreparedStatement stmt = null; - stmt = con2.prepareStatement("INSERT INTO T1 VALUES (?,?);"); - stmt.setInt(1,1); - stmt.setString(2,"test1"); - ret = stmt.executeUpdate(); - if (ret != 1) - System.out.println("test failed!"); - stmt.close(); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - while(rs.next()) - { - count++; - } - rs.close(); - System.out.println("Total rows selected " + count); - cStmt.execute("DROP TABLE T1;"); - con2.close(); - if (count ==1 ) System.exit(0); else System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest27.java b/test/jdbc/Connection/ConnTest27.java deleted file mode 100644 index af207a14..00000000 --- a/test/jdbc/Connection/ConnTest27.java +++ /dev/null @@ -1,48 +0,0 @@ -//Create Connection, call rollback() 10K times. -//System should be stable, check this by creating new connection and insert 1 tuple. -//Author: XieLiang -import java.sql.*; -public class ConnTest27 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - con.setAutoCommit(false); - Statement cStmt = con.createStatement(); - int ret = 0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - con.commit(); - for (int i=0; i <10000; i++) - con.rollback(); - con.close(); - Connection con2 = DriverManager.getConnection("jdbc:csql","root","manager"); - int count = 0; - cStmt = con2.createStatement(); - PreparedStatement stmt = null; - stmt = con2.prepareStatement("INSERT INTO T1 VALUES (?,?);"); - stmt.setInt(1,1); - stmt.setString(2,"test1"); - ret = stmt.executeUpdate(); - if (ret != 1) - System.out.println("test failed!"); - stmt.close(); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - while(rs.next()) - { - count++; - } - rs.close(); - System.out.println("Total rows selected " + count); - cStmt.execute("DROP TABLE T1;"); - con2.close(); - if (count ==1) System.exit(0); else System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest29.java b/test/jdbc/Connection/ConnTest29.java deleted file mode 100644 index 73892a91..00000000 --- a/test/jdbc/Connection/ConnTest29.java +++ /dev/null @@ -1,57 +0,0 @@ -//Create Connection, insert 1 tuple, call rollback. Repeat the steps(connec,insert,rollback) for 10K times. -//Then connect and check whether 0 tuples are present. -//Author: XieLiang -import java.sql.*; -public class ConnTest29 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - con.setAutoCommit(false); - Statement cStmt = con.createStatement(); - PreparedStatement stmt = null; - int ret = 0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - con.commit(); - con.close(); - for (int i=0; i <10000; i++) - { - con = DriverManager.getConnection("jdbc:csql","root","manager"); - con.setAutoCommit(false); - stmt = con.prepareStatement("INSERT INTO T1 VALUES(?,?);"); - stmt.setInt(1,1); - stmt.setString(2,"xieliangkingsoft"); - ret = stmt.executeUpdate(); - if(ret != 1) - { - System.out.println("test failed"); - break; - } - stmt.close(); - con.rollback(); - con.close(); - } - con = DriverManager.getConnection("jdbc:csql","root","manager"); - int count = 0; - cStmt = con.createStatement(); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - while(rs.next()) - { - count++; - } - rs.close(); - System.out.println("Total rows selected " + count); - cStmt.execute("DROP TABLE T1;"); - con.commit(); - con.close(); - if (count == 0) System.exit(0); else System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest3.java b/test/jdbc/Connection/ConnTest3.java deleted file mode 100755 index dafbcdab..00000000 --- a/test/jdbc/Connection/ConnTest3.java +++ /dev/null @@ -1,55 +0,0 @@ -//Test 5000 statements in one connection one after other -//Author: XieLiang -import java.sql.*; -public class ConnTest3 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - int ret =0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - - PreparedStatement stmt = null; - for (int i=0; i <5000 ; i++) - { - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i+100)); - ret = stmt.executeUpdate(); - if (ret !=1) break; - stmt.close(); - con.commit(); - if (i %100 ==0) - { - System.out.println("Total statements created "+ i); - System.gc(); - Thread.sleep(500); - } - - } - - cStmt = con.createStatement(); - System.out.println("Listing tuples:"); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - int count =0; - while (rs.next()) - { - count++; - } - System.out.println("Total rows selected " + count); - rs.close(); - con.commit(); - cStmt.execute("DROP TABLE T1;"); - con.close(); - if (count !=5000) System.exit(1); else System.exit(0); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest34.java b/test/jdbc/Connection/ConnTest34.java deleted file mode 100644 index 8ae7829f..00000000 --- a/test/jdbc/Connection/ConnTest34.java +++ /dev/null @@ -1,56 +0,0 @@ -//Create Connection, setAutocommit(true), create table t1, insert into t1 10 records -//then call rollback(), select and count the number of records. It should be 10 -//Author: XieLiang -import java.sql.*; -public class ConnTest34 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - con.setAutoCommit(true); - Statement cStmt = con.createStatement(); - PreparedStatement stmt = null; - int ret = 0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - cStmt.close(); - for (int i=0; i <10; i++) - { - stmt = con.prepareStatement("INSERT INTO T1 VALUES(?,?);"); - stmt.setInt(1,i); - stmt.setString(2,"test"+i); - ret = stmt.executeUpdate(); - stmt.close(); - if(ret != 1) - { - System.out.println("test failed"); - break; - } - } - con.rollback(); - - int count = 0; - cStmt = con.createStatement(); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - while(rs.next()) - { - count++; - } - rs.close(); - cStmt.execute("DROP TABLE T1;"); - cStmt.close(); - con.close(); - if (count == 10) - System.exit(0); - else - System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} - diff --git a/test/jdbc/Connection/ConnTest4.java b/test/jdbc/Connection/ConnTest4.java deleted file mode 100755 index 077fe617..00000000 --- a/test/jdbc/Connection/ConnTest4.java +++ /dev/null @@ -1,54 +0,0 @@ -//Test 100 statements simultaneously in one connection , insert 1 tuple from -//each stmt, and check whether 100 tuples are inserted. -//Author: XieLiang -import java.sql.*; -public class ConnTest4 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - int ret =0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - - PreparedStatement stmt[] = new PreparedStatement[100];; - for (int i=0; i <100 ; i++) - { - stmt[i] = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - if (i %10 ==0) System.out.println("statements prepared "+ i); - } - int count =0; - for (int i=0; i <100 ; i++) - { - stmt[i].setInt(1, i); - stmt[i].setString(2, String.valueOf(i+100)); - ret = stmt[i].executeUpdate(); - if (ret != 1) break; - stmt[i].close(); - con.commit(); - count++; - } - System.out.println("Total rows inserted "+ count); - cStmt = con.createStatement(); - System.out.println("Listing tuples:"); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - count=0; - while (rs.next()) - { - count++; - } - rs.close(); - con.commit(); - cStmt.execute("DROP TABLE T1;"); - con.close(); - if (count == 100) System.exit(0); else System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest5.java b/test/jdbc/Connection/ConnTest5.java deleted file mode 100755 index eb19cc8c..00000000 --- a/test/jdbc/Connection/ConnTest5.java +++ /dev/null @@ -1,51 +0,0 @@ -//Test 100 statements, inserting 1 tuple, committed in 1 transaction, check whether total tuples is 100 -//Author: XieLiang -import java.sql.*; -public class ConnTest5 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - int ret =0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - - PreparedStatement stmt[] = new PreparedStatement[100]; - for (int i=0; i <100 ; i++) - { - stmt[i] = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - if (i %10 ==0) System.out.println("statements prepared "+ i); - } - for (int i=0; i <100 ; i++) - { - stmt[i].setInt(1, i); - stmt[i].setString(2, String.valueOf(i+100)); - ret = stmt[i].executeUpdate(); - if (ret != 1) break; - stmt[i].close(); - } - con.commit(); - - cStmt = con.createStatement(); - System.out.println("Listing tuples:"); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - int count =0; - while (rs.next()) - { - count++; - } - rs.close(); - con.commit(); - cStmt.execute("DROP TABLE T1;"); - con.close(); - if (count == 100) System.exit(0); else System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/ConnTest6.java b/test/jdbc/Connection/ConnTest6.java deleted file mode 100755 index ad8d9e31..00000000 --- a/test/jdbc/Connection/ConnTest6.java +++ /dev/null @@ -1,51 +0,0 @@ -//Test DML statement with rollback -//Author: XieLiang -import java.sql.*; -public class ConnTest6 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - con.setAutoCommit(false); - int ret =0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - - PreparedStatement stmt = null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i+100)); - ret = stmt.executeUpdate(); - if (ret !=1) break; - } - stmt.close(); - con.commit(); - - cStmt.execute("UPDATE T1 set f2='2' where f1 = 2;"); - ret = cStmt.executeUpdate("INSERT INTO T1 values (100, '100');"); - if (ret != 1) System.out.println("Insert error"); - ret = cStmt.executeUpdate("DELETE FROM T1 WHERE f1 = 4;"); - if (ret != 1) System.out.println("Delete error"); - con.rollback(); - - System.out.println("After rollback, listing tuples:"); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - con.commit(); - cStmt.executeUpdate("DROP TABLE T1;"); - - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} diff --git a/test/jdbc/Connection/ConnTest8.java b/test/jdbc/Connection/ConnTest8.java deleted file mode 100644 index 4f1e5c6a..00000000 --- a/test/jdbc/Connection/ConnTest8.java +++ /dev/null @@ -1,19 +0,0 @@ -//Try to connect with connectstring "jdbc:csql" and give empty properties object. It should fail. -//Author: XieLiang -import java.sql.*; -public class ConnTest8 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", null, null); - if (con != null) {con.close(); System.exit(1);} - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Connection/ConnTest9.java b/test/jdbc/Connection/ConnTest9.java deleted file mode 100644 index ac9f9556..00000000 --- a/test/jdbc/Connection/ConnTest9.java +++ /dev/null @@ -1,19 +0,0 @@ -//Try to connect with connectstring "jdbc:csql" and give empty properties object. It should fail. -//Author: XieLiang -import java.sql.*; -public class ConnTest9 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Connection/IsoTest1.java b/test/jdbc/Connection/IsoTest1.java deleted file mode 100644 index b2f5c50d..00000000 --- a/test/jdbc/Connection/IsoTest1.java +++ /dev/null @@ -1,23 +0,0 @@ -//Open connection and call setTransactionIsolation (TRANSACTION_SERIALIZABLE ). It should throw unsupported SQL exception. -//Author: XieLiang -import java.sql.*; -public class IsoTest1 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - if ( con == null ) - System.out.println("test failed!"); - con.setTransactionIsolation(Connection.TRANSACTION_SERIALIZABLE); - con.commit(); - con.close(); - System.out.println("test failed2!"); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - } - } -} diff --git a/test/jdbc/Connection/IsoTest2.java b/test/jdbc/Connection/IsoTest2.java deleted file mode 100644 index 9b2e21b4..00000000 --- a/test/jdbc/Connection/IsoTest2.java +++ /dev/null @@ -1,53 +0,0 @@ -//Open two connections and call setTransactionIsolation(TRANSACTION_UNCOMMITTED ). -//From 1st connection insert tuple and then sleep, from 2nd connection try to select the inserted tuple. -//Tuple should be seen. -//Author: XieLiang -import java.sql.*; -public class IsoTest2 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con1 = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Connection con2 = DriverManager.getConnection("jdbc:csql", "root", "manager"); - if ( (con1 == null) || (con2 == null) ) - System.out.println("test failed!"); - con1.setTransactionIsolation(Connection.TRANSACTION_READ_UNCOMMITTED); - con2.setTransactionIsolation(Connection.TRANSACTION_READ_UNCOMMITTED); - con1.setAutoCommit(false); - con2.setAutoCommit(false); - Statement cStmt = con1.createStatement(); - cStmt.execute("CREATE TABLE T1(f1 integer,f2 char(20));"); - PreparedStatement stmt = null; - stmt = con1.prepareStatement("INSERT INTO T1 VALUES(?,?);"); - stmt.setInt(1,1); - stmt.setString(2,"test"); - int ret = 0; - ret = stmt.executeUpdate(); - if (ret != 1) { - con1.close(); - con2.close(); - System.exit(1); - } - - cStmt = con2.createStatement(); - ResultSet rs = cStmt.executeQuery("SELECT * FROM T1;"); - int count =0; - while(rs.next()) - { - count++; - } - rs.close(); - cStmt.execute("DROP TABLE T1;"); - con1.close(); - con2.close(); - if (count !=1) System.exit(1); else System.exit(0); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Connection/Makefile b/test/jdbc/Connection/Makefile deleted file mode 100644 index 60543d0e..00000000 --- a/test/jdbc/Connection/Makefile +++ /dev/null @@ -1,16 +0,0 @@ -OSNAME = $(shell uname -s) -JAVAC = javac -TARGETS = ConnTests -TARGETS:ConnTest1.java ConnTest8.java ConnTest9.java \ - ConnTest10.java ConnTest11.java ConnTest12.java ConnTest13.java \ - ConnTest14.java ConnTest15.java ConnTest16.java ConnTest17.java \ - ConnTest18.java ConnTest19.java ConnTest20.java \ - ConnTest22.java ConnTest24.java ConnTest25.java \ - ConnTest26.java ConnTest27.java ConnTest29.java ConnTest34.java \ - ConnTest2.java ConnTest3.java ConnTest4.java \ - ConnTest5.java ConnTest6.java \ - IsoTest1.java IsoTest2.java - ${JAVAC} *.java - chmod +x *.ksh -clean: - rm -rf *.class diff --git a/test/jdbc/Connection/exp.test006.ksh b/test/jdbc/Connection/exp.test006.ksh deleted file mode 100644 index d3513ff0..00000000 --- a/test/jdbc/Connection/exp.test006.ksh +++ /dev/null @@ -1,11 +0,0 @@ -After rollback, listing tuples: -Tuple value is 0 100 -Tuple value is 1 101 -Tuple value is 2 102 -Tuple value is 3 103 -Tuple value is 4 104 -Tuple value is 5 105 -Tuple value is 6 106 -Tuple value is 7 107 -Tuple value is 8 108 -Tuple value is 9 109 diff --git a/test/jdbc/Connection/exp.test030.ksh b/test/jdbc/Connection/exp.test030.ksh deleted file mode 100755 index c1914c02..00000000 --- a/test/jdbc/Connection/exp.test030.ksh +++ /dev/null @@ -1 +0,0 @@ -Feature not supported diff --git a/test/jdbc/Connection/exp.test031.ksh b/test/jdbc/Connection/exp.test031.ksh deleted file mode 100755 index 34f79e10..00000000 --- a/test/jdbc/Connection/exp.test031.ksh +++ /dev/null @@ -1,2 +0,0 @@ -go here! -go here! diff --git a/test/jdbc/Connection/exp.test032.ksh b/test/jdbc/Connection/exp.test032.ksh deleted file mode 100755 index 34f79e10..00000000 --- a/test/jdbc/Connection/exp.test032.ksh +++ /dev/null @@ -1,2 +0,0 @@ -go here! -go here! diff --git a/test/jdbc/Connection/exp.test033.ksh b/test/jdbc/Connection/exp.test033.ksh deleted file mode 100755 index 0c9a0749..00000000 --- a/test/jdbc/Connection/exp.test033.ksh +++ /dev/null @@ -1 +0,0 @@ -select from table: 1 test diff --git a/test/jdbc/Connection/test001.ksh b/test/jdbc/Connection/test001.ksh deleted file mode 100644 index 1cf6ab14..00000000 --- a/test/jdbc/Connection/test001.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest1 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test002.ksh b/test/jdbc/Connection/test002.ksh deleted file mode 100755 index 741d4a42..00000000 --- a/test/jdbc/Connection/test002.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest2 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test003.ksh b/test/jdbc/Connection/test003.ksh deleted file mode 100755 index afc36f46..00000000 --- a/test/jdbc/Connection/test003.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java -Xms256m -Xmx256m ConnTest3 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test004.ksh b/test/jdbc/Connection/test004.ksh deleted file mode 100755 index ea67eecc..00000000 --- a/test/jdbc/Connection/test004.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest4 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test005.ksh b/test/jdbc/Connection/test005.ksh deleted file mode 100755 index 6c009845..00000000 --- a/test/jdbc/Connection/test005.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest5 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test006.ksh b/test/jdbc/Connection/test006.ksh deleted file mode 100755 index cf3ed8f7..00000000 --- a/test/jdbc/Connection/test006.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest6 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test008.ksh b/test/jdbc/Connection/test008.ksh deleted file mode 100755 index f92e6e20..00000000 --- a/test/jdbc/Connection/test008.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest8 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test009.ksh b/test/jdbc/Connection/test009.ksh deleted file mode 100755 index 5da8f710..00000000 --- a/test/jdbc/Connection/test009.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest9 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test010.ksh b/test/jdbc/Connection/test010.ksh deleted file mode 100755 index 9ca41861..00000000 --- a/test/jdbc/Connection/test010.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest10 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test011.ksh b/test/jdbc/Connection/test011.ksh deleted file mode 100755 index 0925fc19..00000000 --- a/test/jdbc/Connection/test011.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest11 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test012.ksh b/test/jdbc/Connection/test012.ksh deleted file mode 100755 index 19248b99..00000000 --- a/test/jdbc/Connection/test012.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest12 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test013.ksh b/test/jdbc/Connection/test013.ksh deleted file mode 100755 index cdcfd2e6..00000000 --- a/test/jdbc/Connection/test013.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest13 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test014.ksh b/test/jdbc/Connection/test014.ksh deleted file mode 100755 index 0d27c3e0..00000000 --- a/test/jdbc/Connection/test014.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest14 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test015.ksh b/test/jdbc/Connection/test015.ksh deleted file mode 100755 index 63b55fbb..00000000 --- a/test/jdbc/Connection/test015.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest15 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test016.ksh b/test/jdbc/Connection/test016.ksh deleted file mode 100755 index 4c690f9c..00000000 --- a/test/jdbc/Connection/test016.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest16 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test017.ksh b/test/jdbc/Connection/test017.ksh deleted file mode 100755 index f38df410..00000000 --- a/test/jdbc/Connection/test017.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest17 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test018.ksh b/test/jdbc/Connection/test018.ksh deleted file mode 100755 index 970756d9..00000000 --- a/test/jdbc/Connection/test018.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest18 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test019.ksh b/test/jdbc/Connection/test019.ksh deleted file mode 100755 index 3b2e8322..00000000 --- a/test/jdbc/Connection/test019.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest19 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test020.ksh b/test/jdbc/Connection/test020.ksh deleted file mode 100755 index 513d7028..00000000 --- a/test/jdbc/Connection/test020.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest20 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test022.ksh b/test/jdbc/Connection/test022.ksh deleted file mode 100755 index df6b1fd6..00000000 --- a/test/jdbc/Connection/test022.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest22 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test024.ksh b/test/jdbc/Connection/test024.ksh deleted file mode 100755 index f87e09f0..00000000 --- a/test/jdbc/Connection/test024.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest24 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test025.ksh b/test/jdbc/Connection/test025.ksh deleted file mode 100755 index 82f40bb9..00000000 --- a/test/jdbc/Connection/test025.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest25 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test026.ksh b/test/jdbc/Connection/test026.ksh deleted file mode 100755 index 78d4f882..00000000 --- a/test/jdbc/Connection/test026.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest26 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test027.ksh b/test/jdbc/Connection/test027.ksh deleted file mode 100755 index f284a336..00000000 --- a/test/jdbc/Connection/test027.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest27 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test029.ksh b/test/jdbc/Connection/test029.ksh deleted file mode 100755 index e34e46c4..00000000 --- a/test/jdbc/Connection/test029.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest29 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test030.ksh b/test/jdbc/Connection/test030.ksh deleted file mode 100755 index eee65580..00000000 --- a/test/jdbc/Connection/test030.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java IsoTest1 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test031.ksh b/test/jdbc/Connection/test031.ksh deleted file mode 100755 index e93d9407..00000000 --- a/test/jdbc/Connection/test031.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java IsoTest2 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Connection/test034.ksh b/test/jdbc/Connection/test034.ksh deleted file mode 100644 index bda35d22..00000000 --- a/test/jdbc/Connection/test034.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest34 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Gateway/ConnTest01.java b/test/jdbc/Gateway/ConnTest01.java deleted file mode 100644 index b2464001..00000000 --- a/test/jdbc/Gateway/ConnTest01.java +++ /dev/null @@ -1,23 +0,0 @@ -//To connect with connectstring "jdbc:gateway" and give correct "user" and "password" in properties object. It should pass. - - -import java.sql.*; -public class ConnTest01 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - if ( con == null ) System.exit(1); - con.close(); - System.exit(0); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.getStackTrace(); - System.exit(1); - } - } -} - diff --git a/test/jdbc/Gateway/ConnTest02.java b/test/jdbc/Gateway/ConnTest02.java deleted file mode 100644 index 167332db..00000000 --- a/test/jdbc/Gateway/ConnTest02.java +++ /dev/null @@ -1,18 +0,0 @@ -//To connect with connectstring "jdbc:gateway" and give null properties object. It should fail. -import java.sql.*; -public class ConnTest02 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", null, null); - if (con != null) {con.close(); System.exit(1);} - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Gateway/ConnTest03.java b/test/jdbc/Gateway/ConnTest03.java deleted file mode 100644 index 3a780378..00000000 --- a/test/jdbc/Gateway/ConnTest03.java +++ /dev/null @@ -1,19 +0,0 @@ -//To connect with connectstring "jdbc:gateway" and give empty properties object. It should fail. - -import java.sql.*; -public class ConnTest03 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Gateway/ConnTest04.java b/test/jdbc/Gateway/ConnTest04.java deleted file mode 100644 index 45229d04..00000000 --- a/test/jdbc/Gateway/ConnTest04.java +++ /dev/null @@ -1,18 +0,0 @@ -//Try to connect with connectstring "jdbc:gateway" and give incorrect "user" and "password" in properties object. It should fail. -import java.sql.*; -public class ConnTest04 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "wrongusertest", "manager"); - if (con != null) System.exit (1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Gateway/ConnTest05.java b/test/jdbc/Gateway/ConnTest05.java deleted file mode 100644 index ab19e0c1..00000000 --- a/test/jdbc/Gateway/ConnTest05.java +++ /dev/null @@ -1,19 +0,0 @@ -//To connect with connectstring "jdbc:gateway" and give correct "user" and incorrect "password" in properties object. It should fail. - -import java.sql.*; -public class ConnTest05 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "wrongpasswdtestxieliang"); - if (con == null) System.exit(0); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Gateway/ConnTest06.java b/test/jdbc/Gateway/ConnTest06.java deleted file mode 100644 index 69ad3d6b..00000000 --- a/test/jdbc/Gateway/ConnTest06.java +++ /dev/null @@ -1,27 +0,0 @@ -//Try to open through jdbc:gateway connection , close , then open . it should pass - -import java.sql.*; -public class ConnTest06 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - if ( con == null ) - System.exit(1); - con.close(); - con = DriverManager.getConnection("jdbc:gateway","root","manager"); - if ( con == null ) - System.exit(1); - con.close(); - System.exit(0); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - System.exit(1); - } - } -} - diff --git a/test/jdbc/Gateway/ConnTest07.java b/test/jdbc/Gateway/ConnTest07.java deleted file mode 100644 index 36efa26e..00000000 --- a/test/jdbc/Gateway/ConnTest07.java +++ /dev/null @@ -1,27 +0,0 @@ -//Try to open through jdbc:gateway connection , close , then open through jdbc:csql . it should pass - -import java.sql.*; -public class ConnTest07 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - if ( con == null ) - System.exit(1); - con.close(); - con = DriverManager.getConnection("jdbc:csql","root","manager"); - if ( con == null ) - System.exit(1); - con.close(); - System.exit(0); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - System.exit(1); - } - } -} - diff --git a/test/jdbc/Gateway/ConnTest08.java b/test/jdbc/Gateway/ConnTest08.java deleted file mode 100644 index 19965a21..00000000 --- a/test/jdbc/Gateway/ConnTest08.java +++ /dev/null @@ -1,24 +0,0 @@ -//Open the connection through jdbc:gateway and then call isClosed(). It should return false. -//Close the connection jdbc:gateway and then call isClosed(). It should return true. - -import java.sql.*; -public class ConnTest08 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - if ( con == null ) - System.exit(1); - if(con.isClosed()) System.exit(1); - con.close(); - if(!con.isClosed()) System.exit(1); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Gateway/ConnTest09.java b/test/jdbc/Gateway/ConnTest09.java deleted file mode 100644 index 4e2d078f..00000000 --- a/test/jdbc/Gateway/ConnTest09.java +++ /dev/null @@ -1,27 +0,0 @@ -//Test 2000 connections in jdbc:gateway -import java.sql.*; - -public class ConnTest09 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - con.close(); - int i; - for ( i=1; i <2000 ; i++) - { - con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - con.close(); - } - if (i !=2000) System.exit(1); else System.exit(0); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} - diff --git a/test/jdbc/Gateway/ConnTest10.java b/test/jdbc/Gateway/ConnTest10.java deleted file mode 100644 index 4673ca0e..00000000 --- a/test/jdbc/Gateway/ConnTest10.java +++ /dev/null @@ -1,54 +0,0 @@ -//Test 100 statements simultaneously in one connection through jdbc:gateway , insert 1 tuple from -//each stmt, and check whether 100 tuples are inserted. -import java.sql.*; -public class ConnTest10 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - Statement cStmt = con.createStatement(); - int ret =0; - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - - PreparedStatement stmt[] = new PreparedStatement[100];; - for (int i=0; i <100 ; i++) - { - stmt[i] = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - if (i %10 ==0) System.out.println("statements prepared "+ i); - } - int count =0; - for (int i=0; i <100 ; i++) - { - stmt[i].setInt(1, i); - stmt[i].setString(2, String.valueOf(i+100)); - ret = stmt[i].executeUpdate(); - if (ret != 1) break; - stmt[i].close(); - con.commit(); - count++; - } - System.out.println("Total rows inserted "+ count); - cStmt = con.createStatement(); - System.out.println("Listing tuples:"); - ResultSet rs = cStmt.executeQuery("SELECT * from T1;"); - count=0; - while (rs.next()) - { - count++; - } - rs.close(); - con.commit(); - cStmt.execute("DROP TABLE T1;"); - con.close(); - if (count == 100) System.exit(0); else System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} - diff --git a/test/jdbc/Gateway/GwStmt1.java b/test/jdbc/Gateway/GwStmt1.java deleted file mode 100644 index e186294f..00000000 --- a/test/jdbc/Gateway/GwStmt1.java +++ /dev/null @@ -1,91 +0,0 @@ -//1. Table T1 is cached to csql. -//Then do (INSERT/UPDATE/DELETE/SELECT) with params statement using gateway statement - -import java.sql.Connection; -import java.sql.DriverManager; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.Statement; - - -/** - * - * @author bijaya - */ -public class GwStmt1 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - Statement cStmt = con.createStatement(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i+100)); - stmt.executeUpdate(); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 where f1 = ?;"); - ResultSet rs = null; - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - int ret=0; - stmt = con.prepareStatement("UPDATE T1 SET f2 = ? WHERE f1 = ?;"); - for (int i =0 ; i< 10 ; i +=2) { - stmt.setString(1, String.valueOf(i+200)); - stmt.setInt(2, i); - ret = stmt.executeUpdate(); - if (ret != 1) break; - } - stmt.close(); - con.commit(); - System.out.println("After update, listing tuples:"); - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - con.commit(); - stmt = con.prepareStatement("DELETE FROM T1 WHERE f1 = ?;"); - for (int i =0 ; i< 10 ; i +=3) { - stmt.setInt(1, i); - ret = stmt.executeUpdate(); - if (ret !=1) break; - } - stmt.close(); - con.commit(); - - System.out.println("After delete, listing tuples:"); - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - con.commit(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Gateway/GwStmt10.java b/test/jdbc/Gateway/GwStmt10.java deleted file mode 100644 index 97e5c5b3..00000000 --- a/test/jdbc/Gateway/GwStmt10.java +++ /dev/null @@ -1,101 +0,0 @@ -//update tuple with SET and WHERE clause having params (UPDATE T1 SET f2=NULL, f6=NULL WHERE f1=?AND f9=?) -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwStmt10 { - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql","root","manager"); - Statement cStmt=con.createStatement(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("CSQLCACHE"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - ret=0; - stmt=con.prepareStatement("UPDATE T1 SET f2=NULL, f5=NULL WHERE f1=?AND f9=?;"); - for(int i=0;i<10;i++) - { - //stmt.setShort(1,(short)null); - //stmt.setTime(2,null); - stmt.setInt(1,3); - stmt.setTimestamp(2,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - rs=null; - rs=selStmt.executeQuery(); - System.out.println(); - while(rs.next()) - { - System.out.print("Tuple value is " + rs.getInt(1)+ " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getShort(2) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getByte(3) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getLong(4) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getFloat(5) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getString(6) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getDate(7) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getTime(8) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.println(rs.getTimestamp(9) + " "); - if(rs.wasNull()) System.out.println(" NULL"); - } - rs.close(); - con.commit(); - - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Gateway/GwStmt2.java b/test/jdbc/Gateway/GwStmt2.java deleted file mode 100644 index 79aa31c6..00000000 --- a/test/jdbc/Gateway/GwStmt2.java +++ /dev/null @@ -1,62 +0,0 @@ -//Cache table T1 -//Create a table and index for that table. Then do (INSERT/UPDATE/DELETE/SELECT) with no params statement. -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwStmt2 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - Statement cStmt = con.createStatement(); - con.commit(); - - cStmt.execute("INSERT INTO T1 VALUES (1, 'FIRST');"); - cStmt.executeUpdate("INSERT INTO T1 VALUES (2, 'SECOND');"); - con.commit(); - - ResultSet rs = null; - rs = cStmt.executeQuery("SELECT * from T1 where f1 = 1;"); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - - - cStmt.execute("SELECT * from T1 where f1 = 2;"); - rs = cStmt.getResultSet(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - con.commit(); - - cStmt.executeUpdate("UPDATE T1 SET f2 = 'CHANGED' WHERE f1 = 1;"); - con.commit(); - - - - cStmt.executeUpdate("DELETE FROM T1 WHERE f1 = 2;"); - con.commit(); - - System.out.println("After delete, listing tuples:"); - rs = cStmt.executeQuery("SELECT * from T1 ;"); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Gateway/GwStmt3.java b/test/jdbc/Gateway/GwStmt3.java deleted file mode 100644 index 5ca8d88f..00000000 --- a/test/jdbc/Gateway/GwStmt3.java +++ /dev/null @@ -1,61 +0,0 @@ -//Cache table T1 -//Open a connection and then close it. After that execute INSERT/QUERY/UPDATE statement. It should fail - -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwStmt3 { -public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - Statement cStmt = con.createStatement(); - con.commit(); - con.close(); - - //after close the connection,execute "INSERT" statement,it should fail - try - { - cStmt.execute("INSERT INTO T1 VALUES (1, 'FIRST');"); - System.exit(1); - } - catch(Exception e) - { - System.out.println("insert exception---" + e.getMessage()); - } - - //after close the connection,execute "QUERY" statement,it should fail - try - { - cStmt.executeQuery("SELECT * from T1 where f1 = 1;"); - System.exit(2); - } - catch(Exception e) - { - System.out.println("query exception---" + e.getMessage()); - } - - //after close the connection,execute "UPDATE" statement,it should fail - try - { - cStmt.executeUpdate("UPDATE T1 SET f2 = 'CHANGED' WHERE f1 = 1;"); - System.exit(3); - } - catch(Exception e) - { - System.out.println("update exception---" + e.getMessage()); - } - - //cleanup - - }catch(Exception e) { - System.out.println("Exception in Test: " + e.getMessage()); - e.printStackTrace(); - System.exit(4); - } - } -} diff --git a/test/jdbc/Gateway/GwStmt4.java b/test/jdbc/Gateway/GwStmt4.java deleted file mode 100644 index 6ce1c6f3..00000000 --- a/test/jdbc/Gateway/GwStmt4.java +++ /dev/null @@ -1,60 +0,0 @@ -//Chache table T1 -//CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint,f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp); -//insert 9 tuples with params for all fields (INSERT INTO T1 values (?,?,?,?,?,?,?,?,?)) -//select tuple with WHERE clause having param for each fields(SELECT * FROM T1 WHERE f1=?, SELECT * from T1 where f2=?) -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwStmt4 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - Statement cStmt = con.createStatement(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?,?,?,?,?,?,?,?,?);"); - stmt.setInt(1, 1); - stmt.setShort(2,(short)2); - stmt.setByte(3,(byte)3); - stmt.setLong(4,(long)4); - stmt.setFloat(5,(float)5); - stmt.setString(6, String.valueOf(5)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - stmt.executeUpdate(); - stmt.close(); - con.commit(); - - selStmt = con.prepareStatement("SELECT * from T1 where f1 = ?;"); - ResultSet rs = null; - - selStmt.setInt(1, 1); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - } - rs.close(); - selStmt.close(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Gateway/GwStmt5.java b/test/jdbc/Gateway/GwStmt5.java deleted file mode 100644 index 24ec486a..00000000 --- a/test/jdbc/Gateway/GwStmt5.java +++ /dev/null @@ -1,64 +0,0 @@ -//Cache table -//select tuple with WHERE clause having param for some fields(SELECT * FROM T1 WHERE f1=?AND f2=? AND f3=?) -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwStmt5 { - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:gateway","root","manager"); - Statement cStmt=con.createStatement(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Nihar"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("SELECT * FROM T1 where f1 = ? "); - ResultSet rs=null; - selStmt.setInt(1,2); - //selStmt.setShort(2,(short)3); - //selStmt.setByte(1,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - System.out.println("Yes"); - } - rs.close(); - con.commit(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Gateway/GwStmt6.java b/test/jdbc/Gateway/GwStmt6.java deleted file mode 100644 index 1bf1d16b..00000000 --- a/test/jdbc/Gateway/GwStmt6.java +++ /dev/null @@ -1,94 +0,0 @@ -//update tuple with WHERE clause having param for all fields(UPDATE T1 SET f2=100 WHERE f1=?AND f3=?....) -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwStmt6 { - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:gateway","root","manager"); - Statement cStmt=con.createStatement(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Cache"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - ret=0; - stmt=con.prepareStatement("UPDATE T1 SET f2=?, f8=? WHERE f1=?AND f9=?;"); - for(int i=0;i<10;i++) - { - stmt.setShort(1,(short)100); - stmt.setTime(2,Time.valueOf("19:38:25")); - stmt.setInt(3,3); - stmt.setTimestamp(4,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - rs=null; - rs=selStmt.executeQuery(); - System.out.println(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - - -} diff --git a/test/jdbc/Gateway/GwStmt7.java b/test/jdbc/Gateway/GwStmt7.java deleted file mode 100644 index 1f23321c..00000000 --- a/test/jdbc/Gateway/GwStmt7.java +++ /dev/null @@ -1,91 +0,0 @@ -//delete tuple with WHERE clause having params (DELETE FROM T1 WHERE f1=?AND f9=?) using gateway -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwStmt7 { -public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:gateway","root","manager"); - Statement cStmt=con.createStatement(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Cache"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - ret=0; - stmt=con.prepareStatement("DELETE FROM T1 WHERE f1=? AND f9=?;"); - for(int i=0;i<10;i++) - { - stmt.setInt(1,3); - stmt.setTimestamp(2,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - rs=null; - rs=selStmt.executeQuery(); - System.out.println(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Gateway/GwStmt8.java b/test/jdbc/Gateway/GwStmt8.java deleted file mode 100644 index 3c9888e2..00000000 --- a/test/jdbc/Gateway/GwStmt8.java +++ /dev/null @@ -1,72 +0,0 @@ -//Set Null insert statement without parameterise on cache tables T1 test it by wasNull() -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwStmt8 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:gateway","root","manager"); - Statement cStmt=con.createStatement(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1(f1,f3,f5,f6,f7,f8,f9) VALUES(?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setByte(2,(byte)(i+2)); - stmt.setFloat(3,(float)1000+i); - stmt.setString(4, String.valueOf("CSQL"+i)); - stmt.setDate(5,Date.valueOf("2008-03-21")); - stmt.setTime(6,Time.valueOf("18:00:00")); - stmt.setTimestamp(7,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - con.commit(); - stmt=con.prepareStatement("INSERT INTO T1(f1,f2,f4,f6,f7,f8,f9) values(10,11,101,'CSQL10','2008-03-21','18:00:00','2008-03-21 18:00:00');"); - stmt.executeUpdate(); - - stmt.close(); - con.commit(); - - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - - System.out.print("Tuple value is " + rs.getInt(1)+ " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getShort(2) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getByte(3) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getLong(4) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getFloat(5) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getString(6) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getDate(7) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getTime(8) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.println(rs.getTimestamp(9) + " "); - if(rs.wasNull()) System.out.println(" NULL"); - } - rs.close(); - con.commit(); - - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} diff --git a/test/jdbc/Gateway/GwStmt9.java b/test/jdbc/Gateway/GwStmt9.java deleted file mode 100644 index f8a7953c..00000000 --- a/test/jdbc/Gateway/GwStmt9.java +++ /dev/null @@ -1,84 +0,0 @@ -//Null statement test in Gateway for parameteraze statement on cache table -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwStmt9 { -public static void main(String[] args) { - - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:gateway","root","manager"); - Statement cStmt=con.createStatement(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - if(i==2 ) { - stmt.setNull(1,java.sql.Types.INTEGER); - stmt.setNull(2,java.sql.Types.SMALLINT); - stmt.setNull(3,java.sql.Types.TINYINT); - stmt.setNull(4,java.sql.Types.BIGINT); - stmt.setNull(5,java.sql.Types.FLOAT); - stmt.setNull(6,java.sql.Types.CHAR); - stmt.setNull(7,java.sql.Types.DATE); - stmt.setNull(8,java.sql.Types.TIME); - stmt.setNull(9,java.sql.Types.TIMESTAMP); - }else{ - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("India"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - } - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("SELECT * FROM T1 ;"); - ResultSet rs=null; - selStmt.setInt(1,2); - selStmt.setShort(2,(short)3); - selStmt.setByte(3,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - - System.out.print("Tuple value is " + rs.getInt(1)+ " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getShort(2) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getByte(3) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getLong(4) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getFloat(5) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getString(6) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getDate(7) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getTime(8) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.println(rs.getTimestamp(9) + " "); - if(rs.wasNull()) System.out.println(" NULL"); - - } - rs.close(); - con.commit(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - - } -} diff --git a/test/jdbc/Gateway/GwTest1.java b/test/jdbc/Gateway/GwTest1.java deleted file mode 100644 index 03fa447a..00000000 --- a/test/jdbc/Gateway/GwTest1.java +++ /dev/null @@ -1,31 +0,0 @@ - // Connect with connectstring "jdbc:gateway" and give correct "user" and "password" in properties object. - //It should pass.when csqlserver is not runnig -import java.sql.*; - -/** - * - * @author bijaya - */ -public class GwTest1 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - if ( con == null ) - { - System.out.println("Test Case Fail"); - System.exit(1); - } - System.out.println("Test Case Passed"); - con.close(); - System.exit(0); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.getStackTrace(); - System.exit(1); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest10.java b/test/jdbc/Gateway/GwTest10.java deleted file mode 100644 index 70e69164..00000000 --- a/test/jdbc/Gateway/GwTest10.java +++ /dev/null @@ -1,92 +0,0 @@ - -//1. Donot run csqlserver -//Then do (INSERT/UPDATE/DELETE/SELECT) with params statement using gateway statement - -import java.sql.Connection; -import java.sql.DriverManager; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.Statement; - - -/** - * - * @author bijaya - */ -public class GwTest10 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - Statement cStmt = con.createStatement(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i+100)); - stmt.executeUpdate(); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 where f1 = ?;"); - ResultSet rs = null; - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - int ret=0; - stmt = con.prepareStatement("UPDATE T1 SET f2 = ? WHERE f1 = ?;"); - for (int i =0 ; i< 10 ; i +=2) { - stmt.setString(1, String.valueOf(i+200)); - stmt.setInt(2, i); - ret = stmt.executeUpdate(); - if (ret != 1) break; - } - stmt.close(); - con.commit(); - System.out.println("After update, listing tuples:"); - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - con.commit(); - stmt = con.prepareStatement("DELETE FROM T1 WHERE f1 = ?;"); - for (int i =0 ; i< 10 ; i +=3) { - stmt.setInt(1, i); - ret = stmt.executeUpdate(); - if (ret !=1) break; - } - stmt.close(); - con.commit(); - - System.out.println("After delete, listing tuples:"); - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - con.commit(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest11.java b/test/jdbc/Gateway/GwTest11.java deleted file mode 100644 index 4d2e1890..00000000 --- a/test/jdbc/Gateway/GwTest11.java +++ /dev/null @@ -1,63 +0,0 @@ - -//donot run csql server -//Create a table and index for that table. Then do (INSERT/UPDATE/DELETE/SELECT) with no params statement. -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest11 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - Statement cStmt = con.createStatement(); - con.commit(); - - cStmt.execute("INSERT INTO T1 VALUES (1, 'FIRST');"); - cStmt.executeUpdate("INSERT INTO T1 VALUES (2, 'SECOND');"); - con.commit(); - - ResultSet rs = null; - rs = cStmt.executeQuery("SELECT * from T1 where f1 = 1;"); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - - - cStmt.execute("SELECT * from T1 where f1 = 2;"); - rs = cStmt.getResultSet(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - con.commit(); - - cStmt.executeUpdate("UPDATE T1 SET f2 = 'CHANGED' WHERE f1 = 1;"); - con.commit(); - - - - cStmt.executeUpdate("DELETE FROM T1 WHERE f1 = 2;"); - con.commit(); - - System.out.println("After delete, listing tuples:"); - rs = cStmt.executeQuery("SELECT * from T1 ;"); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest12.java b/test/jdbc/Gateway/GwTest12.java deleted file mode 100644 index d17a796f..00000000 --- a/test/jdbc/Gateway/GwTest12.java +++ /dev/null @@ -1,61 +0,0 @@ -//donot run csql server -//Open a connection and then close it. After that execute INSERT/QUERY/UPDATE statement. It should fail - -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest12 { -public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - Statement cStmt = con.createStatement(); - con.commit(); - con.close(); - - //after close the connection,execute "INSERT" statement,it should fail - try - { - cStmt.execute("INSERT INTO T1 VALUES (1, 'FIRST');"); - System.exit(1); - } - catch(Exception e) - { - System.out.println("insert exception---" + e.getMessage()); - } - - //after close the connection,execute "QUERY" statement,it should fail - try - { - cStmt.executeQuery("SELECT * from T1 where f1 = 1;"); - System.exit(2); - } - catch(Exception e) - { - System.out.println("query exception---" + e.getMessage()); - } - - //after close the connection,execute "UPDATE" statement,it should fail - try - { - cStmt.executeUpdate("UPDATE T1 SET f2 = 'CHANGED' WHERE f1 = 1;"); - System.exit(3); - } - catch(Exception e) - { - System.out.println("update exception---" + e.getMessage()); - } - - //cleanup - - }catch(Exception e) { - System.out.println("Exception in Test: " + e.getMessage()); - e.printStackTrace(); - System.exit(4); - } - } -} diff --git a/test/jdbc/Gateway/GwTest13.java b/test/jdbc/Gateway/GwTest13.java deleted file mode 100644 index 31e0e0ee..00000000 --- a/test/jdbc/Gateway/GwTest13.java +++ /dev/null @@ -1,60 +0,0 @@ -//donot run csql server -//CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint,f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp); -//insert 9 tuples with params for all fields (INSERT INTO T1 values (?,?,?,?,?,?,?,?,?)) -//select tuple with WHERE clause having param for each fields(SELECT * FROM T1 WHERE f1=?, SELECT * from T1 where f2=?) -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest13 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - Statement cStmt = con.createStatement(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?,?,?,?,?,?,?,?,?);"); - stmt.setInt(1, 1); - stmt.setShort(2,(short)2); - stmt.setByte(3,(byte)3); - stmt.setLong(4,(long)4); - stmt.setFloat(5,(float)5); - stmt.setString(6, String.valueOf(5)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - stmt.executeUpdate(); - stmt.close(); - con.commit(); - - selStmt = con.prepareStatement("SELECT * from T1 where f1 = ?;"); - ResultSet rs = null; - - selStmt.setInt(1, 1); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - } - rs.close(); - selStmt.close(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest14.java b/test/jdbc/Gateway/GwTest14.java deleted file mode 100644 index dedbebf0..00000000 --- a/test/jdbc/Gateway/GwTest14.java +++ /dev/null @@ -1,63 +0,0 @@ -//donot run csql server -//select tuple with WHERE clause having param for some fields(SELECT * FROM T1 WHERE f1=?AND f2=? AND f3=?) -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest14 { - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:gateway","root","manager"); - Statement cStmt=con.createStatement(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Nihar"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("SELECT * FROM T1 where f1 = ? "); - ResultSet rs=null; - selStmt.setInt(1,2); - //selStmt.setShort(2,(short)3); - //selStmt.setByte(1,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - } - rs.close(); - con.commit(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest15.java b/test/jdbc/Gateway/GwTest15.java deleted file mode 100644 index 15caf6c1..00000000 --- a/test/jdbc/Gateway/GwTest15.java +++ /dev/null @@ -1,95 +0,0 @@ -//donot run csql server -//update tuple with WHERE clause having param for all fields(UPDATE T1 SET f2=100 WHERE f1=?AND f3=?....) -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest15 { - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:gateway","root","manager"); - Statement cStmt=con.createStatement(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Cache"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - ret=0; - stmt=con.prepareStatement("UPDATE T1 SET f2=?, f8=? WHERE f1=?AND f9=?;"); - for(int i=0;i<10;i++) - { - stmt.setShort(1,(short)100); - stmt.setTime(2,Time.valueOf("19:38:25")); - stmt.setInt(3,3); - stmt.setTimestamp(4,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - rs=null; - rs=selStmt.executeQuery(); - System.out.println(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - - -} diff --git a/test/jdbc/Gateway/GwTest16.java b/test/jdbc/Gateway/GwTest16.java deleted file mode 100644 index 5af38f40..00000000 --- a/test/jdbc/Gateway/GwTest16.java +++ /dev/null @@ -1,92 +0,0 @@ -//donot run csql server -//delete tuple with WHERE clause having params (DELETE FROM T1 WHERE f1=?AND f9=?) using gateway -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest16 { -public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:gateway","root","manager"); - Statement cStmt=con.createStatement(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Cache"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - ret=0; - stmt=con.prepareStatement("DELETE FROM T1 WHERE f1=? AND f9=?;"); - for(int i=0;i<10;i++) - { - stmt.setInt(1,3); - stmt.setTimestamp(2,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - rs=null; - rs=selStmt.executeQuery(); - System.out.println(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest2.java b/test/jdbc/Gateway/GwTest2.java deleted file mode 100644 index 5eeb4060..00000000 --- a/test/jdbc/Gateway/GwTest2.java +++ /dev/null @@ -1,22 +0,0 @@ -//Donot start the server .Connect with connectstring "jdbc:gateway" and null for username and password. It should fail -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest2 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", null, null); - if (con != null) {con.close(); System.exit(1);} - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest3.java b/test/jdbc/Gateway/GwTest3.java deleted file mode 100644 index 5ad628a2..00000000 --- a/test/jdbc/Gateway/GwTest3.java +++ /dev/null @@ -1,23 +0,0 @@ -//Donot Start Server .Connect only with connectstring "jdbc:"gateway and no username and password. It should fail -import java.sql.*; - -/** - * - * @author bijaya - */ -public class GwTest3 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest4.java b/test/jdbc/Gateway/GwTest4.java deleted file mode 100644 index 5e8952ab..00000000 --- a/test/jdbc/Gateway/GwTest4.java +++ /dev/null @@ -1,37 +0,0 @@ -//No CSQL server is running .Connect with connectstring "jdbc:gateway" and give incorrect "user" and "password" in properties object. It should fail. -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest4 { - - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "wrongusertest", "manager"); - if (con == null) - { - System.out.println("Test Case1 Passed"); - } - System.out.println("Test Case1 Failed"); - System.exit(1); - Connection con1 = DriverManager.getConnection("jdbc:gateway", "root", "wrongpasswdtestxieliang"); - if (con == null) - { - System.out.println("Test Case2 Passed"); - System.exit(0); - } - System.out.println("Test Case2 Failed"); - con.close(); - System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest6.java b/test/jdbc/Gateway/GwTest6.java deleted file mode 100644 index a580375e..00000000 --- a/test/jdbc/Gateway/GwTest6.java +++ /dev/null @@ -1,32 +0,0 @@ -//Donot Start CSQL Server -//Open through "jdbc:gateway", close and then again open through "jdbc:gateway". It should pass. -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest6 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - if ( con == null ) - System.exit(1); - System.out.println("Connection 1 done"); - con.close(); - con = DriverManager.getConnection("jdbc:gateway","root","manager"); - if ( con == null ) - System.exit(1); - System.out.println("connection second time done"); - con.close(); - System.exit(0); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - System.exit(1); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest7.java b/test/jdbc/Gateway/GwTest7.java deleted file mode 100644 index 7740b548..00000000 --- a/test/jdbc/Gateway/GwTest7.java +++ /dev/null @@ -1,37 +0,0 @@ -//Donot Start CSQL Server -//Open the connection through jdbc:gateway and then call isClosed(). It should return false. -//Close the connection jdbc:gateway and then call isClosed(). It should return true -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest7 { - - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - if ( con == null ) - System.exit(1); - if(con.isClosed()) { - System.out.println("Test Case Failed"); - System.exit(1); - } - con.close(); - if(!con.isClosed()) - { - System.out.println("Test Case Failed"); - System.exit(1); - } - System.out.println("Test Case Passed"); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - System.exit(1); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest8.java b/test/jdbc/Gateway/GwTest8.java deleted file mode 100644 index ae8d4755..00000000 --- a/test/jdbc/Gateway/GwTest8.java +++ /dev/null @@ -1,39 +0,0 @@ -//Donot Start CSQL Server -//Test 2000 connections in jdbc:gateway - -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest8 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - con.close(); - int i; - for ( i=1; i <2000 ; i++) - { - con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - if(con==null) break; - con.close(); - } - if (i !=2000) - { - System.out.println("Test Case Failed"); - System.exit(1); - }else { - System.out.println("Test Case Passed"); - System.exit(0); - } - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } - -} diff --git a/test/jdbc/Gateway/GwTest9.java b/test/jdbc/Gateway/GwTest9.java deleted file mode 100644 index f5c8dbb4..00000000 --- a/test/jdbc/Gateway/GwTest9.java +++ /dev/null @@ -1,30 +0,0 @@ -//Donot Start CSQL Server -//connect through the jdbc:gateway URL create Statement and call execute to create a table. it should fail -import java.sql.*; -/** - * - * @author bijaya - */ -public class GwTest9 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:gateway", "root", "manager"); - Statement cStmt = con.createStatement(); - boolean ret ; - cStmt.execute("CREATE TABLE T2 (f1 integer, f2 char (20));"); - cStmt.close(); - con.close(); - }catch(Exception e) - { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.out.println("Test Case Passed"); - System.exit(0); - - } - } - -} diff --git a/test/jdbc/Gateway/Makefile b/test/jdbc/Gateway/Makefile deleted file mode 100644 index 1dfc6f25..00000000 --- a/test/jdbc/Gateway/Makefile +++ /dev/null @@ -1,10 +0,0 @@ -OSNAME = $(shell uname -s) -JAVAC = javac -TARGETS = ConnTests -TARGETS:ConnTest01.java ConnTest02.java ConnTest03.java \ - ConnTest04.java ConnTest05.java ConnTest06.java ConnTest07.java \ - ConnTest08.java ConnTest09.java ConnTest10.java - ${JAVAC} *.java - chmod +x *.ksh -clean: - rm -rf *.class diff --git a/test/jdbc/Gateway/test001.ksh b/test/jdbc/Gateway/test001.ksh deleted file mode 100755 index fac831eb..00000000 --- a/test/jdbc/Gateway/test001.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest01 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Gateway/test002.ksh b/test/jdbc/Gateway/test002.ksh deleted file mode 100755 index 8190e11c..00000000 --- a/test/jdbc/Gateway/test002.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest02 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Gateway/test003.ksh b/test/jdbc/Gateway/test003.ksh deleted file mode 100755 index 41656fd7..00000000 --- a/test/jdbc/Gateway/test003.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest03 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Gateway/test004.ksh b/test/jdbc/Gateway/test004.ksh deleted file mode 100755 index df3790f7..00000000 --- a/test/jdbc/Gateway/test004.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest04 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Gateway/test005.ksh b/test/jdbc/Gateway/test005.ksh deleted file mode 100755 index 671eaf03..00000000 --- a/test/jdbc/Gateway/test005.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest05 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Gateway/test006.ksh b/test/jdbc/Gateway/test006.ksh deleted file mode 100755 index 647bcd5d..00000000 --- a/test/jdbc/Gateway/test006.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest06 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Gateway/test007.ksh b/test/jdbc/Gateway/test007.ksh deleted file mode 100755 index a4c9cce2..00000000 --- a/test/jdbc/Gateway/test007.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest07 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Gateway/test008.ksh b/test/jdbc/Gateway/test008.ksh deleted file mode 100755 index 5aff0956..00000000 --- a/test/jdbc/Gateway/test008.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest08 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Gateway/test009.ksh b/test/jdbc/Gateway/test009.ksh deleted file mode 100755 index c862c77e..00000000 --- a/test/jdbc/Gateway/test009.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest09 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Gateway/test010.ksh b/test/jdbc/Gateway/test010.ksh deleted file mode 100755 index 6bf88447..00000000 --- a/test/jdbc/Gateway/test010.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest10 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Gateway/test031.ksh b/test/jdbc/Gateway/test031.ksh deleted file mode 100755 index 7b39ca1e..00000000 --- a/test/jdbc/Gateway/test031.ksh +++ /dev/null @@ -1,40 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} - -echo "create table T1 (f1 int,f2 char(10),primary key(f1));" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 2; -fi -java GwStmt1 -if [ $? -ne 0 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 -u >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 4; -fi -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test032.ksh b/test/jdbc/Gateway/test032.ksh deleted file mode 100755 index 8a4750f9..00000000 --- a/test/jdbc/Gateway/test032.ksh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -#JDBC GATEWAY CACHE -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} - -echo "create table T1 (f1 int,f2 char(10),primary key(f1));" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 2; -fi -java GwStmt2 -if [ $? -ne 0 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 -u >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 4; -fi -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test033.ksh b/test/jdbc/Gateway/test033.ksh deleted file mode 100755 index bab2ecc3..00000000 --- a/test/jdbc/Gateway/test033.ksh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -#JDBC GATEWAY CACHE -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} - -echo "create table T1 (f1 int,f2 char(10),primary key(f1));" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 2; -fi -java GwStmt3 -if [ $? -ne 0 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 -u >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 4; -fi -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test034.ksh b/test/jdbc/Gateway/test034.ksh deleted file mode 100755 index 464772c9..00000000 --- a/test/jdbc/Gateway/test034.ksh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -#JDBC GATEWAY CACHE -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} - -echo "CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 2; -fi -java GwStmt4 -if [ $? -ne 0 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 -u >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 4; -fi -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test035.ksh b/test/jdbc/Gateway/test035.ksh deleted file mode 100755 index 31883154..00000000 --- a/test/jdbc/Gateway/test035.ksh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -#JDBC GATEWAY CACHE -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} - -echo "CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 2; -fi -java GwStmt5 -if [ $? -ne 0 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 -u >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 4; -fi -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test036.ksh b/test/jdbc/Gateway/test036.ksh deleted file mode 100755 index bbaef012..00000000 --- a/test/jdbc/Gateway/test036.ksh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -#JDBC GATEWAY CACHE -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} - -echo "CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 2; -fi -java GwStmt6 -if [ $? -ne 0 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 -u >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 4; -fi -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test037.ksh b/test/jdbc/Gateway/test037.ksh deleted file mode 100755 index abe9dc32..00000000 --- a/test/jdbc/Gateway/test037.ksh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -#JDBC GATEWAY CACHE -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} - -echo "CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 2; -fi -java GwStmt7 -if [ $? -ne 0 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 -u >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 4; -fi -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test038.ksh b/test/jdbc/Gateway/test038.ksh deleted file mode 100755 index ca885bdd..00000000 --- a/test/jdbc/Gateway/test038.ksh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -#JDBC GATEWAY CACHE -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} - -echo "CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 2; -fi -java GwStmt8 -if [ $? -ne 0 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 -u >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 4; -fi -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test039.ksh b/test/jdbc/Gateway/test039.ksh deleted file mode 100755 index 3b352a98..00000000 --- a/test/jdbc/Gateway/test039.ksh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -#JDBC GATEWAY CACHE -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} - -echo "CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 2; -fi -java GwStmt9 -if [ $? -ne 0 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 -u >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 4; -fi -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test040.ksh b/test/jdbc/Gateway/test040.ksh deleted file mode 100755 index 560201ff..00000000 --- a/test/jdbc/Gateway/test040.ksh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -#JDBC GATEWAY CACHE -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} - -echo "CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 2; -fi -java GwStmt10 -if [ $? -ne 0 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/cachetable -t T1 -u >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 4; -fi -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test041.ksh b/test/jdbc/Gateway/test041.ksh deleted file mode 100755 index fe320911..00000000 --- a/test/jdbc/Gateway/test041.ksh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/sh -# Connect with connectstring "jdbc:gateway" and give correct "user" and "password" in properties object. -# It should pass.when csqlserver is not runnig -# GwTest1.java - -TESTFILE=${PWD}/jdbc/Gateway/GwTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -java GwTest1 -if [ $? -ne 0 ] -then - exit 1; -fi - - -exit 0; diff --git a/test/jdbc/Gateway/test042.ksh b/test/jdbc/Gateway/test042.ksh deleted file mode 100755 index 839daeff..00000000 --- a/test/jdbc/Gateway/test042.ksh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/sh -#Donot start the server .Connect with connectstring "jdbc:gateway" and null for username and password. It should fail -# GwTest2.java - -TESTFILE=${PWD}/jdbc/Gateway/GwTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -java GwTest2 -if [ $? -ne 0 ] -then - exit 1; -fi - - -exit 0; diff --git a/test/jdbc/Gateway/test043.ksh b/test/jdbc/Gateway/test043.ksh deleted file mode 100755 index 87371b0f..00000000 --- a/test/jdbc/Gateway/test043.ksh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/sh -#Donot Start Server .Connect only with connectstring "jdbc:"gateway and no username and password. It should fail - -# GwTest3.java - -TESTFILE=${PWD}/jdbc/Gateway/GwTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -java GwTest3 -if [ $? -ne 0 ] -then - exit 1; -fi - - -exit 0; diff --git a/test/jdbc/Gateway/test044.ksh b/test/jdbc/Gateway/test044.ksh deleted file mode 100755 index b447c164..00000000 --- a/test/jdbc/Gateway/test044.ksh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/sh -#No CSQL server is running .Connect with connectstring "jdbc:gateway" and give incorrect "user" and "password" in properties object. It should fail. -# GwTest4.java - -TESTFILE=${PWD}/jdbc/Gateway/GwTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -java GwTest4 -if [ $? -ne 0 ] -then - exit 1; -fi - - -exit 0; diff --git a/test/jdbc/Gateway/test046.ksh b/test/jdbc/Gateway/test046.ksh deleted file mode 100755 index 71bdb113..00000000 --- a/test/jdbc/Gateway/test046.ksh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/sh -# Donot Start CSQL Server -# Open through "jdbc:gateway", close and then again open through "jdbc:gateway". It should pass. - -# GwTest6.java - -TESTFILE=${PWD}/jdbc/Gateway/GwTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -java GwTest6 -if [ $? -ne 0 ] -then - exit 1; -fi - - -exit 0; diff --git a/test/jdbc/Gateway/test047.ksh b/test/jdbc/Gateway/test047.ksh deleted file mode 100755 index e0a42732..00000000 --- a/test/jdbc/Gateway/test047.ksh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -# Donot Start CSQL Server -# Open the connection through jdbc:gateway and then call isClosed(). It should return false. -# Close the connection jdbc:gateway and then call isClosed(). It should return true - -# GwTest7.java - -TESTFILE=${PWD}/jdbc/Gateway/GwTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -java GwTest7 -if [ $? -ne 0 ] -then - exit 1; -fi - - -exit 0; diff --git a/test/jdbc/Gateway/test048.ksh b/test/jdbc/Gateway/test048.ksh deleted file mode 100755 index 89e96748..00000000 --- a/test/jdbc/Gateway/test048.ksh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/sh -# Donot Start CSQL Server -# Test 2000 connections in jdbc:gateway - -# GwTest8.java - -TESTFILE=${PWD}/jdbc/Gateway/GwTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -java GwTest8 -if [ $? -ne 0 ] -then - exit 1; -fi - - -exit 0; diff --git a/test/jdbc/Gateway/test049.ksh b/test/jdbc/Gateway/test049.ksh deleted file mode 100755 index ed2d5e11..00000000 --- a/test/jdbc/Gateway/test049.ksh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/sh -# Donot Start CSQL Server -# Connect through the csql:gateway URL create Statement and call execute to create a table. it should fail - -# GwTest9.java - -TESTFILE=${PWD}/jdbc/Gateway/GwTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -java GwTest9 -if [ $? -ne 0 ] -then - exit 1; -fi - - -exit 0; diff --git a/test/jdbc/Gateway/test050.ksh b/test/jdbc/Gateway/test050.ksh deleted file mode 100755 index 74b12abd..00000000 --- a/test/jdbc/Gateway/test050.ksh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh -# Connect with connectstring "jdbc:gateway" -# Then do (INSERT/UPDATE/DELETE/SELECT) with params statement using gateway statement -# It should pass.when csqlserver is not runnig -# GwTest10.java - -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -echo "create table T1 (f1 int,f2 char(10),primary key(f1));" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -java GwTest10 -if [ $? -ne 0 ] -then - exit 2; -fi - -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test051.ksh b/test/jdbc/Gateway/test051.ksh deleted file mode 100755 index 8befcb8a..00000000 --- a/test/jdbc/Gateway/test051.ksh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/sh -# Connect with connectstring "jdbc:gateway" -# Create a table and index for that table. Then do (INSERT/UPDATE/DELETE/SELECT) with no params statement. when csqlserver is not runnig -# GwTest11.java -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -echo "create table T1 (f1 int,f2 char(10),primary key(f1));" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -java GwTest11 -if [ $? -ne 0 ] -then - exit 2; -fi - -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test052.ksh b/test/jdbc/Gateway/test052.ksh deleted file mode 100755 index 02915d5f..00000000 --- a/test/jdbc/Gateway/test052.ksh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/sh -# Connect with connectstring "jdbc:gateway" -# Open a connection and then close it. After that execute INSERT/QUERY/UPDATE statement. It should fail,when csqlserver is not runnig -# GwTest12.java -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -echo "create table T1 (f1 int,f2 char(10),primary key(f1));" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -java GwTest12 -if [ $? -ne 0 ] -then - exit 2; -fi - -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test053.ksh b/test/jdbc/Gateway/test053.ksh deleted file mode 100755 index 2b4937dc..00000000 --- a/test/jdbc/Gateway/test053.ksh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh -# Connect with connectstring "jdbc:gateway" -# CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint,f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp); -# insert 9 tuples with params for all fields (INSERT INTO T1 values (?,?,?,?,?,?,?,?,?)) -# select tuple with WHERE clause having param for each fields(SELECT * FROM T1 WHERE f1=?, SELECT * from T1 where f2=?) -# GwTest13.java - -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -echo "CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -java GwTest13 -if [ $? -ne 0 ] -then - exit 2; -fi - -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test054.ksh b/test/jdbc/Gateway/test054.ksh deleted file mode 100755 index d6183721..00000000 --- a/test/jdbc/Gateway/test054.ksh +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh -# Connect with connectstring "jdbc:gateway" -# select tuple with WHERE clause having param for some fields(SELECT * FROM T1 WHERE f1=?AND f2=? AND f3=?) -# when csqlserver is not runnig -# GwTest14.java -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -echo "CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -java GwTest14 -if [ $? -ne 0 ] -then - exit 2; -fi - -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test055.ksh b/test/jdbc/Gateway/test055.ksh deleted file mode 100755 index 4d95bba8..00000000 --- a/test/jdbc/Gateway/test055.ksh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/sh -# Connect with connectstring "jdbc:gateway" -# Then do (INSERT/UPDATE/DELETE/SELECT) with params statement using gateway statement, when csqlserver is not running -# GwTest15.java -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -echo "CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -java GwTest15 -if [ $? -ne 0 ] -then - exit 2; -fi - -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql - -exit 0; diff --git a/test/jdbc/Gateway/test056.ksh b/test/jdbc/Gateway/test056.ksh deleted file mode 100755 index b4f86b84..00000000 --- a/test/jdbc/Gateway/test056.ksh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/sh -# Connect with connectstring "jdbc:gateway" -# delete tuple with WHERE clause having params (DELETE FROM T1 WHERE f1=?AND f9=?) using gateway,when csqlserver is not runnig - -# GwTest16.java -TESTFILE=${PWD}/jdbc/Gateway/ConnTest01.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Gateway -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -echo "CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);" >${REL_PATH}/t1create.sql -isql $DSN < ${REL_PATH}/t1create.sql >/dev/null 2>&1 -if [ $? -ne 0 ] -then - rm -f ${REL_PATH}/t1create.sql - exit 1; -fi -java GwTest16 -if [ $? -ne 0 ] -then - exit 2; -fi - -echo "drop table T1;">${REL_PATH}/dp.sql -isql $DSN < ${REL_PATH}/dp.sql >/dev/null 2>&1 -rm -f ${REL_PATH}/dp.sql -rm -f ${REL_PATH}/t1create.sql -exit 0; diff --git a/test/jdbc/Makefile b/test/jdbc/Makefile deleted file mode 100644 index 88876187..00000000 --- a/test/jdbc/Makefile +++ /dev/null @@ -1,35 +0,0 @@ -OSNAME = $(shell uname -s) -MAKE=make - -ifeq ($(OSNAME), SunOS) -PlatForm=supported -else -ifeq ($(OSNAME), Linux) -PlatForm=supported -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - - -ifeq ($(PlatForm), supported) -all: buildall -endif - -buildall: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE); cd ..;\ - fi;\ - done - -clean: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE) clean; cd ..;\ - fi;\ - done diff --git a/test/jdbc/ParameterMetadata/Makefile b/test/jdbc/ParameterMetadata/Makefile deleted file mode 100644 index d6576088..00000000 --- a/test/jdbc/ParameterMetadata/Makefile +++ /dev/null @@ -1,9 +0,0 @@ -OSNAME = $(shell uname -s) -JAVAC = javac -TARGETS = ConnTests -TARGETS: ParaMetaTest1.java ParaMetaTest3.java ParaMetaTest3.java - - ${JAVAC} *.java - chmod +x *.ksh -clean: - rm -rf *.class diff --git a/test/jdbc/ParameterMetadata/ParaMetaTest1.java b/test/jdbc/ParameterMetadata/ParaMetaTest1.java deleted file mode 100644 index e98bf32d..00000000 --- a/test/jdbc/ParameterMetadata/ParaMetaTest1.java +++ /dev/null @@ -1,114 +0,0 @@ -//Test for nullable Test -// and getParameterTypeClassName(param); in ParameterMetaData - -import java.sql.*; -public class ParaMetaTest1 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer not null, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp,primary key(f6,f7));"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); -//Parameter Test - - ParameterMetaData paramMetaData = null; - paramMetaData = stmt.getParameterMetaData(); - if (paramMetaData == null) { - System.out.println("db vendor does NOT support ParameterMetaData"); - } else { - System.out.println("db vendor supports ParameterMetaData"); - int paramCount = paramMetaData.getParameterCount(); - System.out.println("paramCount=" + paramCount); - System.out.println("param number is NULL allow className"); - System.out.println("-----------------------------------------------"); - for (int param = 1; param <= paramCount; param++) { - System.out.print(" "+param+" "); - int nullable = paramMetaData.isNullable(param); - if (nullable == ParameterMetaData.parameterNoNulls) - System.out.print("NO "); - else - System.out.print("YES "); - String paramClassName = paramMetaData.getParameterClassName(param); - System.out.println(paramClassName); - } - } - - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Bijaya"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("SELECT * FROM T1 where f2 = ? and f1 = ? and f3 = ?"); - - -//Parameter metadataTest - - paramMetaData = selStmt.getParameterMetaData(); - if (paramMetaData == null) { - System.out.println("db vendor does NOT support ParameterMetaData"); - } else { - System.out.println("db vendor supports ParameterMetaData"); - int paramCount = paramMetaData.getParameterCount(); - System.out.println("paramCount=" + paramCount); - System.out.println("param number is NULL allow className"); - System.out.println("-----------------------------------------------"); - for (int param = 1; param <= paramCount; param++) { - System.out.print(" "+param+" "); - int nullable = paramMetaData.isNullable(param); - if (nullable == ParameterMetaData.parameterNoNulls) - System.out.print("NO "); - else - System.out.print("YES "); - String paramClassName = paramMetaData.getParameterClassName(param); - System.out.println(paramClassName); - } - } - - ResultSet rs=null; - selStmt.setInt(2,2); - selStmt.setShort(1,(short)3); - selStmt.setByte(3,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/jdbc/ParameterMetadata/ParaMetaTest2.java b/test/jdbc/ParameterMetadata/ParaMetaTest2.java deleted file mode 100644 index af0f3287..00000000 --- a/test/jdbc/ParameterMetadata/ParaMetaTest2.java +++ /dev/null @@ -1,115 +0,0 @@ -//Test for getParameterMode -// and getParameterType(param); in ParameterMetaData - -import java.sql.*; -public class ParaMetaTest2 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer not null, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp,primary key(f6,f7));"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); -//Parameter Test - - ParameterMetaData paramMetaData = null; - paramMetaData = stmt.getParameterMetaData(); - if (paramMetaData == null) { - System.out.println("db vendor does NOT support ParameterMetaData"); - } else { - System.out.println("db vendor supports ParameterMetaData"); - int paramCount = paramMetaData.getParameterCount(); - System.out.println("paramCount=" + paramCount); - System.out.println("param number Mode Type"); - System.out.println("-----------------------------------------------"); - for (int param = 1; param <= paramCount; param++) { - System.out.print(" "+param+" "); - int nullable = paramMetaData.getParameterMode(param); - if (nullable == ParameterMetaData.parameterModeIn) - System.out.print("IN "); - else - System.out.print("OUT "); - int paramType = paramMetaData.getParameterType(param); - System.out.println(paramType); - } - } - - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Bijaya"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("SELECT * FROM T1 where f2 = ? and f1 = ? and f3 = ?"); - - -//Parameter metadataTest - - paramMetaData = selStmt.getParameterMetaData(); - if (paramMetaData == null) { - System.out.println("db vendor does NOT support ParameterMetaData"); - } else { - System.out.println("db vendor supports ParameterMetaData"); - int paramCount = paramMetaData.getParameterCount(); - System.out.println("paramCount=" + paramCount); - System.out.println("param number Mode Type"); - System.out.println("-----------------------------------------------"); - for (int param = 1; param <= paramCount; param++) { - System.out.print(" "+param+" "); - int nullable = paramMetaData.getParameterMode(param); - if (nullable == ParameterMetaData.parameterModeIn) - System.out.print("IN "); - else - System.out.print("OUT "); - int paramType = paramMetaData.getParameterType(param); - System.out.println(paramType); - } - - } - - ResultSet rs=null; - selStmt.setInt(2,2); - selStmt.setShort(1,(short)3); - selStmt.setByte(3,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/jdbc/ParameterMetadata/ParaMetaTest3.java b/test/jdbc/ParameterMetadata/ParaMetaTest3.java deleted file mode 100644 index cffce064..00000000 --- a/test/jdbc/ParameterMetadata/ParaMetaTest3.java +++ /dev/null @@ -1,106 +0,0 @@ -//Test for getParameterCount(); -// and getParameterTypeName(param); in ParameterMetaData - -import java.sql.*; -public class ParaMetaTest3 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); -//Parameter Test - - - ParameterMetaData paramMetaData = null; - paramMetaData = stmt.getParameterMetaData(); - if (paramMetaData == null) { - System.out.println("db vendor does NOT support ParameterMetaData"); - } else { - System.out.println("db vendor supports ParameterMetaData"); - int paramCount = paramMetaData.getParameterCount(); - System.out.println("paramCount=" + paramCount); - System.out.println("param number param SQL type name"); - System.out.println("-----------------------------------------------"); - for (int param = 1; param <= paramCount; param++) { - System.out.print(" "+param+" "); - String paramTypeName = paramMetaData.getParameterTypeName(param); - System.out.println(paramTypeName); - } - } - - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Bijaya"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("SELECT * FROM T1 where f2 = ? and f1 = ? and f3 = ?"); - - -//Parameter metadataTest - - - paramMetaData = selStmt.getParameterMetaData(); - if (paramMetaData == null) { - System.out.println("db vendor does NOT support ParameterMetaData"); - } else { - System.out.println("db vendor supports ParameterMetaData"); - int paramCount = paramMetaData.getParameterCount(); - System.out.println("paramCount=" + paramCount); - System.out.println("param number param SQL type name"); - System.out.println("-----------------------------------------------"); - for (int param = 1; param <= paramCount; param++) { - System.out.print(" "+param+" "); - String paramTypeName = paramMetaData.getParameterTypeName(param); - System.out.println(paramTypeName); - } - } - - ResultSet rs=null; - selStmt.setInt(2,2); - selStmt.setShort(1,(short)3); - selStmt.setByte(3,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/jdbc/ParameterMetadata/test001.ksh b/test/jdbc/ParameterMetadata/test001.ksh deleted file mode 100755 index f7766555..00000000 --- a/test/jdbc/ParameterMetadata/test001.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/ParameterMetadata/ParaMetaTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/ParameterMetadata -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ParaMetaTest1 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/ParameterMetadata/test002.ksh b/test/jdbc/ParameterMetadata/test002.ksh deleted file mode 100755 index 54a6e36a..00000000 --- a/test/jdbc/ParameterMetadata/test002.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/ParameterMetadata/ParaMetaTest2.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/ParameterMetadata -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ParaMetaTest2 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/ParameterMetadata/test003.ksh b/test/jdbc/ParameterMetadata/test003.ksh deleted file mode 100755 index fd98b987..00000000 --- a/test/jdbc/ParameterMetadata/test003.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/ParameterMetadata/ParaMetaTest3.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/ParameterMetadata -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ParaMetaTest3 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/ResultSetMetaData/Makefile b/test/jdbc/ResultSetMetaData/Makefile deleted file mode 100644 index ce30d6ed..00000000 --- a/test/jdbc/ResultSetMetaData/Makefile +++ /dev/null @@ -1,8 +0,0 @@ -OSNAME = $(shell uname -s) -JAVAC = javac -TARGETS = ConnTests -TARGETS: RSMetadata2.java RSMetadata2.java - ${JAVAC} *.java - chmod +x *.ksh -clean: - rm -rf *.class diff --git a/test/jdbc/ResultSetMetaData/RSMetadata1.java b/test/jdbc/ResultSetMetaData/RSMetadata1.java deleted file mode 100644 index 8d5d69e5..00000000 --- a/test/jdbc/ResultSetMetaData/RSMetadata1.java +++ /dev/null @@ -1,99 +0,0 @@ -//Test DML statement -//Test Script for getColumnDisplaySize,getColumnLabel,getColumnName,getColumnType,getColumnTypeName,getColumnClassName,getTableName,isNullable takeing two Field -import java.sql.*; -public class RSMetadata1 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - cStmt.execute("CREATE INDEX IDX ON T1 ( f1);"); - con.commit(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - for (int j =0 ; j< 10 ; j++) { - stmt.setInt(1, j); - stmt.setString(2, String.valueOf(j+100)); - stmt.executeUpdate(); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT f2,f1 from T1 ;"); - ResultSet rs = null; - rs = selStmt.executeQuery(); - - System.out.println("SELECT f2,f1 from T1 ;"); - System.out.println(); - ResultSetMetaData rsMetaData = rs.getMetaData(); - - int numberOfColumns = rsMetaData.getColumnCount(); - System.out.println("resultSet MetaData column Count=" + numberOfColumns); - - for (int i = 1; i <= numberOfColumns; i++) - { - - System.out.println("=============================== "); - System.out.println("RESULT SET METADATA "); - System.out.println("=============================== "); - System.out.println("column number = " + i); - System.out.println("DisplaySize = "+rsMetaData.getColumnDisplaySize(i)); - System.out.println("ColumnLabel = "+rsMetaData.getColumnLabel(i)); - System.out.println("ColumnName = "+rsMetaData.getColumnName(i)); - System.out.println("ColumnType = "+rsMetaData.getColumnType(i)); - System.out.println("TypeName = "+rsMetaData.getColumnTypeName(i)); - System.out.println("ClassName = "+rsMetaData.getColumnClassName(i)); - System.out.println("TableName = "+rsMetaData.getTableName(i)); - System.out.println("sNullable = "+rsMetaData.isNullable(i)); - System.out.println("=============================== "); - } - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(2)+ " "+ rs.getString(1)); - } - rs.close(); - - selStmt = con.prepareStatement("SELECT * from T1 ;"); - rs = selStmt.executeQuery(); - System.out.println("SELECT * from T1 ;"); - System.out.println(); - - rsMetaData = rs.getMetaData(); - - numberOfColumns = rsMetaData.getColumnCount(); - System.out.println("resultSet MetaData column Count=" + numberOfColumns); - - for (int i = 1; i <= numberOfColumns; i++) - { - - System.out.println("=============================== "); - System.out.println("RESULT SET METADATA "); - System.out.println("=============================== "); - System.out.println("column number = " + i); - System.out.println("DisplaySize = "+rsMetaData.getColumnDisplaySize(i)); - System.out.println("ColumnLabel = "+rsMetaData.getColumnLabel(i)); - System.out.println("ColumnName = "+rsMetaData.getColumnName(i)); - System.out.println("ColumnType = "+rsMetaData.getColumnType(i)); - System.out.println("TypeName = "+rsMetaData.getColumnTypeName(i)); - System.out.println("ClassName = "+rsMetaData.getColumnClassName(i)); - System.out.println("TableName = "+rsMetaData.getTableName(i)); - System.out.println("sNullable = "+rsMetaData.isNullable(i)); - System.out.println("=============================== "); - } - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} diff --git a/test/jdbc/ResultSetMetaData/RSMetadata2.java b/test/jdbc/ResultSetMetaData/RSMetadata2.java deleted file mode 100644 index 9ae3b629..00000000 --- a/test/jdbc/ResultSetMetaData/RSMetadata2.java +++ /dev/null @@ -1,137 +0,0 @@ -//Test Script for getColumnDisplaySize,getColumnLabel,getColumnName,getColumnType,getColumnTypeName,getColumnClassName,getTableName,isNullable Taking 9 different type of field -import java.sql.*; -public class RSMetadata2 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("BIJAYA"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - - System.out.println("SELECT * from T1 ;"); - System.out.println(); - - ResultSetMetaData rsMetaData = rs.getMetaData(); - - int numberOfColumns = rsMetaData.getColumnCount(); - System.out.println("resultSet MetaData column Count=" + numberOfColumns); - - for (int i = 1; i <= numberOfColumns; i++) - { - - System.out.println("=============================== "); - System.out.println("RESULT SET METADATA "); - System.out.println("=============================== "); - System.out.println("column number = " + i); - System.out.println("DisplaySize = "+rsMetaData.getColumnDisplaySize(i)); - System.out.println("ColumnLabel = "+rsMetaData.getColumnLabel(i)); - System.out.println("ColumnName = "+rsMetaData.getColumnName(i)); - System.out.println("ColumnType = "+rsMetaData.getColumnType(i)); - System.out.println("TypeName = "+rsMetaData.getColumnTypeName(i)); - System.out.println("ClassName = "+rsMetaData.getColumnClassName(i)); - System.out.println("TableName = "+rsMetaData.getTableName(i)); - System.out.println("sNullable = "+rsMetaData.isNullable(i)); - System.out.println("=============================== "); - } - - - - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - ret=0; - selStmt=con.prepareStatement("Select f9,f2,f4,f5,f7,f1,f8,f6,f3 from T1"); - rs=null; - rs=selStmt.executeQuery(); - System.out.println(); - - System.out.println("SELECT f9,f2,f4,f5,f7,f1,f8,f6,f3 from T1 ;"); - System.out.println(); - - rsMetaData = rs.getMetaData(); - - numberOfColumns = rsMetaData.getColumnCount(); - System.out.println("resultSet MetaData column Count=" + numberOfColumns); - - for (int i = 1; i <= numberOfColumns; i++) - { - - System.out.println("=============================== "); - System.out.println("RESULT SET METADATA "); - System.out.println("=============================== "); - System.out.println("column number = " + i); - System.out.println("DisplaySize = "+rsMetaData.getColumnDisplaySize(i)); - System.out.println("ColumnLabel = "+rsMetaData.getColumnLabel(i)); - System.out.println("ColumnName = "+rsMetaData.getColumnName(i)); - System.out.println("ColumnType = "+rsMetaData.getColumnType(i)); - System.out.println("TypeName = "+rsMetaData.getColumnTypeName(i)); - System.out.println("ClassName = "+rsMetaData.getColumnClassName(i)); - System.out.println("TableName = "+rsMetaData.getTableName(i)); - System.out.println("sNullable = "+rsMetaData.isNullable(i)); - System.out.println("=============================== "); - } - - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(6) + " "+ - rs.getShort(2) + " "+ - rs.getByte(9) + " "+ - rs.getLong(3) + " "+ - rs.getFloat(4) + " "+ - rs.getString(8) + " "+ - rs.getDate(5) + " "+ - rs.getTime(7) + " "+ - rs.getTimestamp(1) + " " - ); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/jdbc/ResultSetMetaData/test001.ksh b/test/jdbc/ResultSetMetaData/test001.ksh deleted file mode 100755 index 6e24466c..00000000 --- a/test/jdbc/ResultSetMetaData/test001.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/ResultSetMetaData/RSMetadata1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/ -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java RSMetadata1 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/ResultSetMetaData/test002.ksh b/test/jdbc/ResultSetMetaData/test002.ksh deleted file mode 100755 index 36eb7276..00000000 --- a/test/jdbc/ResultSetMetaData/test002.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/ResultSetMetaData/RSMetadata1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/ -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java RSMetadata2 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/Makefile b/test/jdbc/Statement/Makefile deleted file mode 100644 index 9d8d8917..00000000 --- a/test/jdbc/Statement/Makefile +++ /dev/null @@ -1,11 +0,0 @@ -OSNAME = $(shell uname -s) -JAVAC = javac -TARGETS = StmtTests -StmtTests: StmtTest1.java StmtTest2.java StmtTest3.java StmtTest4.java \ - StmtTest5.java StmtTest6.java StmtTest7.java StmtTest8.java \ - StmtTest9.java - - javac *.java - chmod +x *.ksh -clean: - rm -rf *.class diff --git a/test/jdbc/Statement/StmtTest1.java b/test/jdbc/Statement/StmtTest1.java deleted file mode 100644 index 8de367aa..00000000 --- a/test/jdbc/Statement/StmtTest1.java +++ /dev/null @@ -1,87 +0,0 @@ -//Test DML statement with parameters -import java.sql.*; -public class StmtTest1 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - cStmt.execute("CREATE INDEX IDX ON T1 ( f1);"); - con.commit(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i+100)); - stmt.executeUpdate(); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 where f1 = ?;"); - ResultSet rs = null; - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - int ret=0; - stmt = con.prepareStatement("UPDATE T1 SET f2 = ? WHERE f1 = ?;"); - for (int i =0 ; i< 10 ; i +=2) { - stmt.setString(1, String.valueOf(i+200)); - stmt.setInt(2, i); - ret = stmt.executeUpdate(); - if (ret != 1) break; - } - stmt.close(); - con.commit(); - - System.out.println("After update, listing tuples:"); - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - con.commit(); - - - - stmt = con.prepareStatement("DELETE FROM T1 WHERE f1 = ?;"); - for (int i =0 ; i< 10 ; i +=3) { - stmt.setInt(1, i); - ret = stmt.executeUpdate(); - if (ret !=1) break; - } - stmt.close(); - con.commit(); - - System.out.println("After delete, listing tuples:"); - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - con.commit(); - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} diff --git a/test/jdbc/Statement/StmtTest2.java b/test/jdbc/Statement/StmtTest2.java deleted file mode 100755 index 5049a4a5..00000000 --- a/test/jdbc/Statement/StmtTest2.java +++ /dev/null @@ -1,61 +0,0 @@ -//Test DML statement with no parameters on execute and executeUpdate -import java.sql.*; -public class StmtTest2 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - cStmt.execute("CREATE INDEX IDX ON T1 ( f1);"); - con.commit(); - - cStmt.execute("INSERT INTO T1 VALUES (1, 'FIRST');"); - cStmt.executeUpdate("INSERT INTO T1 VALUES (2, 'SECOND');"); - con.commit(); - - ResultSet rs = null; - rs = cStmt.executeQuery("SELECT * from T1 where f1 = 1;"); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - - - cStmt.execute("SELECT * from T1 where f1 = 2;"); - rs = cStmt.getResultSet(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - con.commit(); - - cStmt.executeUpdate("UPDATE T1 SET f2 = 'CHANGED' WHERE f1 = 1;"); - con.commit(); - - - - cStmt.executeUpdate("DELETE FROM T1 WHERE f1 = 2;"); - con.commit(); - - System.out.println("After delete, listing tuples:"); - rs = cStmt.executeQuery("SELECT * from T1 ;"); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - con.commit(); - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} diff --git a/test/jdbc/Statement/StmtTest3.java b/test/jdbc/Statement/StmtTest3.java deleted file mode 100644 index e7b11c6e..00000000 --- a/test/jdbc/Statement/StmtTest3.java +++ /dev/null @@ -1,63 +0,0 @@ -//close() and then execute INSERT/QUERY/UPDATE statement. It should fail -import java.sql.*; -public class StmtTest3 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - cStmt.execute("CREATE INDEX IDX ON T1 ( f1);"); - con.commit(); - con.close(); - - //after close the connection,execute "INSERT" statement,it should fail - try - { - cStmt.execute("INSERT INTO T1 VALUES (1, 'FIRST');"); - System.exit(1); - } - catch(Exception e) - { - System.out.println("insert exception---" + e.getMessage()); - } - - //after close the connection,execute "QUERY" statement,it should fail - try - { - cStmt.executeQuery("SELECT * from T1 where f1 = 1;"); - System.exit(2); - } - catch(Exception e) - { - System.out.println("query exception---" + e.getMessage()); - } - - //after close the connection,execute "UPDATE" statement,it should fail - try - { - cStmt.executeUpdate("UPDATE T1 SET f2 = 'CHANGED' WHERE f1 = 1;"); - System.exit(3); - } - catch(Exception e) - { - System.out.println("update exception---" + e.getMessage()); - } - - //cleanup - cStmt.close(); - Connection con1 = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt1 = con1.createStatement(); - cStmt1.execute("DROP TABLE T1 ;"); - cStmt1.close(); - con1.close(); - }catch(Exception e) { - System.out.println("Exception in Test: " + e.getMessage()); - e.printStackTrace(); - System.exit(4); - } - } -} diff --git a/test/jdbc/Statement/StmtTest4.java b/test/jdbc/Statement/StmtTest4.java deleted file mode 100644 index d7beebee..00000000 --- a/test/jdbc/Statement/StmtTest4.java +++ /dev/null @@ -1,19 +0,0 @@ -//close() and then again call close(). it should no error -import java.sql.*; -public class StmtTest4 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - con.close(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Statement/StmtTest5.java b/test/jdbc/Statement/StmtTest5.java deleted file mode 100644 index f0719c9f..00000000 --- a/test/jdbc/Statement/StmtTest5.java +++ /dev/null @@ -1,56 +0,0 @@ -import java.sql.*; -public class StmtTest5 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?,?,?,?,?,?,?,?,?);"); - stmt.setInt(1, 1); - stmt.setShort(2,(short)2); - stmt.setByte(3,(byte)3); - stmt.setLong(4,(long)4); - stmt.setFloat(5,(float)5); - stmt.setString(6, String.valueOf(5)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - stmt.executeUpdate(); - stmt.close(); - con.commit(); - - selStmt = con.prepareStatement("SELECT * from T1 where f1 = ?;"); - ResultSet rs = null; - - selStmt.setInt(1, 1); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - } - rs.close(); - selStmt.close(); - - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} diff --git a/test/jdbc/Statement/StmtTest6.java b/test/jdbc/Statement/StmtTest6.java deleted file mode 100644 index 898cb568..00000000 --- a/test/jdbc/Statement/StmtTest6.java +++ /dev/null @@ -1,63 +0,0 @@ -//select tuple with WHERE clause having param for some fields(SELECT * FROM T1 WHERE f1=?AND f2=? AND f3=?) -import java.sql.*; -public class StmtTest6 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Nihar"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("SELECT * FROM T1 where f1 = ? and f2 = ? and f3 = ?"); - ResultSet rs=null; - selStmt.setInt(1,2); - selStmt.setShort(2,(short)3); - selStmt.setByte(3,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/jdbc/Statement/StmtTest7.java b/test/jdbc/Statement/StmtTest7.java deleted file mode 100644 index 893f2b07..00000000 --- a/test/jdbc/Statement/StmtTest7.java +++ /dev/null @@ -1,93 +0,0 @@ -//update tuple with SET and WHERE clause having params (UPDATE T1 SET f2=?, f8=? WHERE f1=?AND f9=?) -import java.sql.*; -public class StmtTest7 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Nihar"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - ret=0; - stmt=con.prepareStatement("UPDATE T1 SET f2=?, f8=? WHERE f1=?AND f9=?;"); - for(int i=0;i<10;i++) - { - stmt.setShort(1,(short)100); - stmt.setTime(2,Time.valueOf("19:38:25")); - stmt.setInt(3,3); - stmt.setTimestamp(4,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - rs=null; - rs=selStmt.executeQuery(); - System.out.println(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/jdbc/Statement/StmtTest8.java b/test/jdbc/Statement/StmtTest8.java deleted file mode 100644 index 28a638a5..00000000 --- a/test/jdbc/Statement/StmtTest8.java +++ /dev/null @@ -1,64 +0,0 @@ -//NULL Tset "INSERT null values to some fields with and without parameters" -import java.sql.*; -public class StmtTest8 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1(f1,f3,f5,f6,f7,f8,f9) VALUES(?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setByte(2,(byte)(i+2)); - stmt.setFloat(3,(float)1000+i); - stmt.setString(4, String.valueOf("Nihar"+i)); - stmt.setDate(5,Date.valueOf("2008-03-21")); - stmt.setTime(6,Time.valueOf("18:00:00")); - stmt.setTimestamp(7,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - con.commit(); - stmt=con.prepareStatement("INSERT INTO T1(f1,f2,f4,f6,f7,f8,f9) values(10,11,101,'Nihar10','2008-03-21','18:00:00','2008-03-21 18:00:00');"); - stmt.executeUpdate(); - - stmt.close(); - con.commit(); - - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/jdbc/Statement/StmtTest9.java b/test/jdbc/Statement/StmtTest9.java deleted file mode 100644 index 20baee3d..00000000 --- a/test/jdbc/Statement/StmtTest9.java +++ /dev/null @@ -1,93 +0,0 @@ -//update tuple with SET and WHERE clause having params (UPDATE T1 SET f2=NULL, f6=NULL WHERE f1=?AND f9=?) -import java.sql.*; -public class StmtTest9 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Nihar"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - ret=0; - stmt=con.prepareStatement("UPDATE T1 SET f2=NULL, f5=NULL WHERE f1=?AND f9=?;"); - for(int i=0;i<10;i++) - { - //stmt.setShort(1,(short)null); - //stmt.setTime(2,null); - stmt.setInt(1,3); - stmt.setTimestamp(2,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - rs=null; - rs=selStmt.executeQuery(); - System.out.println(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/jdbc/Statement/TestScript1.java b/test/jdbc/Statement/TestScript1.java deleted file mode 100644 index 305c5b25..00000000 --- a/test/jdbc/Statement/TestScript1.java +++ /dev/null @@ -1,91 +0,0 @@ -// Run csqlserver ,Create table. At the time of insertion , Insert some record with Null Value -//Check null inserted or not -// Test For setNull() -import java.sql.*; -/** - * - * @author bijaya - */ -public class TestScript1 { - - public static void main(String[] args) { - - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - if(i==2 ) { - stmt.setNull(1,java.sql.Types.INTEGER); - stmt.setNull(2,java.sql.Types.SMALLINT); - stmt.setNull(3,java.sql.Types.TINYINT); - stmt.setNull(4,java.sql.Types.BIGINT); - stmt.setNull(5,java.sql.Types.FLOAT); - stmt.setNull(6,java.sql.Types.CHAR); - stmt.setNull(7,java.sql.Types.DATE); - stmt.setNull(8,java.sql.Types.TIME); - stmt.setNull(9,java.sql.Types.TIMESTAMP); - }else{ - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("India"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - } - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("SELECT * FROM T1 ;"); - ResultSet rs=null; - selStmt.setInt(1,2); - selStmt.setShort(2,(short)3); - selStmt.setByte(3,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - - System.out.print("Tuple value is " + rs.getInt(1)+ " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getShort(2) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getByte(3) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getLong(4) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getFloat(5) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getString(6) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getDate(7) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getTime(8) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.println(rs.getTimestamp(9) + " "); - if(rs.wasNull()) System.out.println(" NULL"); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - - } -} diff --git a/test/jdbc/Statement/TestScript10.java b/test/jdbc/Statement/TestScript10.java deleted file mode 100644 index d312157a..00000000 --- a/test/jdbc/Statement/TestScript10.java +++ /dev/null @@ -1,66 +0,0 @@ - -//Irrespective of number set in setFetchSize(), getFetchSize() should return 1 - -import java.sql.*; -/** - * - * @author bijaya - */ -public class TestScript10 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?,?,?,?,?,?,?,?,?);"); - stmt.setInt(1, 1); - stmt.setShort(2,(short)2); - stmt.setByte(3,(byte)3); - stmt.setLong(4,(long)4); - stmt.setFloat(5,(float)5); - stmt.setString(6, String.valueOf(5)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - stmt.executeUpdate(); - stmt.close(); - con.commit(); - - cStmt = con.createStatement(); - cStmt.execute("SELECT * from T1;"); - ResultSet rs=cStmt.getResultSet(); - int retval=cStmt.getFetchSize(); - System.out.println("Default Fetch Size "+retval); - cStmt.setFetchSize(3); - retval=cStmt.getFetchSize(); - System.out.println("Default Fetch Size "+retval); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - } - rs.close(); - cStmt.close(); - - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Statement/TestScript11.java b/test/jdbc/Statement/TestScript11.java deleted file mode 100644 index be7de9ef..00000000 --- a/test/jdbc/Statement/TestScript11.java +++ /dev/null @@ -1,58 +0,0 @@ -//execute with select ,close statement and call getResultSet(). it should not give result set -import java.sql.*; -/** - * - * @author bijaya - */ -public class TestScript11 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?,?,?,?,?,?,?,?,?);"); - stmt.setInt(1, 1); - stmt.setShort(2,(short)2); - stmt.setByte(3,(byte)3); - stmt.setLong(4,(long)4); - stmt.setFloat(5,(float)5); - stmt.setString(6, String.valueOf(5)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - stmt.executeUpdate(); - stmt.close(); - con.commit(); - - cStmt = con.createStatement(); - cStmt.execute("SELECT * from T1;"); - cStmt.close(); - ResultSet rs=cStmt.getResultSet(); - if(rs==null) - { - System.out.println("Test case Passed "); - cStmt = con.createStatement(); - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - System.exit(0); - }else - { - System.out.println("Test case failed"); - cStmt = con.createStatement(); - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - System.exit(1); - } - - - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} diff --git a/test/jdbc/Statement/TestScript2.java b/test/jdbc/Statement/TestScript2.java deleted file mode 100644 index 8c70b7d0..00000000 --- a/test/jdbc/Statement/TestScript2.java +++ /dev/null @@ -1,53 +0,0 @@ -//select Null test -import java.sql.*; - -/** - * - * @author bijaya - */ -public class TestScript2 { - - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, NULL);"); - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.executeUpdate(); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 ;"); - ResultSet rs = null; - //selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - int f1=rs.getInt(1); - if(rs.wasNull()) - System.out.print(" NULL"); - else - System.out.print(" "+ f1); - String f2=rs.getString(2); - if(rs.wasNull()) - System.out.println(" NULL"); - else - System.out.println(" "+ f2); - } - rs.close(); - - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Statement/TestScript3.java b/test/jdbc/Statement/TestScript3.java deleted file mode 100644 index 19f0e1b1..00000000 --- a/test/jdbc/Statement/TestScript3.java +++ /dev/null @@ -1,99 +0,0 @@ -//ExecuteUpdate Should return no of records updated - -import java.sql.Connection; -import java.sql.DriverManager; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.Statement; - -/** - * - * @author bijaya - */ -public class TestScript3 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - cStmt.execute("CREATE INDEX IDX ON T1 ( f1);"); - con.commit(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - int ret=0; - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i+100)); - ret=stmt.executeUpdate(); - if (ret != 1){ - System.out.println("ExecuteUpdate doesnot return proper values in Insert "+ret); - break; - } - System.out.println("ExecuteUpdate return proper values in Insert "); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 where f1 = ?;"); - ResultSet rs = null; - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - int a=5; - stmt = con.prepareStatement("UPDATE T1 SET f2 = ? WHERE f1 >5;"); - - stmt.setString(1, String.valueOf(a+200)); - - ret = stmt.executeUpdate(); - if (ret != 4){ - System.out.println("ExecuteUpdate doesnot return proper values for Update "+ret); - } - System.out.println("ExecuteUpdate return proper values fro Update "+ret); - - stmt.close(); - con.commit(); - - System.out.println("After update, listing tuples:"); - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - con.commit(); - - stmt = con.prepareStatement("DELETE FROM T1 ;"); - - - ret = stmt.executeUpdate(); - if (ret !=10) - { - System.out.println("ExecuteUpdate doesnot return proper vslues for Delete "+ret); - } - System.out.println("ExecuteUpdate returns proper vslues for delete "+ret); - - stmt.close(); - con.commit(); - - - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/jdbc/Statement/TestScript4.java b/test/jdbc/Statement/TestScript4.java deleted file mode 100644 index 8875a734..00000000 --- a/test/jdbc/Statement/TestScript4.java +++ /dev/null @@ -1,58 +0,0 @@ -//ExecuteUpdate for SELECT statement it should not return resultset throw exception - -import java.sql.Connection; -import java.sql.DriverManager; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.Statement; - -/** - * - * @author bijaya - */ -public class TestScript4 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, NULL);"); - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.executeUpdate(); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 ;"); - ResultSet rs = null; - System.out.println("yes"); - int result = selStmt.executeUpdate(); - /* while (rs.next()) - { - int f1=rs.getInt(1); - if(rs.wasNull()) - System.out.print(" NULL"); - else - System.out.print(" "+ f1); - String f2=rs.getString(2); - if(rs.wasNull()) - System.out.println(" NULL"); - else - System.out.println(" "+ f2); - } - rs.close(); - */ - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(0); - } - } -} diff --git a/test/jdbc/Statement/TestScript5.java b/test/jdbc/Statement/TestScript5.java deleted file mode 100644 index 40abb92a..00000000 --- a/test/jdbc/Statement/TestScript5.java +++ /dev/null @@ -1,61 +0,0 @@ -//Getting maximum row information from select statement instance -import java.sql.DriverManager; -import java.sql.Connection; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.Statement; -/** - * - * @author bijaya - */ -public class TestScript5 { -public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, NULL);"); - Connection conn=stmt.getConnection(); - if(conn==null){ - System.out.println("Statement doesnot give connection object"); - } - else - System.out.println("Statement gives connection object"); - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.executeUpdate(); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 ;"); - ResultSet rs = null; - System.out.println("Total No of rows= "+selStmt.getMaxRows()); - rs = selStmt.executeQuery(); - while (rs.next()) - { - int f1=rs.getInt(1); - if(rs.wasNull()) - System.out.print(" NULL"); - else - System.out.print(" "+ f1); - String f2=rs.getString(2); - if(rs.wasNull()) - System.out.println(" NULL"); - else - System.out.println(" "+ f2); - } - rs.close(); - - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/jdbc/Statement/TestScript6.java b/test/jdbc/Statement/TestScript6.java deleted file mode 100644 index e85ed264..00000000 --- a/test/jdbc/Statement/TestScript6.java +++ /dev/null @@ -1,96 +0,0 @@ -//Select Data with Field name instead of position - -import java.sql.Connection; -import java.sql.Date; -import java.sql.DriverManager; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.Statement; -import java.sql.Time; -import java.sql.Timestamp; -/** - * - * @author bijaya - */ -public class TestScript6 { - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Bijaya"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("SELECT * FROM T1 ;"); - ResultSet rs=null; - selStmt.setInt(1,2); - selStmt.setShort(2,(short)3); - selStmt.setByte(3,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt("f1") + " "+ - rs.getShort("f2") + " "+ - rs.getByte("f3") + " "+ - rs.getLong("f4") + " "+ - rs.getFloat("f5") + " "+ - rs.getString("f6") + " "+ - rs.getDate("f7") + " "+ - rs.getTime("f7") + " "+ - rs.getTimestamp("f9") + " " - ); - - } - rs.close(); - System.out.println(""); - selStmt=con.prepareStatement("SELECT * FROM T1 ;"); - rs=null; - selStmt.setInt(1,2); - selStmt.setShort(2,(short)3); - selStmt.setByte(3,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Statement/TestScript7.java b/test/jdbc/Statement/TestScript7.java deleted file mode 100644 index 32fd562e..00000000 --- a/test/jdbc/Statement/TestScript7.java +++ /dev/null @@ -1,91 +0,0 @@ - -//executequery with ins, upd, del statements which will throw exception - -import java.sql.Connection; -import java.sql.DriverManager; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.Statement; - -/** - * - * @author bijaya - */ -public class TestScript7 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - con.commit(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i+100)); - stmt.executeQuery(); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 ;"); - ResultSet rs = null; - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - - int ret=0; - stmt = con.prepareStatement("UPDATE T1 SET f2 = ? WHERE f1 = ?;"); - for (int i =0 ; i< 10 ; i +=2) { - stmt.setString(1, String.valueOf(i+200)); - stmt.setInt(2, i); - stmt.executeQuery(); - - } - stmt.close(); - con.commit(); - - System.out.println("After update, listing tuples:"); - - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - - con.commit(); - stmt = con.prepareStatement("DELETE FROM T1 WHERE f1 = ?;"); - for (int i =0 ; i< 10 ; i +=3) { - stmt.setInt(1, i); - stmt.executeQuery(); - - } - stmt.close(); - con.commit(); - - System.out.println("After delete, listing tuples:"); - - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - - con.commit(); - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(0); - } - } - -} diff --git a/test/jdbc/Statement/TestScript8.java b/test/jdbc/Statement/TestScript8.java deleted file mode 100644 index defee573..00000000 --- a/test/jdbc/Statement/TestScript8.java +++ /dev/null @@ -1,87 +0,0 @@ - -//execute with ins,upd,del and getUpdateCount(). getResultSet() should return null. - -import java.sql.Connection; -import java.sql.DriverManager; -import java.sql.ResultSet; -import java.sql.Statement; - -/** - * - * @author bijaya - */ -public class TestScript8 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - - con.commit(); - for(int i=0;i<10;i++){ - cStmt.execute("INSERT INTO T1 VALUES (1, 'FIRST');"); - } - ResultSet rs = null; - rs=cStmt.getResultSet(); - if(rs==null) - System.out.println(" Not return a result set for insert statement"); - else - System.out.println(" Test Case Failed"); - con.commit(); - - rs = null; - rs = cStmt.executeQuery("SELECT * from T1 ;"); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - - cStmt.executeUpdate("UPDATE T1 SET f2 = 'CHANGED' WHERE f1 <4;"); - int cout=cStmt.getUpdateCount(); - System.out.println("Total update: "+cout); - rs=cStmt.getResultSet(); - if(rs==null) - System.out.println(" Not return a result set for update statement"); - else - System.out.println(" Test Case Failed"); - con.commit(); - cStmt.execute("SELECT * from T1 ;"); - rs = cStmt.getResultSet(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - con.commit(); - - cStmt.executeUpdate("DELETE FROM T1 WHERE f1 <5;"); - cout=cStmt.getUpdateCount(); - System.out.println("Total delete: "+cout); - rs=cStmt.getResultSet(); - if(rs==null) - System.out.println(" Not return a result set for delete statement"); - else - System.out.println(" Test Case Failed"); - con.commit(); - - System.out.println("After delete, listing tuples:"); - rs = cStmt.executeQuery("SELECT * from T1 ;"); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - con.commit(); - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Statement/TestScript9.java b/test/jdbc/Statement/TestScript9.java deleted file mode 100644 index 8897bb48..00000000 --- a/test/jdbc/Statement/TestScript9.java +++ /dev/null @@ -1,70 +0,0 @@ - -//execute with select and getResultSet(). getUpdateCount() should return -1. -import java.sql.*; - -/** - * - * @author bijaya - */ -public class TestScript9 { - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?,?,?,?,?,?,?,?,?);"); - stmt.setInt(1, 1); - stmt.setShort(2,(short)2); - stmt.setByte(3,(byte)3); - stmt.setLong(4,(long)4); - stmt.setFloat(5,(float)5); - stmt.setString(6, String.valueOf(5)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - stmt.executeUpdate(); - stmt.close(); - con.commit(); - - cStmt = con.createStatement(); - cStmt.execute("SELECT * from T1;"); - ResultSet rs=cStmt.getResultSet(); - int retval=cStmt.getUpdateCount(); - if(retval!=-1) - { - System.out.println("Update count not returning -1 "); - System.exit(1); - } else - { - System.out.println("Update count returning -1 "); - } - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - } - rs.close(); - cStmt.close(); - - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/jdbc/Statement/exp.test001.ksh b/test/jdbc/Statement/exp.test001.ksh deleted file mode 100644 index bb6b92be..00000000 --- a/test/jdbc/Statement/exp.test001.ksh +++ /dev/null @@ -1,28 +0,0 @@ -Tuple value is 0 100 -Tuple value is 1 101 -Tuple value is 2 102 -Tuple value is 3 103 -Tuple value is 4 104 -Tuple value is 5 105 -Tuple value is 6 106 -Tuple value is 7 107 -Tuple value is 8 108 -Tuple value is 9 109 -After update, listing tuples: -Tuple value is 0 200 -Tuple value is 1 101 -Tuple value is 2 202 -Tuple value is 3 103 -Tuple value is 4 204 -Tuple value is 5 105 -Tuple value is 6 206 -Tuple value is 7 107 -Tuple value is 8 208 -Tuple value is 9 109 -After delete, listing tuples: -Tuple value is 1 101 -Tuple value is 2 202 -Tuple value is 4 204 -Tuple value is 5 105 -Tuple value is 7 107 -Tuple value is 8 208 diff --git a/test/jdbc/Statement/exp.test002.ksh b/test/jdbc/Statement/exp.test002.ksh deleted file mode 100644 index 72f7266a..00000000 --- a/test/jdbc/Statement/exp.test002.ksh +++ /dev/null @@ -1,4 +0,0 @@ -Tuple value is 1 FIRST -Tuple value is 2 SECOND -After delete, listing tuples: -Tuple value is 1 CHANGED diff --git a/test/jdbc/Statement/exp.test005.ksh b/test/jdbc/Statement/exp.test005.ksh deleted file mode 100755 index 3e9c6180..00000000 --- a/test/jdbc/Statement/exp.test005.ksh +++ /dev/null @@ -1 +0,0 @@ -Tuple value is 1 2 3 4 5.0 5 2008-03-21 18:00:00 2008-03-21 18:00:00.0 diff --git a/test/jdbc/Statement/exp.test006.ksh b/test/jdbc/Statement/exp.test006.ksh deleted file mode 100755 index 93281eea..00000000 --- a/test/jdbc/Statement/exp.test006.ksh +++ /dev/null @@ -1,2 +0,0 @@ -SELECT * FROM T1 WHERE f1=?AND f2=? AND f3=? -Tuple value is 2 3 4 2 1002.0 Nihar2 2008-03-21 18:00:00 2008-03-21 18:00:00.0 diff --git a/test/jdbc/Statement/exp.test007.ksh b/test/jdbc/Statement/exp.test007.ksh deleted file mode 100755 index cddcd9ae..00000000 --- a/test/jdbc/Statement/exp.test007.ksh +++ /dev/null @@ -1,21 +0,0 @@ -Tuple value is 0 1 2 0 1000.0 Nihar0 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 1 2 3 1 1001.0 Nihar1 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 2 3 4 2 1002.0 Nihar2 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 3 4 5 3 1003.0 Nihar3 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 4 5 6 4 1004.0 Nihar4 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 5 6 7 5 1005.0 Nihar5 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 6 7 8 6 1006.0 Nihar6 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 7 8 9 7 1007.0 Nihar7 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 8 9 10 8 1008.0 Nihar8 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 9 10 11 9 1009.0 Nihar9 2008-03-21 18:00:00 2008-03-21 18:00:00.0 - -Tuple value is 0 1 2 0 1000.0 Nihar0 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 1 2 3 1 1001.0 Nihar1 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 2 3 4 2 1002.0 Nihar2 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 3 100 5 3 1003.0 Nihar3 2008-03-21 19:38:25 2008-03-21 18:00:00.0 -Tuple value is 4 5 6 4 1004.0 Nihar4 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 5 6 7 5 1005.0 Nihar5 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 6 7 8 6 1006.0 Nihar6 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 7 8 9 7 1007.0 Nihar7 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 8 9 10 8 1008.0 Nihar8 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 9 10 11 9 1009.0 Nihar9 2008-03-21 18:00:00 2008-03-21 18:00:00.0 diff --git a/test/jdbc/Statement/exp.test008.ksh b/test/jdbc/Statement/exp.test008.ksh deleted file mode 100644 index 68e51a28..00000000 --- a/test/jdbc/Statement/exp.test008.ksh +++ /dev/null @@ -1,11 +0,0 @@ -Tuple value is 0 0 2 0 1000.0 Nihar0 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 1 0 3 0 1001.0 Nihar1 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 2 0 4 0 1002.0 Nihar2 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 3 0 5 0 1003.0 Nihar3 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 4 0 6 0 1004.0 Nihar4 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 5 0 7 0 1005.0 Nihar5 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 6 0 8 0 1006.0 Nihar6 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 7 0 9 0 1007.0 Nihar7 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 8 0 10 0 1008.0 Nihar8 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 9 0 11 0 1009.0 Nihar9 2008-03-21 18:00:00 2008-03-21 18:00:00.0 -Tuple value is 10 11 0 101 0.0 Nihar10 2008-03-21 18:00:00 2008-03-21 18:00:00.0 diff --git a/test/jdbc/Statement/test001.ksh b/test/jdbc/Statement/test001.ksh deleted file mode 100644 index f5b6eef4..00000000 --- a/test/jdbc/Statement/test001.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest1 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test002.ksh b/test/jdbc/Statement/test002.ksh deleted file mode 100755 index 382e9d8f..00000000 --- a/test/jdbc/Statement/test002.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest2 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test003.ksh b/test/jdbc/Statement/test003.ksh deleted file mode 100755 index e930faec..00000000 --- a/test/jdbc/Statement/test003.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest3 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test004.ksh b/test/jdbc/Statement/test004.ksh deleted file mode 100755 index 3d3d21ea..00000000 --- a/test/jdbc/Statement/test004.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest4 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test005.ksh b/test/jdbc/Statement/test005.ksh deleted file mode 100755 index 58c17b21..00000000 --- a/test/jdbc/Statement/test005.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest5 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test006.ksh b/test/jdbc/Statement/test006.ksh deleted file mode 100755 index 18220d91..00000000 --- a/test/jdbc/Statement/test006.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Statement/StmtTest6.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -echo "SELECT * FROM T1 WHERE f1=?AND f2=? AND f3=?" -java StmtTest6 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test007.ksh b/test/jdbc/Statement/test007.ksh deleted file mode 100755 index a224a7c6..00000000 --- a/test/jdbc/Statement/test007.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Statement/StmtTest7.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest7 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test008.ksh b/test/jdbc/Statement/test008.ksh deleted file mode 100755 index 5d2f74c8..00000000 --- a/test/jdbc/Statement/test008.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Statement/StmtTest8.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest8 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test009.ksh b/test/jdbc/Statement/test009.ksh deleted file mode 100755 index 2afae76a..00000000 --- a/test/jdbc/Statement/test009.ksh +++ /dev/null @@ -1,14 +0,0 @@ -#!/bin/sh -TESTFILE=${PWD}/jdbc/Statement/StmtTest9.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest9 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test010.ksh b/test/jdbc/Statement/test010.ksh deleted file mode 100755 index 6c55a8b8..00000000 --- a/test/jdbc/Statement/test010.ksh +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh -# Run csqlserver ,Create table. At the time of insertion , Insert some record with Null Value -# Check null inserted or not -# Test For setNull() -# TestScript1.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript1 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test011.ksh b/test/jdbc/Statement/test011.ksh deleted file mode 100755 index b06b909e..00000000 --- a/test/jdbc/Statement/test011.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# select Null test -# TestScript2.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript2 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test012.ksh b/test/jdbc/Statement/test012.ksh deleted file mode 100755 index d95ae2dc..00000000 --- a/test/jdbc/Statement/test012.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# ExecuteUpdate Should return no of records updated -# TestScript3.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript3 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test013.ksh b/test/jdbc/Statement/test013.ksh deleted file mode 100755 index dd0c64c8..00000000 --- a/test/jdbc/Statement/test013.ksh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/sh -# ExecuteUpdate for SELECT statement it should not return resultset throw exception -# TestScript4.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -echo "Drop table T1;" > ${REL_PATH}/tmp.sql -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript4 -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/tmp.sql - rm -f ${REL_PATH}/tmp.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/tmp.sql -rm -f ${REL_PATH}/tmp.sql -exit 0; diff --git a/test/jdbc/Statement/test014.ksh b/test/jdbc/Statement/test014.ksh deleted file mode 100755 index 6c02d277..00000000 --- a/test/jdbc/Statement/test014.ksh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/sh -# Getting maximum row information from select statement instance getMaxRows() -# TestScript5.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -echo "Drop table T1;" > ${REL_PATH}/tmp.sql -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript5 -if [ $? -ne 0 ] -then -$CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/tmp.sql -rm -f ${REL_PATH}/tmp.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/tmp.sql -rm -f ${REL_PATH}/tmp.sql -exit 0; diff --git a/test/jdbc/Statement/test015.ksh b/test/jdbc/Statement/test015.ksh deleted file mode 100755 index 7ff2bf9e..00000000 --- a/test/jdbc/Statement/test015.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Select Data with Field name instead of position -# TestScript6.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript6 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test016.ksh b/test/jdbc/Statement/test016.ksh deleted file mode 100755 index f44f2404..00000000 --- a/test/jdbc/Statement/test016.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# executequery with ins, upd, del statements which will throw exception -# TestScript7.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript7 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test017.ksh b/test/jdbc/Statement/test017.ksh deleted file mode 100755 index dd909f38..00000000 --- a/test/jdbc/Statement/test017.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# execute with ins,upd,del and getUpdateCount(). getResultSet() should return null. -# TestScript8.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript8 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test018.ksh b/test/jdbc/Statement/test018.ksh deleted file mode 100755 index e03b3f51..00000000 --- a/test/jdbc/Statement/test018.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# execute with select and getResultSet(). getUpdateCount() should return -1. -# TestScript9.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript9 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/jdbc/Statement/test019.ksh b/test/jdbc/Statement/test019.ksh deleted file mode 100755 index ba4b2483..00000000 --- a/test/jdbc/Statement/test019.ksh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/sh -# Irrespective of number set in setFetchSize(), getFetchSize() should return 1 -# TestScript10.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -echo "Drop table T1;" > ${REL_PATH}/tmp.sql -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript10 -if [ $? -ne 0 ] -then -$CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/tmp.sql -rm -f ${REL_PATH}/tmp.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/tmp.sql -rm -f ${REL_PATH}/tmp.sql -exit 0; diff --git a/test/jdbc/Statement/test020.ksh b/test/jdbc/Statement/test020.ksh deleted file mode 100755 index 7935a5f2..00000000 --- a/test/jdbc/Statement/test020.ksh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/sh -# execute with select ,close statement and call getResultSet(). it should not give result set -# TestScript11.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -echo "Drop table T1;" > ${REL_PATH}/tmp.sql -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript11 -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/tmp.sql - rm -f ${REL_PATH}/tmp.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/tmp.sql -rm -f ${REL_PATH}/tmp.sql -exit 0; diff --git a/test/jdbc/Statement/test021.ksh b/test/jdbc/Statement/test021.ksh deleted file mode 100755 index 2a359156..00000000 --- a/test/jdbc/Statement/test021.ksh +++ /dev/null @@ -1,22 +0,0 @@ -#!/bin/sh -# Get Result set then close result set and then fetch it should fail -# TestScript12.java - -TESTFILE=${PWD}/jdbc/Statement/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Statement -fi -echo "Drop table T1;" > ${REL_PATH}/tmp.sql -export CLASSPATH=$CLASSPATH:${REL_PATH} -java TestScript12 -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/tmp.sql - rm -f ${REL_PATH}/tmp.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/tmp.sql -rm -f ${REL_PATH}/tmp.sql -exit 0; diff --git a/test/odbc/Connect/Makefile b/test/odbc/Connect/Makefile deleted file mode 100644 index a2564c47..00000000 --- a/test/odbc/Connect/Makefile +++ /dev/null @@ -1,51 +0,0 @@ -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -O2 -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include - -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlodbc - -TARGETS = test001 test002 test003 test004 test005 test006 test007 - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -.c.o:.c - $(CPlus) $(CPlusFlags) $(INCL) -c -o $@ $< - -test001: odbcconnect1.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - -test002:odbcconnect2.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test003:odbcconnect3.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test004:odbcconnect4.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test005:odbcconnect5.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test006:odbcconnect6.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test007:odbcconnect7.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - -clean: - rm -f *.o $(TARGETS) - diff --git a/test/odbc/Connect/odbcconnect1.c b/test/odbc/Connect/odbcconnect1.c deleted file mode 100644 index d1208bbf..00000000 --- a/test/odbc/Connect/odbcconnect1.c +++ /dev/null @@ -1,83 +0,0 @@ -// connect to the DATA SOURCE. -// disconnect from the data source - -// Author : Jitendra Lenka - -#include -#include -#include -#include -#include - - - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN data source - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source successfully..\n"); - - } - else - { - printf("error in connection\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - - return 2; - } - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - printf("Disconnected from the Datasource\n"); - - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 0; -} diff --git a/test/odbc/Connect/odbcconnect2.c b/test/odbc/Connect/odbcconnect2.c deleted file mode 100644 index e907837f..00000000 --- a/test/odbc/Connect/odbcconnect2.c +++ /dev/null @@ -1,120 +0,0 @@ -// sqlconnect,sqldisconnect and then again call sqlconnect.it should pass. -// see retrieving ODBC Diagnostics - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - //************************************************************************************************** - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source successfully..\n"); - - } - else - { - printf("connection failed\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - - return 1; - } - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - printf("Disconnected from the Datasource\n"); - //************************************************************************************************** - // again sqlconnect - - - - - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - int rettype =ret; - - if(SQL_SUCCEEDED(ret)) - { - printf("Again Connected to the Data Source successfully..\n"); - - - } - else - { - printf("connection failed\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - - return 1; - } - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - //************************************************************************************************** - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - if(rettype !=0)return 1; - return 0; -} diff --git a/test/odbc/Connect/odbcconnect3.c b/test/odbc/Connect/odbcconnect3.c deleted file mode 100644 index 1d1bf454..00000000 --- a/test/odbc/Connect/odbcconnect3.c +++ /dev/null @@ -1,94 +0,0 @@ -/* close the connection and then call commit,it should fail. - - * AUTHOR : Jitendra Lenka - */ - -#include -#include -#include -#include -#include - - - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source successfully..\n"); - - - } - else - { - printf("error in connection\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - - return 1; - } - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - // call to commit - ret = SQLTransact(env,dbc,SQL_COMMIT); - - int rettype = ret; - - if(ret) - - printf("After disconnect,commit failed\n"); - else - printf("After disconenct, commit passed\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - if (rettype == 0) return 1; - return 0; -} diff --git a/test/odbc/Connect/odbcconnect4.c b/test/odbc/Connect/odbcconnect4.c deleted file mode 100644 index 4ee07f08..00000000 --- a/test/odbc/Connect/odbcconnect4.c +++ /dev/null @@ -1,99 +0,0 @@ -// close the connction and then call prepare, -// it should failed - -// AUTHOR : Jitendra Lenka. - -#include -#include -#include -#include -#include - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - } - else - { - printf("conenction failed\n"); - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[100]="CREATE TABLE EMP(EID INT,SALARY INT)"; - - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - //AFTER CLOSE THE CONNECTION ,CALL PREPARE - ret = SQLPrepare(stmt,table,SQL_NTS); - int rettype = ret; - if(ret!=SQL_SUCCESS && ret !=SQL_SUCCESS_WITH_INFO) - printf("After closing the connection, prepare failed \n"); - - - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - if(rettype == 0) - { - printf("Test script failed\n"); - return 1; - } - - return 0; -} diff --git a/test/odbc/Connect/odbcconnect5.c b/test/odbc/Connect/odbcconnect5.c deleted file mode 100644 index 737fdaf2..00000000 --- a/test/odbc/Connect/odbcconnect5.c +++ /dev/null @@ -1,99 +0,0 @@ -/* close the connection and call execute, it should fail. - - * AUTHOR : Jitendra Lenka - */ - -#include -#include -#include -#include -#include - - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - } - else - { - printf("connection failed\n"); - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[100]="CREATE TABLE EMP(EID INT,SALARY INT)"; - - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - //AFTER CLOSE THE CONNECTION ,CALL execute - - ret = SQLExecute(stmt); - int rettype = ret; - if(ret ) - printf("After closing the connection, Execution failed\n"); - - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - - if(rettype ==0)return 1; - - - return 0; -} diff --git a/test/odbc/Connect/odbcconnect6.c b/test/odbc/Connect/odbcconnect6.c deleted file mode 100644 index a3ec2aff..00000000 --- a/test/odbc/Connect/odbcconnect6.c +++ /dev/null @@ -1,186 +0,0 @@ -// close the connection and then call fetch,it should fail. - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* - - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source successfully..\n"); - - } - - - else - { - printf("error in connection\n"); - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 INT)"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nTABLE CREATED\n"); - //**************************************************************** - // insert tuple into table - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(100,200)",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - //***************************************************************** - // FETCHING ROWS FROM TABLE - int f1=1; - int f2=2; - ret = SQLPrepare(stmt,(unsigned char*)"SELECT * FROM T1",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,1,SQL_C_LONG,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,2,SQL_C_LONG,&f2,0,NULL); - checkrc(ret,__LINE__); - - int j,count=0; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - //close the connection - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - // after closing call fetch. - int rettype; - while(SQL_SUCCEEDED(ret =SQLFetch(stmt))) - { - - if(ret ) - printf("After disconnect, Fetch failed\n"); - else - count++; - } - rettype=ret; - printf("Number of rows are fetched=%d\n",count); - - - // ***************************************************************** - // again connect for drop the table - - - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - - if(SQL_SUCCEEDED(ret)) - { - printf("\nagain Connected to the Data Source successfully..\n"); - - } - - - else - { - printf("error in connection\n"); - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - - ret = SQLPrepare(stmt,(unsigned char*)"drop table T1;",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("Table dropped\n"); - - - //**************************************************************** - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - if(rettype == 0) return 1; - printf("After closing the connection, fetch does not work\n"); - return 0; -} diff --git a/test/odbc/Connect/odbcconnect7.c b/test/odbc/Connect/odbcconnect7.c deleted file mode 100644 index 4c6828de..00000000 --- a/test/odbc/Connect/odbcconnect7.c +++ /dev/null @@ -1,106 +0,0 @@ -// SQLConnect, again call SQLConnect. -// second SQLConnect should return "connection name in use". - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the Data source - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - } - - - else - { - printf("error in connection\n"); - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,env); - checkrc(ret,__LINE__); - return 1; - } - //********************************************************************* - //again call to driver connect - - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - int rettype = ret; - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - } - - - else - { - printf("Connection name in use\n"); - } - - //********************************************************************** - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - if(rettype ==0)return 1; - return 0; -} diff --git a/test/odbc/Makefile b/test/odbc/Makefile deleted file mode 100644 index 88876187..00000000 --- a/test/odbc/Makefile +++ /dev/null @@ -1,35 +0,0 @@ -OSNAME = $(shell uname -s) -MAKE=make - -ifeq ($(OSNAME), SunOS) -PlatForm=supported -else -ifeq ($(OSNAME), Linux) -PlatForm=supported -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - - -ifeq ($(PlatForm), supported) -all: buildall -endif - -buildall: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE); cd ..;\ - fi;\ - done - -clean: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE) clean; cd ..;\ - fi;\ - done diff --git a/test/odbc/NonSelectDML/Makefile b/test/odbc/NonSelectDML/Makefile deleted file mode 100644 index 5e3387d2..00000000 --- a/test/odbc/NonSelectDML/Makefile +++ /dev/null @@ -1,40 +0,0 @@ -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -O2 -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include - -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlodbc - -TARGETS = test001 - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -.c.o:.c - $(CPlus) $(CPlusFlags) $(INCL) -c -o $@ $< - -test001: nonselectdml1.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - - - -clean: - rm -f *.o $(TARGETS) - diff --git a/test/odbc/NonSelectDML/nonselectdml1.c b/test/odbc/NonSelectDML/nonselectdml1.c deleted file mode 100644 index 16099176..00000000 --- a/test/odbc/NonSelectDML/nonselectdml1.c +++ /dev/null @@ -1,234 +0,0 @@ -/* create table Ti with one integer field and one char field. insert some records into it. - delete from t1 where f1=10. - sqlrowcount() should return 1. - - delete from t1 where f1 > 900 - sqlrowcount shpuld return 100. - - insert one record with values(1001,'1000') - sqlrowcount should return 1. - - update T1 set f2='thousand' where f1<10. - sqlrowcount() should return 9 - - - AUTHOR : Jitendra Lenka - -*/ - - -#include -#include -#include -#include -#include -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - - SQLRETURN ret; - int f1=0; // f1 field - char f2[15]="jitendra";//f2 field - SQLINTEGER slen=SQL_NTS; - - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?,?)",SQL_NTS); - checkrc(ret,__LINE__); - - // BIND PARAMETER - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_LONG,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f2,0,&slen); - checkrc(ret,__LINE__); - - - - int i,count=0; - for(i=0;i<1000;i++) - { - f1++; - - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count++; - } - printf("Total row inserted=%d\n",count); - } -//*********************************************************************** - - - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - } - - - else - { - printf("error in connection\n"); - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - - return 1; - } - - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 char(30))"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nTABLE CREATED\n"); - //**************************************************************** - - // INSERT FUNCTION - InsertTest(env,dbc,stmt); - //***************************************************************** - // DELETE FROM T1; - printf("delete from T1 where F1=10\n"); - SQLCHAR delete1[50]="DELETE FROM T1 WHERE F1=10;"; - - ret = SQLPrepare(stmt,delete1,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - - - SQLINTEGER nor; - ret = SQLRowCount(stmt,&nor); - printf("sqlrowcount() returns=%d\n",nor); // nor should return 1. - if(nor!=1)return 1; - ret = SQLFreeStmt(stmt,SQL_RESET_PARAMS); - checkrc(ret,__LINE__); - //************************************************ - - printf("\ndelete from T1 where F1 > 900\n"); - ret = SQLPrepare(stmt,(unsigned char*)"DELETE FROM T1 WHERE F1 > 900",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - SQLINTEGER nor1; - ret = SQLRowCount(stmt,&nor1); - printf("sqlrowcount() returns=%d\n",nor1); - if(nor1!=100)return 1; - - ret = SQLFreeStmt(stmt,SQL_RESET_PARAMS); - checkrc(ret,__LINE__); - //************************************************************* - printf("\ninsert into T1 values(1001,'1000')\n"); - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(1001,'1000')",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - SQLINTEGER nor2; - ret = SQLRowCount(stmt,&nor2); - checkrc(ret,__LINE__); - - printf("sqlrowcount() returns=%d\n",nor2); - if(nor2!=1)return 1; - ret = SQLFreeStmt(stmt,SQL_RESET_PARAMS); - - //***************************************************** - printf("\nUPDATE T1 SET F2='THOUSAND' WHERE F1<10\n"); - ret = SQLPrepare(stmt,(unsigned char*)"UPDATE T1 SET F2='THOUSAND' WHERE F1<10",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - SQLINTEGER nor3; - ret = SQLRowCount(stmt,&nor3); - - checkrc(ret,__LINE__); - printf("sqlrowcount() returns=%d\n",nor3); - if(nor3!=9)return 1; - /*ret = SQLFreeStmt(stmt,SQL_RESET_PARAMS); - checkrc(ret,__LINE__);*/ - //*********************************************** - - //FetchTest(env,dbc,stmt); - - //**************************************************************** - //drop the table - ret = SQLPrepare(stmt,(unsigned char*)"drop table T1;",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("Table 'T1' dropped\n"); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 0; -} diff --git a/test/odbc/Parameters/Makefile b/test/odbc/Parameters/Makefile deleted file mode 100644 index fe5cf8f1..00000000 --- a/test/odbc/Parameters/Makefile +++ /dev/null @@ -1,45 +0,0 @@ -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -O2 -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include - -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlodbc - -TARGETS = test001 test002 test003 test004 - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -.c.o:.c - $(CPlus) $(CPlusFlags) $(INCL) -c -o $@ $< - -test001: parameter1.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - -test002:parameter2.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test003:parameter3.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test004:parameter4.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - -clean: - rm -f *.o $(TARGETS) - diff --git a/test/odbc/Parameters/exp.test002 b/test/odbc/Parameters/exp.test002 deleted file mode 100644 index 3e1f5574..00000000 --- a/test/odbc/Parameters/exp.test002 +++ /dev/null @@ -1,17 +0,0 @@ - -Connected to the Data Source.. - -TABLE CREATED -Total row inserted=10 -F1=11 F2=21 F3=praba F4=3.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=12 F2=22 F3=praba F4=4.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=13 F2=23 F3=praba F4=5.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=14 F2=24 F3=praba F4=6.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=15 F2=25 F3=praba F4=7.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=16 F2=26 F3=praba F4=8.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=17 F2=27 F3=praba F4=9.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=18 F2=28 F3=praba F4=10.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=19 F2=29 F3=praba F4=11.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=20 F2=30 F3=praba F4=12.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - Total row fetched=10 -Table 'T1' dropped successfully diff --git a/test/odbc/Parameters/exp.test004 b/test/odbc/Parameters/exp.test004 deleted file mode 100644 index b260e40d..00000000 --- a/test/odbc/Parameters/exp.test004 +++ /dev/null @@ -1,19 +0,0 @@ - -Connected to the datastring -Table 'T1' created -10 Rows Inserted -Number of parameters=7 -5 Rows updated -Fetching starts on table 't1' -F10=12000 TIMESTAMP=2009-12-31 9:35:55 DATE=2009-12-31 F5=15.900000 F4=9.500000 F3=Lakshya -F10=12000 TIMESTAMP=2009-12-31 9:35:55 DATE=2009-12-31 F5=15.900000 F4=9.500000 F3=Lakshya -F10=12000 TIMESTAMP=2009-12-31 9:35:55 DATE=2009-12-31 F5=15.900000 F4=9.500000 F3=Lakshya -F10=12000 TIMESTAMP=2009-12-31 9:35:55 DATE=2009-12-31 F5=15.900000 F4=9.500000 F3=Lakshya -F10=12000 TIMESTAMP=2009-12-31 9:35:55 DATE=2009-12-31 F5=15.900000 F4=9.500000 F3=Lakshya -F10=15000 TIMESTAMP=2008-3-18 5:22:10 DATE=2008-3-18 F5=10.500000 F4=2.500000 F3=jitendra -F10=15000 TIMESTAMP=2008-3-18 5:22:10 DATE=2008-3-18 F5=10.500000 F4=2.500000 F3=jitendra -F10=15000 TIMESTAMP=2008-3-18 5:22:10 DATE=2008-3-18 F5=10.500000 F4=2.500000 F3=jitendra -F10=15000 TIMESTAMP=2008-3-18 5:22:10 DATE=2008-3-18 F5=10.500000 F4=2.500000 F3=jitendra -F10=15000 TIMESTAMP=2008-3-18 5:22:10 DATE=2008-3-18 F5=10.500000 F4=2.500000 F3=jitendra -Total row fetched=10 -Table 'T1' Dropped successfully diff --git a/test/odbc/Parameters/parameter1.c b/test/odbc/Parameters/parameter1.c deleted file mode 100644 index df64caeb..00000000 --- a/test/odbc/Parameters/parameter1.c +++ /dev/null @@ -1,227 +0,0 @@ -/* CREATE TABLE "T1" WITH 10 FIELDS. - INSERT SOME TUPLES IN IT. - SQLNumParam() should return 10. - - AUTHOR : JITENDRA Lenka. -*/ - -#include -#include -#include -#include -#include -#include -//************************************************************************* -// ERROR CHECK FUNCTION -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -// FUNCTION FOR INSERTING ROWS IN IT. - -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - - int ret; - int f1=90; // f1 field - short int f2=20;//f2 field - char f3[50]= "jitendra"; - float f4 = 2.5; - float f5 = 10.50; - int f9 = 5; - long long f10 = 15000; - int result; - - SQLINTEGER slen = SQL_NTS; - //*********************************** - // STRUCTURE FOR DATE DATATYPE - SQL_DATE_STRUCT date; - char strDate[30]; - - date.year=2008; - date.month=03; - date.day=18; - // strcpy(strDate,"{d '2008-03-18'}"); - //******************************* - // STRUCTURE FOR TIME DATATYPE. - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //***************************** - // STRUCTURE FOR TIMESTAMP DATATYPE - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2008; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - timestamp.fraction = 764576; - //****************************** - // PREPARE THE STATEMENT. - - - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?);",SQL_NTS); - checkrc(ret,__LINE__); - - - /*SQLSMALLINT nop; - SQLNumParams(stmt,&nop); - - - - if(nop!=10)return 1; - printf("Number of parameter=%d\n",nop);*/ - - // BIND PARAMETER FOR ALL THE FIELD - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_SMALLINT,0,0,&f2,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&date,sizeof(date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_TYPE_TIME,SQL_TYPE_TIME,196,0,&time,sizeof(time),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,8,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,×tamp,sizeof(timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,9,SQL_PARAM_INPUT,SQL_C_TINYINT,SQL_TINYINT,0,0,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,10,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10,0,NULL); - checkrc(ret,__LINE__); - - int i,count=0; - // EXECUTE THE STATEMENT - for(i=0;i<20;i++) - { - f1++; - f2++; - f4++; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count++; - } - printf("Total row inserted=%d\n",count); - } -//*********************************************************************** - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - - } - else - { - printf("error in conenction\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - //***************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 TINYINT,F10 BIGINT);"; - - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nTABLE CREATED\n"); - //*************************** - InsertTest(env,dbc,stmt); - printf("I am here\n"); - // FetchTest(env,dbc,stmt); - - //************************************************** - SQLCHAR drop[100]="DROP TABLE T1"; - ret = SQLPrepare(stmt,drop,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - if(ret!=SQL_SUCCESS && ret !=SQL_SUCCESS_WITH_INFO) - { - printf("Statement failed\n"); - return 1; - } - else - printf("Table 'T1' dropped successfully\n"); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 0; -} diff --git a/test/odbc/Parameters/parameter2.c b/test/odbc/Parameters/parameter2.c deleted file mode 100644 index 8183d92e..00000000 --- a/test/odbc/Parameters/parameter2.c +++ /dev/null @@ -1,345 +0,0 @@ -// CREATE TABLE "T1" WITH 10 FIELDS. -// INSERT SOME TUPLES IN IT. -// SELECT TUPLES WITH WHERE CLAUSE - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - -//************************************************************************* -// ERROR CHECK FUNCTION -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - - } -} - -//************************************************************************* -// FUNCTION FOR INSERTING ROWS IN IT. -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - - int ret; - int f1=90; // f1 field - short int f2=20;//f2 field - char f3[50]= "Praba"; - float f4 = 2.5; - float f5 = 10.50; - int f9 = 5; - long long f10 = 15000; - int result; - - SQLINTEGER slen = SQL_NTS; - //*********************************** - // STRUCTURE FIOR DATE DATATYPE - SQL_DATE_STRUCT date; - char strDate[30]; - - date.year=2008; - date.month=03; - date.day=18; - // strcpy(strDate,"{d '2008-03-18'}"); - //******************************* - // STRUCTURE FOR TIME DATATYPE. - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //***************************** - // STRUCTURE FOR TIMESTAMP DATATYPE - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2008; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - timestamp.fraction = 764576; - //****************************** - // PREPARE THE STATEMENT. - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?)",SQL_NTS); - checkrc(ret,__LINE__); - - // BIND PARAMETER FOR ALL THE FIELD - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_SMALLINT,0,0,&f2,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_REAL,0,0,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&date,sizeof(date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_TYPE_TIME,SQL_TYPE_TIME,196,0,&time,sizeof(time),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,8,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,×tamp,sizeof(timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,9,SQL_PARAM_INPUT,SQL_C_TINYINT,SQL_TINYINT,0,0,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,10,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10,0,NULL); - checkrc(ret,__LINE__); - - int i,count=0; - // EXECUTE THE STATEMENT - for(i=0;i<10;i++) - { - f1++; - f2++; - f4++; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count++; - } - printf("Total row inserted=%d\n",count); - } -//*********************************************************************** -// FETCH ROWS FROM THE TABLE "T1"......select * from T1; -int FetchTest(SQLHANDLE env, SQLHANDLE dbc, SQLHANDLE stmt) -{ - - int ret; - int f1=10; // f1 field - short int f2=20;//f2 field - char f3[50]= "praba"; - float f4 = 2.5; - float f5 = 10.50; - int f9=5; - long long f10=15000; - SQLINTEGER slen = SQL_NTS; - SQL_DATE_STRUCT date,f6Date; - SQL_TIME_STRUCT time, f7Time; - SQL_TIMESTAMP_STRUCT timestamp, f8Timestamp; - - date.year=2008; - date.month=03; - date.day=18; - - time.hour=5; - time.minute=22; - time.second=10; - - timestamp.year=2008; - timestamp.month=03; - timestamp.day=18; - timestamp.hour=5; - timestamp.minute = 22; - timestamp.second = 10; - timestamp.fraction = 764576; - - int f1temp,f2temp; - char f3temp[20]; - float f4temp, f5temp; - - int f9temp; - long long f10temp; - - ret = SQLPrepare(stmt,(unsigned char*)"SELECT * FROM T1 WHERE F1=? AND F2=? AND F3=? AND F4=? AND F5=? AND F6=? AND F7=? AND F8=? AND F9=? AND F10=?",SQL_NTS); - checkrc(ret,__LINE__); - - //ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SMALL,SQL_SMALL,0,0,) - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_INTEGER,0,0,&f2temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3temp,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_REAL,0,0,&f5temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&f6Date,sizeof(f6Date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_TYPE_TIME,SQL_TYPE_TIME,196,0,&f7Time,sizeof(f7Time),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,8,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,&f8Timestamp,sizeof(f8Timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,9,SQL_PARAM_INPUT,SQL_C_TINYINT,SQL_TINYINT,0,0,&f9temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,10,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10temp,0,NULL); - checkrc(ret,__LINE__); - //******************************************************************************************************* - - ret = SQLBindCol(stmt,1,SQL_C_SLONG,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,2,SQL_C_SSHORT,&f2,0,NULL); - checkrc(ret,__LINE__); - - - ret = SQLBindCol(stmt,3,SQL_C_CHAR,f3,sizeof(f3),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,4,SQL_C_FLOAT,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,5,SQL_C_FLOAT,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,6,SQL_C_TYPE_DATE,&date,sizeof(date),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,7,SQL_C_TYPE_TIME,&time,sizeof(time),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,8,SQL_C_TYPE_TIMESTAMP,×tamp,sizeof(timestamp),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,9,SQL_C_TINYINT,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,10,SQL_C_SBIGINT,&f10,0,NULL); - checkrc(ret,__LINE__); - - int j, count=0; - - - - f6Date=date; - f7Time=time; - f8Timestamp=timestamp; - for(j=0;j<10;j++) - { - f1temp=f1++; - f2temp=f2++; - strcpy(f3temp,"praba"); - f4temp=f4++; - f5temp=f5; - f9temp=f9; - f10temp=f10; - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - ret = SQLFetch(stmt); - ret = SQLCloseCursor(stmt); - checkrc(ret,__LINE__); - count++; - - printf("F1=%d\tF2=%d\tF3=%s\tF4=%f\tF5=%f\tDATE=%d/%d/%d\tTIME=%d-%d-%d\tTIMESTAMP=%d/%d/%d %d-%d-%d\tF9=%d\tF10=%lld\n ",f1,f2,f3,f4,f5,date.year,date.month,date.day,time.hour,time.minute,time.second,timestamp.year,timestamp.month,timestamp.day,timestamp.hour,timestamp.minute,timestamp.second,f9,f10); - - - } - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - - printf("Total row fetched=%d\n",count); -} - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - } - else - { - printf("error in connection\n"); - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 TINYINT,F10 BIGINT)"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nTABLE CREATED\n"); - //***************************** - InsertTest(env,dbc,stmt); - FetchTest(env,dbc,stmt); - - //**************************************************************** - SQLCHAR drop[100]="DROP TABLE T1"; - ret = SQLPrepare(stmt,drop,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("Table 'T1' dropped successfully\n"); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 0; -} diff --git a/test/odbc/Parameters/parameter3.c b/test/odbc/Parameters/parameter3.c deleted file mode 100644 index f1e7a8fa..00000000 --- a/test/odbc/Parameters/parameter3.c +++ /dev/null @@ -1,320 +0,0 @@ -// CREATE TABLE "T1" WITH 10 FIELDS. -// INSERT SOME TUPLES IN IT. -// DELETE TUPLES WITH WHERE CLAUSE. - -// Author : Jitendra Lenka - -#include -#include -#include -#include -#include - -//************************************************************************* -// ERROR CHECK FUNCTION -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -// FUNCTION FOR INSERTING ROWS IN IT. -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - - int ret; - int f1=90; // f1 field - short int f2=20;//f2 field - char f3[50]= "jitendra"; - float f4 = 2.5; - float f5 = 10.50; - int f9 = 5; - long long f10 = 15000; - int result; - - SQLINTEGER slen = SQL_NTS; - //*********************************** - // STRUCTURE FIOR DATE DATATYPE - SQL_DATE_STRUCT date; - char strDate[30]; - - date.year=2008; - date.month=03; - date.day=18; - // strcpy(strDate,"{d '2008-03-18'}"); - //******************************* - // STRUCTURE FOR TIME DATATYPE. - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //***************************** - // STRUCTURE FOR TIMESTAMP DATATYPE - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2008; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - timestamp.fraction = 764576; - //****************************** - // PREPARE THE STATEMENT. - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?)",SQL_NTS); - checkrc(ret,__LINE__); - - // BIND PARAMETER FOR ALL THE FIELD - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SHORT,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_SMALLINT,0,0,&f2,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_REAL,0,0,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&date,sizeof(date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_TYPE_TIME,SQL_TYPE_TIME,196,0,&time,sizeof(time),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,8,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,×tamp,sizeof(timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,9,SQL_PARAM_INPUT,SQL_C_TINYINT,SQL_TINYINT,0,0,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,10,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10,0,NULL); - checkrc(ret,__LINE__); - - int i,count=0; - // EXECUTE THE STATEMENT - for(i=0;i<20;i++) - { - f1++; - f2++; - f4++; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count++; - } - printf("Total row inserted=%d\n",count); - } -//*********************************************************************** -// FETCH ROWS FROM THE TABLE "T1"......select * from T1; -int DeleteTest(SQLHANDLE env, SQLHANDLE dbc, SQLHANDLE stmt) -{ - - int ret; - int f1=10; // f1 field - short int f2=20;//f2 field - char f3[50]= "jitendra"; - float f4 = 2.5; - float f5 = 10.50; - - int f9 = 5; - long long f10 = 15000; - int result; - - SQLINTEGER slen=SQL_NTS; - - char strDate[20]; - char strTime[20]; - char strTimestamp[30]; - - SQL_DATE_STRUCT date; - - - date.year=2008; - date.month=03; - date.day=18; - - //********************************************** - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //********************************************* - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2008; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - timestamp.fraction = 764576; - - int f1temp,f2temp; - char f3temp[20]; - float f4temp, f5temp; - SQL_DATE_STRUCT f6Date; - SQL_TIME_STRUCT f7Time; - SQL_TIMESTAMP_STRUCT f8Timestamp; - int f9temp; - long long f10temp; - - ret = SQLPrepare(stmt,(unsigned char*)"DELETE FROM T1 WHERE F1=? AND F2=? AND F3=? AND F4=? AND F5=? AND F6=? AND F7=? AND F8=? AND F9=? AND F10=?",SQL_NTS); - checkrc(ret,__LINE__); - - //ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SMALL,SQL_SMALL,0,0,) - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_INTEGER,0,0,&f2temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3temp,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_REAL,0,0,&f5temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&f6Date,sizeof(f6Date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_TYPE_TIME,SQL_TYPE_TIME,196,0,&f7Time,sizeof(f7Time),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,8,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,&f8Timestamp,sizeof(f8Timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,9,SQL_PARAM_INPUT,SQL_C_TINYINT,SQL_TINYINT,0,0,&f9temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,10,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10temp,0,NULL); - checkrc(ret,__LINE__); - //******************************************************************************************************* - - int j, count=0; - - - - f6Date=date; - f7Time=time; - f8Timestamp=timestamp; - for(j=0;j<20;j++) - { - f1temp=f1++; - f2temp=f2++; - strcpy(f3temp,"jitendra"); - f4temp=f4++; - f5temp=f5; - f9temp=f9; - f10temp=f10; - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - count++; - } - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - - printf("Total row deleted=%d\n",count); -} - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - } - else - { - printf("error in connection\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 TINYINT,F10 BIGINT)"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nTABLE CREATED\n"); - //***************************** - InsertTest(env,dbc,stmt); - DeleteTest(env,dbc,stmt); - - //**************************************************************** - SQLCHAR drop[100]="DROP TABLE T1"; - ret = SQLPrepare(stmt,drop,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - if(ret!=SQL_SUCCESS && ret !=SQL_SUCCESS_WITH_INFO) - printf("Statement failed\n"); - else - printf("Table 'T1' dropped successfully\n"); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 0; -} diff --git a/test/odbc/Parameters/parameter4.c b/test/odbc/Parameters/parameter4.c deleted file mode 100644 index d18cd58b..00000000 --- a/test/odbc/Parameters/parameter4.c +++ /dev/null @@ -1,342 +0,0 @@ -// create table T1 with 10 fields.insert some record. -// update some fields with where clause(f2=?) - -// Author : Jitendra Lenka - - -#include -#include -#include -#include -#include - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - - } -} - -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - int ret; - int f1=90; - short int f2=20; - char f3[20]="jitendra"; - float f4=2.5; - float f5=10.50; - int f9=5; - long long f10=15000; - int result; - - SQLINTEGER slen = SQL_NTS; - - SQL_DATE_STRUCT date; - date.year=2008; - date.month=03; - date.day=18; - - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second =10; - - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2008; - timestamp.month = 03; - timestamp.day = 18; - - timestamp.hour = 5; - timestamp.minute =22; - timestamp.second = 10; - timestamp.fraction = 764576; - - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?)",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_SMALLINT,0,0,&f2,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&date,sizeof(date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_TYPE_TIME,SQL_TYPE_TIME,196,0,&time,sizeof(time),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,8,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,×tamp,sizeof(timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,9,SQL_PARAM_INPUT,SQL_C_TINYINT,SQL_TINYINT,0,0,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,10,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10,0,NULL); - checkrc(ret,__LINE__); - - int count=0,i; - for(i=0;i<10;i++) - { - f1++; - f2++; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - - count++; - } - - printf("%d Rows Inserted\n",count); -} - -//******************************************************************* -int UpdateTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - SQLRETURN ret; - SQLINTEGER slen; - short int f2temp; - char f3temp[30]; - float f4temp; - float f5temp; - long long f10temp; - SQL_DATE_STRUCT f6Date; - SQL_TIMESTAMP_STRUCT f8Timestamp; - - - - - ret = SQLPrepare(stmt,(unsigned char*)"UPDATE T1 SET F10=? ,F8=?,F6=?,F5=?,F4=?,F3=? WHERE F2=? ",SQL_NTS); - checkrc(ret,__LINE__); - - SQLSMALLINT nop; - SQLNumParams(stmt,&nop); - printf("Number of parameters=%d\n",nop); - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,&f8Timestamp,sizeof(f8Timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&f6Date,sizeof(f6Date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_REAL,0,0,&f5temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4temp,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3temp,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_INTEGER,0,0,&f2temp,0,NULL); - checkrc(ret,__LINE__); - //************************************************************************************************** - - f2temp=20;int count1=0; - for(int i=0;i<5;i++) - { - f2temp++; - strcpy(f3temp,"Lakshya"); - f4temp=9.5; - f5temp=15.90; - - f6Date.year=2009; - f6Date.month=12; - f6Date.day=31; - - f8Timestamp.year=2009; - f8Timestamp.month=12; - f8Timestamp.day=31; - f8Timestamp.hour=9; - f8Timestamp.minute=35; - f8Timestamp.second=55; - f8Timestamp.fraction=1234; - f10temp=12000; - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count1++; - } - printf("%d Rows updated\n",count1); - -} -int FetchTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - SQLRETURN ret; - long long int f10=12000; - - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2007; - timestamp.month = 3; - timestamp.day = 15; - - timestamp.hour = 12; - timestamp.minute = 15; - timestamp.second = 30; - - SQL_DATE_STRUCT date; - date.year = 2007; - date.month = 3; - date.day = 10; - - float f5=2.4; - float f4=10.3; - char f3[10]="LAKSHYA"; - - ret = SQLPrepare(stmt,(unsigned char*)"SELECT F10,F8,F6,F5,F4,F3 FROM T1",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,1,SQL_C_SBIGINT,&f10,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,2,SQL_C_TYPE_TIMESTAMP,×tamp,sizeof(timestamp),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,3,SQL_C_TYPE_DATE,&date,sizeof(date),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,4,SQL_C_FLOAT,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,5,SQL_C_FLOAT,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,6,SQL_C_CHAR,f3,sizeof(f3),NULL); - checkrc(ret,__LINE__); - - int count=0; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("Fetching starts on table 't1'\n"); - while(SQL_SUCCEEDED(ret=SQLFetch(stmt))) - { - - printf("F10=%lld\tTIMESTAMP=%d-%d-%d %d:%d:%d\tDATE=%d-%d-%d\tF5=%f\tF4=%f\tF3=%s\n",f10,timestamp.year,timestamp.month,timestamp.day,timestamp.hour,timestamp.minute,timestamp.second,date.year,date.month,date.day,f5,f4,f3); - count++; - } - - ret = SQLCloseCursor(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - - printf("Total row fetched=%d\n",count); -} - - - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - ret = SQLAllocHandle(SQL_HANDLE_ENV , SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void *)SQL_OV_ODBC3,0); - - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - checkrc(ret,__LINE__); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the datastring\n"); - - } - - else - { - printf("error in connection\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 TINYINT,F10 BIGINT)"; - - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - printf("Table 'T1' created\n"); - //********************************** - InsertTest(env,dbc,stmt); - UpdateTest(env,dbc,stmt); - FetchTest(env,dbc,stmt); - //********************************* - SQLCHAR drop[30]="DROP TABLE T1"; - - ret = SQLPrepare(stmt,drop,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - if(ret!=SQL_SUCCESS && ret!=SQL_SUCCESS_WITH_INFO) - printf("Statement failed\n"); - else - printf("Table 'T1' Dropped successfully\n"); - - - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - - return 0; -} - - diff --git a/test/odbc/Parameters/parameter5.c b/test/odbc/Parameters/parameter5.c deleted file mode 100644 index 39b477d1..00000000 --- a/test/odbc/Parameters/parameter5.c +++ /dev/null @@ -1,234 +0,0 @@ -/* CREATE TABLE "T1" WITH 10 FIELDS. - INSERT SOME TUPLES IN IT. - SQLNumParam() should return 10. - - AUTHOR : JITENDRA Lenka. -*/ - -#include -#include -#include -#include -#include -#include -//************************************************************************* -// ERROR CHECK FUNCTION -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -// FUNCTION FOR INSERTING ROWS IN IT. - -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - - int ret; - int f1=90; // f1 field - short int f2=20;//f2 field - char f3[50]= "jitendra"; - float f4 = 2.5; - float f5 = 10.50; - int f9 = 5; - long long f10 = 15000; - int result; - - SQLINTEGER slen = SQL_NTS; - //*********************************** - // STRUCTURE FOR DATE DATATYPE - SQL_DATE_STRUCT date; - char strDate[30]; - - date.year=2008; - date.month=03; - date.day=18; - // strcpy(strDate,"{d '2008-03-18'}"); - //******************************* - // STRUCTURE FOR TIME DATATYPE. - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //***************************** - // STRUCTURE FOR TIMESTAMP DATATYPE - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2008; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - timestamp.fraction = 764576; - //****************************** - // PREPARE THE STATEMENT. - - - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?);",SQL_NTS); - checkrc(ret,__LINE__); - - - SQLSMALLINT nop; - SQLNumParams(stmt,&nop); - - - - if(nop!=1)return 1; - printf("Number of parameter=%d\n",nop); - - // BIND PARAMETER FOR ALL THE FIELD - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - /* ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_SMALLINT,0,0,&f2,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&date,sizeof(date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_TYPE_TIME,SQL_TYPE_TIME,196,0,&time,sizeof(time),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,8,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,×tamp,sizeof(timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,9,SQL_PARAM_INPUT,SQL_C_TINYINT,SQL_TINYINT,0,0,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,10,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10,0,NULL); - checkrc(ret,__LINE__);*/ - - int i,count=0; - // EXECUTE THE STATEMENT - for(i=0;i<20;i++) - { - f1++; - f2++; - f4++; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count++; - } - printf("Total row inserted=%d\n",count); - } -//*********************************************************************** - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - - } - else - { - printf("error in conenction\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - //***************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - -// SQLCHAR table[200]= - //"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 TINYINT,F10 BIGINT);"; - - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT);"; - - - - - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nTABLE CREATED\n"); - //*************************** - InsertTest(env,dbc,stmt); - - // FetchTest(env,dbc,stmt); - - //************************************************** - SQLCHAR drop[100]="DROP TABLE T1"; - ret = SQLPrepare(stmt,drop,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - if(ret!=SQL_SUCCESS && ret !=SQL_SUCCESS_WITH_INFO) - { - printf("Statement failed\n"); - return 1; - } - else - printf("Table 'T1' dropped successfully\n"); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 0; -} diff --git a/test/odbc/Select/Makefile b/test/odbc/Select/Makefile deleted file mode 100644 index 60ff97d2..00000000 --- a/test/odbc/Select/Makefile +++ /dev/null @@ -1,53 +0,0 @@ -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -O2 -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include - -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlodbc - -TARGETS = test001 test002 test003 test004 test005 test006 test007 test008 - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -.c.o:.c - $(CPlus) $(CPlusFlags) $(INCL) -c -o $@ $< - -test001: odbcselect1.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - -test002:odbcselect2.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test003:odbcselect3.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test004:odbcselect4.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test005:odbcselect5.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test006:odbcselect6.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test007:odbcselect7.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test008:odbcselect8.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - -clean: - rm -f *.o $(TARGETS) - diff --git a/test/odbc/Select/exp.test001 b/test/odbc/Select/exp.test001 deleted file mode 100644 index 299ceb7a..00000000 --- a/test/odbc/Select/exp.test001 +++ /dev/null @@ -1,18 +0,0 @@ - -Connected to the Data Source SUCCESSFULLY.. - -TABLE CREATED -Total row inserted=10 -Fetching starts on table T1 : -F1=51 F2=1 F3=Praba F4=3.500000 F5=10.500000 DATE=2007/3/19 TIME=5-22-10 TIMESTAMP=2007/3/18 5-22-10 F9=5 F10=15000 - F1=52 F2=2 F3=Praba F4=4.500000 F5=10.500000 DATE=2007/4/20 TIME=5-22-10 TIMESTAMP=2007/3/18 5-22-10 F9=5 F10=15000 - F1=53 F2=3 F3=Praba F4=5.500000 F5=10.500000 DATE=2007/5/21 TIME=5-22-10 TIMESTAMP=2007/3/18 5-22-10 F9=5 F10=15000 - F1=54 F2=4 F3=Praba F4=6.500000 F5=10.500000 DATE=2007/6/22 TIME=5-22-10 TIMESTAMP=2007/3/18 5-22-10 F9=5 F10=15000 - F1=55 F2=5 F3=Praba F4=7.500000 F5=10.500000 DATE=2007/7/23 TIME=5-22-10 TIMESTAMP=2007/3/18 5-22-10 F9=5 F10=15000 - F1=56 F2=6 F3=Praba F4=8.500000 F5=10.500000 DATE=2007/8/24 TIME=5-22-10 TIMESTAMP=2007/3/18 5-22-10 F9=5 F10=15000 - F1=57 F2=7 F3=Praba F4=9.500000 F5=10.500000 DATE=2007/9/25 TIME=5-22-10 TIMESTAMP=2007/3/18 5-22-10 F9=5 F10=15000 - F1=58 F2=8 F3=Praba F4=10.500000 F5=10.500000 DATE=2007/10/26 TIME=5-22-10 TIMESTAMP=2007/3/18 5-22-10 F9=5 F10=15000 - F1=59 F2=9 F3=Praba F4=11.500000 F5=10.500000 DATE=2007/11/27 TIME=5-22-10 TIMESTAMP=2007/3/18 5-22-10 F9=5 F10=15000 - F1=60 F2=10 F3=Praba F4=12.500000 F5=10.500000 DATE=2007/12/28 TIME=5-22-10 TIMESTAMP=2007/3/18 5-22-10 F9=5 F10=15000 - Total row fetched=10 -Table 'T1' dropped successfully diff --git a/test/odbc/Select/exp.test004 b/test/odbc/Select/exp.test004 deleted file mode 100644 index e2d74788..00000000 --- a/test/odbc/Select/exp.test004 +++ /dev/null @@ -1,14 +0,0 @@ - -Connected to the Data Source.. - -TABLE CREATED -Total row inserted=10 -SQLNumResultCols() returns=5 -SELECT F8,F10,F2,F6,F3 FROM T1 WHERE F1=100 : -F1=100 F2=21 F3=Praba F4=2.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=100 F2=22 F3=Praba F4=2.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=100 F2=23 F3=Praba F4=2.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=100 F2=24 F3=Praba F4=2.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - F1=100 F2=25 F3=Praba F4=2.500000 F5=10.500000 DATE=2008/3/18 TIME=5-22-10 TIMESTAMP=2008/3/18 5-22-10 F9=5 F10=15000 - Total row fetched=5 -Table dropped successfully diff --git a/test/odbc/Select/odbcselect1.c b/test/odbc/Select/odbcselect1.c deleted file mode 100644 index ae05d286..00000000 --- a/test/odbc/Select/odbcselect1.c +++ /dev/null @@ -1,312 +0,0 @@ -// CREATE TABLE "T1" WITH 10 FIELDS. -// INSERT SOME TUPLES IN IT. AND FETCH ALL THE TUPLES. - -// Author: jitendra Lenka - - -#include -#include -#include -#include -#include - - - -//************************************************************************* -// ERROR CHECK FUNCTION -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -// FUNCTION FOR INSERTING ROWS IN IT. -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - - int ret; - int f1=50; // f1 field - short int f2=0;//f2 field - char f3[50]= "Praba"; - float f4 = 2.5; - float f5 = 10.50; - int f9 = 5; - long long f10 = 15000; - int result; - - SQLINTEGER slen = SQL_NTS; - //*********************************** - // STRUCTURE FIOR DATE DATATYPE - SQL_DATE_STRUCT date; - - - date.year=2007; - date.month=03; - date.day=18; - // strcpy(strDate,"{d '2008-03-18'}"); - //******************************* - // STRUCTURE FOR TIME DATATYPE. - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //***************************** - // STRUCTURE FOR TIMESTAMP DATATYPE - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2007; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - - //****************************** - // PREPARE THE STATEMENT. - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?)",SQL_NTS); - checkrc(ret,__LINE__); - - // BIND PARAMETER FOR ALL THE FIELD - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_SMALLINT,0,0,&f2,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_REAL,0,0,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&date,sizeof(date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_TYPE_TIME,SQL_TYPE_TIME,196,0,&time,sizeof(time),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,8,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,×tamp,sizeof(timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,9,SQL_PARAM_INPUT,SQL_C_TINYINT,SQL_TINYINT,0,0,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,10,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10,0,NULL); - checkrc(ret,__LINE__); - - int i,count=0; - // EXECUTE THE STATEMENT - for(i=0;i<10;i++) - { - f1++; - f2++; - f4++; - // date.month = date.month+1; - date.day = date.day+1; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - date.month = date.month+1; - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count++; - } - printf("Total row inserted=%d\n",count); - } -//*********************************************************************** -// FETCH ROWS FROM THE TABLE "T1"......select * from T1; -int FetchTest(SQLHANDLE env, SQLHANDLE dbc, SQLHANDLE stmt) -{ - - int ret; - int f1=10; // f1 field - short int f2=20;//f2 field - char f3[50]= "jitendra"; - float f4 = 2.5; - float f5 = 10.50; - int f9 = 5; - long long f10 = 15000; - int result; - - - SQL_DATE_STRUCT date; - char strDate[30]; - - date.year=2007; - date.month=03; - date.day=18; - // strcpy(strDate,"{d '2008-03-18'}"); - //********************************************** - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //********************************************* - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2007; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - - - ret = SQLPrepare(stmt,(unsigned char*)"SELECT * FROM T1",SQL_NTS); - checkrc(ret,__LINE__); - - //ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SMALL,SQL_SMALL,0,0,) - ret = SQLBindCol(stmt,1,SQL_C_SLONG,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,2,SQL_C_SSHORT,&f2,0,NULL); - checkrc(ret,__LINE__); - - - ret = SQLBindCol(stmt,3,SQL_C_CHAR,f3,sizeof(f3),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,4,SQL_C_FLOAT,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,5,SQL_C_FLOAT,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,6,SQL_C_TYPE_DATE,&date,sizeof(date),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,7,SQL_C_TYPE_TIME,&time,sizeof(time),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,8,SQL_C_TYPE_TIMESTAMP,×tamp,sizeof(timestamp),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,9,SQL_C_TINYINT,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,10,SQL_C_SBIGINT,&f10,0,NULL); - checkrc(ret,__LINE__); - - int j, count=0; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("Fetching starts on table T1 :\n"); - - while(SQL_SUCCEEDED(ret = SQLFetch(stmt))) - { - printf("F1=%d\tF2=%d\tF3=%s\tF4=%f\tF5=%f\tDATE=%d/%d/%d\tTIME=%d-%d-%d\tTIMESTAMP=%d/%d/%d %d-%d-%d\tF9=%d\tF10=%lld\n ",f1,f2,f3,f4,f5,date.year,date.month,date.day,time.hour,time.minute,time.second,timestamp.year,timestamp.month,timestamp.day,timestamp.hour,timestamp.minute,timestamp.second,f9,f10); - - - count++; - - } - - - - ret = SQLCloseCursor(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - - printf("Total row fetched=%d\n",count); -} - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - ret = SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - checkrc(ret,__LINE__); - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source SUCCESSFULLY..\n"); - - - } - else - { - printf("error in connection\n"); - return 1; - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - - } - - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 TINYINT,F10 BIGINT)"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nTABLE CREATED\n"); - //***************************** - InsertTest(env,dbc,stmt); - FetchTest(env,dbc,stmt); - - //**************************************************************** - SQLCHAR drop[100]="DROP TABLE T1"; - ret = SQLPrepare(stmt,drop,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - if(ret!=SQL_SUCCESS && ret !=SQL_SUCCESS_WITH_INFO) - { - printf("Statement failed\n"); - return 2; - } - else - printf("Table 'T1' dropped successfully\n"); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 0; -} diff --git a/test/odbc/Select/odbcselect2.c b/test/odbc/Select/odbcselect2.c deleted file mode 100644 index 10b0584a..00000000 --- a/test/odbc/Select/odbcselect2.c +++ /dev/null @@ -1,311 +0,0 @@ -// CREATE TABLE T1 WITH 10 TUPLES. -// USE SQLNumRestltCols() to get the number of fields in prepare statements. - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - - - - -//************************************ -// function for check the error. - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} -//************************************** - -//this function is meant for insert rows into table T1. -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - int ret; - int f1=90; // f1 field - short int f2=20;//f2 field - char f3[50]= "jitendra"; - float f4 = 2.5; - float f5 = 10.50; - int f9 = 5; - long long f10 = 15000; - int result; - - SQLINTEGER slen = SQL_NTS; - //*********************************** - SQL_DATE_STRUCT date; - - date.year=2007; - date.month=03; - date.day=18; - // strcpy(strDate,"{d '2008-03-18'}"); - //************************************* - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //************************************* - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2007; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - - //*************************************** - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?)",SQL_NTS); - checkrc(ret,__LINE__); - - // BIND PARAMETER - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_SMALLINT,0,0,&f2,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_REAL,0,0,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&date,sizeof(date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_TYPE_TIME,SQL_TYPE_TIME,196,0,&time,sizeof(time),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,8,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,×tamp,sizeof(timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,9,SQL_PARAM_INPUT,SQL_C_TINYINT,SQL_TINYINT,0,0,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,10,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10,0,NULL); - checkrc(ret,__LINE__); - - int i,count=0; - for(i=0;i<10;i++) - { - f1++; - f2++; - f4++; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count++; - } - printf("Total row inserted=%d\n",count); - } -//*********************************************************************** -// FETCH ROWS FROM THE TABLE "T1"......select * from T1; -int FetchTest(SQLHANDLE env, SQLHANDLE dbc, SQLHANDLE stmt) -{ - int ret; - int f1=10; // f1 field - short int f2=20;//f2 field - char f3[50]= "jitendra"; - float f4 = 2.5; - float f5 = 10.50; - char f6date[15]= "2008-01-12";// f6 field.DATE Field. yyyy-mm-dd - char f7time[20] = "11:30:55";// hh:mm:ss - char f8timestamp[50]= "2008-01-12 11:30:55"; //YYYY-MM-DD .....HH:MM:SS - int f9 = 5; - long long f10 = 15000; - int result; - - - SQL_DATE_STRUCT date; - //char strDate[30]; - date.year=2008; - date.month=03; - date.day=18; - //strcpy(strDate,"{d '2008-03-18'}"); - //********************************************** - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //********************************************* - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2008; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - - - ret = SQLPrepare(stmt,(unsigned char*)"SELECT * FROM T1 WHERE F1=100",SQL_NTS); - checkrc(ret,__LINE__); - - // SQLNumResultCols() - SQLSMALLINT noc; - SQLNumResultCols(stmt,&noc); - printf("SQLNumResultCols() returns=%d\n",noc); - if(noc!=10) return 1; - - - - ret = SQLBindCol(stmt,1,SQL_C_SLONG,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,2,SQL_C_SSHORT,&f2,0,NULL); - checkrc(ret,__LINE__); - - - ret = SQLBindCol(stmt,3,SQL_C_CHAR,f3,sizeof(f3),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,4,SQL_C_FLOAT,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,5,SQL_C_FLOAT,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,6,SQL_C_TYPE_DATE,&date,sizeof(date),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,7,SQL_C_TYPE_TIME,&time,sizeof(time),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,8,SQL_C_TYPE_TIMESTAMP,×tamp,sizeof(timestamp),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,9,SQL_C_TINYINT,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,10,SQL_C_SBIGINT,&f10,0,NULL); - checkrc(ret,__LINE__); - - int j, count=0; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nSELECT * FROM T1 WHERE F1=100 :\n"); - - while(SQL_SUCCEEDED(ret = SQLFetch(stmt))) - { - - printf("F1=%d F2=%d F3=%s F4=%f F5=%f DATE=%d/%d/%d TIME=%d-%d-%d TIMESTAMP=%d/%d/%d %d-%d-%d F9=%d F10=%lld\n ",f1,f2,f3,f4,f5,date.year,date.month,date.day,time.hour,time.minute,time.second,timestamp.year,timestamp.month,timestamp.day,timestamp.hour,timestamp.minute,timestamp.second,f9,f10); - - count++; - - } - - - ret = SQLCloseCursor(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - - printf("Total row fetched=%d\n",count); -} -//******************************************************************* - - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - } - else - { - printf("error in connection\n"); - - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 TINYINT,F10 BIGINT)"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nTABLE CREATED\n"); - //**************************************************************** - - InsertTest(env,dbc,stmt); - FetchTest(env,dbc,stmt); - - //**************************************************************** - SQLCHAR drop[100]="DROP TABLE T1"; - ret = SQLPrepare(stmt,drop,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - if(ret!=SQL_SUCCESS && SQL_SUCCESS_WITH_INFO) - printf("Statement failed\n"); - else - printf("Table 'T1' dropped successfully\n"); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 0; -} diff --git a/test/odbc/Select/odbcselect3.c b/test/odbc/Select/odbcselect3.c deleted file mode 100644 index c41f9737..00000000 --- a/test/odbc/Select/odbcselect3.c +++ /dev/null @@ -1,292 +0,0 @@ -// create table t1 with 10 fileds an d insert some rows in it. -// fetch for some selected field where f1=100 - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - - -//***************************************** - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//******************************************* -// insert some rows in it. -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - - int ret; - int f1=90; // f1 field - short int f2=20;//f2 field - char f3[50]= "jitendra"; - float f4 = 2.5; - float f5 = 10.50; - char f6date[15]= "2008-01-12";// f6 field.DATE Field. yyyy-mm-dd - char f7time[20] = "11:30:55";// hh:mm:ss - char f8timestamp[50]= "2008-01-12 11:30:55"; //YYYY-MM-DD .....HH:MM:SS - int f9 = 5; - long long f10 = 15000; - int result; - - SQLINTEGER slen = SQL_NTS; - //*********************************** - SQL_DATE_STRUCT date; - char strDate[30]; - - date.year=2008; - date.month=03; - date.day=18; - // strcpy(strDate,"{d '2008-03-18'}"); - //********************************************** - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //********************************************* - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2008; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - timestamp.fraction = 764576; - //********************************************* - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?)",SQL_NTS); - checkrc(ret,__LINE__); - - // BIND PARAMETER - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_SMALLINT,0,0,&f2,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_REAL,0,0,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&date,sizeof(date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_TYPE_TIME,SQL_TYPE_TIME,196,0,&time,sizeof(time),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,8,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,×tamp,sizeof(timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,9,SQL_PARAM_INPUT,SQL_C_TINYINT,SQL_TINYINT,0,0,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,10,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10,0,NULL); - checkrc(ret,__LINE__); - - int i,count=0; - for(i=0;i<20;i++) - { - f1++; - f2++; - f4++; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count++; - } - printf("Total row inserted=%d\n",count); - } -//*********************************************************************** - -// FETCH ROWS FROM THE TABLE "T1"......select * from T1; -int FetchTest(SQLHANDLE env, SQLHANDLE dbc, SQLHANDLE stmt) -{ - - int ret; - int f1=10; // f1 field - short int f2=20;//f2 field - char f3[50]= "jitendra"; - float f4 = 2.5; - float f5 = 10.50; - int f9 = 5; - long long f10 = 15000; - int result; - - - SQL_DATE_STRUCT date; - char strDate[30]; - - date.year=2008; - date.month=03; - date.day=18; - // strcpy(strDate,"{d '2008-03-18'}"); - //********************************************** - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //********************************************* - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2008; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - timestamp.fraction = 764576; - - ret = SQLPrepare(stmt,(unsigned char*)"SELECT F8,F10,F2,F6,F3 FROM T1 WHERE F1=100 ",SQL_NTS); - checkrc(ret,__LINE__); - - //ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SMALL,SQL_SMALL,0,0,) - - - ret = SQLBindCol(stmt,1,SQL_C_TYPE_TIMESTAMP,×tamp,sizeof(timestamp),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,2,SQL_C_SBIGINT,&f10,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,3,SQL_C_SSHORT,&f2,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,4,SQL_C_TYPE_DATE,&date,sizeof(date),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,5,SQL_C_CHAR,f3,sizeof(f3),NULL); - checkrc(ret,__LINE__); - - - int j, count=0; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("SELECT F8,F10,F2,F6,F3 FROM T1 WHERE F1=100:\n "); - - while(SQL_SUCCEEDED(ret = SQLFetch(stmt))) - { - printf("TIMESTAMP=%d-%d-%d %d:%d:%d F10=%lld F2=%d DATE=%d-%d-%d F3=%s\n ",timestamp.year,timestamp.month,timestamp.day,timestamp.hour,timestamp.minute,timestamp.second,f10,f2,date.year,date.month,date.day,f3); - count++; - - - } - - - ret = SQLCloseCursor(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - - printf("Total row fetched=%d\n",count); -} - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - } - else - { - printf("error in conenction\n"); - - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 TINYINT,F10 BIGINT)"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nTABLE CREATED\n"); - //**************************************************************** - - InsertTest(env,dbc,stmt); - //***************************************************************** - - FetchTest(env,dbc,stmt); - - //**************************************************************** - SQLCHAR drop[100]="DROP TABLE T1"; - ret = SQLPrepare(stmt,drop,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - if(ret!=SQL_SUCCESS && ret !=SQL_SUCCESS_WITH_INFO) - printf("Statement failed\n"); - else - printf("Table dropped successfully\n"); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 0; -} diff --git a/test/odbc/Select/odbcselect4.c b/test/odbc/Select/odbcselect4.c deleted file mode 100644 index aff3ccd5..00000000 --- a/test/odbc/Select/odbcselect4.c +++ /dev/null @@ -1,301 +0,0 @@ -// create table T1 witjh 10 fileds and insert rows in it. -// prepare statement with 5 fields. -// use SQLNumResultCols() to get the nuber of fields in prepare statements. - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - - int ret; - int f1=100; // f1 field - short int f2=20;//f2 field - char f3[50]= "Praba"; - float f4 = 2.5; - float f5 = 10.50; - char f6date[15]= "2008-01-12";// f6 field.DATE Field. yyyy-mm-dd - char f7time[20] = "11:30:55";// hh:mm:ss - char f8timestamp[50]= "2008-01-12 11:30:55"; //YYYY-MM-DD .....HH:MM:SS - int f9 = 5; - long long f10 = 15000; - int result; - - SQLINTEGER slen = SQL_NTS; - //*********************************** - SQL_DATE_STRUCT date; - char strDate[30]; - - date.year=2008; - date.month=03; - date.day=18; - // strcpy(strDate,"{d '2008-03-18'}"); - //********************************************** - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //********************************************* - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2008; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - timestamp.fraction = 764576; - //********************************************* - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?)",SQL_NTS); - checkrc(ret,__LINE__); - - // BIND PARAMETER - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SSHORT,SQL_SMALLINT,0,0,&f2,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,3,SQL_PARAM_INPUT,SQL_C_CHAR,SQL_CHAR,196,0,(void*)f3,0,&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,4,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_FLOAT,0,0,&f4,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,5,SQL_PARAM_INPUT,SQL_C_FLOAT,SQL_REAL,0,0,&f5,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,6,SQL_PARAM_INPUT,SQL_C_TYPE_DATE,SQL_TYPE_DATE,196,0,&date,sizeof(date),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,7,SQL_PARAM_INPUT,SQL_C_TYPE_TIME,SQL_TYPE_TIME,196,0,&time,sizeof(time),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,8,SQL_PARAM_INPUT,SQL_C_TYPE_TIMESTAMP,SQL_TYPE_TIMESTAMP,196,0,×tamp,sizeof(timestamp),&slen); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,9,SQL_PARAM_INPUT,SQL_C_TINYINT,SQL_TINYINT,0,0,&f9,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,10,SQL_PARAM_INPUT,SQL_C_SBIGINT,SQL_BIGINT,0,0,&f10,0,NULL); - checkrc(ret,__LINE__); - - int i,count=0; - for(i=0;i<2;i++) - { - for(int j=0;j<5;j++) - { - f1= f1+i; - f2++; - f4++; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count++; - } - } - printf("Total row inserted=%d\n",count); - } -//*********************************************************************** -// FETCH ROWS FROM THE TABLE "T1"......select * from T1; -int FetchTest(SQLHANDLE env, SQLHANDLE dbc, SQLHANDLE stmt) -{ - - int ret; - int f1=100; // f1 field - short int f2=20;//f2 field - char f3[50]= "jitendra"; - float f4 = 2.5; - float f5 = 10.50; - //char f6date[15]= "2008-01-12";// f6 field.DATE Field. yyyy-mm-dd - //char f7time[20] = "11:30:55";// hh:mm:ss - //char f8timestamp[50]= "2008-01-12 11:30:55"; //YYYY-MM-DD .....HH:MM:SS - int f9 = 5; - long long f10 = 15000; - int result; - - - SQL_DATE_STRUCT date; - char strDate[30]; - - date.year=2008; - date.month=03; - date.day=18; - // strcpy(strDate,"{d '2008-03-18'}"); - //********************************************** - SQL_TIME_STRUCT time; - time.hour = 5; - time.minute = 22; - time.second = 10; - //********************************************* - SQL_TIMESTAMP_STRUCT timestamp; - timestamp.year = 2008; - timestamp.month = 03; - timestamp.day = 18; - timestamp.hour = 5; - timestamp.minute = 22; - timestamp.second = 10; - timestamp.fraction = 764576; - - ret = SQLPrepare(stmt,(unsigned char*)"SELECT F8,F10,F2,F6,F3 FROM T1 WHERE F1=100 ",SQL_NTS); - checkrc(ret,__LINE__); - - SQLSMALLINT noc; - SQLNumResultCols(stmt,&noc); - printf("SQLNumResultCols() returns=%d\n",noc); - - - - ret = SQLBindCol(stmt,1,SQL_C_TYPE_TIMESTAMP,×tamp,sizeof(timestamp),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,2,SQL_C_SBIGINT,&f10,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,3,SQL_C_SSHORT,&f2,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,4,SQL_C_TYPE_DATE,&date,sizeof(date),NULL); - checkrc(ret,__LINE__); - - ret = SQLBindCol(stmt,5,SQL_C_CHAR,f3,sizeof(f3),NULL); - checkrc(ret,__LINE__); - - - int j, count=0; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("SELECT F8,F10,F2,F6,F3 FROM T1 WHERE F1=100 :\n"); - - - while(SQL_SUCCEEDED(ret = SQLFetch(stmt))) - { - printf("F1=%d\tF2=%d\tF3=%s\tF4=%f\tF5=%f\tDATE=%d/%d/%d\tTIME=%d-%d-%d\tTIMESTAMP=%d/%d/%d %d-%d-%d\tF9=%d\tF10=%lld\n ",f1,f2,f3,f4,f5,date.year,date.month,date.day,time.hour,time.minute,time.second,timestamp.year,timestamp.month,timestamp.day,timestamp.hour,timestamp.minute,timestamp.second,f9,f10); - - - count++; - - } - - - ret = SQLCloseCursor(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - - printf("Total row fetched=%d\n",count); -} - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - ret = SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - checkrc(ret,__LINE__); - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - } - else - { - printf("Error in conenction\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 TINYINT,F10 BIGINT)"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nTABLE CREATED\n"); - //**************************************************************** - - InsertTest(env,dbc,stmt); - //***************************************************************** - - FetchTest(env,dbc,stmt); - - //**************************************************************** - SQLCHAR drop[100]="DROP TABLE T1"; - ret = SQLPrepare(stmt,drop,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - if(ret!=0) - printf("Statement failed\n"); - else - printf("Table dropped successfully\n"); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 0; -} diff --git a/test/odbc/Select/odbcselect5.c b/test/odbc/Select/odbcselect5.c deleted file mode 100644 index ea8f7388..00000000 --- a/test/odbc/Select/odbcselect5.c +++ /dev/null @@ -1,105 +0,0 @@ -// select from non-existing table it should fail - -// AUTHOR : Jitendra lenka - -#include -#include -#include -#include -#include - -inline void checkrc(int rc, int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} -//********************************************************************************** - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - ret = SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - ret = SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - checkrc(ret,__LINE__); - - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("Connected to the data source successfully..\n"); - - } - - else - { - printf("error in connection\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - ret = SQLPrepare(stmt,(unsigned char*)"SELECT * FROM EMP",SQL_NTS); - - - ret = SQLExecute(stmt); - - if(ret != SQL_SUCCESS && ret != SQL_SUCCESS_WITH_INFO) - printf("Could not SQL Execute\n"); - int rettype = ret; - - - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - if(rettype == 0) - { - printf("test script failed\n"); - return 1; - } - else - printf("Test script passed\n"); - return 0; - -} - - - - - - - diff --git a/test/odbc/Select/odbcselect6.c b/test/odbc/Select/odbcselect6.c deleted file mode 100644 index 13e82e32..00000000 --- a/test/odbc/Select/odbcselect6.c +++ /dev/null @@ -1,191 +0,0 @@ -// create table t1 . -// select statements with nonexisting field.it should failed - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - - int ret; - int f1=90; // f1 field - int f2=20;//f2 field - - - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?,?)",SQL_NTS); - checkrc(ret,__LINE__); - - // BIND PARAMETER - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f2,0,NULL); - checkrc(ret,__LINE__); - - - - int i,count=0; - for(i=0;i<10;i++) - { - f1++; - f2++; - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count++; - } - printf("Total row inserted=%d\n",count); - } -//*********************************************************************** -// FETCH ROWS FROM THE TABLE "T1"......select * from T1; -int FetchTest(SQLHANDLE env, SQLHANDLE dbc, SQLHANDLE stmt) -{ - - int ret; - int f1=10; // f1 field - int f2=20;//f2 field - int rettype ; - - - ret = SQLPrepare(stmt,(unsigned char*)"SELECT F3,F2 FROM T1 ",SQL_NTS); - rettype=ret; - if(rettype!=0)return 1; - - - - //ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SMALL,SQL_SMALL,0,0,) - ret = SQLBindCol(stmt,1,SQL_C_SLONG,&f1,0,NULL); - - - ret = SQLBindCol(stmt,2,SQL_C_SLONG,&f2,0,NULL); - - - - - int j, count=0; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - while(SQL_SUCCEEDED(ret = SQLFetch(stmt))) - { - count++; - - } - - - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - - printf("Total row fetched=%d\n",count); -} - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - } - else - { - printf("error in connection\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 INT)"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - printf("\nTABLE CREATED\n"); - //**************************************************************** - - InsertTest(env,dbc,stmt); - //***************************************************************** - int ret1; - ret1=FetchTest(env,dbc,stmt); - - //**************************************************************** - ret = SQLPrepare(stmt,(unsigned char*)"drop table T1;",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("Table 'T1' Dropped\n"); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - - if(ret1 == 0)return 1; - return 0; -} diff --git a/test/odbc/Select/odbcselect7.c b/test/odbc/Select/odbcselect7.c deleted file mode 100644 index e4ad94f1..00000000 --- a/test/odbc/Select/odbcselect7.c +++ /dev/null @@ -1,206 +0,0 @@ -// create table t1 with two fields. -// prepare with nonexisting field. -// SQLNumResultCols() should return zero. - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - -//************************************************************************* -int InsertTest(SQLHANDLE env,SQLHANDLE dbc,SQLHANDLE stmt) -{ - - int ret; - int f1=90; // f1 field - int f2=20;//f2 field - - - ret = SQLPrepare(stmt,(unsigned char*)"INSERT INTO T1 VALUES(?,?)",SQL_NTS); - checkrc(ret,__LINE__); - - // BIND PARAMETER - - ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f1,0,NULL); - checkrc(ret,__LINE__); - - ret = SQLBindParameter(stmt,2,SQL_PARAM_INPUT,SQL_C_SLONG,SQL_INTEGER,0,0,&f2,0,NULL); - checkrc(ret,__LINE__); - - - - int i,count=0; - for(i=0;i<10;i++) - { - f1++; - f2++; - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - count++; - } - printf("Total row inserted=%d\n",count); - } -//*********************************************************************** -// FETCH ROWS FROM THE TABLE "T1"......select * from T1; -int FetchTest(SQLHANDLE env, SQLHANDLE dbc, SQLHANDLE stmt) -{ - - int ret; - int f1=10; // f1 field - int f2=20;//f2 field - - int rettype ; - - ret = SQLPrepare(stmt,(unsigned char*)"SELECT F3,F2 FROM T1 ",SQL_NTS); - rettype = ret; - if(rettype!=0)return 1; - - //ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SMALL,SQL_SMALL,0,0,) - ret = SQLBindCol(stmt,1,SQL_C_SLONG,&f1,0,NULL); - - - - ret = SQLBindCol(stmt,2,SQL_C_SLONG,&f2,0,NULL); - - - - - int j, count=0; - - ret = SQLExecute(stmt); - - SQLSMALLINT noc; - ret = SQLNumResultCols(stmt,&noc); - rettype=ret; - - if(rettype != 0 ) - { - printf("SQLNumResultCol() returns = %d\n",noc); - return 1; - } - - while(SQL_SUCCEEDED(ret = SQLFetch(stmt))) - { - count++; - - } - - /*SQLSMALLINT noc; - ret =SQLNumResultCols(stmt,&noc); - - printf("SQLNumResultCols() returns=%d\n",noc);*/ - - ret = SQLCloseCursor(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - - printf("Total row fetched=%d\n",count); -} - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - } - else - { - printf("error in connection\n"); - return 1; - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[100]= - "CREATE TABLE T1(F1 INT,F2 INT)"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - printf("\nTABLE CREATED\n"); - //**************************************************************** - - InsertTest(env,dbc,stmt); - //***************************************************************** - int ret1; - ret1=FetchTest(env,dbc,stmt); - - //**************************************************************** - ret = SQLExecDirect(stmt,(unsigned char*)"DROP TABLE T1",SQL_NTS); - checkrc(ret,__LINE__); - printf("Table 'T1' dropped\n"); - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - - if(ret1 == 0)return 1; - - return 0; -} diff --git a/test/odbc/Select/odbcselect8.c b/test/odbc/Select/odbcselect8.c deleted file mode 100644 index 4bbf12a6..00000000 --- a/test/odbc/Select/odbcselect8.c +++ /dev/null @@ -1,107 +0,0 @@ -// call SQLExecute() without calling SQLPrepare(). -// it should fail. - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - - } -} - -//************************************************************************* - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - } - else - { - printf("error in connection\n"); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 INT)"; - // ret = SQLPrepare(stmt,table,SQL_NTS); -// checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - int rettype = ret; - if(ret) - printf("Table creation failed\n"); - - else - printf("\nTABLE CREATED\n"); - //**************************************************************** - - - //**************************************************************** - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - - if(rettype == 0)return 1; - - return 0; - } diff --git a/test/odbc/Transaction/Makefile b/test/odbc/Transaction/Makefile deleted file mode 100644 index 081b791e..00000000 --- a/test/odbc/Transaction/Makefile +++ /dev/null @@ -1,41 +0,0 @@ -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -O2 -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include - -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlodbc - -TARGETS = test001 test002 - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -.c.o:.c - $(CPlus) $(CPlusFlags) $(INCL) -c -o $@ $< - -test001: transact1.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - -test002:transact2.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - -clean: - rm -f *.o $(TARGETS) - diff --git a/test/odbc/Transaction/transact1.c b/test/odbc/Transaction/transact1.c deleted file mode 100644 index baf8b694..00000000 --- a/test/odbc/Transaction/transact1.c +++ /dev/null @@ -1,157 +0,0 @@ -// create table T1 with two integer field. perform insert,update,select. - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - - -// FETCH ROWS FROM THE TABLE "T1"......select * from T1; -int FetchTest(SQLHANDLE env, SQLHANDLE dbc, SQLHANDLE stmt) -{ - - SQLRETURN ret; - int f2=20;//f2 field - - - - ret = SQLPrepare(stmt,(unsigned char*)"SELECT F2 FROM T1 ",SQL_NTS); - checkrc(ret,__LINE__); - - //ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SMALL,SQL_SMALL,0,0,) - ret = SQLBindCol(stmt,1,SQL_C_SLONG,&f2,0,NULL); - checkrc(ret,__LINE__); - - int j, count=0; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - while(SQL_SUCCEEDED(ret = SQLFetch(stmt))) - { - printf("F2=%d\n",f2); - count++; - - } - - /*SQLSMALLINT noc; - SQLNumResultCols(stmt,&noc); - printf("SQLNumResultCols() returns=%d\n",noc);*/ - - ret = SQLCloseCursor(stmt); - checkrc(ret,__LINE__); - - ret = SQLTransact(env,dbc,SQL_COMMIT); - checkrc(ret,__LINE__); - - printf("Total row fetched=%d\n",count); -} - - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - ret =SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - checkrc(ret,__LINE__); - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret = SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - - } - else - { - printf("error in connection\n"); - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - ret = SQLSetConnectAttr(dbc,SQL_ATTR_AUTOCOMMIT,(void*)SQL_AUTOCOMMIT_OFF,SQL_IS_UINTEGER); - checkrc(ret,__LINE__); - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 INT)"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - - printf("\nTABLE CREATED\n"); - //**************************************************************** - ret = SQLExecDirect(stmt,(unsigned char*)"INSERT INTO T1 VALUES(1,1)",SQL_NTS); - //InsertTest(env,dbc,stmt); - //***************************************************************** - - //update - ret = SQLExecDirect(stmt,(unsigned char*)"UPDATE T1 SET F2=100",SQL_NTS); - checkrc(ret,__LINE__); - ret = SQLEndTran(SQL_HANDLE_DBC,dbc,SQL_COMMIT); - if(ret!=SQL_SUCCESS && ret !=SQL_SUCCESS_WITH_INFO) - printf("error in commit\n"); - checkrc(ret,__LINE__); - //*********************************************************** - //FETCH - FetchTest(env,dbc,stmt); - - //**************************************************************** - ret = SQLExecDirect(stmt,(unsigned char*)"DROP TABLE T1",SQL_NTS); - checkrc(ret,__LINE__); - printf("Table T1 dropped\n"); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 0; -} diff --git a/test/odbc/Transaction/transact2.c b/test/odbc/Transaction/transact2.c deleted file mode 100644 index f0cb2f4e..00000000 --- a/test/odbc/Transaction/transact2.c +++ /dev/null @@ -1,174 +0,0 @@ -// create table with two integer field. -// update and rollbacked ,in sqlfetch counter value should be zero. - -// AUTHOR : Jitendra Lenka - -#include -#include -#include -#include -#include - - -//************************************************************************* - -inline void checkrc(int rc,int line) -{ - if(rc) - { - printf("ERROR %d at line %d\n",rc,line); - exit(1); - } -} - - - -//*********************************************************************** -// FETCH ROWS FROM THE TABLE "T1"......select * from T1; -int FetchTest(SQLHANDLE env, SQLHANDLE dbc, SQLHANDLE stmt) -{ - - SQLRETURN ret; - int f2=20;//f2 field - - - - ret = SQLPrepare(stmt,(unsigned char*)"SELECT F2 FROM T1 ",SQL_NTS); - checkrc(ret,__LINE__); - - //ret = SQLBindParameter(stmt,1,SQL_PARAM_INPUT,SQL_C_SMALL,SQL_SMALL,0,0,) - ret = SQLBindCol(stmt,1,SQL_C_SLONG,&f2,0,NULL); - checkrc(ret,__LINE__); - - int j, count=0; - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - while(SQL_SUCCEEDED(ret = SQLFetch(stmt))) - { - count++; - - } - - SQLSMALLINT noc; - SQLNumResultCols(stmt,&noc); - printf("SQLNumResultCols() returns=%d\n",noc); - - ret = SQLCloseCursor(stmt); - checkrc(ret,__LINE__); - - - printf("Total row fetched=%d\n",count); - if(count != 0)return 1; - return 0; -} - -//****************************************************************** - - -int main() -{ - SQLHENV env; - SQLHDBC dbc; - SQLHSTMT stmt; - SQLRETURN ret; - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - // Aloocate an environment handle - ret=SQLAllocHandle(SQL_HANDLE_ENV,SQL_NULL_HANDLE,&env); - checkrc(ret,__LINE__); - - //we need odbc3 support - SQLSetEnvAttr(env,SQL_ATTR_ODBC_VERSION,(void*)SQL_OV_ODBC3,0); - - //ALLOCATE A Connection handle - ret = SQLAllocHandle(SQL_HANDLE_DBC,env,&dbc); - checkrc(ret,__LINE__); - - // connect to the DSN mydsn - ret= SQLConnect (dbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - if(SQL_SUCCEEDED(ret)) - { - printf("\nConnected to the Data Source..\n"); - - } - else - { - printf("Error in connection\n"); - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - return 1; - } - - //ret = SQLSetConnectAttr(dbc,SQL_ATTR_AUTOCOMMIT,(void*)SQL_AUTOCOMMIT_OFF,SQL_IS_UINTEGER); - //checkrc(ret,__LINE__); - - //****************************************************************** - // TABLE CREATED - ret = SQLAllocHandle(SQL_HANDLE_STMT,dbc,&stmt); - checkrc(ret,__LINE__); - - SQLCHAR table[200]= - "CREATE TABLE T1(F1 INT,F2 INT)"; - ret = SQLPrepare(stmt,table,SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLExecute(stmt); - checkrc(ret,__LINE__); - printf("\nTABLE CREATED\n"); - //**************************************************************** - - ret = SQLSetConnectAttr(dbc,SQL_ATTR_AUTOCOMMIT,(void*)SQL_AUTOCOMMIT_OFF,SQL_IS_UINTEGER); - checkrc(ret,__LINE__); - - ret = SQLExecDirect(stmt,(unsigned char*)"INSERT INTO T1 VALUES(1,1)",SQL_NTS); - checkrc(ret,__LINE__); - - //***************************************************************** - - //update - ret = SQLExecDirect(stmt,(unsigned char*)"UPDATE T1 SET F2=100",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLEndTran(SQL_HANDLE_DBC,dbc,SQL_ROLLBACK); - checkrc(ret,__LINE__); - //*********************************************************** - //FETCH - int ret1; - ret1 = FetchTest(env,dbc,stmt); - - //**************************************************************** - ret = SQLExecDirect(stmt,(unsigned char*)"DROP TABLE T1",SQL_NTS); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_STMT,stmt); - checkrc(ret,__LINE__); - - ret = SQLDisconnect(dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_DBC,dbc); - checkrc(ret,__LINE__); - - ret = SQLFreeHandle(SQL_HANDLE_ENV,env); - checkrc(ret,__LINE__); - if(ret1 ==1) - { - - printf("Test script failed\n"); - return 1; - } -else - printf("Test script passed\n"); - return 0; -} - diff --git a/test/performance/DMLTest.c b/test/performance/DMLTest.c deleted file mode 100644 index e3ee8e25..00000000 --- a/test/performance/DMLTest.c +++ /dev/null @@ -1,169 +0,0 @@ -#include -#include -#include -#define ITERATIONS 100 -//#define LOAD 1000000 -//Note: Set following parameters in csql.conf for this test -//MAX_SYS_DB_SIZE=10485760 -//MAX_DB_SIZE=335544320 -//you may have to set the kernel.shmmax kernel paremeter(login as root) using -//$sysctl -w kernel.shmmax=1000000000 -#define LOAD 0 -int main() -{ - - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) - { - printf("Error during connection %d\n", rv); - return -1; - } - - - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return -1;} - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true ); - tabDef.addField("f2", typeString, 196); - rv = dbMgr->createTable("t1", tabDef); - if (rv != OK) { printf("Table creation failed\n"); return -1; } - printf("Table created\n"); - HashIndexInitInfo *idxInfo = new HashIndexInitInfo(); - strcpy(idxInfo->tableName, "t1"); - idxInfo->list.append("f1"); - idxInfo->indType = hashIndex; - if (LOAD >0 ) - idxInfo->bucketSize = 100007; - else - idxInfo->bucketSize = 10007; - rv = dbMgr->createIndex("indx1", idxInfo); - if (rv != OK) { printf("Index creation failed\n"); return -1; } - printf("Index created\n"); - delete idxInfo; - Table *table = dbMgr->openTable("t1"); - if (table == NULL) { printf("Unable to open table\n"); return -1; } - int id = 0; - char name[196] = "PRABAKARAN"; - table->bindFld("f1", &id); - table->bindFld("f2", name); - char *tuple; - int ret; - int i; - int icount =0; - if (LOAD > 0) { - TableImpl *impl = (TableImpl*)table; - impl->setUndoLogging(false); - strcpy(name, "PRABAKARAN0123456750590"); - rv = conn.startTransaction(); - if (rv != OK) exit(1); - for(i = 0; i< LOAD; i++) - { - id= i; - ret = table->insertTuple(); - if (ret != 0) break; - icount++; - if (i % 100 == 0 ) { rv = conn.commit(); - if (rv != OK) exit(1); - rv = conn.startTransaction(); - if (rv != OK) exit(1); - } - if (i %50000 == 0) printf("%d rows inserted\n", i); - } - conn.commit(); - impl->setUndoLogging(true); - printf("Loaded %d records\n", icount); - } - - //TableImpl *impl = (TableImpl*)table; - //impl->setUndoLogging(false); - i = 0; - NanoTimer timer; - icount =0; - for(i = LOAD; i< LOAD+ITERATIONS; i++) - { - timer.start(); - rv = conn.startTransaction(); - if (rv != OK) exit(1); - id= i; - strcpy(name, "PRABAKARAN0123456750590"); - ret = table->insertTuple(); - if (ret != 0) break; - // printf("%d\n ", i); - icount++; - conn.commit(); - timer.stop(); - } - printf("%d rows inserted %lld %lld %lld\n",icount, timer.min(), timer.max(), timer.avg()); - - int offset1= os::align(sizeof(int)); - Condition p1; - int val1 = 0; - p1.setTerm("f1", OpEquals, &val1); - table->setCondition(&p1); - icount=0; - - - timer.reset(); - for(i = LOAD; i< LOAD+ITERATIONS; i++) - { - timer.start(); - rv =conn.startTransaction(); - if (rv != OK) exit(1); - val1 = i; - table->execute(); - tuple = (char*)table->fetch() ; - if (tuple == NULL) {printf("loop break in %d\n", i);table->closeScan();break;} - // printf(" %d tuple value is %d %s \n", i, *((int*)tuple), tuple+offset1); - table->closeScan(); - icount++; - conn.commit(); - timer.stop(); - } - printf("%d rows selected %lld %lld %lld\n", icount, timer.min(), timer.max(), timer.avg()); - timer.reset(); - - for(i = LOAD; i< LOAD+ITERATIONS; i++) - { - timer.start(); - rv = conn.startTransaction(); - if (rv != OK) exit (1); - val1 = i; - table->execute(); - tuple = (char*)table->fetch() ; - if (tuple == NULL) {printf("loop break in %d\n", i);table->closeScan();break;} - strcpy(name, "PRABAKARAN0950576543210"); - table->updateTuple(); - table->closeScan(); - conn.commit(); - timer.stop(); - } - printf("%d rows updated %lld %lld %lld\n", i- LOAD, timer.min(), timer.max(), timer.avg()); - - - icount=0; - for(i = LOAD; i< LOAD+ITERATIONS; i++) - { - timer.start(); - rv = conn.startTransaction(); - if (rv != OK) exit (1); - val1 = i; - table->execute(); - tuple = (char*)table->fetch() ; - if (tuple == NULL) {printf("No record for %d\n", i);table->closeScan();break;} - table->deleteTuple(); - icount++; - table->closeScan(); - conn.commit(); - timer.stop(); - } - printf("%d rows deleted %lld %lld %lld\n", icount, timer.min(), timer.max(), timer.avg()); - - - dbMgr->closeTable(table); - dbMgr->dropTable("t1"); - printf("Table dropped\n"); - - conn.close(); - return 0; -} diff --git a/test/performance/DMLThreadTest.c b/test/performance/DMLThreadTest.c deleted file mode 100644 index 6d98b1c7..00000000 --- a/test/performance/DMLThreadTest.c +++ /dev/null @@ -1,237 +0,0 @@ -#include -#include -#define THREADS 5 -void* runInsTest(void *p); -void* runSelTest(void *p); -int main() -{ - - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) - { - printf("Error during connection %d\n", rv); - return -1; - } - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return -1;} - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - tabDef.addField("f2", typeString, 196); - rv = dbMgr->createTable("t1", tabDef); - if (rv != OK) { printf("Table creation failed\n"); return -1; } - HashIndexInitInfo *idxInfo = new HashIndexInitInfo(); - strcpy(idxInfo->tableName, "t1"); - idxInfo->list.append("f1"); - idxInfo->indType = hashIndex; - rv = dbMgr->createIndex("indx1", idxInfo); - if (rv != OK) { printf("Index creation failed\n"); return -1; } - delete idxInfo; - pthread_t thr[THREADS]; - int message[THREADS]; - int status; - for (int i=0; i openTable("t1"); - if (table == NULL) { printf("Unable to open table\n"); return -1; } - table->setCondition(NULL); - rv = conn.startTransaction(); - if (rv != OK) while (rv !=OK) rv = conn.startTransaction(); - table->execute(); - int count=0; - void *tuple = NULL; - while ((tuple = (char*) table->fetch())) { - count++; - } - printf("Tuples found: %d\n", count); - table->closeScan(); - conn.commit(); - - - Condition p1; - int valTerm = 0; - p1.setTerm("f1", OpEquals, &valTerm); - table->setCondition(&p1); - int icount=0; - for(int i = 0; i< 50000; i++) - { - rv = conn.startTransaction(); - if (rv != OK) while (rv !=OK) rv = conn.startTransaction(); - valTerm = i; - rv = table->execute(); - tuple = (char*)table->fetch() ; - if (tuple == NULL) break; - icount++; - table->closeScan(); - conn.commit(); - } - printf("Index Tuples found: %d\n", icount); - - - - dbMgr->closeTable(table); - - for (int i=0; i dropTable("t1"); - conn.close(); - return 0; -} -void* runInsTest(void *message) -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) - { - printf("Error during connection %d\n", rv); - return NULL; - } - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return NULL;} - Table *table = dbMgr->openTable("t1"); - if (table == NULL) { printf("Unable to open table\n"); return NULL; } - int id = 0; - char name[200] = "PRABAKARAN"; - table->bindFld("f1", &id); - table->bindFld("f2", name); - char *tuple; - int ret; - int i; - int icount =0; - NanoTimer timer; - int val = *(int*)message; - int retrycnt=0; - timer.start(); - for(i = val * 10000; i< (val *10000) +10000; i++) - { - rv = conn.startTransaction(); - if (rv != OK) while (rv !=OK) rv = conn.startTransaction(); - id= i; - strcpy(name, "PRABAKARAN0123456750590"); - ret = table->insertTuple(); - retrycnt=0; - while (ret == ErrLockTimeOut) - { - rv = conn.rollback(); - if (rv != OK) { - while (rv == ErrLockTimeOut) - { - printf("retrying abort\n"); - rv = conn.rollback(); - } - } - if (retrycnt == 3) { ret = 1; break;} - rv = conn.startTransaction(); - if (rv != OK) { - while (rv == ErrLockTimeOut) - { - printf("retrying startTransaction\n"); - rv = conn.startTransaction(); - } - } - ret = table->insertTuple(); - retrycnt++; - //ret =1; break; //temp to analyse issue - } - if (ret != 0) { printf("RETURNING EARLY: %d with i:%d\n", ret, i); break;} - icount++; - rv = conn.commit(); - if (rv != OK) { - printf("COMMIT returned %d\n", rv); - os::usleep(500); - while (rv == ErrLockTimeOut) { - printf("retrying commit\n"); - rv = conn.commit(); - } - } - //if (icount %10000 ==0) printf("%d\n", i); - } - timer.stop(); - char msgBuf[1024]; - sprintf(msgBuf,"Insert: Thread %lu %d: Total rows :%d Time taken:%lld ms\n",os::getthrid(), val, icount, timer.avg()/1000/1000); - os::write(1,msgBuf,strlen(msgBuf)); - dbMgr->closeTable(table); - rv = conn.close(); - return NULL; -} -void* runSelTest(void *message) -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) - { - printf("Error during connection %d\n", rv); - return NULL; - } - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return NULL;} - Table *table = dbMgr->openTable("t1"); - if (table == NULL) { printf("Unable to open table\n"); return NULL; } - int id = 0; - char name[1020] = "PRABAKARAN"; - table->bindFld("f1", &id); - table->bindFld("f2", name); - char *tuple; - int i; - int icount =0; - NanoTimer timer; - int val = *(int*)message; - - Condition p1; - int valTerm = 0; - p1.setTerm("f1", OpEquals, &valTerm); - table->setCondition(&p1); - - timer.start(); - for(i = val * 10000; i< (val *10000) +10000; i++) - { - rv = conn.startTransaction(); - if (rv != OK) while (rv !=OK) rv = conn.startTransaction(); - valTerm = i; - rv = table->execute(); - if (rv != OK) { - printf("Execute returned %d\n", rv); - os::usleep(500); - int retry=5; - while (rv == ErrLockTimeOut) { - if (retry == 0) break; - printf("retrying execute\n"); - rv = table->execute(); - retry--; - } - } - tuple = (char*)table->fetch() ; - if (tuple == NULL) break; - icount++; - table->closeScan(); - rv = conn.commit(); - if (rv != OK) { - while (rv == ErrLockTimeOut) { - printf("retrying commit\n"); - rv = conn.commit(); - } - } - } - - timer.stop(); - char msgBuf[1024]; - sprintf(msgBuf,"Select: Thread %lu %d: Total rows :%d Time taken:%lld ms\n",os::getthrid(), val, icount, timer.avg()/1000/1000); - os::write(1,msgBuf,strlen(msgBuf)); - dbMgr->closeTable(table); - rv = conn.close(); - return NULL; -} - diff --git a/test/performance/DMLThroughput.c b/test/performance/DMLThroughput.c deleted file mode 100644 index fb4e5c58..00000000 --- a/test/performance/DMLThroughput.c +++ /dev/null @@ -1,114 +0,0 @@ -#include -#include -#include -//MAX_SYS_DB_SIZE=10485760 -//MAX_DB_SIZE=335544320 -//you may have to set the kernel.shmmax kernel paremeter(login as root) using -//$sysctl -w kernel.shmmax=1000000000 -#define LOAD 0 -int main() -{ - - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) - { - printf("Error during connection %d\n", rv); - return -1; - } - - - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return -1;} - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true ); - tabDef.addField("f2", typeString, 6); - rv = dbMgr->createTable("t1", tabDef); - if (rv != OK) { printf("Table creation failed\n"); return -1; } - printf("Table created\n"); - HashIndexInitInfo *idxInfo = new HashIndexInitInfo(); - strcpy(idxInfo->tableName, "t1"); - idxInfo->list.append("f1"); - idxInfo->indType = hashIndex; - idxInfo->bucketSize = 100007; - rv = dbMgr->createIndex("indx1", idxInfo); - if (rv != OK) { printf("Index creation failed\n"); return -1; } - printf("Index created\n"); - delete idxInfo; - Table *table = dbMgr->openTable("t1"); - if (table == NULL) { printf("Unable to open table\n"); return -1; } - int id = 0; - char name[6] = "PRABA"; - table->bindFld("f1", &id); - table->bindFld("f2", name); - char *tuple; - int ret; - int i; - int icount =0; - i = 0; - NanoTimer timer; - icount =0; - for(i = 0; i < 20; i++) - { - timer.start(); - for (int j =0; j < 100000; j++) - { - rv = conn.startTransaction(); - //if (rv != OK) exit(1); - if (rv != OK) { - dbMgr->closeTable(table); - dbMgr->dropTable("t1"); - conn.close(); - return 1; - } - id= i*100000+j; - strcpy(name, "KARAN"); - ret = table->insertTuple(); - if (ret != 0) break; - icount++; - conn.commit(); - } - timer.stop(); - printf("Insert: %d %lld\n", icount, timer.last()); - } - printf("%d rows inserted %lld %lld %lld\n",icount, timer.min(), timer.max(), timer.avg()); - - int offset1= os::align(sizeof(int)); - Condition p1; - int val1 = 0; - p1.setTerm("f1", OpEquals, &val1); - table->setCondition(&p1); - icount=0; - - - timer.reset(); - for(i = 0; i< 20; i++) - { - timer.start(); - for (int j=0 ; j <100000; j++) - { - rv =conn.startTransaction(); - if (rv != OK) exit(1); - val1 = i *100000 + j; - table->execute(); - tuple = (char*)table->fetch() ; - if (tuple == NULL) {printf("loop break in %d\n", i);table->closeScan();break;} - // printf(" %d tuple value is %d %s \n", i, *((int*)tuple), tuple+offset1); - table->closeScan(); - icount++; - conn.commit(); - } - timer.stop(); - printf("Select: %d %lld\n", icount, timer.last()); - } - printf("%d rows selected %lld %lld %lld\n", icount, timer.min(), timer.max(), timer.avg()); - timer.reset(); - - dbMgr->closeTable(table); - dbMgr->dropTable("t1"); - printf("Table dropped\n"); - - - conn.close(); - return 0; -} diff --git a/test/performance/JDBCTest.java b/test/performance/JDBCTest.java deleted file mode 100644 index bd7a942f..00000000 --- a/test/performance/JDBCTest.java +++ /dev/null @@ -1,132 +0,0 @@ -import java.sql.*; -public class JDBCTest -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (194), primary key(f1));"); - System.out.println("Table t1 created"); - cStmt.close(); - con.commit(); - - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 (f1, f2) VALUES (?, ?);"); - int count =0; - int ret =0; - stmt.setString(2, "DummyValue"); - long start =0, end =0, curr =0; - long min =100000, max =0, tot =0; - for (int i =0 ; i<= 100 ; i++) { - start = System.nanoTime(); - stmt.setInt(1, i); - stmt.setString(2, "DummyValue"); - ret = stmt.executeUpdate(); - if (ret != 1) break; //error - end = System.nanoTime(); - if (i ==0) continue; - curr = end-start; - tot = tot + curr; - if (min > curr) min = curr; - if (max < curr) max = curr; - count++; - - } - stmt.close(); - con.commit(); - System.out.print("Insert : " + count ); - System.out.println(" Min:" + min+ " Max: "+max+" Avg: "+ tot/100 ); - - count=0; - start=0; end=0; curr=0; - min=100000; max=0;tot =0; - selStmt = con.prepareStatement("SELECT * from T1 where f1 = ?;"); - ResultSet rs = null; - int intVal =0; - String strVal = null; - for (int i =0 ; i<= 100 ; i++) { - start = System.nanoTime(); - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - if (rs.next()) - { - //intVal = rs.getInt(1); - strVal = rs.getString(2); - } - rs.close(); - end = System.nanoTime(); - if (i ==0) continue; - //System.out.println("Tuple "+ intVal+ " "+ strVal); - curr = end-start; - tot = tot + curr; - if (min > curr) min = curr; - if (max < curr) max = curr; - count++; - } - selStmt.close(); - con.commit(); - System.out.print("Select : " + count); - System.out.println(" Min:" + min+ " Max: "+max+" Avg: "+ tot/100 ); - - count =0; - start=0; end=0; curr=0; - min=100000; max=0;tot =0; - stmt = con.prepareStatement("UPDATE T1 SET f2 = ? WHERE f1 = ?;"); - for (int i =0 ; i<= 100 ; i++) { - start = System.nanoTime(); - stmt.setInt(2, i); - stmt.setString(1, "UpdatedValue"); - ret = stmt.executeUpdate(); - if (ret != 1) break; //error - end = System.nanoTime(); - if (i ==0) continue; - curr = end-start; - tot = tot + curr; - if (min > curr) min = curr; - if (max < curr) max = curr; - count++; - } - stmt.close(); - con.commit(); - System.out.print("Update : " + count); - System.out.println(" Min:" + min+ " Max: "+max+" Avg: "+ tot/100 ); - - count =0; - start=0; end=0; curr=0; - min=100000; max=0;tot =0; - stmt = con.prepareStatement("DELETE FROM T1 WHERE f1 = ?;"); - for (int i =0 ; i<= 100 ; i++) { - start = System.nanoTime(); - stmt.setInt(1, i); - ret = stmt.executeUpdate(); - if (ret != 1) break; //error - end = System.nanoTime(); - if (i ==0) continue; - curr = end-start; - tot = tot + curr; - if (min > curr) min = curr; - if (max < curr) max = curr; - count++; - } - stmt.close(); - con.commit(); - System.out.print("Delete : " + count); - System.out.println(" Min:" + min+ " Max: "+max+" Avg: "+ tot/100 ); - - cStmt.execute("DROP TABLE T1;"); - System.out.println("Dropped table T1"); - cStmt.close(); - - con.close(); - } - catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - - } -} - diff --git a/test/performance/Makefile b/test/performance/Makefile deleted file mode 100644 index 7e4af624..00000000 --- a/test/performance/Makefile +++ /dev/null @@ -1,61 +0,0 @@ - -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -JAVAC = javac -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -O2 -w -JAVAC = javac -g:none -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlodbc -lcsqlsql -lcsqlsqllog -lcsqlodbcadapter -lcsql -lcsqlnw -lodbc -lcsqlgw -lcacheload - -TARGETS = \ - SQLGWTest \ - SQLAdapterTest \ - SQLTest \ - DMLTest \ - DMLThroughput \ - DMLThreadTest \ - ODBCTest \ - JDBCTest - - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -DMLTest: DMLTest.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -DMLThroughput: DMLThroughput.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -SQLTest: SQLTest.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -SQLGWTest: SQLGWTest.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -SQLAdapterTest: SQLAdapterTest.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -DMLThreadTest: DMLThreadTest.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) - -ODBCTest: ODBCTest.c - $(CPlus) $(CPlusFlags)-o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -JDBCTest: JDBCTest.java - $(JAVAC) JDBCTest.java - -clean: - rm -f $(TARGETS) *.class - diff --git a/test/performance/ODBCTest.c b/test/performance/ODBCTest.c deleted file mode 100644 index 846dd796..00000000 --- a/test/performance/ODBCTest.c +++ /dev/null @@ -1,349 +0,0 @@ - -#include -#include -#include -#include -#include -#include -#include -#include "NanoTimer.h" -#define ITERATION 100 -using namespace std; - -NanoTimer timer; - -void extract_error( - char *fn, - SQLHANDLE handle, - SQLSMALLINT type) -{ - SQLINTEGER i = 0; - SQLINTEGER native; - SQLCHAR state[ 7 ]; - SQLCHAR text[256]; - SQLSMALLINT len; - SQLRETURN ret; - - fprintf(stderr, - "\n" - "The driver reported the following diagnostics whilst running " - "%s\n\n", - fn); - - do - { - ret = SQLGetDiagRec(type, handle, ++i, state, &native, text, - sizeof(text), &len ); - if (SQL_SUCCEEDED(ret)) - printf("%s:%ld:%ld:%s\n", state, i, native, text); - } - while( ret == SQL_SUCCESS ); -} - -inline void -check_error (SQLSMALLINT handleType, SQLHANDLE handle, int rc, int line) -{ - if (rc) - { - cout << "Error " << rc << " at line: " << line << endl; - SQLCHAR state[10]; - SQLINTEGER native; - SQLCHAR mesg[300]; - int i=0; - while (SQLGetDiagRec (handleType, handle, i++, state, &native, mesg, 300, - NULL) == SQL_SUCCESS) - { - mesg[299] = '\0'; - cout << "state: " << state << endl; - cout << "native: " << native << endl; - cout << "mesg: " << mesg << endl; - } - exit (1); - } -} - - -inline void -checkrc (int rc, int line) -{ - if (rc) - { - cout << "Error " << rc << " at line: " << line << endl; - exit (1); - } -} - -void -readWriteTrans (SQLHDBC hdbc) -{ - int rc = SQLSetConnectAttr (hdbc, SQL_ATTR_ACCESS_MODE, - (SQLPOINTER) SQL_MODE_READ_WRITE, 0); - checkrc (rc, __LINE__); - rc = SQLEndTran (SQL_HANDLE_DBC, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); -} - -void -readOnlyTrans (SQLHDBC hdbc) -{ - int rc = SQLSetConnectAttr (hdbc, SQL_ATTR_ACCESS_MODE, - (SQLPOINTER) SQL_MODE_READ_ONLY, 0); - checkrc (rc, __LINE__); - rc = SQLEndTran (SQL_HANDLE_DBC, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); -} - -int -runInsertTest (SQLHANDLE henv, SQLHANDLE hdbc, SQLHANDLE hstmt) -{ - int rc; - int iHolder; - char sHolder[200]; - char sData[200]; - - iHolder = 0; - strcpy (sData, "0123456789012345678901234567890123456789"); - rc = SQLPrepare (hstmt, (unsigned char *) "INSERT INTO t1 VALUES (?, ?)", - SQL_NTS); - checkrc (rc, __LINE__); - rc = SQLBindParameter (hstmt, 1, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, - 0, 0, &iHolder, 0, NULL); - checkrc (rc, __LINE__); - SQLINTEGER sLen = SQL_NTS; - rc = SQLBindParameter (hstmt, 2, SQL_PARAM_INPUT, SQL_C_CHAR, SQL_CHAR, - 196, 0, (void *) sHolder, 0, &sLen); - checkrc (rc, __LINE__); - int i, j, k; - int tCount; - - timer.reset (); - - /* Run 1per Test */ - for (i = 0; i < ITERATION; i++) - { - timer.start (); - iHolder = i ; - strcpy (sHolder, sData); - rc = SQLExecute (hstmt); - checkrc (rc, __LINE__); - rc = SQLTransact (henv, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); - timer.stop (); - } - - printf ("Insert: 1 %lld %lld %lld\n", timer.min (), timer.max (), - timer.avg ()); - - return 0; - -} - -int -runReadTest (SQLHANDLE henv, SQLHANDLE hdbc, SQLHANDLE hstmt) -{ - int iHolder; - char sHolder[200]; - char sData[200]; - - int tempTermVar = 0; - int tempTermVal = 0; - int rc; - - /* Set read-only transaction type */ - readOnlyTrans (hdbc); - rc = SQLPrepare (hstmt, (unsigned char *) - "SELECT f1, f2 FROM t1 where f1 = ?", SQL_NTS); - checkrc (rc, __LINE__); - long sz = 0; - rc = SQLBindParameter (hstmt, 1, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, - 0, 0, &tempTermVar, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 1, SQL_INTEGER, &iHolder, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 2, SQL_C_CHAR, sHolder, sizeof (sHolder), NULL); - checkrc (rc, __LINE__); - iHolder = 0; - strcpy (sData, "0123456789012345678901234567890123456789"); - - int i, j, k; - int tCount; - - timer.reset (); - - /* Run 1per Test */ - for (i = 0; i < ITERATION; i++) - { - timer.start (); - tempTermVar = i ; - rc = SQLExecute (hstmt); - checkrc (rc, __LINE__); - rc = SQLFetch (hstmt); - checkrc (rc, __LINE__); - tempTermVal = iHolder; - strcpy (sData, sHolder); - rc = SQLCloseCursor (hstmt); - checkrc (rc, __LINE__); - rc = SQLTransact (henv, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); - timer.stop (); - } - printf ("Read: 1 %lld %lld %lld\n", timer.min (), timer.max (), - timer.avg ()); - /* Set read-write transaction type */ - readWriteTrans (hdbc); - return rc; -} - -int -runUpdateTest (SQLHANDLE henv, SQLHANDLE hdbc, SQLHANDLE hstmt) -{ - int rc; - int iHolder; - char sHolder[200]; - char sData[200]; - - rc = SQLPrepare (hstmt, - (unsigned char *) "UPDATE t1 SET f2 = ? WHERE f1 = ?", - SQL_NTS); - checkrc (rc, __LINE__); - SQLINTEGER sLen = SQL_NTS; - rc = SQLBindParameter (hstmt, 1, SQL_PARAM_INPUT, SQL_C_CHAR, SQL_CHAR, - 196, 0, (void *) sHolder, 0, &sLen); - checkrc (rc, __LINE__); - rc = SQLBindParameter (hstmt, 2, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, - 0, 0, &iHolder, 0, NULL); - checkrc (rc, __LINE__); - iHolder = 0; - strcpy (sData, "9876543210987654321098765432109876543210"); - - int i, j, k; - int tCount; - - timer.reset (); - - /* Run 1per Test */ - for (i = 0; i < ITERATION; i++) - { - timer.start (); - iHolder = i ; - strcpy (sHolder, sData); - rc = SQLExecute (hstmt); - checkrc (rc, __LINE__); - rc = SQLTransact (henv, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); - timer.stop (); - } - printf ("Update: 1 %lld %lld %lld\n", timer.min (), timer.max (), - timer.avg ()); - - return 0; -} - -int -runDeleteTest (SQLHANDLE henv, SQLHANDLE hdbc, SQLHANDLE hstmt) -{ - int rc; - int iHolder; - - rc = SQLPrepare (hstmt, (unsigned char *) - "DELETE FROM t1 WHERE f1 = ?", SQL_NTS); - checkrc (rc, __LINE__); - rc = SQLBindParameter (hstmt, 1, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, - 0, 0, &iHolder, 0, NULL); - checkrc (rc, __LINE__); - iHolder = 0; - int i, j, k; - int tCount; - timer.reset (); - /* Run 1per Test */ - for (i = 0; i < ITERATION; i++) - { - timer.start (); - iHolder = i ; - rc = SQLExecute (hstmt); - checkrc (rc, __LINE__); - rc = SQLTransact (henv, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); - timer.stop (); - } - printf ("Delete: 1 %lld %lld %lld\n", timer.min (), timer.max (), - timer.avg ()); - return 0; - -} - -int -main (int ac, char **av) -{ - int rc; - char *dsn; - //SQLHANDLE henv, hdbc, hstmt; -SQLHENV henv; -SQLHDBC hdbc; -SQLHSTMT hstmt; - - dsn = (char *) "DSN=myodbc3;"; - - rc = SQLAllocHandle (SQL_HANDLE_ENV, SQL_NULL_HANDLE, &henv); - checkrc (rc, __LINE__); - SQLSetEnvAttr(henv, SQL_ATTR_ODBC_VERSION, (void *) SQL_OV_ODBC3, 0); - - rc = SQLAllocHandle (SQL_HANDLE_DBC, henv, &hdbc); - checkrc (rc, __LINE__); - rc = SQLConnect (hdbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - - /* - rc = SQLDriverConnect(hdbc, NULL, (SQLCHAR*)"DSN=myodbc3;", SQL_NTS, - outstr, sizeof(outstr), &outstrlen, - SQL_DRIVER_NOPROMPT); - */ - - if (SQL_SUCCEEDED(rc)) { - printf("Connected\n"); - //printf("Returned connection string was:\n\t%s\n", outstr); - if (rc == SQL_SUCCESS_WITH_INFO) { - printf("Driver reported the following diagnostics\n"); - extract_error("SQLDriverConnect", hdbc, SQL_HANDLE_DBC); - } - } else { - fprintf(stderr, "Failed to connect\n"); - extract_error("SQLDriverConnect", hdbc, SQL_HANDLE_DBC); - } - - //check_error (SQL_HANDLE_DBC, hdbc, rc, __LINE__); - checkrc (rc, __LINE__); - rc = SQLSetConnectOption (hdbc, SQL_AUTOCOMMIT, SQL_AUTOCOMMIT_OFF); - checkrc (rc, __LINE__); - rc = SQLAllocHandle (SQL_HANDLE_STMT, hdbc, &hstmt); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE TABLE t1 (f1 INTEGER, f2 char(196), primary key (f1));", SQL_NTS ); - checkrc (rc, __LINE__); - - runInsertTest (henv, hdbc, hstmt); - runReadTest (henv, hdbc, hstmt); - runUpdateTest (henv, hdbc, hstmt); - runDeleteTest (henv, hdbc, hstmt); - - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP TABLE t1;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLEndTran(SQL_HANDLE_DBC, hdbc, SQL_COMMIT ); - checkrc (rc, __LINE__); - - rc = SQLFreeHandle (SQL_HANDLE_STMT, hstmt); - checkrc (rc, __LINE__); - rc = SQLDisconnect (hdbc); - checkrc (rc, __LINE__); - rc = SQLFreeHandle (SQL_HANDLE_DBC, hdbc); - checkrc (rc, __LINE__); - rc = SQLFreeHandle (SQL_HANDLE_ENV, henv); - checkrc (rc, __LINE__); - exit (0); -} diff --git a/test/performance/SQLAdapterTest.c b/test/performance/SQLAdapterTest.c deleted file mode 100644 index ebc37240..00000000 --- a/test/performance/SQLAdapterTest.c +++ /dev/null @@ -1,121 +0,0 @@ -#include -#include -#include -#define ITERATIONS 100 -//NOTE CREATE TABLE t1 (f1 int, f2 char(196), primary key(f1)); -//add 1:t1 in csqltable.conf and do csqlserver -c -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = SqlFactory::createConnection(CSqlAdapter); - rv = con->connect("root", "manager"); - if (rv != OK) return 1; - AbsSqlStatement *stmt = SqlFactory::createStatement(CSqlAdapter); - stmt->setConnection(con); - char statement[1024]; - - strcpy(statement, "INSERT INTO t1 (f1, f2) VALUES (?, ?);"); - int id1 =10; - char name[196]; - strcpy(name, "Rithish"); - NanoTimer timer; - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - int count =0, rows=0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - id1 = i; - stmt->setIntParam(1, id1); - strcpy(name, "Gopika"); - stmt->setStringParam(2, name); - rv = stmt->execute(rows); - if (rv != OK) break; - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - printf("Total Rows Inserted %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - stmt->free(); - - strcpy(statement, "SELECT * FROM t1 where f1 = ?;"); - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->bindField(1, &id1); - stmt->bindField(2, name); - timer.reset(); - count =0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - stmt->setIntParam(1, i); - stmt->execute(rows); - if (stmt->fetch() == NULL) { printf("unable to read record\n"); break; } - stmt->close(); - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - stmt->free(); - printf("Total Rows Selected %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - - strcpy(statement, "UPDATE t1 set f2=? where f1=?;"); - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->bindField(1, &id1); - stmt->bindField(2, name); - timer.reset(); - count =0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - stmt->setIntParam(2, i); - stmt->setStringParam(1, "ChangedValue"); - rv = stmt->execute(rows); - if (rv != OK && rows !=1) break; - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - stmt->free(); - printf("Total Rows Updated %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - - strcpy(statement, "DELETE FROM t1 where f1=?;"); - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->bindField(1, &id1); - timer.reset(); - count =0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - stmt->setIntParam(1, i); - rv = stmt->execute(rows); - if (rv != OK && rows != 1) break; - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - stmt->free(); - printf("Total Rows Deleted %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - - delete stmt; - delete con; - return 0; -} diff --git a/test/performance/SQLGWTest.c b/test/performance/SQLGWTest.c deleted file mode 100644 index 7490c2c4..00000000 --- a/test/performance/SQLGWTest.c +++ /dev/null @@ -1,121 +0,0 @@ -#include -#include -#include -#define ITERATIONS 100 -//NOTE CREATE TABLE t1 (f1 int, f2 char(196), primary key(f1)); -//add 1:t1 in csqltable.conf and do csqlserver -c -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = SqlFactory::createConnection(CSqlGateway); - rv = con->connect("root", "manager"); - if (rv != OK) return 1; - AbsSqlStatement *stmt = SqlFactory::createStatement(CSqlGateway); - stmt->setConnection(con); - char statement[1024]; - - strcpy(statement, "INSERT INTO t1 (f1, f2) VALUES (?, ?);"); - int id1 =10; - char name[196]; - strcpy(name, "Rithish"); - NanoTimer timer; - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - int count =0, rows=0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - id1 = i; - stmt->setIntParam(1, id1); - strcpy(name, "Gopika"); - stmt->setStringParam(2, name); - rv = stmt->execute(rows); - if (rv != OK) break; - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - printf("Total Rows Inserted %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - stmt->free(); - - strcpy(statement, "SELECT * FROM t1 where f1 = ?;"); - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->bindField(1, &id1); - stmt->bindField(2, name); - timer.reset(); - count =0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - stmt->setIntParam(1, i); - stmt->execute(rows); - if (stmt->fetch() == NULL) { printf("unable to read record\n"); break; } - stmt->close(); - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - stmt->free(); - printf("Total Rows Selected %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - - strcpy(statement, "UPDATE t1 set f2=? where f1=?;"); - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->bindField(1, &id1); - stmt->bindField(2, name); - timer.reset(); - count =0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - stmt->setIntParam(2, i); - stmt->setStringParam(1, "ChangedValue"); - rv = stmt->execute(rows); - if (rv != OK && rows !=1) break; - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - stmt->free(); - printf("Total Rows Updated %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - - strcpy(statement, "DELETE FROM t1 where f1=?;"); - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->bindField(1, &id1); - timer.reset(); - count =0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - stmt->setIntParam(1, i); - rv = stmt->execute(rows); - if (rv != OK && rows != 1) break; - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - stmt->free(); - printf("Total Rows Deleted %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - - delete stmt; - delete con; - return 0; -} diff --git a/test/performance/SQLTest.c b/test/performance/SQLTest.c deleted file mode 100644 index 544b0231..00000000 --- a/test/performance/SQLTest.c +++ /dev/null @@ -1,144 +0,0 @@ -#include -#include -#include -#define ITERATIONS 100 -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = SqlFactory::createConnection(CSql); - rv = con->connect("root", "manager"); - if (rv != OK) return 1; - AbsSqlStatement *stmt = SqlFactory::createStatement(CSql); - stmt->setConnection(con); - char statement[1024]; - strcpy(statement, "CREATE TABLE t1 (f1 int, f2 char(196));"); - int rows =0; - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - rv = stmt->execute(rows); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->free(); - printf("Table t1 created\n"); - - strcpy(statement, "CREATE INDEX t1idx on t1 (f1);"); - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - rv = stmt->execute(rows); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->free(); - printf("Index created on t1(f1) \n"); - - strcpy(statement, "INSERT INTO t1 (f1, f2) VALUES (?, ?);"); - int id1 =10; - char name[196]; - strcpy(name, "Rithish"); - NanoTimer timer; - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - int count =0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - id1 = i; - stmt->setIntParam(1, id1); - strcpy(name, "Gopika"); - stmt->setStringParam(2, name); - rv = stmt->execute(rows); - if (rv != OK) break; - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - printf("Total Rows Inserted %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - stmt->free(); - - strcpy(statement, "SELECT * FROM t1 where f1 = ?;"); - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->bindField(1, &id1); - stmt->bindField(2, name); - timer.reset(); - count =0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - stmt->setIntParam(1, i); - stmt->execute(rows); - if (stmt->fetch() == NULL) { printf("unable to read record\n"); break; } - stmt->close(); - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - stmt->free(); - printf("Total Rows Selected %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - - strcpy(statement, "UPDATE t1 set f2=? where f1=?;"); - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->bindField(1, &id1); - stmt->bindField(2, name); - timer.reset(); - count =0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - stmt->setIntParam(2, i); - stmt->setStringParam(1, "ChangedValue"); - rv = stmt->execute(rows); - if (rv != OK && rows !=1) break; - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - stmt->free(); - printf("Total Rows Updated %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - - strcpy(statement, "DELETE FROM t1 where f1=?;"); - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->bindField(1, &id1); - timer.reset(); - count =0; - for (int i = 0 ; i < ITERATIONS ; i++) - { - timer.start(); - rv = con->beginTrans(); - if (rv != OK) break; - stmt->setIntParam(1, i); - rv = stmt->execute(rows); - if (rv != OK && rows != 1) break; - rv = con->commit(); - if (rv != OK) break; - timer.stop(); - count++; - } - stmt->free(); - printf("Total Rows Deleted %d %lld %lld %lld\n", count, timer.min(), - timer.max(), timer.avg()); - - strcpy(statement, "DROP TABLE t1);"); - rv = stmt->prepare(statement); - if (rv != OK) {delete stmt; delete con; return -1; } - rv = stmt->execute(rows); - if (rv != OK) {delete stmt; delete con; return -1; } - stmt->free(); - printf("Table dropped\n"); - - - delete stmt; - delete con; - return 0; -} diff --git a/test/performance/wisc/JDBCBench.java b/test/performance/wisc/JDBCBench.java deleted file mode 100644 index e05ee3ca..00000000 --- a/test/performance/wisc/JDBCBench.java +++ /dev/null @@ -1,413 +0,0 @@ -import java.sql.*; -import java.util.Random; -public class JDBCBench -{ - public static Random generator = new Random(); - public static int getRandom(int end) - { - double val = generator.nextDouble(); - val *=end; - return (int)(val); - } - - public static int singleTuple(Connection con, boolean flag)throws Exception - { - PreparedStatement stmt = null ; - String stmtStr; - if (flag) { - String buf = "SELECT unique1, unique2, stringu1, stringu2 from big1 where unique1=?;"; - stmtStr = buf; - }else { - String buf = "SELECT unique1, unique2, stringu1, stringu2 from big1 where stringu1=?;"; - stmtStr = buf; - } - - stmt = con.prepareStatement(stmtStr); - int count=0, recordCount=0; - int ret =0; - long start=0, end=0, curr=0; - long tot=0; - ResultSet rs; - int searchVal[] = {1, 10, 100, 500, 1000, 5000 ,7500, 8000, 9000, 9999}; - - for(int i=0; i<10; i++) { - start = System.nanoTime(); - if (flag) - stmt.setInt(1, searchVal[i]); - else - stmt.setString(1, "Value" +searchVal[i]); - rs = stmt.executeQuery(); - recordCount=0; - if(rs.next()) - { - recordCount++; - } - rs.close(); - con.commit(); - end = System.nanoTime(); - if(recordCount != 1) - { - System.out.println("No of records for Q1: "+ recordCount ); - return 0; - } - - curr = end - start; - tot = tot + curr; - count++; - } - - stmt.close(); - return (int)tot/10/1000; - } - - public static int onePerSel(Connection con) throws Exception - { - PreparedStatement stmt = null; - - String stmtStr; - String buf= "SELECT unique1, unique2, stringu1 from big1 where unique1 between ? and ?;"; - stmtStr= buf; - stmt = con.prepareStatement(stmtStr); - int count =0, recordCount=0; - int ret =0; - long start =0, end =0, curr =0; - long tot =0; - ResultSet rs; - int searchVal[] = {1, 5, 10, 50, 100, 500, 1000, 5000 ,7500, 9500}; - for (int i =0 ; i< 10 ; i++) { - start = System.nanoTime(); - stmt.setInt(1, searchVal[i]); - stmt.setInt(2, searchVal[i] +99); - rs = stmt.executeQuery(); - recordCount=0; - while (rs.next()) - { - recordCount++; - } - - rs.close(); - con.commit(); - end = System.nanoTime(); - - - if (recordCount!= 100) - { - System.out.println("No. of records for Q2: "+recordCount); - return 0; - } - curr = end-start; - tot = tot + curr; - count++; - - } - stmt.close(); - return (int)tot/10/1000; - } - -// aggregate -public static int aggregate(Connection con, int val)throws Exception -{ - PreparedStatement stmt = null; - String stmtStr=""; - if(val==1) - { - String buf = "SELECT MIN(unique1) from big1;"; - stmtStr = buf; - } - else if (val ==2) - { - String buf = "SELECT SUM(unique1) from big1;"; - stmtStr = buf; - } - stmt = con.prepareStatement(stmtStr); - int count = 0, recordCount; - int ret = 0; - long start = 0,end = 0,curr = 0; - long tot = 0; - ResultSet rs; - - for(int i=0;i<10;i++){ - start = System.nanoTime(); - rs = stmt.executeQuery(); - recordCount = 0; - if(rs.next()) - { - recordCount++; - } - - rs.close(); - con.commit(); - end = System.nanoTime(); - - if(recordCount !=1) - { - System.out.println("No. of records for Q4-7(" + val +" ): " + recordCount); - return 0; - } - curr = end - start; - tot = tot + curr; - count++; - } - stmt.close(); - return (int)tot/10/1000; - } - - - // DML statement - public static int dmlstatement(Connection con, int val)throws Exception - { - PreparedStatement stmt = null; - String stmtStr=""; - if(val==1) - { - String buf = "insert into big1 values(?,?,0,2,0,10,50,688,1950,4950,9950,1,100,'MXXXXXXXXXXXXXXXXXXXXXXXXXGXXXXXXXXXXXXXXXXXXXXXXXXC','GXXXXXXXXXXXXXXXXXXXXXXXXXCXXXXXXXXXXXXXXXXXXXXXXXXA','OXXXXXXXXXXXXXXXXXXXXXXXXXOXXXXXXXXXXXXXXXXXXXXXXXXO');"; - stmtStr = buf; - } - else if(val==2) - { - String buf = "UPDATE big1 SET two=1 WHERE unique1=?;"; - stmtStr = buf; - } - else - { - String buf = "DELETE FROM big1 WHERE unique1=?;"; - stmtStr = buf; - } - - stmt = con.prepareStatement(stmtStr); - int count = 0, recordCount=0; - int ret = 0; - long start = 0,end = 0,curr = 0; - long tot = 0; - for(int i=0; i<100; i++){ - stmt.setInt(1, 10000+i); - if (val ==1) stmt.setInt(2, 10000+i); - start = System.nanoTime(); - ret = stmt.executeUpdate(); - if(ret!=1) return 1; - - con.commit(); - end = System.nanoTime(); - curr = end - start; - tot = tot + curr; - count++; - } - stmt.close(); - return (int)tot/100/1000; - } - -// Joining -public static int joining(Connection con,int val)throws Exception -{ - PreparedStatement stmt = null; - String stmtStr= null; - if(val==1) - { - String buf = "SELECT big1.unique1, big1.unique2, small.unique1, small.stringu1 FROM small,big1 WHERE big1.unique1=small.unique1 AND small.unique1=?;"; - stmtStr = buf; - } - else if(val==2) - { - String buf = "SELECT small.unique1, big1.unique1, big2.unique1, small.stringu1, big1.unique2, big2.unique2 FROM big1, big2, small WHERE small.unique1=big1.unique1 AND big1.unique1=big2.unique1 AND big1.unique1 = ?;"; - stmtStr=buf; - } - - stmt = con.prepareStatement(stmtStr); - int count=0,recordCount=0,ret=0; - long start=0,end=0,curr=0; - long tot=0; - ResultSet rs; - int searchVal[] = {1, 5, 10, 50, 100, 250, 500, 750, 900, 999}; - for(int i=0;i<10;i++) - { - recordCount =0; - start = System.nanoTime(); - stmt.setInt(1, searchVal[i]); - rs = stmt.executeQuery(); - if(rs.next()) - { - //System.out.println("Record:"+ rs.getInt(1)+ " "+ rs.getInt(2)+" " +rs.getInt(3)+ " "+ rs.getString(4)); - recordCount++; - } - rs.close(); - con.commit(); - end=System.nanoTime(); - if(recordCount!=1) - { - System.out.println("No. of records Join: "+recordCount); - return 0; - } - curr = end - start; - tot = tot + curr; - count++; - } - stmt.close(); - return (int)tot/10/1000; -} -//***************************************************** -public static void main(String[] args) - - { - int flag=1; - if (args.length == 1) - { - if (args[0].equals("csql")) flag=1; - else if (args[0].equals("mysql")) flag=2; - else { - System.out.println("Valid values: csql or mysql"); - return; - } - } - try - { - Connection con = null; - if (flag == 1) { - Class.forName("csql.jdbc.JdbcSqlDriver"); - con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - }else if (flag == 2) { - Class.forName("com.mysql.jdbc.Driver"); - con = DriverManager.getConnection("jdbc:mysql://localhost/test", "root", ""); - } - con.setAutoCommit(false); - con.setTransactionIsolation(Connection.TRANSACTION_READ_COMMITTED); - Statement cStmt = con.createStatement(); - - int timeTaken[][] = new int[15][3]; - int ins=1,upd=2,del=3;// function parameter - int min=1, sum=2;// function parameter - - - timeTaken[0][0] = singleTuple(con, true); - timeTaken[1][0] = onePerSel(con); - timeTaken[2][0] = aggregate(con,min); - timeTaken[3][0] = aggregate(con,sum); - timeTaken[4][0] = dmlstatement(con,ins); - timeTaken[5][0] = dmlstatement(con,upd); - timeTaken[6][0] = dmlstatement(con,del); - timeTaken[7][0] = joining(con,1); - timeTaken[8][0] = joining(con,2); - timeTaken[9][0] = singleTuple(con, false); - System.out.println("Finished no index queries"); - - //create index - try{ - if (flag ==1) { - cStmt.execute("CREATE INDEX idx1 ON big1(unique1) HASH"); - cStmt.close(); - cStmt.execute("CREATE INDEX idx2 ON big2(unique1) HASH"); - cStmt.close(); - cStmt.execute("CREATE INDEX idx3 ON small(unique1) HASH"); - cStmt.close(); - cStmt.execute("CREATE INDEX idx4 ON big1(stringu1) HASH"); - cStmt.close(); - con.commit(); - }else if (flag ==2) { - cStmt.execute("CREATE INDEX mysqld1 USING HASH ON big1(unique1)"); - cStmt.execute("CREATE INDEX mysqld2 USING HASH ON big2(unique1)"); - cStmt.execute("CREATE INDEX mysqld3 USING HASH ON small(unique1)"); - cStmt.execute("CREATE INDEX mysqld4 USING HASH ON big1(stringu1)"); - con.commit(); - } - }catch(Exception e ){e.printStackTrace(); System.out.println("Error creating index");} - timeTaken[0][1] = singleTuple(con, true); - timeTaken[1][1] = 0; - timeTaken[2][1] = 0; - timeTaken[3][1] = 0; - timeTaken[4][1] = dmlstatement(con,ins); - timeTaken[5][1] = dmlstatement(con,upd); - timeTaken[6][1] = dmlstatement(con,del); - timeTaken[7][1] = joining(con,1); - timeTaken[8][1] = joining(con,2); - timeTaken[9][1] = singleTuple(con, false); - System.out.println("Finished hash index queries"); - - - try{ - if (flag ==1) { - cStmt.execute("DROP INDEX idx1"); - cStmt.close(); - cStmt.execute("DROP INDEX idx2"); - cStmt.close(); - cStmt.execute("DROP INDEX idx3"); - cStmt.close(); - cStmt.execute("DROP INDEX idx4"); - cStmt.close(); - cStmt.execute("CREATE INDEX idx5 ON big1(unique1) TREE"); - cStmt.execute("CREATE INDEX idx6 ON big2(unique1) TREE"); - cStmt.execute("CREATE INDEX idx7 ON small(unique1) TREE"); - cStmt.execute("CREATE INDEX idx8 ON big1(stringu1) TREE"); - con.commit(); - }else if (flag ==2) { - cStmt.execute("DROP INDEX mysqld1 on big1"); - cStmt.execute("DROP INDEX mysqld2 on big2"); - cStmt.execute("DROP INDEX mysqld3 on small"); - cStmt.execute("DROP INDEX mysqld4 on big1;"); - cStmt.execute("CREATE INDEX mysqld5 USING BTREE ON big1(unique1)"); - cStmt.execute("CREATE INDEX mysqld6 USING BTREE ON big2(unique1)"); - cStmt.execute("CREATE INDEX mysqld7 USING BTREE ON small(unique1)"); - cStmt.execute("CREATE INDEX mysqld8 USING BTREE ON big1(stringu1)"); - con.commit(); - } - }catch(Exception e ){e.printStackTrace(); System.out.println("Error creating index");} - - timeTaken[0][2] = singleTuple(con, true); - timeTaken[1][2] = onePerSel(con); - timeTaken[2][2] = aggregate(con,min); - timeTaken[3][2] = 0; - timeTaken[4][2] = dmlstatement(con,ins); - timeTaken[5][2] = dmlstatement(con,upd); - timeTaken[6][2] = dmlstatement(con,del); - timeTaken[7][2] = joining(con,1); - timeTaken[8][2] = joining(con,2); - timeTaken[9][2] = singleTuple(con, false); - System.out.println("Finished tree index queries"); - - - - try{ - if (flag ==1) { - cStmt.execute("DROP INDEX idx5;"); - cStmt.close(); - cStmt.execute("DROP INDEX idx6;"); - cStmt.close(); - cStmt.execute("DROP INDEX idx7;"); - cStmt.close(); - cStmt.execute("DROP INDEX idx8;"); - cStmt.close(); - con.commit(); - } else if (flag ==2) { - cStmt.execute("DROP INDEX mysqld5 on big1"); - cStmt.execute("DROP INDEX mysqld6 on big2"); - cStmt.execute("DROP INDEX mysqld7 on small"); - cStmt.execute("DROP INDEX mysqld8 on big1"); - con.commit(); - } - }catch(Exception e ){System.out.println("Error dropping indexes");} - - System.out.println("Wisconsin Benchmark Report:"); - - System.out.println("**********************************************************"); - System.out.println(" Statement \t NoIndex\tHash \tTree"); - System.out.println("**********************************************************"); - System.out.println(" SelectInt 1 \t "+timeTaken[0][0] +" \t \t"+ timeTaken[0][1]+ " \t"+ timeTaken[0][2]); - System.out.println(" SelectStr 1 \t "+timeTaken[9][0] +" \t \t"+ timeTaken[9][1]+ " \t"+ timeTaken[9][2]); - System.out.println(" 1% Sel \t "+timeTaken[1][0] +" \t \t- \t"+ timeTaken[1][2]); - - System.out.println(" Min All \t "+timeTaken[2][0] +" \t \t- \t"+ timeTaken[2][2]); - System.out.println(" Sum All \t "+timeTaken[3][0] +" \t \t- \t-"); - System.out.println(" Insert 1 \t "+timeTaken[4][0] +" \t \t"+ timeTaken[4][1]+ " \t"+ timeTaken[4][2]); - System.out.println(" Update 1 \t "+timeTaken[5][0] +" \t \t"+ timeTaken[5][1]+ " \t"+ timeTaken[5][2]); - System.out.println(" Delete 1 \t "+timeTaken[6][0] +" \t \t"+ timeTaken[6][1]+ " \t"+ timeTaken[6][2]); - System.out.println(" Join(10K*1K)1 \t "+timeTaken[7][0] +" \t \t"+ timeTaken[7][1]+ "\t"+ timeTaken[7][2]); - System.out.println(" Join(10K*10K*1K)1\t "+timeTaken[8][0] +"\t \t"+ timeTaken[8][1]+ "\t"+ timeTaken[8][2]); - System.out.println("**********************************************************"); - - con.close(); - } - catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - - } -} diff --git a/test/performance/wisc/JDBCPopulate.java b/test/performance/wisc/JDBCPopulate.java deleted file mode 100644 index 2665606e..00000000 --- a/test/performance/wisc/JDBCPopulate.java +++ /dev/null @@ -1,120 +0,0 @@ -import java.sql.*; -import java.util.Random; -public class JDBCPopulate -{ - public static Random generator = new Random(); - public static int getRandom(int end) - { - double val = generator.nextDouble(); - val *=end; - return (int)(val); - } - - public static void populate(Connection con)throws Exception - { - PreparedStatement stmt = null; - String stmtStr=""; - String buf = "insert into big1 values(?,?,0,2,0,10,50,688,1950,4950,9950,1,100,?,'GXXXXXXXXXXXXXXXXXXXXXXXXXCXXXXXXXXXXXXXXXXXXXXXXXXA','OXXXXXXXXXXXXXXXXXXXXXXXXXOXXXXXXXXXXXXXXXXXXXXXXXXO');"; - stmtStr = buf; - stmt = con.prepareStatement(stmtStr); - int count = 0; - int ret =0; - for(int i=0; i<10000; i++){ - stmt.setInt(1, i); - stmt.setInt(2, i); - stmt.setString(3, "Value" + i); - ret = stmt.executeUpdate(); - if(ret!=1) { - System.out.println("Table population failed"); - return; - } - if (i % 1000 == 0) con.commit(); - count++; - } - con.commit(); - stmt.close(); - System.out.println("Records Inserted into big1 table: "+count); - - stmtStr = "insert into big2 values(?,?,0,2,0,10,50,688,1950,4950,9950,1,100,'AXXXXXXXXXXXXXXXXXXXXXXXXXCXXXXXXXXXXXXXXXXXXXXXXXX','GXXXXXXXXXXXXXXXXXXXXXXXXXCXXXXXXXXXXXXXXXXXXXXXXXXA','OXXXXXXXXXXXXXXXXXXXXXXXXXOXXXXXXXXXXXXXXXXXXXXXXXXO');"; - stmt = con.prepareStatement(stmtStr); - count = 0; - for(int i=0; i<10000; i++){ - stmt.setInt(1, i); - stmt.setInt(2, i); - ret = stmt.executeUpdate(); - if(ret!=1) { - System.out.println("Table population failed"); - return; - } - if (i % 1000 == 0) con.commit(); - count++; - } - con.commit(); - stmt.close(); - System.out.println("Records Inserted into big2 table: "+count); - - stmtStr = "insert into small values(?,?,0,2,0,10,50,688,1950,4950,9950,1,100,'AXXXXXXXXXXXXXXXXXXXXXXXXXCXXXXXXXXXXXXXXXXXXXXXXXX','GXXXXXXXXXXXXXXXXXXXXXXXXXCXXXXXXXXXXXXXXXXXXXXXXXXA','OXXXXXXXXXXXXXXXXXXXXXXXXXOXXXXXXXXXXXXXXXXXXXXXXXXO');"; - stmt = con.prepareStatement(stmtStr); - count = 0; - for(int i=0; i<1000; i++){ - stmt.setInt(1, i); - stmt.setInt(2, i); - ret = stmt.executeUpdate(); - if(ret!=1) { - System.out.println("Table population failed"); - return; - } - if (i % 100 == 0) con.commit(); - count++; - } - con.commit(); - stmt.close(); - System.out.println("Records Inserted into small table: "+count); - - return; - } - -//***************************************************** -public static void main(String[] args) - - { - int flag=1; - if (args.length == 1) - { - if (args[0].equals("csql")) flag=1; - else if (args[0].equals("mysql")) flag=2; - else { - System.out.println("Valid values: csql or mysql"); - return; - } - } - try - { - Connection con = null; - if (flag == 1) { - Class.forName("csql.jdbc.JdbcSqlDriver"); - con = DriverManager.getConnection("jdbc:csql", "root", "manager"); - }else if (flag == 2) { - Class.forName("com.mysql.jdbc.Driver"); - con = DriverManager.getConnection("jdbc:mysql://localhost/test", "root", ""); - } - con.setAutoCommit(false); - con.setTransactionIsolation(Connection.TRANSACTION_READ_COMMITTED); - Statement cStmt = con.createStatement(); - try { - cStmt.execute("CREATE TABLE small (unique1 INT NOT NULL , unique2 INT NOT NULL , two INT NOT NULL , four INT NOT NULL , ten INT NOT NULL , twenty INT NOT NULL , onepercent INT NOT NULL , tenpercent INT NOT NULL , twentypercent INT NOT NULL , fiftypercent INT NOT NULL , unique3 INT NOT NULL , evenonepercent INT NOT NULL , oddonepercent INT NOT NULL , stringu1 CHAR (52) NOT NULL , stringu2 CHAR (52) NOT NULL , string4 CHAR (52) NOT NULL );"); - cStmt.execute("CREATE TABLE big1 (unique1 INT NOT NULL , unique2 INT NOT NULL , two INT NOT NULL , four INT NOT NULL , ten INT NOT NULL , twenty INT NOT NULL , onepercent INT NOT NULL , tenpercent INT NOT NULL , twentypercent INT NOT NULL , fiftypercent INT NOT NULL , unique3 INT NOT NULL , evenonepercent INT NOT NULL , oddonepercent INT NOT NULL , stringu1 CHAR (52) NOT NULL , stringu2 CHAR (52) NOT NULL , string4 CHAR (52) NOT NULL );"); - cStmt.execute("CREATE TABLE big2 (unique1 INT NOT NULL , unique2 INT NOT NULL , two INT NOT NULL , four INT NOT NULL , ten INT NOT NULL , twenty INT NOT NULL , onepercent INT NOT NULL , tenpercent INT NOT NULL , twentypercent INT NOT NULL , fiftypercent INT NOT NULL , unique3 INT NOT NULL , evenonepercent INT NOT NULL , oddonepercent INT NOT NULL , stringu1 CHAR (52) NOT NULL , stringu2 CHAR (52) NOT NULL , string4 CHAR (52) NOT NULL );"); - cStmt.close(); - con.commit(); - }catch(Exception e ){e.printStackTrace(); System.out.println("Error creating index");} - populate(con); - con.close(); - - } catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - - } -} diff --git a/test/performance/wisc/Makefile b/test/performance/wisc/Makefile deleted file mode 100644 index d738755c..00000000 --- a/test/performance/wisc/Makefile +++ /dev/null @@ -1,19 +0,0 @@ -CC=g++ -O2 -INCL= -I$(CSQL_INSTALL_ROOT)/include -#LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcrypt -lrt -lodbc -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcrypt -lrt -lcsqlodbc -lcacheload -ALL_CC_FLAG=$(INCL) $(LIBS) -JAVAC = javac -g:none - -all: odbcBench JDBCBench JDBCPopulate - -odbcBench: odbcBench.c - $(CC) $(ALL_CC_FLAG) -o odbcBench odbcBench.c -JDBCBench: JDBCBench.java - $(JAVAC) JDBCBench.java - -JDBCPopulate: JDBCPopulate.java - $(JAVAC) JDBCPopulate.java -clean: - rm -rf *.o odbcBench - rm -rf *.class diff --git a/test/performance/wisc/README b/test/performance/wisc/README deleted file mode 100644 index c9e47810..00000000 --- a/test/performance/wisc/README +++ /dev/null @@ -1,30 +0,0 @@ -Wisconsin Benchmark Suite -------------------------- -set the following in csql.conf file -MAX_SYS_DB_SIZE=104857600 -MAX_DB_SIZE=104857600 - -Run make to build the suite as follows ---------------------------- -$make - -To populate the database run ----------------------------- -$java JDBCPopulate - -For mysql -$java JDBCPopulate mysql - - -To run odbc test -$./odbcBench - -For mysql, edit(uncomment) Makefile to link with unixODBC library -$./odbcBench mysql - -To run csql jdbc test ---------------------- -$java JDBCBench - -For mysql, set the CLASSPATH to point to mysql jdbc jar file and run -$java JDBCBench mysql diff --git a/test/performance/wisc/odbcBench.c b/test/performance/wisc/odbcBench.c deleted file mode 100644 index 5c099de4..00000000 --- a/test/performance/wisc/odbcBench.c +++ /dev/null @@ -1,612 +0,0 @@ - -#include -#include -#include -#include -#include -#include -#include -#include "NanoTimer.h" -#define ITERATION 100 -using namespace std; -bool mysql; - -NanoTimer timer; -long long int timevalues[30]={0}; -void extract_error( - char *fn, - SQLHANDLE handle, - SQLSMALLINT type) -{ - SQLINTEGER i = 0; - SQLINTEGER native; - SQLCHAR state[ 7 ]; - SQLCHAR text[256]; - SQLSMALLINT len; - SQLRETURN ret; - - fprintf(stderr, - "\n" - "The driver reported the following diagnostics whilst running " - "%s\n\n", - fn); - - do - { - ret = SQLGetDiagRec(type, handle, ++i, state, &native, text, - sizeof(text), &len ); - if (SQL_SUCCEEDED(ret)) - printf("%s:%ld:%ld:%s\n", state, i, native, text); - } - while( ret == SQL_SUCCESS ); -} - -inline void -check_error (SQLSMALLINT handleType, SQLHANDLE handle, int rc, int line) -{ - if (rc) - { - cout << "Error " << rc << " at line: " << line << endl; - SQLCHAR state[10]; - SQLINTEGER native; - SQLCHAR mesg[300]; - int i=0; - while (SQLGetDiagRec (handleType, handle, i++, state, &native, mesg, 300, - NULL) == SQL_SUCCESS) - { - mesg[299] = '\0'; - cout << "state: " << state << endl; - cout << "native: " << native << endl; - cout << "mesg: " << mesg << endl; - } - exit (1); - } -} - - -inline void checkrc (int rc, int line) -{ - if (rc) - { - cout << "Error " << rc << " at line: " << line << endl; - exit (1); - } -} - -void readWriteTrans (SQLHDBC hdbc) -{ - int rc = SQLSetConnectAttr (hdbc, SQL_ATTR_ACCESS_MODE, - (SQLPOINTER) SQL_MODE_READ_WRITE, 0); - checkrc (rc, __LINE__); - rc = SQLEndTran (SQL_HANDLE_DBC, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); -} - -void readOnlyTrans (SQLHDBC hdbc) -{ - int rc = SQLSetConnectAttr (hdbc, SQL_ATTR_ACCESS_MODE, - (SQLPOINTER) SQL_MODE_READ_ONLY, 0); - checkrc (rc, __LINE__); - rc = SQLEndTran (SQL_HANDLE_DBC, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); -} - -void createHashIndex(SQLHANDLE hstmt,bool flag) -{ - int rc; - if (mysql) { - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx1 USING HASH ON big1(unique1);", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx2 USING HASH ON big2(unique1);", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx3 USING HASH ON small(unique1)", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx4 USING HASH ON big1(stringu1)", SQL_NTS ); - checkrc (rc, __LINE__); - } else { - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx1 ON big1(unique1) HASH;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx2 ON big2(unique1) HASH;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx3 ON small(unique1) HASH", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx4 ON big1(stringu1) HASH", SQL_NTS ); - checkrc (rc, __LINE__); - } -} -void createTreeIndex(SQLHANDLE hstmt,bool flag) -{ - int rc; - if (mysql) - { - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx5 USING BTREE ON big1(unique1);", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx6 USING BTREE ON big2(unique1);", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx7 USING BTREE ON small(unique1);", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx8 USING BTREE ON big1(stringu1);", SQL_NTS ); - checkrc (rc, __LINE__); - }else { - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx5 ON big1(unique1) TREE;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx6 ON big2(unique1) TREE;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx7 ON small(unique1) TREE;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "CREATE INDEX idx8 ON big1(stringu1) TREE;", SQL_NTS ); - checkrc (rc, __LINE__); - } - -} -void dropHashIndex(SQLHANDLE hstmt,bool flag) -{ - int rc; - if (mysql) { - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx1 on big1 ;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx2 on big2;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx3 on small", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx4 on big1;", SQL_NTS ); - checkrc (rc, __LINE__); - } else { - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx1 ;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx2 ;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx3 ;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx4 ;", SQL_NTS ); - checkrc (rc, __LINE__); - } -} -void dropTreeIndex(SQLHANDLE hstmt,bool flag) -{ - int rc; - if (mysql) - { - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx5 on big1 ;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx6 on big2;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx7 on small;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx8 on big1;", SQL_NTS ); - checkrc (rc, __LINE__); - }else { - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx5 ;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx6 ;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx7 ;", SQL_NTS ); - checkrc (rc, __LINE__); - rc = SQLExecDirect(hstmt, (SQLCHAR*) "DROP INDEX idx8 ;", SQL_NTS ); - checkrc (rc, __LINE__); - } - -} - -long long int onePerSel(SQLHANDLE henv, SQLHANDLE hdbc, SQLHANDLE hstmt) -{ - int uni1; - int uni2; - char str1[200]; - char str2[200]; - int val[] = {1, 5, 10, 50, 100, 500, 1000, 5000 ,7500, 9900};; - int tempTermVar=0; - int tempTermVar2=0; - char tempval[124]="Value"; - int rc; - readOnlyTrans (hdbc); - rc = SQLPrepare (hstmt, (unsigned char *) "SELECT unique1, unique2, stringu1 from big1 where unique1 between ? and ?;", SQL_NTS); - checkrc (rc, __LINE__); - rc = SQLBindParameter (hstmt, 1, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, 0, 0, &tempTermVar, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindParameter (hstmt, 2, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, 0, 0, &tempTermVar2, 0, NULL); - checkrc (rc, __LINE__); - - rc = SQLBindCol (hstmt, 1, SQL_INTEGER, &uni1, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 2, SQL_INTEGER, &uni2, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 3, SQL_C_CHAR, str1, sizeof (str1), NULL); - checkrc (rc, __LINE__); - //rc = SQLBindCol (hstmt, 4, SQL_C_CHAR, str2, sizeof (str2), NULL); - //checkrc (rc, __LINE__); - - int i, j, k; - int Count; - - timer.reset (); - - /* Run 1per Test */ - for (i = 0; i < 10; i++) - { - Count=0; - strcpy(tempval,"Value"); - tempTermVar = val[i] ; - tempTermVar2 = val[i]+99 ; - timer.start (); - rc = SQLExecute (hstmt); - checkrc (rc, __LINE__); - while(SQL_SUCCEEDED(rc = SQLFetch(hstmt))) - { - Count++; - } - // printf("Count=%d\n",Count); - rc = SQLCloseCursor (hstmt); - checkrc (rc, __LINE__); - rc = SQLTransact (henv, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); - timer.stop (); - } - readWriteTrans (hdbc); - //printf ("Read: 1 %lld\n", timer.avg ()); - return timer.avg()/1000; -} - -long long int runReadTest (SQLHANDLE henv, SQLHANDLE hdbc,SQLHANDLE hstmt,bool flag) -{ - int uni1; - int uni2; - char str1[200]; - char str2[200]; - - int val[] = {1, 10, 100, 500, 1000, 5000 ,7500, 8000, 9000, 9999}; - int tempTermVar=0; - char tempval[124]="Value"; - int rc; - - /* Set read-only transaction type */ - readOnlyTrans (hdbc); - if(flag){ - rc = SQLPrepare (hstmt, (unsigned char *) "SELECT unique1, unique2, stringu1, stringu2 from big1 where unique1=?;", SQL_NTS); - } - else { - rc = SQLPrepare (hstmt, (unsigned char *) "SELECT unique1, unique2, stringu1, stringu2 from big1 where stringu1=?;", SQL_NTS); - } - checkrc (rc, __LINE__); - long sz = 0; - if(flag){ - rc = SQLBindParameter (hstmt, 1, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, 0, 0, &tempTermVar, 0, NULL); - checkrc (rc, __LINE__); - } - else{ - rc = SQLBindParameter (hstmt, 1, SQL_PARAM_INPUT, SQL_C_CHAR, SQL_C_CHAR, 196, 0, tempval, 0, NULL); - checkrc (rc, __LINE__); - - } - rc = SQLBindCol (hstmt, 1, SQL_INTEGER, &uni1, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 2, SQL_INTEGER, &uni2, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 3, SQL_C_CHAR, str1, sizeof (str1), NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 4, SQL_C_CHAR, str2, sizeof (str2), NULL); - checkrc (rc, __LINE__); - - int i, j, k; - int Count; - - timer.reset (); - - /* Run 1per Test */ - for (i = 0; i < 10; i++) - { - strcpy(tempval,"Value"); - if(flag){ - tempTermVar = val[i] ;} - else{ - char buf[10]; - sprintf(buf,"%d",val[i]); - strcat(tempval,buf); - } - timer.start (); - rc = SQLExecute (hstmt); - checkrc (rc, __LINE__); - rc = SQLFetch (hstmt); - checkrc (rc, __LINE__); - Count++; - rc = SQLCloseCursor (hstmt); - checkrc (rc, __LINE__); - rc = SQLTransact (henv, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); - timer.stop (); - } - //printf ("Read: 1 %lld\n", timer.avg ()); - /* Set read-write transaction type */ - readWriteTrans (hdbc); - return timer.avg()/1000; -} - - -//aggregate -long long int aggregate(SQLHANDLE henv, SQLHANDLE hdbc,SQLHANDLE hstmt,bool flag) -{ - int summin; - int rc; - /* Set read-only transaction type */ - readOnlyTrans (hdbc); - if(flag){ - rc = SQLPrepare (hstmt, (unsigned char *) "SELECT MIN(unique1) from big1;", SQL_NTS); - } - else { - rc = SQLPrepare (hstmt, (unsigned char *) "SELECT SUM(unique1) from big1;", SQL_NTS); - } - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 1, SQL_INTEGER, &summin, 0, NULL); - checkrc (rc, __LINE__); - - int i, j, k; - int Count; - - timer.reset (); - for (i = 0; i < 10; i++) - { - timer.start (); - rc = SQLExecute (hstmt); - checkrc (rc, __LINE__); - rc = SQLFetch (hstmt); - checkrc (rc, __LINE__); - Count++; - // printf("value=%d",summin); - rc = SQLCloseCursor (hstmt); - checkrc (rc, __LINE__); - rc = SQLTransact (henv, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); - timer.stop (); - } - //printf ("Read: 1 %lld\n", timer.avg ()); - /* Set read-write transaction type */ - readWriteTrans (hdbc); - return timer.avg()/1000; - -} - -long long int dmlstatement(SQLHANDLE henv, SQLHANDLE hdbc,SQLHANDLE hstmt,int val) -{ - int tempTermVar=10000,tempTermVar2=10000; - int rc; - /* Set read-only transaction type */ - readOnlyTrans (hdbc); - if(val==1){ - rc = SQLPrepare (hstmt, (unsigned char *) "insert into big1 values(?,?,0,2,0,10,50,688,1950,4950,9950,1,100,'MXXXXXXXXXXXXXXXXXXXXXXXXXGXXXXXXXXXXXXXXXXXXXXXXXXC','GXXXXXXXXXXXXXXXXXXXXXXXXXCXXXXXXXXXXXXXXXXXXXXXXXXA','OXXXXXXXXXXXXXXXXXXXXXXXXXOXXXXXXXXXXXXXXXXXXXXXXXXO');", SQL_NTS); - } - else if(val==2){ - rc = SQLPrepare (hstmt, (unsigned char *) "UPDATE big1 SET two=1 WHERE unique1=?;", SQL_NTS); - }else - { - rc = SQLPrepare (hstmt, (unsigned char *) "DELETE FROM big1 WHERE unique1=?;", SQL_NTS); - } - checkrc (rc, __LINE__); - - int i, j, k; - int Count; - - timer.reset (); - for (i = 0; i < 100; i++) - { tempTermVar+=i; - rc = SQLBindParameter (hstmt, 1, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, 0, 0, &tempTermVar, 0, NULL); - checkrc (rc, __LINE__); - if(val==1) - { - tempTermVar2+=i; - rc = SQLBindParameter (hstmt, 1, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, 0, 0, &tempTermVar2, 0, NULL); - checkrc (rc, __LINE__); - } - timer.start (); - rc = SQLExecute (hstmt); - checkrc (rc, __LINE__); - rc = SQLTransact (henv, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); - timer.stop (); - tempTermVar=10000;tempTermVar2=10000; - } - //printf ("Read: 1 %lld\n", timer.avg ()); - /* Set read-write transaction type */ - readWriteTrans (hdbc); - return timer.avg()/1000; - -} - -//Joining -long long int joining(SQLHANDLE henv, SQLHANDLE hdbc, SQLHANDLE hstmt,int flag) -{ - int uni1; - int uni2,uni3,uni4,uni5; - char str1[200]; - char str2[200]; - - int val[] = {1, 5, 10, 50, 100, 250, 500, 750, 900, 999}; - int tempTermVar=0; - char tempval[124]="Value"; - int rc; - - /* Set read-only transaction type */ - readOnlyTrans (hdbc); - if(flag==1){ - rc = SQLPrepare (hstmt, (unsigned char *) "SELECT big1.unique1, big1.unique2, small.unique1, small.stringu1 FROM small,big1 WHERE big1.unique1=small.unique1 AND small.unique1=?;", SQL_NTS); - } - else { - rc = SQLPrepare (hstmt, (unsigned char *) "SELECT small.unique1, big1.unique1, big2.unique1, small.stringu1, big1.unique2, big2.unique2 FROM big1, big2, small WHERE small.unique1=big1.unique1 AND big1.unique1=big2.unique1 AND big1.unique1 = ?;", SQL_NTS); - } - checkrc (rc, __LINE__); - long sz = 0; - rc = SQLBindParameter (hstmt, 1, SQL_PARAM_INPUT, SQL_C_LONG, SQL_INTEGER, 0, 0, &tempTermVar, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 1, SQL_INTEGER, &uni1, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 2, SQL_INTEGER, &uni2, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 2, SQL_INTEGER, &uni3, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 4, SQL_C_CHAR, str1, sizeof (str1), NULL); - checkrc (rc, __LINE__); - if(flag==2){ - rc = SQLBindCol (hstmt, 5, SQL_INTEGER, &uni4, 0, NULL); - checkrc (rc, __LINE__); - rc = SQLBindCol (hstmt, 6, SQL_INTEGER, &uni5, 0, NULL); - checkrc (rc, __LINE__); - } - int i, j, k; - int Count; - - timer.reset (); - - /* Run 1per Test */ - for (i = 0; i < 10; i++) - { - tempTermVar = val[i] ; - timer.start (); - rc = SQLExecute (hstmt); - checkrc (rc, __LINE__); - rc = SQLFetch(hstmt); - Count++; -// printf("%d,%d\n",uni1,uni3); - rc = SQLCloseCursor (hstmt); - checkrc (rc, __LINE__); - rc = SQLTransact (henv, hdbc, SQL_COMMIT); - checkrc (rc, __LINE__); - timer.stop (); - } - //printf ("Read: 1 %lld\n", timer.avg ()); - /* Set read-write transaction type */ - readWriteTrans (hdbc); - return timer.avg()/1000; -} - - -void printTime() -{ - printf("Wisconsin Benchmark Report:\n"); - printf("*******************************************************\n"); - printf(" Statement \t NoIndex Hash\t Tree\n"); - printf("*******************************************************\n"); - printf(" SelectInt 1 \t %lld\t %lld \t %lld\n",timevalues[0],timevalues[1],timevalues[2]); - printf(" SelectStr 1 \t %lld\t %lld \t %lld\n",timevalues[3],timevalues[4],timevalues[5]); - printf(" 1Per Sel \t %lld\t %lld \t %lld\n\n",timevalues[6],timevalues[7],timevalues[8]); - printf(" Min All \t %lld\t %lld \t %lld\n",timevalues[9],timevalues[10],timevalues[11]); - printf(" Sum All \t %lld\t %lld \t %lld\n\n",timevalues[12],timevalues[13],timevalues[14]); - printf(" Insert 1 \t %lld\t %lld \t %lld\n",timevalues[15],timevalues[16],timevalues[17]); - printf(" Update 1 \t %lld\t %lld \t %lld\n",timevalues[18],timevalues[19],timevalues[20]); - printf(" Delete 1 \t %lld\t %lld \t %lld\n\n",timevalues[21],timevalues[22],timevalues[23]); - printf(" Join(10K*1K)1 \t %lld\t %lld \t %lld\n",timevalues[24],timevalues[25],timevalues[26]); - printf(" Join(10K*10K*1K)1 \t %lld\t %lld \t %lld\n",timevalues[27],timevalues[28],timevalues[29]); - printf("*******************************************************\n"); - -} - -int main (int ac, char **av) -{ - int rc; - SQLHENV henv; - SQLHDBC hdbc; - SQLHSTMT hstmt; - mysql=false; - if (ac ==2) mysql = true; - //printf("Mysql Set %d \n", ac); return 0; - rc = SQLAllocHandle (SQL_HANDLE_ENV, SQL_NULL_HANDLE, &henv); - checkrc (rc, __LINE__); - SQLSetEnvAttr(henv, SQL_ATTR_ODBC_VERSION, (void *) SQL_OV_ODBC3, 0); - - rc = SQLAllocHandle (SQL_HANDLE_DBC, henv, &hdbc); - checkrc (rc, __LINE__); - if (!mysql) { - rc = SQLConnect (hdbc, - (SQLCHAR *) "test", (SQLSMALLINT) strlen ("test"), - (SQLCHAR *) "root", - (SQLSMALLINT) strlen ("root"), - (SQLCHAR *) "manager", - (SQLSMALLINT) strlen ("")); - }else { - - SQLCHAR outstr[1024]; - SQLSMALLINT outstrlen; - rc = SQLDriverConnect(hdbc, NULL, (SQLCHAR*)"DSN=myodbc3;", SQL_NTS, - outstr, sizeof(outstr), &outstrlen, - SQL_DRIVER_NOPROMPT); - } - - - if (SQL_SUCCEEDED(rc)) { - printf("Connected\n"); - //printf("Returned connection string was:\n\t%s\n", outstr); - if (rc == SQL_SUCCESS_WITH_INFO) { - printf("Driver reported the following diagnostics\n"); - extract_error("SQLDriverConnect", hdbc, SQL_HANDLE_DBC); - } - } else { - fprintf(stderr, "Failed to connect\n"); - extract_error("SQLDriverConnect", hdbc, SQL_HANDLE_DBC); - } - - //check_error (SQL_HANDLE_DBC, hdbc, rc, __LINE__); - checkrc (rc, __LINE__); - rc = SQLSetConnectOption (hdbc, SQL_AUTOCOMMIT, SQL_AUTOCOMMIT_OFF); - checkrc (rc, __LINE__); - rc = SQLAllocHandle (SQL_HANDLE_STMT, hdbc, &hstmt); - checkrc (rc, __LINE__); - int ins=1,upd=2,del=3; -//Query 1 - timevalues[0] = runReadTest (henv, hdbc, hstmt,true); - timevalues[3] = runReadTest (henv, hdbc, hstmt,false); - timevalues[6] = onePerSel(henv, hdbc, hstmt); - timevalues[9] = aggregate(henv, hdbc, hstmt,true); - timevalues[12] = aggregate(henv, hdbc, hstmt,false); - timevalues[15] = dmlstatement(henv, hdbc, hstmt,ins); - timevalues[18] = dmlstatement(henv, hdbc, hstmt,upd); - timevalues[21] = dmlstatement(henv, hdbc, hstmt,del); - timevalues[24] = joining(henv, hdbc, hstmt,1); - timevalues[27] = joining(henv, hdbc, hstmt,2); - printf("NON INDEX OVER\n"); - -//Hash - createHashIndex( hstmt,true); - timevalues[1] = runReadTest (henv, hdbc, hstmt,true); - timevalues[4] = runReadTest (henv, hdbc, hstmt,false); - timevalues[7] = onePerSel(henv, hdbc, hstmt); - timevalues[10] = aggregate(henv, hdbc, hstmt,true); - timevalues[13] = aggregate(henv, hdbc, hstmt,false); - timevalues[16] = dmlstatement(henv, hdbc, hstmt,ins); - timevalues[19] = dmlstatement(henv, hdbc, hstmt,upd); - timevalues[22] = dmlstatement(henv, hdbc, hstmt,del); - timevalues[25] = joining(henv, hdbc, hstmt,1); - timevalues[28] = joining(henv, hdbc, hstmt,2); - dropHashIndex(hstmt,true); - printf("HASH INDEX OVER\n"); - //printTime(); - -//TREE - createTreeIndex(hstmt,true); - timevalues[2] = runReadTest (henv, hdbc, hstmt,true); - timevalues[5] = runReadTest (henv, hdbc, hstmt,false); - timevalues[8] = onePerSel(henv, hdbc, hstmt); - timevalues[11] = aggregate(henv, hdbc, hstmt,true); - timevalues[14] = aggregate(henv, hdbc, hstmt,false); - timevalues[17] = dmlstatement(henv, hdbc, hstmt,ins); - timevalues[20] = dmlstatement(henv, hdbc, hstmt,upd); - timevalues[23] = dmlstatement(henv, hdbc, hstmt,del); - timevalues[26] = joining(henv, hdbc,hstmt,1); - timevalues[29] = joining(henv, hdbc,hstmt,2); - dropTreeIndex(hstmt,true); - printf("TREE INDEX OVER\n"); - - printTime(); - rc = SQLEndTran(SQL_HANDLE_DBC, hdbc, SQL_COMMIT ); - checkrc (rc, __LINE__); - - rc = SQLFreeHandle (SQL_HANDLE_STMT, hstmt); - checkrc (rc, __LINE__); - rc = SQLDisconnect (hdbc); - checkrc (rc, __LINE__); - rc = SQLFreeHandle (SQL_HANDLE_DBC, hdbc); - checkrc (rc, __LINE__); - rc = SQLFreeHandle (SQL_HANDLE_ENV, henv); - checkrc (rc, __LINE__); - exit (0); -} - - - diff --git a/test/performance/wisc/wbench.c b/test/performance/wisc/wbench.c deleted file mode 100644 index 8a684645..00000000 --- a/test/performance/wisc/wbench.c +++ /dev/null @@ -1,685 +0,0 @@ - -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#include "support.h" -#include "db.h" - -#include "odbcDB.h" - -#define MAX_QUERIES 33 - -/* variables used for timing */ - -int verboseOut = 0; /* verboseOut flag */ - -int verify = 0; /* Flag set to 1 if "-v" is specified, verify means - count all the tuples and print out a message if they - don't match the expected value - */ - -int modify = 0; /* Flag to indicate whether or not to run the modification - queries. If set, tables are deleted on exit - */ - -int build = 0; /* Flag set to 1 if "-b" is - specified, build means to populate - the tables with the data and run - the modification tests. - */ - -int readOnly = 0; /* Flag to indicate whether or not we are set for read-only - transactions. - */ - -long numSmallTblTups = 1000; /* # of rows for the small table */ - -long numBigTblTups = 10000; /* # of rows for the big tables */ - -extern unsigned int querySelection; /* Query specification, 1 bit per query */ - -/* Table names */ -#define SMALLTBLNAME "small" -#define BIG1TBLNAME "big1" -#define BIG2TBLNAME "big2" -#define BPRIMETBLNAME "bprime" - -#define NUMTABLES 4 - -static char *tableNames[NUMTABLES] = { - SMALLTBLNAME, BIG1TBLNAME, BIG2TBLNAME, BPRIMETBLNAME, -}; - -void -usage(char *prog) -{ - char *progname; - - // Get base name of program - progname = strrchr(prog, '/'); - - if (progname == 0) - progname = prog; - else - progname++; - - /* Print the usage message */ - - fprintf(stderr, - "Usage:\t%s [-?] [-c ] [-v] [-verify] [-b] [-m] [-q ]\n" - " -? Same as -h.\n" - " -v Verbose trace messages\n" - " -q Specifies a comma-separated list of query numbers or\n" - " ranges (e.g., -q 1,3,5-7,10-14,25). If not specified,\n" - " ALL 32 queries are selected.\n" - " -b Build data store.\n" - " -m Run modify transactions (deletes data when done).\n" - " -verify Enables verification.\n" - " -readonly Set Queries to use readonly transactions.\n", - progname - ); -} - -int populateDatabase (class DB *db, int empty) -{ - int rc = 0; - int i; - - srand48(12345678); - - if (empty) - for (i=0; iemptyTable (tableNames[i]); - - rc += db->populateTable(SMALLTBLNAME, numSmallTblTups, numSmallTblTups); - - rc += db->populateTable(BPRIMETBLNAME, numBigTblTups/10, numBigTblTups); - - rc += db->populateTable(BIG1TBLNAME, numBigTblTups, numBigTblTups); - - rc += db->populateTable(BIG2TBLNAME, numBigTblTups, numBigTblTups); - - return rc; -} - -void -get_args(int argc, char **argv) -{ - int i = 1; - - while (i < argc) { - - if (!strcmp(argv[i], "-?")) { - usage(argv[0]); - exit(1); - } - else if ( !strcmp("-verify", argv[i]) ) { - verify = 1; - if (verboseOut) - printf ("Verification enabled.\n"); - i += 1; - } - else if (!strcmp("-q", argv[i])) { - if (i + 1 >= argc) { - usage(argv[0]); - exit(1); - } - if (setQueries(argv[i+1])) { - usage(argv[0]); - exit(1); - } - i += 2; - } - else if ( !strcmp("-b", argv[i]) ) { - build = 1; - if (verboseOut) - printf ("Data store build enabled.\n"); - i += 1; - } - else if (!strcmp("-v", argv[i])) { - verboseOut = 1; - printf ("Verbose Tracing Enabled.\n"); - i += 1; - } - else if (!strcmp("-readonly", argv[i])) { - readOnly = 1; - if (verboseOut) - printf ("Readonly transaction set for Queries.\n"); - i += 1; - } - else if (!strcmp("-m", argv[i])) { - modify = 1; - if (verboseOut) - printf ("Modification queries enabled.\n"); - i += 1; - } - else { - usage(argv[0]); - exit(1); - } - } -} - -int -main(int argc, char *argv[]) -{ - int i, rc; - char *connect_string = 0; - char queryBuf1[512]; - char queryBuf2[512]; - class wiscTimer *timer[MAX_QUERIES]; - class DB *db = 0; - - - /* parse the command line arguments */ - - get_args(argc, argv); - - for (i=0; iconnect (connect_string); - - if (rc) { - printf ("ERROR in connection\n"); - exit(1); - } - - //printf ("build = %d\n", build); - - if (build) { - /* Delete and recreate the tables */ - - for (i=0; idropTable (tableNames[i]); - rc = db->createTable (tableNames[i]); - if (rc) - { - printf("Create Tables failed"); exit(1); - } - } - - populateDatabase (db, 0); - - if (verboseOut) - printf ("Database Population Complete.\n"); - - } - else { - /* Drop indexes so Non-Indexed Queries */ - db->dropIndex ("idx1", "small"); - db->dropIndex ("idx2", "small"); - db->dropIndex ("idx3", "big1"); - db->dropIndex ("idx4", "big1"); - db->dropIndex ("idx5", "big2"); - db->dropIndex ("idx6", "big2"); - } - - /* execute the non-indexed queries */ - - if (verboseOut) - printf ("Running Non-Indexed Queries...\n"); - - /* query 1 - 1% selection on large table, no index */ - - rc = db->selectionQuery(1, timer[1], - "select * from big1 where unique2 between %d and %d", - "select * from big2 where unique2 between %d and %d", - numBigTblTups, numBigTblTups/100, 0, verify, 2, 2); - if (rc) - printf ("Query 1 failed\n"); - - /* query 2 - 10% selection on large table, no index */ - - rc = db->selectionQuery(2, timer[2], - "select * from big1 where unique2 between %d and %d", - "select * from big2 where unique2 between %d and %d", - numBigTblTups, numBigTblTups/10, 0, verify, 5, 2); - if (rc) - printf ("Query 2 failed\n"); - - /* query 9 - one join with range-selected input, no index */ - -/* - sprintf(queryBuf1, - "select * from big1, big2 where big1.unique2 = big2.unique2 and big2.unique2 < %d", - numBigTblTups/10); - sprintf(queryBuf2, - "select * from big1, big2 where big1.unique2 = big2.unique2 and big1.unique2 < %d", - numBigTblTups/10); - - rc = db->selectionQuery(9, timer[9], queryBuf1, queryBuf2, - numBigTblTups, numBigTblTups/10, 0, verify, 2, 0); - if (rc) - printf ("Query 9 failed\n"); - - // query 10 - single join, no index - - rc = db->selectionQuery(10, timer[10], - "select * from big1, bprime where big1.unique2 = bprime.unique2", - "select * from big2, bprime where big2.unique2 = bprime.unique2", - numBigTblTups, numBigTblTups/10, 0, verify, 2, 0); - if (rc) - printf ("Query 10 failed\n"); - -*/ - // query 11 - two joins with filtered input, no index -/* - sprintf(queryBuf1, "select * from small, big1, big2 " - "where big1.unique2 = big2.unique2 and " - "small.unique2 = big1.unique2 and " - "big1.unique2 < %d", numBigTblTups/10); - - sprintf(queryBuf2, "select * from small, big2, big1 " - "where big2.unique2 = big1.unique2 and " - "small.unique2 = big2.unique2 and " - "big2.unique2 < %d", numBigTblTups/10); - - rc = db->selectionQuery(11, timer[11], queryBuf1, queryBuf2, - numBigTblTups, numBigTblTups/10, 0, verify, 2, 0); - if (rc) - printf ("Query 11 failed\n"); -*/ - /* query 18 - projection, 1% */ - - rc = db->selectionQuery (18, timer[18], - "select distinct two, four, ten, twenty, onepercent, string4 from big1", - "select distinct two, four, ten, twenty, onepercent, string4 from big2", - numBigTblTups, 400, 0, verify, 2, 0); - - if (rc) - printf ("Query 18 failed\n"); - - /* query 19 - projection, 100% */ - - rc = db->selectionQuery (19, timer[19], - "select distinct two, four, ten, twenty, onepercent, tenpercent, twentypercent, fiftypercent, unique3, " - "evenonepercent, oddonepercent, stringu1, stringu2, string4 from big1", - "select distinct two, four, ten, twenty, onepercent, tenpercent, twentypercent, fiftypercent, unique3, " - "evenonepercent, oddonepercent, stringu1, stringu2, string4 from big2", - numBigTblTups, numBigTblTups, 0, verify, 2, 0); - - if (rc) - printf ("Query 19 failed"); - - // query 20 - min. agg., no grouping - - rc = db->selectionQuery (20, timer[20], - "select min(unique2) from big1", - "select min(unique2) from big2", - numBigTblTups, 1, 0, verify, 2, 0); - - if (rc) - printf ("Query 20 failed\n"); - - // query 21 - min. agg., 100 groups - - rc = db->selectionQuery (21, timer[21], - "select min(unique2) from big1 group by onepercent", - "select min(unique2) from big2 group by onepercent", - numBigTblTups, 100, 0, verify, 2, 0); - - if (rc) - printf ("Query 21 failed\n"); - - // query 22 - sum agg., 100 groups - - rc = db->selectionQuery (22, timer[22], - "select sum(unique2) from big1 group by onepercent", - "select sum(unique2) from big2 group by onepercent", - numBigTblTups, 100, 0, verify, 2, 0); - - if (rc) - printf ("Query 22 failed\n"); - - if (modify) { - // query 26 - insert one row, no index - - rc = db->runInsert(26, timer[26], numBigTblTups, BIG1TBLNAME, BIG2TBLNAME); - - if (rc) - printf ("Query 26, Insert failed\n"); - - // query 27 - delete one row, no index - - rc = db->runDelete(27, timer[27], numBigTblTups, BIG1TBLNAME, BIG2TBLNAME); - if (rc) - printf ("Query 27, Delete failed\n"); - - // query 28 - update key attribute, no index - rc = db->runUpdate(28, timer[28], "unique2", numBigTblTups, - BIG1TBLNAME, BIG2TBLNAME); - if (rc) - printf ("Query 28, Update failed\n"); - - // Now destroy and recreate database. - - if (populateDatabase (db, 1)) - printf ("repopulation of database failed.\n"); - } - - // Use statement handle allocated to create tables * as handle for creating indices - - - //build indexes - - if (verboseOut) - printf ("Creating indices...\n"); - - db->createIndex ("idx1", "small", "unique1"); - db->createIndex ("idx2", "small", "unique2"); - db->createIndex ("idx3", "big1", "unique1"); - db->createIndex ("idx4", "big1", "unique2"); - db->createIndex ("idx5", "big2", "unique1"); - db->createIndex ("idx6", "big2", "unique2"); - - if (verboseOut) - printf ("Index Creation Completed\n"); - - /* indexed queries */ - - if (verboseOut) - printf ("Executing Indexed Queries...\n"); - - /* query 3 - 1% selection on big table, index */ - - rc = db->selectionQuery (3, timer[3], - "select * from big1 where unique2 between %d and %d", - "select * from big2 where unique2 between %d and %d", - numBigTblTups, numBigTblTups/100, 0, verify, 5, 2); - if (rc) - printf ("Query 3 failed\n"); - - /* query 4 - 10% selection on big table, index */ - - rc = db->selectionQuery (4, timer[4], - "select * from big1 where unique2 between %d and %d", - "select * from big2 where unique2 between %d and %d", - numBigTblTups, numBigTblTups/10, 0, verify, 5, 2); - if (rc) - printf ("Query 4 failed\n"); - - /* query 5 - 1% selection on big table, index */ - - rc = db->selectionQuery (5, timer[5], - "select * from big1 where unique1 between %d and %d", - "select * from big2 where unique1 between %d and %d", - numBigTblTups, numBigTblTups/100, 0, verify, 5, 2); - if (rc) - printf ("Query 5 failed\n"); - - /* query 6 - 10% selection on big table, index */ - - rc = db->selectionQuery (6, timer[6], - "select * from big1 where unique1 between %d and %d", - "select * from big2 where unique1 between %d and %d", - numBigTblTups, numBigTblTups/10, 0, verify, 5, 2); - if (rc) - printf ("Query 6 failed\n"); - - /* query 7 - 1 row selection on big table, index */ - - rc = db->selectionQuery (7, timer[7], - "select * from big1 where unique2 = %d", - "select * from big2 where unique2 = %d", - numBigTblTups, 1, 1, verify, 5, 1); - if (rc) - printf ("Query 7 failed\n"); - - /* query 8 - 1% selection on big table, index */ - - rc = db->selectionQuery (8, timer[8], - "select * from big1 where unique2 between %d and %d", - "select * from big2 where unique2 between %d and %d", - numBigTblTups, numBigTblTups/100, 0, verify, 5, 2); - if (rc) - printf ("Query 8 failed\n"); - - /* query 12 - one join with filtered input, with index */ -/* - sprintf(queryBuf1, - "select * from big1, big2 where big1.unique2 = big2.unique2 and big2.unique2 < %d", - numBigTblTups/10); - - sprintf(queryBuf2, - "select * from big2, big1 where big2.unique2 = big1.unique2 and big1.unique2 < %d", - numBigTblTups/10); - - rc = db->selectionQuery (12, timer[12], queryBuf1, queryBuf2, numBigTblTups, - numBigTblTups/10, 0, verify, 2, 0); - if (rc) - printf ("Query 12 failed\n"); - - // query 13 - one join, index - - rc = db->selectionQuery (13, timer[13], - "select * from big1, bprime where big1.unique2 = bprime.unique2", - "select * from big2, bprime where big2.unique2 = bprime.unique2", - numBigTblTups, numBigTblTups/10, 0, verify, 2, 0); - if (rc) - printf ("Query 13 failed\n"); - - // query 14 - two joins with filtered input, index - - sprintf(queryBuf1, - "select * from small, big1, big2 where big1.unique2 = big2.unique2 and " - "small.unique2 = big1.unique2 and big1.unique2 < %d", - numBigTblTups/10); - - sprintf(queryBuf2, - "select * from small, big2, big1 where big2.unique2 = big1.unique2 and " - "small.unique2 = big2.unique2 and big2.unique2 < %d", - numBigTblTups/10); - - rc = db->selectionQuery (14, timer[14], queryBuf1, queryBuf2, numBigTblTups, - numBigTblTups/10, 0, verify, 2, 0); - if (rc) - printf ("Query 14 failed\n"); - - - // query 15 - one join with filtered input, no index - - sprintf(queryBuf1, - "select * from big1, big2 where big1.unique1 = big2.unique1 and big2.unique1 < %d", - numBigTblTups/10); - - sprintf(queryBuf2, - "select * from big2, big1 where big2.unique1 = big1.unique1 and big1.unique1 < %d", - numBigTblTups/10); - - rc = db->selectionQuery (15, timer[15], queryBuf1, queryBuf2, numBigTblTups, - numBigTblTups/10, 0, verify, 2, 0); - if (rc) - printf ("Query 15 failed\n"); - - // query 16 - one join, index - - rc = db->selectionQuery (16, timer[16], - "select * from big1, bprime where big1.unique1 = bprime.unique1", - "select * from big2, bprime where big2.unique1 = bprime.unique1", - numBigTblTups, numBigTblTups/10, 0, verify, 2, 0); - if (rc) - printf ("Query 16 failed\n"); - - // query 17 - two joins with filtered input, index - - sprintf(queryBuf1, - "select * from small, big1, big2 where big1.unique1 = big2.unique1 and " - "small.unique1 = big1.unique1 and big1.unique1 < %d", - numBigTblTups/10); - - sprintf(queryBuf2, - "select * from small, big2, big1 where big2.unique1 = big1.unique1 and " - "small.unique1 = big2.unique1 and big2.unique1 < %d", - numBigTblTups/10); - - rc = db->selectionQuery (17, timer[17], queryBuf1, queryBuf2, numBigTblTups, - numBigTblTups/10, 0, verify, 2, 0); - if (rc) - printf ("Query 17 failed\n"); -*/ - - // query 23 - min. agg., no grouping - - rc = db->selectionQuery (23, timer[23], - "select min(unique2) from big1", - "select min(unique2) from big2", - numBigTblTups, 1, 0, verify, 2, 0); - - if (rc) - printf ("Query 23 failed\n"); - - // query 24 - min. agg., 100 groups - rc = db->selectionQuery (24, timer[24], - "select min(unique2) from big1 group by onepercent", - "select min(unique2) from big2 group by onepercent", - numBigTblTups, 100, 0, verify, 2, 0); - if (rc) - printf ("Query 24 failed\n"); - - // query 25 - sum agg., 100 groups - - rc = db->selectionQuery (25, timer[25], - "select avg(unique2) from big1", - "select avg(unique2) from big2", - numBigTblTups, 100, 0, verify, 2, 0); - if (rc) - printf ("Query 25 failed\n"); - - if (modify) { - // query 29 - insert one row, index - rc = db->runInsert (29, timer[29], numBigTblTups, - BIG1TBLNAME, BIG2TBLNAME); - if (rc) - printf ("Query 29 failed\n"); - - // query 30 - delete one row - - rc = db->runDelete(30, timer[30], numBigTblTups, - BIG1TBLNAME, BIG2TBLNAME); - if (rc) - printf ("Query 30 failed\n"); - - // query 31 - update key attribute - - rc = db->runUpdate(31, timer[31], "unique2", numBigTblTups, - BIG1TBLNAME, BIG2TBLNAME); - if (rc) - printf ("Query 31 failed\n"); - - // query 32 - update non-clustered key attribute - - rc = db->runUpdate(32, timer[32], "unique1", numBigTblTups, - BIG1TBLNAME, BIG2TBLNAME); - if (rc) - printf ("Query 32 failed\n"); - - for (i=0; idropTable (tableNames[i]); - } - } - db->disconnect(); - - - - printf("\nQuery Type No Index Index1 Index2 Query Numbers\n"); - printf("1%% Sel %12.6lf %12.6lf %12.6lf 1,3,5\n", - timer[1]->avgTime(wiscWallTime), - timer[3]->avgTime(wiscWallTime), - timer[5]->avgTime(wiscWallTime)); - - printf("10%% Sel %12.6lf %12.6lf %12.6lf 2,4,6\n", - timer[2]->avgTime(wiscWallTime), - timer[4]->avgTime(wiscWallTime), - timer[6]->avgTime(wiscWallTime)); - - printf("1 Tup Sel - %12.6lf - 7\n", - timer[7]->avgTime(wiscWallTime)); - - printf("1%% Sel - %12.6lf - 8\n", - timer[8]->avgTime(wiscWallTime)); - - printf("JoinAselB %12.6lf %12.6lf %12.6lf 9,12,15\n", - timer[9]->avgTime(wiscWallTime), - timer[12]->avgTime(wiscWallTime), - timer[15]->avgTime(wiscWallTime)); - - printf("JoinABprime %12.6lf %12.6lf %12.6lf 10,13,16\n", - timer[10]->avgTime(wiscWallTime), - timer[13]->avgTime(wiscWallTime), - timer[16]->avgTime(wiscWallTime)); - - printf("JoinCselAselB %12.6lf %12.6lf %12.6lf 11,14,17\n", - timer[11]->avgTime(wiscWallTime), - timer[14]->avgTime(wiscWallTime), - timer[17]->avgTime(wiscWallTime)); - - printf("MinAgg No Grps %12.6lf %12.6lf - 20,23\n", - timer[20]->avgTime(wiscWallTime), - timer[23]->avgTime(wiscWallTime)); - - printf("MinAgg 100 Grps %12.6lf %12.6lf - 21,24\n", - timer[21]->avgTime(wiscWallTime), - timer[24]->avgTime(wiscWallTime)); - - printf("SumAgg 100 Grps %12.6lf %12.6lf - 22,25\n", - timer[22]->avgTime(wiscWallTime), - timer[25]->avgTime(wiscWallTime)); - - printf("Delete 1 Tup %12.6lf - %12.6lf 27,30\n", - timer[27]->avgTime(wiscWallTime), - timer[30]->avgTime(wiscWallTime)); - - printf("Update 1 Tup %12.6lf %12.6lf %12.6lf 28,31,32\n", - timer[28]->avgTime(wiscWallTime), - timer[31]->avgTime(wiscWallTime), - timer[32]->avgTime(wiscWallTime)); - - printf("Insert 1 Tup %12.6lf - %12.6lf 26,29\n", - timer[26]->avgTime(wiscWallTime), - timer[29]->avgTime(wiscWallTime)); - - printf("1%% Prj No Dup %12.6lf - - 18\n", - timer[18]->avgTime(wiscWallTime)); - - printf("100%% Prj No Dup %12.6lf - - 19\n", - timer[19]->avgTime(wiscWallTime)); - - printf("\nBenchmark Results by Query - (times are in millisecs):\n"); - - printf ("\nQuery Wall-clk Resource User System\n"); - - - for (i=0; inumIters() != 0) { - printf ("%2d %14f %14f %14f %14f\n", i, - timer[i]->avgTime (wiscWallTime), - timer[i]->avgTime (wiscResTime), - timer[i]->avgTime (wiscUserTime), - timer[i]->avgTime (wiscSysTime)); - } - delete timer[i]; - timer[i] = 0; - } - - printf ("\n"); - - delete db; - - exit (0); -} diff --git a/test/sql/Aggregate/agg1.sql b/test/sql/Aggregate/agg1.sql deleted file mode 100644 index 9fe948fd..00000000 --- a/test/sql/Aggregate/agg1.sql +++ /dev/null @@ -1 +0,0 @@ -select count(*),min(f1),sum(f1) from t1; diff --git a/test/sql/Aggregate/aggmin4.sql b/test/sql/Aggregate/aggmin4.sql deleted file mode 100644 index f2fc2d44..00000000 --- a/test/sql/Aggregate/aggmin4.sql +++ /dev/null @@ -1 +0,0 @@ -select min(t10.f1) from t1; diff --git a/test/sql/Aggregate/aggregate1.sql b/test/sql/Aggregate/aggregate1.sql deleted file mode 100644 index 78c74eaf..00000000 --- a/test/sql/Aggregate/aggregate1.sql +++ /dev/null @@ -1,17 +0,0 @@ -echo select count(f1) from t2; -select count(f1) from t2; - -echo select count(f1) from t1; -select count(f1) from t1; - -echo select sum(f1) from t1; -select sum(f1) from t1; - -echo select avg(f1) from t1; -select avg(f1) from t1; - -echo select min(f1) from t1; -select min(f1) from t1; - -echo select max(f1) from t1; -select max(f1) from t1; diff --git a/test/sql/Aggregate/aggregate2.sql b/test/sql/Aggregate/aggregate2.sql deleted file mode 100644 index d4ecd7c9..00000000 --- a/test/sql/Aggregate/aggregate2.sql +++ /dev/null @@ -1,23 +0,0 @@ -echo select count(f1) from t1; -select count(t1.f1) from t1; - -echo select count(*) from t1 where f4='AAA'; -select count(*) from t1 where f4='AAA'; - -echo select sum(f1) from t1; -select sum(t1.f1) from t1; - -echo select avg(f1) from t1; -select avg(t1.f1) from t1; - -echo select min(t1.f1) from t1; -select min(t1.f1) from t1; - -echo select min(f4) from t1; -select min(f4) from t1; - -echo select max(t1.f1) from t1; -select max(t1.f1) from t1; - -echo select max(f4) from t1; -select max(f4) from t1; diff --git a/test/sql/Aggregate/aggregate4.sql b/test/sql/Aggregate/aggregate4.sql deleted file mode 100644 index 0cd0c53e..00000000 --- a/test/sql/Aggregate/aggregate4.sql +++ /dev/null @@ -1,11 +0,0 @@ -echo select min(t1.notexist) from t1; -select min(t1.notexist) from t1; - -echo select max(t1.f1), sum(t2.f1) from t1,t2 where t1.f1 = t2.f1 and t1.f1 <100; -select max(t1.f1), sum(t2.f1) from t1,t2 where t1.f1 = t2.f1 and t1.f1 <100; - -echo select max(t1.f1), sum(t2.f1) from t1,t2 where t1.f1 = t2.f1 and t1.f1 <100 group by t1.f2; -select max(t1.f1), sum(t2.f1) from t1,t2 where t1.f1 = t2.f1 and t1.f1 <100 group by t1.f2; - -echo select max(t1.f1), max(t2.notexist) from t1,t2 group by t1.f2; -select max(t1.f1), max(t2.notexist) from t1,t2 group by t1.f2; diff --git a/test/sql/Aggregate/aggregate5.sql b/test/sql/Aggregate/aggregate5.sql deleted file mode 100644 index 7d57755a..00000000 --- a/test/sql/Aggregate/aggregate5.sql +++ /dev/null @@ -1,15 +0,0 @@ - -echo select t1.f2, t1.f1, t2.f1 from t1,t2; -select t1.f2, t1.f1, t2.f1 from t1,t2; - -echo select t1.f2, t1.f1, t2.f1 from t1,t2 group by t1.f2; -select t1.f2, t1.f1, t2.f1 from t1,t2 group by t1.f2; - -echo select t1.f2, max(t1.f1), sum(t2.f1) from t1, t2 group by t1.f2; -select t1.f2, max(t1.f1), sum(t2.f1) from t1, t2 group by t1.f2; - -echo select f1, f2 from t1 group by f1,f2; -select f1, f2 from t1 group by f1,f2; - -echo select f1, sum(f2) from t1 group by f3; -select f1, sum(f2) from t1 group by f3; diff --git a/test/sql/Aggregate/aggregate6.sql b/test/sql/Aggregate/aggregate6.sql deleted file mode 100644 index 2ae2f579..00000000 --- a/test/sql/Aggregate/aggregate6.sql +++ /dev/null @@ -1,17 +0,0 @@ -echo select * from t1; -select * from t1; - -echo select min(t1.f2) from t1 group by t1.f1; -select min(t1.f2) from t1 group by t1.f1; - -echo select avg(t1.f2) from t1 group by t1.f1; -select avg(t1.f2) from t1 group by t1.f1; - -echo select sum(t1.f2) from t1 group by notexist; -select sum(t1.f2) from t1 group by notexist; - -echo select sum(t1.f2) from t1 group by t1.notexist; -select sum(t1.f2) from t1 group by t1.notexist; - -echo select sum(t1.f2) from t1 group by notexist.f1; -select sum(t1.f2) from t1 group by notexist.f1; diff --git a/test/sql/Aggregate/aggsum3.sql b/test/sql/Aggregate/aggsum3.sql deleted file mode 100644 index 6e95da4f..00000000 --- a/test/sql/Aggregate/aggsum3.sql +++ /dev/null @@ -1 +0,0 @@ -select sum(12*f1) from t1 where f4='BBB'; diff --git a/test/sql/Aggregate/createt1.sql b/test/sql/Aggregate/createt1.sql deleted file mode 100644 index b82e392a..00000000 --- a/test/sql/Aggregate/createt1.sql +++ /dev/null @@ -1,6 +0,0 @@ -create table t1(f1 int,f2 int,f3 int,f4 char(10),primary key(f1)); -insert into t1 values(98,1,10,'AAA'); -insert into t1 values(99,2,20,'BBB'); -insert into t1 values(100,3,30,'CCC'); -insert into t1 values(101,4,40,'AAA'); -insert into t1 values(102,5,50,'BBB'); diff --git a/test/sql/Aggregate/createt1t2.sql b/test/sql/Aggregate/createt1t2.sql deleted file mode 100644 index f983f8dc..00000000 --- a/test/sql/Aggregate/createt1t2.sql +++ /dev/null @@ -1,13 +0,0 @@ -create table t1(f1 int,f2 int,f3 int,primary key(f1)); -insert into t1 values(98,1,10); -insert into t1 values(99,2,20); -insert into t1 values(100,3,30); -insert into t1 values(101,4,40); -insert into t1 values(102,5,50); -create table t2(f1 int,f2 int,f3 int,primary key(f1)); -insert into t2 values(98,1,10); -insert into t2 values(99,2,20); -insert into t2 values(100,3,30); -insert into t2 values(101,4,40); -insert into t2 values(102,5,50); - diff --git a/test/sql/Aggregate/dropt1.sql b/test/sql/Aggregate/dropt1.sql deleted file mode 100644 index 2d707d46..00000000 --- a/test/sql/Aggregate/dropt1.sql +++ /dev/null @@ -1,2 +0,0 @@ -drop table t1; - diff --git a/test/sql/Aggregate/dropt1t2.sql b/test/sql/Aggregate/dropt1t2.sql deleted file mode 100644 index 9c354ab0..00000000 --- a/test/sql/Aggregate/dropt1t2.sql +++ /dev/null @@ -1,2 +0,0 @@ -drop table t1; -drop table t2; diff --git a/test/sql/Aggregate/exp.test001.ksh b/test/sql/Aggregate/exp.test001.ksh deleted file mode 100644 index b83e6824..00000000 --- a/test/sql/Aggregate/exp.test001.ksh +++ /dev/null @@ -1,32 +0,0 @@ -echo select count(f1) from t2; -Statement prepare failed with error -5 -echo select count(f1) from t1; ---------------------------------------------------------- - COUNT(f1) ---------------------------------------------------------- - 5 - -echo select sum(f1) from t1; ---------------------------------------------------------- - SUM(f1) ---------------------------------------------------------- - 500 - -echo select avg(f1) from t1; ---------------------------------------------------------- - AVG(f1) ---------------------------------------------------------- - 100 - -echo select min(f1) from t1; ---------------------------------------------------------- - MIN(f1) ---------------------------------------------------------- - 98 - -echo select max(f1) from t1; ---------------------------------------------------------- - MAX(f1) ---------------------------------------------------------- - 102 - diff --git a/test/sql/Aggregate/exp.test002.ksh b/test/sql/Aggregate/exp.test002.ksh deleted file mode 100644 index 1b66243f..00000000 --- a/test/sql/Aggregate/exp.test002.ksh +++ /dev/null @@ -1,48 +0,0 @@ -echo select count(f1) from t1; ---------------------------------------------------------- - COUNT(t1.f1) ---------------------------------------------------------- - 5 - -echo select count(*) from t1 where f4='AAA'; ---------------------------------------------------------- - COUNT(*) ---------------------------------------------------------- - 2 - -echo select sum(f1) from t1; ---------------------------------------------------------- - SUM(t1.f1) ---------------------------------------------------------- - 500 - -echo select avg(f1) from t1; ---------------------------------------------------------- - AVG(t1.f1) ---------------------------------------------------------- - 100 - -echo select min(t1.f1) from t1; ---------------------------------------------------------- - MIN(t1.f1) ---------------------------------------------------------- - 98 - -echo select min(f4) from t1; ---------------------------------------------------------- - MIN(f4) ---------------------------------------------------------- - AAA - -echo select max(t1.f1) from t1; ---------------------------------------------------------- - MAX(t1.f1) ---------------------------------------------------------- - 102 - -echo select max(f4) from t1; ---------------------------------------------------------- - MAX(f4) ---------------------------------------------------------- - CCC - diff --git a/test/sql/Aggregate/exp.test003.ksh b/test/sql/Aggregate/exp.test003.ksh deleted file mode 100644 index 480ee0ff..00000000 --- a/test/sql/Aggregate/exp.test003.ksh +++ /dev/null @@ -1,6 +0,0 @@ -select count(*) from t1 : ---------------------------------------------------------- - ---------------------------------------------------------- - 5 - diff --git a/test/sql/Aggregate/exp.test004.ksh b/test/sql/Aggregate/exp.test004.ksh deleted file mode 100644 index ed7e24f6..00000000 --- a/test/sql/Aggregate/exp.test004.ksh +++ /dev/null @@ -1,17 +0,0 @@ -echo select min(t1.notexist) from t1; -Statement prepare failed with error -19 -echo select max(t1.f1), sum(t2.f1) from t1,t2 where t1.f1 = t2.f1 and t1.f1 <100; ---------------------------------------------------------- - MAX(t1.f1) SUM(t2.f1) ---------------------------------------------------------- - 99 197 - -echo select max(t1.f1), sum(t2.f1) from t1,t2 where t1.f1 = t2.f1 and t1.f1 <100 group by t1.f2; ---------------------------------------------------------- - MAX(t1.f1) SUM(t2.f1) ---------------------------------------------------------- - 98 98 - 99 99 - -echo select max(t1.f1), max(t2.notexist) from t1,t2 group by t1.f2; -Statement prepare failed with error -19 diff --git a/test/sql/Aggregate/exp.test005.ksh b/test/sql/Aggregate/exp.test005.ksh deleted file mode 100644 index 93d4d2e1..00000000 --- a/test/sql/Aggregate/exp.test005.ksh +++ /dev/null @@ -1 +0,0 @@ -expected file needs to be generated. diff --git a/test/sql/Aggregate/exp.test006.ksh b/test/sql/Aggregate/exp.test006.ksh deleted file mode 100644 index f53309a0..00000000 --- a/test/sql/Aggregate/exp.test006.ksh +++ /dev/null @@ -1,36 +0,0 @@ -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 98 1 10 - 99 2 20 - 100 3 30 - 101 4 40 - 102 5 50 - -echo select min(t1.f2) from t1 group by t1.f1; ---------------------------------------------------------- - MIN(t1.f2) ---------------------------------------------------------- - 1 - 2 - 3 - 4 - 5 - -echo select avg(t1.f2) from t1 group by t1.f1; ---------------------------------------------------------- - AVG(t1.f2) ---------------------------------------------------------- - 1 - 2 - 3 - 4 - 5 - -echo select sum(t1.f2) from t1 group by notexist; -Statement prepare failed with error -19 -echo select sum(t1.f2) from t1 group by t1.notexist; -Statement prepare failed with error -19 -echo select sum(t1.f2) from t1 group by notexist.f1; -Statement prepare failed with error -19 diff --git a/test/sql/Aggregate/exp.test007.ksh b/test/sql/Aggregate/exp.test007.ksh deleted file mode 100644 index 72b6c117..00000000 --- a/test/sql/Aggregate/exp.test007.ksh +++ /dev/null @@ -1,6 +0,0 @@ -select count(*),min(f1),sum(f1) from t1 : ---------------------------------------------------------- - COUNT(*) MIN(f1) SUM(f1) ---------------------------------------------------------- - 5 98 500 - diff --git a/test/sql/Aggregate/exp.test008.ksh b/test/sql/Aggregate/exp.test008.ksh deleted file mode 100644 index 6d2f5da5..00000000 --- a/test/sql/Aggregate/exp.test008.ksh +++ /dev/null @@ -1,2 +0,0 @@ -select min(nonexist.f1) from t1 : -Statement prepare failed with error -19 diff --git a/test/sql/Aggregate/exp.test009.ksh b/test/sql/Aggregate/exp.test009.ksh deleted file mode 100644 index 26b68a3b..00000000 --- a/test/sql/Aggregate/exp.test009.ksh +++ /dev/null @@ -1,2 +0,0 @@ -select sum(12*f1) where f4='BBB': -Statement prepare failed with error -19 diff --git a/test/sql/Aggregate/quit.sql b/test/sql/Aggregate/quit.sql deleted file mode 100644 index 8c0cb686..00000000 --- a/test/sql/Aggregate/quit.sql +++ /dev/null @@ -1 +0,0 @@ -quit; diff --git a/test/sql/Aggregate/test001.ksh b/test/sql/Aggregate/test001.ksh deleted file mode 100755 index c63ac274..00000000 --- a/test/sql/Aggregate/test001.ksh +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/sh -#Test Case -#1. Create table t1 with 5 records in csql database. -# select query with count,sum,avg,min,max. - -# Author : Jitendra Lenka - -QUITFILE=${PWD}/sql/Aggregate/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Aggregate -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1.sql > /dev/null 2>&1 -if [ $? -ne 0 ] - then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/aggregate1.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1.sql > /dev/null 2>&1 - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Aggregate/test002.ksh b/test/sql/Aggregate/test002.ksh deleted file mode 100755 index 8dc26052..00000000 --- a/test/sql/Aggregate/test002.ksh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/sh -#Test Case -#2. Create table t1 with 5 records in csql database. -# select query with count,sum,avg,min,max. - -# Author : Jitendra Lenka - -QUITFILE=${PWD}/sql/Aggregate/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Aggregate -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1.sql > /dev/null 2>&1 -if [ $? -ne 0 ] - then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/aggregate2.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1.sql > /dev/null 2>&1 - exit 2; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Aggregate/test004.ksh b/test/sql/Aggregate/test004.ksh deleted file mode 100755 index 3c653f35..00000000 --- a/test/sql/Aggregate/test004.ksh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/sh -#Test Case -#4. Create table t1 with 5 records in csql database. -# select query with count,sum,avg,min,max. - -# Author : Jitendra Lenka - -QUITFILE=${PWD}/sql/Aggregate/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Aggregate -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1t2.sql > /dev/null 2>&1 -if [ $? -ne 0 ] - then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/aggregate4.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 - exit 2; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Aggregate/test005.ksh b/test/sql/Aggregate/test005.ksh deleted file mode 100755 index 7fa13e09..00000000 --- a/test/sql/Aggregate/test005.ksh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/sh -#Test Case -#5. Create table t1 with 5 records in csql database. -# select query with count,sum,avg,min,max.and Group By. - -# Author : Jitendra Lenka - -QUITFILE=${PWD}/sql/Aggregate/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Aggregate -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1t2.sql > /dev/null 2>&1 -if [ $? -ne 0 ] - then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/aggregate5.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 -exit 0; diff --git a/test/sql/Aggregate/test006.ksh b/test/sql/Aggregate/test006.ksh deleted file mode 100755 index a9051190..00000000 --- a/test/sql/Aggregate/test006.ksh +++ /dev/null @@ -1,30 +0,0 @@ -#!/bin/sh -#Test Case -#6. Create table t1 with 5 records in csql database. -# select query with count,sum,avg,min,max and Group By. - -# Author : Jitendra Lenka - -QUITFILE=${PWD}/sql/Aggregate/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Aggregate -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1t2.sql > /dev/null 2>&1 -if [ $? -ne 0 ] - then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/aggregate6.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Aggregate/test007.ksh b/test/sql/Aggregate/test007.ksh deleted file mode 100755 index e01531a3..00000000 --- a/test/sql/Aggregate/test007.ksh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh -#Test Case -#3. Create table t1 with 5 records in csql database. -# select query with count,sum,avg,min,max. - -# Author : Jitendra Lenka - -QUITFILE=${PWD}/sql/Aggregate/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Aggregate -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1.sql > /dev/null 2>&1 -if [ $? -ne 0 ] - then - exit 1; -fi - - -echo "select count(*),min(f1),sum(f1) from t1 :" -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/agg1.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1.sql > /dev/null 2>&1 - exit 2; -fi - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1.sql > /dev/null 2>&1 -exit 0 ; - diff --git a/test/sql/Aggregate/test008.ksh b/test/sql/Aggregate/test008.ksh deleted file mode 100755 index 38c678af..00000000 --- a/test/sql/Aggregate/test008.ksh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh -#Test Case -#4. Create table t1 with 5 records in csql database. -# select query with count,sum,avg,min,max. - -# Author : Jitendra Lenka - -QUITFILE=${PWD}/sql/Aggregate/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Aggregate -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1t2.sql > /dev/null 2>&1 -if [ $? -ne 0 ] - then - exit 1; -fi - - -echo "select min(nonexist.f1) from t1 :" -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/aggmin4.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 - exit 2; -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Aggregate/test009.ksh b/test/sql/Aggregate/test009.ksh deleted file mode 100755 index 1a30912c..00000000 --- a/test/sql/Aggregate/test009.ksh +++ /dev/null @@ -1,36 +0,0 @@ -#!/bin/sh -#Test Case -#9. Create table t1 with 5 records in csql database. -# select query with expression in aggregate -# as we do not support expressions in aggregate, it should give syntax error - - -# Author : Jitendra Lenka - -QUITFILE=${PWD}/sql/Aggregate/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Aggregate -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1.sql > /dev/null 2>&1 -if [ $? -ne 0 ] - then - exit 1; -fi - - -echo "select sum(12*f1) where f4='BBB':" -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/aggsum3.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1.sql > /dev/null 2>&1 - exit 2; - fi - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Join/createt1.sql b/test/sql/Join/createt1.sql deleted file mode 100644 index 1b4461ab..00000000 --- a/test/sql/Join/createt1.sql +++ /dev/null @@ -1,6 +0,0 @@ -create table t1(f1 int,f2 int,primary key(f1)); -insert into t1 values(1,10); -insert into t1 values(2,20); -insert into t1 values(3,30); -insert into t1 values(4,40); - diff --git a/test/sql/Join/createt1t2.sql b/test/sql/Join/createt1t2.sql deleted file mode 100644 index 96233a4c..00000000 --- a/test/sql/Join/createt1t2.sql +++ /dev/null @@ -1,14 +0,0 @@ -create table t1(f1 int,f2 int,f3 int,primary key(f1)); -insert into t1 values(98,13,108); -insert into t1 values(99,14,109); -insert into t1 values(100,15,109); -insert into t1 values(101,16,110); -insert into t1 values(102,17,111); -insert into t1 values(103,18,112); -create table t2(f1 int,f2 int,f3 int,primary key(f1)); -insert into t2 values(98,13,108); -insert into t2 values(99,14,109); -insert into t2 values(100,15,109); -insert into t2 values(101,16,110); -insert into t2 values(102,17,111); -insert into t2 values(103,18,112); diff --git a/test/sql/Join/createt1t2t3.sql b/test/sql/Join/createt1t2t3.sql deleted file mode 100644 index 5aff90dd..00000000 --- a/test/sql/Join/createt1t2t3.sql +++ /dev/null @@ -1,12 +0,0 @@ -create table t1(f1 int,f2 int,f3 int,primary key(f1)); -insert into t1 values(98,13,108); -insert into t1 values(99,14,109); -insert into t1 values(100,15,109); -create table t2(f1 int,f2 int,f3 int,primary key(f1)); -insert into t2 values(98,13,108); -insert into t2 values(99,14,109); -insert into t2 values(100,15,109); -create table t3(f1 int,f2 int,f3 int,primary key(f1)); -insert into t3 values(98,13,108); -insert into t3 values(100,109,109); -insert into t3 values(102,17,111); diff --git a/test/sql/Join/createt1t2t3t4t5.sql b/test/sql/Join/createt1t2t3t4t5.sql deleted file mode 100644 index d9ab1049..00000000 --- a/test/sql/Join/createt1t2t3t4t5.sql +++ /dev/null @@ -1,27 +0,0 @@ -create table t1(f1 int,f2 int,f3 int,primary key(f1)); -insert into t1 values(98,13,108); -insert into t1 values(99,14,109); -insert into t1 values(100,15,109); -insert into t1 values(101,16,110); -insert into t1 values(102,17,111); -insert into t1 values(103,18,112); -create table t2(f1 int,f2 int,f3 int,primary key(f1)); -insert into t2 values(98,13,108); -insert into t2 values(99,14,109); -insert into t2 values(100,15,109); -insert into t2 values(101,16,110); -insert into t2 values(102,17,111); -insert into t2 values(103,18,112); -create table t3(f1 int,f2 int,f3 int,primary key(f1)); -insert into t3 values(98,13,108); -insert into t3 values(99,14,109); -insert into t3 values(100,15,109); -insert into t3 values(101,16,110); -insert into t3 values(102,17,111); -insert into t3 values(103,18,112); -create table t4(f1 int,f2 int); -insert into t4 values(1,10); -insert into t4 values(2,20); -create table t5(f1 int,f2 int); -insert into t5 values(3,30); -insert into t5 values(4,40); diff --git a/test/sql/Join/drop_emp_dept.sql b/test/sql/Join/drop_emp_dept.sql deleted file mode 100644 index 3fdf55d0..00000000 --- a/test/sql/Join/drop_emp_dept.sql +++ /dev/null @@ -1,4 +0,0 @@ -echo drop table emp; -drop table emp; -echo drop table dept; -drop table dept; diff --git a/test/sql/Join/dropt1.sql b/test/sql/Join/dropt1.sql deleted file mode 100644 index 853c1ad6..00000000 --- a/test/sql/Join/dropt1.sql +++ /dev/null @@ -1 +0,0 @@ -drop table t1; diff --git a/test/sql/Join/dropt11.sql b/test/sql/Join/dropt11.sql deleted file mode 100644 index 34a16d31..00000000 --- a/test/sql/Join/dropt11.sql +++ /dev/null @@ -1 +0,0 @@ -drop table t11; diff --git a/test/sql/Join/dropt11t12.sql b/test/sql/Join/dropt11t12.sql deleted file mode 100644 index de61bb49..00000000 --- a/test/sql/Join/dropt11t12.sql +++ /dev/null @@ -1,2 +0,0 @@ -drop table t11; -drop table t12; diff --git a/test/sql/Join/dropt11t12t13.sql b/test/sql/Join/dropt11t12t13.sql deleted file mode 100644 index b86985db..00000000 --- a/test/sql/Join/dropt11t12t13.sql +++ /dev/null @@ -1,4 +0,0 @@ -drop table t11; -drop table t12; -drop table t13; -\ diff --git a/test/sql/Join/dropt11t13.sql b/test/sql/Join/dropt11t13.sql deleted file mode 100644 index af455023..00000000 --- a/test/sql/Join/dropt11t13.sql +++ /dev/null @@ -1,2 +0,0 @@ -drop table t11; -drop table t13; diff --git a/test/sql/Join/dropt1t2.sql b/test/sql/Join/dropt1t2.sql deleted file mode 100644 index 9c354ab0..00000000 --- a/test/sql/Join/dropt1t2.sql +++ /dev/null @@ -1,2 +0,0 @@ -drop table t1; -drop table t2; diff --git a/test/sql/Join/dropt1t2t3.sql b/test/sql/Join/dropt1t2t3.sql deleted file mode 100644 index 3e9ecdb1..00000000 --- a/test/sql/Join/dropt1t2t3.sql +++ /dev/null @@ -1,3 +0,0 @@ -drop table t1; -drop table t2; -drop table t3; diff --git a/test/sql/Join/dropt1t2t3t4t5.sql b/test/sql/Join/dropt1t2t3t4t5.sql deleted file mode 100644 index a7c61193..00000000 --- a/test/sql/Join/dropt1t2t3t4t5.sql +++ /dev/null @@ -1,5 +0,0 @@ -drop table t1; -drop table t2; -drop table t3; -drop table t4; -drop table t5; diff --git a/test/sql/Join/exp.test001.ksh b/test/sql/Join/exp.test001.ksh deleted file mode 100644 index 55343d2e..00000000 --- a/test/sql/Join/exp.test001.ksh +++ /dev/null @@ -1,15 +0,0 @@ -echo select t1.f1 from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 2 - 3 - 4 - -echo select t1.f30 from t1; -Statement prepare failed with error -19 -echo select * from t1,t55 ; -Statement prepare failed with error -5 -echo select t100.f1 from t1; -Statement prepare failed with error -19 diff --git a/test/sql/Join/exp.test002.ksh b/test/sql/Join/exp.test002.ksh deleted file mode 100644 index d455bcaa..00000000 --- a/test/sql/Join/exp.test002.ksh +++ /dev/null @@ -1,37 +0,0 @@ -echo select * from t1,t2 where t1.f1>100 or t2.f1<100; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t2.f1 t2.f2 t2.f3 ---------------------------------------------------------- - 98 13 108 98 13 108 - 98 13 108 99 14 109 - 99 14 109 98 13 108 - 99 14 109 99 14 109 - 100 15 109 98 13 108 - 100 15 109 99 14 109 - 101 16 110 98 13 108 - 101 16 110 99 14 109 - 101 16 110 100 15 109 - 101 16 110 101 16 110 - 101 16 110 102 17 111 - 101 16 110 103 18 112 - 102 17 111 98 13 108 - 102 17 111 99 14 109 - 102 17 111 100 15 109 - 102 17 111 101 16 110 - 102 17 111 102 17 111 - 102 17 111 103 18 112 - 103 18 112 98 13 108 - 103 18 112 99 14 109 - 103 18 112 100 15 109 - 103 18 112 101 16 110 - 103 18 112 102 17 111 - 103 18 112 103 18 112 - -echo select * from t1,t2 where t1.f1 = t2.f1 and t1.f1 >100; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t2.f1 t2.f2 t2.f3 ---------------------------------------------------------- - 101 16 110 101 16 110 - 102 17 111 102 17 111 - 103 18 112 103 18 112 - diff --git a/test/sql/Join/exp.test003.ksh b/test/sql/Join/exp.test003.ksh deleted file mode 100644 index dedba937..00000000 --- a/test/sql/Join/exp.test003.ksh +++ /dev/null @@ -1,892 +0,0 @@ -echo select * from t1,t2,t3,t4,t5; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t2.f1 t2.f2 t2.f3 t3.f1 t3.f2 t3.f3 t4.f1 t4.f2 t5.f1 t5.f2 ---------------------------------------------------------- - 98 13 108 98 13 108 98 13 108 1 10 3 30 - 98 13 108 98 13 108 98 13 108 1 10 4 40 - 98 13 108 98 13 108 98 13 108 2 20 3 30 - 98 13 108 98 13 108 98 13 108 2 20 4 40 - 98 13 108 98 13 108 99 14 109 1 10 3 30 - 98 13 108 98 13 108 99 14 109 1 10 4 40 - 98 13 108 98 13 108 99 14 109 2 20 3 30 - 98 13 108 98 13 108 99 14 109 2 20 4 40 - 98 13 108 98 13 108 100 15 109 1 10 3 30 - 98 13 108 98 13 108 100 15 109 1 10 4 40 - 98 13 108 98 13 108 100 15 109 2 20 3 30 - 98 13 108 98 13 108 100 15 109 2 20 4 40 - 98 13 108 98 13 108 101 16 110 1 10 3 30 - 98 13 108 98 13 108 101 16 110 1 10 4 40 - 98 13 108 98 13 108 101 16 110 2 20 3 30 - 98 13 108 98 13 108 101 16 110 2 20 4 40 - 98 13 108 98 13 108 102 17 111 1 10 3 30 - 98 13 108 98 13 108 102 17 111 1 10 4 40 - 98 13 108 98 13 108 102 17 111 2 20 3 30 - 98 13 108 98 13 108 102 17 111 2 20 4 40 - 98 13 108 98 13 108 103 18 112 1 10 3 30 - 98 13 108 98 13 108 103 18 112 1 10 4 40 - 98 13 108 98 13 108 103 18 112 2 20 3 30 - 98 13 108 98 13 108 103 18 112 2 20 4 40 - 98 13 108 99 14 109 98 13 108 1 10 3 30 - 98 13 108 99 14 109 98 13 108 1 10 4 40 - 98 13 108 99 14 109 98 13 108 2 20 3 30 - 98 13 108 99 14 109 98 13 108 2 20 4 40 - 98 13 108 99 14 109 99 14 109 1 10 3 30 - 98 13 108 99 14 109 99 14 109 1 10 4 40 - 98 13 108 99 14 109 99 14 109 2 20 3 30 - 98 13 108 99 14 109 99 14 109 2 20 4 40 - 98 13 108 99 14 109 100 15 109 1 10 3 30 - 98 13 108 99 14 109 100 15 109 1 10 4 40 - 98 13 108 99 14 109 100 15 109 2 20 3 30 - 98 13 108 99 14 109 100 15 109 2 20 4 40 - 98 13 108 99 14 109 101 16 110 1 10 3 30 - 98 13 108 99 14 109 101 16 110 1 10 4 40 - 98 13 108 99 14 109 101 16 110 2 20 3 30 - 98 13 108 99 14 109 101 16 110 2 20 4 40 - 98 13 108 99 14 109 102 17 111 1 10 3 30 - 98 13 108 99 14 109 102 17 111 1 10 4 40 - 98 13 108 99 14 109 102 17 111 2 20 3 30 - 98 13 108 99 14 109 102 17 111 2 20 4 40 - 98 13 108 99 14 109 103 18 112 1 10 3 30 - 98 13 108 99 14 109 103 18 112 1 10 4 40 - 98 13 108 99 14 109 103 18 112 2 20 3 30 - 98 13 108 99 14 109 103 18 112 2 20 4 40 - 98 13 108 100 15 109 98 13 108 1 10 3 30 - 98 13 108 100 15 109 98 13 108 1 10 4 40 - 98 13 108 100 15 109 98 13 108 2 20 3 30 - 98 13 108 100 15 109 98 13 108 2 20 4 40 - 98 13 108 100 15 109 99 14 109 1 10 3 30 - 98 13 108 100 15 109 99 14 109 1 10 4 40 - 98 13 108 100 15 109 99 14 109 2 20 3 30 - 98 13 108 100 15 109 99 14 109 2 20 4 40 - 98 13 108 100 15 109 100 15 109 1 10 3 30 - 98 13 108 100 15 109 100 15 109 1 10 4 40 - 98 13 108 100 15 109 100 15 109 2 20 3 30 - 98 13 108 100 15 109 100 15 109 2 20 4 40 - 98 13 108 100 15 109 101 16 110 1 10 3 30 - 98 13 108 100 15 109 101 16 110 1 10 4 40 - 98 13 108 100 15 109 101 16 110 2 20 3 30 - 98 13 108 100 15 109 101 16 110 2 20 4 40 - 98 13 108 100 15 109 102 17 111 1 10 3 30 - 98 13 108 100 15 109 102 17 111 1 10 4 40 - 98 13 108 100 15 109 102 17 111 2 20 3 30 - 98 13 108 100 15 109 102 17 111 2 20 4 40 - 98 13 108 100 15 109 103 18 112 1 10 3 30 - 98 13 108 100 15 109 103 18 112 1 10 4 40 - 98 13 108 100 15 109 103 18 112 2 20 3 30 - 98 13 108 100 15 109 103 18 112 2 20 4 40 - 98 13 108 101 16 110 98 13 108 1 10 3 30 - 98 13 108 101 16 110 98 13 108 1 10 4 40 - 98 13 108 101 16 110 98 13 108 2 20 3 30 - 98 13 108 101 16 110 98 13 108 2 20 4 40 - 98 13 108 101 16 110 99 14 109 1 10 3 30 - 98 13 108 101 16 110 99 14 109 1 10 4 40 - 98 13 108 101 16 110 99 14 109 2 20 3 30 - 98 13 108 101 16 110 99 14 109 2 20 4 40 - 98 13 108 101 16 110 100 15 109 1 10 3 30 - 98 13 108 101 16 110 100 15 109 1 10 4 40 - 98 13 108 101 16 110 100 15 109 2 20 3 30 - 98 13 108 101 16 110 100 15 109 2 20 4 40 - 98 13 108 101 16 110 101 16 110 1 10 3 30 - 98 13 108 101 16 110 101 16 110 1 10 4 40 - 98 13 108 101 16 110 101 16 110 2 20 3 30 - 98 13 108 101 16 110 101 16 110 2 20 4 40 - 98 13 108 101 16 110 102 17 111 1 10 3 30 - 98 13 108 101 16 110 102 17 111 1 10 4 40 - 98 13 108 101 16 110 102 17 111 2 20 3 30 - 98 13 108 101 16 110 102 17 111 2 20 4 40 - 98 13 108 101 16 110 103 18 112 1 10 3 30 - 98 13 108 101 16 110 103 18 112 1 10 4 40 - 98 13 108 101 16 110 103 18 112 2 20 3 30 - 98 13 108 101 16 110 103 18 112 2 20 4 40 - 98 13 108 102 17 111 98 13 108 1 10 3 30 - 98 13 108 102 17 111 98 13 108 1 10 4 40 - 98 13 108 102 17 111 98 13 108 2 20 3 30 - 98 13 108 102 17 111 98 13 108 2 20 4 40 - 98 13 108 102 17 111 99 14 109 1 10 3 30 - 98 13 108 102 17 111 99 14 109 1 10 4 40 - 98 13 108 102 17 111 99 14 109 2 20 3 30 - 98 13 108 102 17 111 99 14 109 2 20 4 40 - 98 13 108 102 17 111 100 15 109 1 10 3 30 - 98 13 108 102 17 111 100 15 109 1 10 4 40 - 98 13 108 102 17 111 100 15 109 2 20 3 30 - 98 13 108 102 17 111 100 15 109 2 20 4 40 - 98 13 108 102 17 111 101 16 110 1 10 3 30 - 98 13 108 102 17 111 101 16 110 1 10 4 40 - 98 13 108 102 17 111 101 16 110 2 20 3 30 - 98 13 108 102 17 111 101 16 110 2 20 4 40 - 98 13 108 102 17 111 102 17 111 1 10 3 30 - 98 13 108 102 17 111 102 17 111 1 10 4 40 - 98 13 108 102 17 111 102 17 111 2 20 3 30 - 98 13 108 102 17 111 102 17 111 2 20 4 40 - 98 13 108 102 17 111 103 18 112 1 10 3 30 - 98 13 108 102 17 111 103 18 112 1 10 4 40 - 98 13 108 102 17 111 103 18 112 2 20 3 30 - 98 13 108 102 17 111 103 18 112 2 20 4 40 - 98 13 108 103 18 112 98 13 108 1 10 3 30 - 98 13 108 103 18 112 98 13 108 1 10 4 40 - 98 13 108 103 18 112 98 13 108 2 20 3 30 - 98 13 108 103 18 112 98 13 108 2 20 4 40 - 98 13 108 103 18 112 99 14 109 1 10 3 30 - 98 13 108 103 18 112 99 14 109 1 10 4 40 - 98 13 108 103 18 112 99 14 109 2 20 3 30 - 98 13 108 103 18 112 99 14 109 2 20 4 40 - 98 13 108 103 18 112 100 15 109 1 10 3 30 - 98 13 108 103 18 112 100 15 109 1 10 4 40 - 98 13 108 103 18 112 100 15 109 2 20 3 30 - 98 13 108 103 18 112 100 15 109 2 20 4 40 - 98 13 108 103 18 112 101 16 110 1 10 3 30 - 98 13 108 103 18 112 101 16 110 1 10 4 40 - 98 13 108 103 18 112 101 16 110 2 20 3 30 - 98 13 108 103 18 112 101 16 110 2 20 4 40 - 98 13 108 103 18 112 102 17 111 1 10 3 30 - 98 13 108 103 18 112 102 17 111 1 10 4 40 - 98 13 108 103 18 112 102 17 111 2 20 3 30 - 98 13 108 103 18 112 102 17 111 2 20 4 40 - 98 13 108 103 18 112 103 18 112 1 10 3 30 - 98 13 108 103 18 112 103 18 112 1 10 4 40 - 98 13 108 103 18 112 103 18 112 2 20 3 30 - 98 13 108 103 18 112 103 18 112 2 20 4 40 - 99 14 109 98 13 108 98 13 108 1 10 3 30 - 99 14 109 98 13 108 98 13 108 1 10 4 40 - 99 14 109 98 13 108 98 13 108 2 20 3 30 - 99 14 109 98 13 108 98 13 108 2 20 4 40 - 99 14 109 98 13 108 99 14 109 1 10 3 30 - 99 14 109 98 13 108 99 14 109 1 10 4 40 - 99 14 109 98 13 108 99 14 109 2 20 3 30 - 99 14 109 98 13 108 99 14 109 2 20 4 40 - 99 14 109 98 13 108 100 15 109 1 10 3 30 - 99 14 109 98 13 108 100 15 109 1 10 4 40 - 99 14 109 98 13 108 100 15 109 2 20 3 30 - 99 14 109 98 13 108 100 15 109 2 20 4 40 - 99 14 109 98 13 108 101 16 110 1 10 3 30 - 99 14 109 98 13 108 101 16 110 1 10 4 40 - 99 14 109 98 13 108 101 16 110 2 20 3 30 - 99 14 109 98 13 108 101 16 110 2 20 4 40 - 99 14 109 98 13 108 102 17 111 1 10 3 30 - 99 14 109 98 13 108 102 17 111 1 10 4 40 - 99 14 109 98 13 108 102 17 111 2 20 3 30 - 99 14 109 98 13 108 102 17 111 2 20 4 40 - 99 14 109 98 13 108 103 18 112 1 10 3 30 - 99 14 109 98 13 108 103 18 112 1 10 4 40 - 99 14 109 98 13 108 103 18 112 2 20 3 30 - 99 14 109 98 13 108 103 18 112 2 20 4 40 - 99 14 109 99 14 109 98 13 108 1 10 3 30 - 99 14 109 99 14 109 98 13 108 1 10 4 40 - 99 14 109 99 14 109 98 13 108 2 20 3 30 - 99 14 109 99 14 109 98 13 108 2 20 4 40 - 99 14 109 99 14 109 99 14 109 1 10 3 30 - 99 14 109 99 14 109 99 14 109 1 10 4 40 - 99 14 109 99 14 109 99 14 109 2 20 3 30 - 99 14 109 99 14 109 99 14 109 2 20 4 40 - 99 14 109 99 14 109 100 15 109 1 10 3 30 - 99 14 109 99 14 109 100 15 109 1 10 4 40 - 99 14 109 99 14 109 100 15 109 2 20 3 30 - 99 14 109 99 14 109 100 15 109 2 20 4 40 - 99 14 109 99 14 109 101 16 110 1 10 3 30 - 99 14 109 99 14 109 101 16 110 1 10 4 40 - 99 14 109 99 14 109 101 16 110 2 20 3 30 - 99 14 109 99 14 109 101 16 110 2 20 4 40 - 99 14 109 99 14 109 102 17 111 1 10 3 30 - 99 14 109 99 14 109 102 17 111 1 10 4 40 - 99 14 109 99 14 109 102 17 111 2 20 3 30 - 99 14 109 99 14 109 102 17 111 2 20 4 40 - 99 14 109 99 14 109 103 18 112 1 10 3 30 - 99 14 109 99 14 109 103 18 112 1 10 4 40 - 99 14 109 99 14 109 103 18 112 2 20 3 30 - 99 14 109 99 14 109 103 18 112 2 20 4 40 - 99 14 109 100 15 109 98 13 108 1 10 3 30 - 99 14 109 100 15 109 98 13 108 1 10 4 40 - 99 14 109 100 15 109 98 13 108 2 20 3 30 - 99 14 109 100 15 109 98 13 108 2 20 4 40 - 99 14 109 100 15 109 99 14 109 1 10 3 30 - 99 14 109 100 15 109 99 14 109 1 10 4 40 - 99 14 109 100 15 109 99 14 109 2 20 3 30 - 99 14 109 100 15 109 99 14 109 2 20 4 40 - 99 14 109 100 15 109 100 15 109 1 10 3 30 - 99 14 109 100 15 109 100 15 109 1 10 4 40 - 99 14 109 100 15 109 100 15 109 2 20 3 30 - 99 14 109 100 15 109 100 15 109 2 20 4 40 - 99 14 109 100 15 109 101 16 110 1 10 3 30 - 99 14 109 100 15 109 101 16 110 1 10 4 40 - 99 14 109 100 15 109 101 16 110 2 20 3 30 - 99 14 109 100 15 109 101 16 110 2 20 4 40 - 99 14 109 100 15 109 102 17 111 1 10 3 30 - 99 14 109 100 15 109 102 17 111 1 10 4 40 - 99 14 109 100 15 109 102 17 111 2 20 3 30 - 99 14 109 100 15 109 102 17 111 2 20 4 40 - 99 14 109 100 15 109 103 18 112 1 10 3 30 - 99 14 109 100 15 109 103 18 112 1 10 4 40 - 99 14 109 100 15 109 103 18 112 2 20 3 30 - 99 14 109 100 15 109 103 18 112 2 20 4 40 - 99 14 109 101 16 110 98 13 108 1 10 3 30 - 99 14 109 101 16 110 98 13 108 1 10 4 40 - 99 14 109 101 16 110 98 13 108 2 20 3 30 - 99 14 109 101 16 110 98 13 108 2 20 4 40 - 99 14 109 101 16 110 99 14 109 1 10 3 30 - 99 14 109 101 16 110 99 14 109 1 10 4 40 - 99 14 109 101 16 110 99 14 109 2 20 3 30 - 99 14 109 101 16 110 99 14 109 2 20 4 40 - 99 14 109 101 16 110 100 15 109 1 10 3 30 - 99 14 109 101 16 110 100 15 109 1 10 4 40 - 99 14 109 101 16 110 100 15 109 2 20 3 30 - 99 14 109 101 16 110 100 15 109 2 20 4 40 - 99 14 109 101 16 110 101 16 110 1 10 3 30 - 99 14 109 101 16 110 101 16 110 1 10 4 40 - 99 14 109 101 16 110 101 16 110 2 20 3 30 - 99 14 109 101 16 110 101 16 110 2 20 4 40 - 99 14 109 101 16 110 102 17 111 1 10 3 30 - 99 14 109 101 16 110 102 17 111 1 10 4 40 - 99 14 109 101 16 110 102 17 111 2 20 3 30 - 99 14 109 101 16 110 102 17 111 2 20 4 40 - 99 14 109 101 16 110 103 18 112 1 10 3 30 - 99 14 109 101 16 110 103 18 112 1 10 4 40 - 99 14 109 101 16 110 103 18 112 2 20 3 30 - 99 14 109 101 16 110 103 18 112 2 20 4 40 - 99 14 109 102 17 111 98 13 108 1 10 3 30 - 99 14 109 102 17 111 98 13 108 1 10 4 40 - 99 14 109 102 17 111 98 13 108 2 20 3 30 - 99 14 109 102 17 111 98 13 108 2 20 4 40 - 99 14 109 102 17 111 99 14 109 1 10 3 30 - 99 14 109 102 17 111 99 14 109 1 10 4 40 - 99 14 109 102 17 111 99 14 109 2 20 3 30 - 99 14 109 102 17 111 99 14 109 2 20 4 40 - 99 14 109 102 17 111 100 15 109 1 10 3 30 - 99 14 109 102 17 111 100 15 109 1 10 4 40 - 99 14 109 102 17 111 100 15 109 2 20 3 30 - 99 14 109 102 17 111 100 15 109 2 20 4 40 - 99 14 109 102 17 111 101 16 110 1 10 3 30 - 99 14 109 102 17 111 101 16 110 1 10 4 40 - 99 14 109 102 17 111 101 16 110 2 20 3 30 - 99 14 109 102 17 111 101 16 110 2 20 4 40 - 99 14 109 102 17 111 102 17 111 1 10 3 30 - 99 14 109 102 17 111 102 17 111 1 10 4 40 - 99 14 109 102 17 111 102 17 111 2 20 3 30 - 99 14 109 102 17 111 102 17 111 2 20 4 40 - 99 14 109 102 17 111 103 18 112 1 10 3 30 - 99 14 109 102 17 111 103 18 112 1 10 4 40 - 99 14 109 102 17 111 103 18 112 2 20 3 30 - 99 14 109 102 17 111 103 18 112 2 20 4 40 - 99 14 109 103 18 112 98 13 108 1 10 3 30 - 99 14 109 103 18 112 98 13 108 1 10 4 40 - 99 14 109 103 18 112 98 13 108 2 20 3 30 - 99 14 109 103 18 112 98 13 108 2 20 4 40 - 99 14 109 103 18 112 99 14 109 1 10 3 30 - 99 14 109 103 18 112 99 14 109 1 10 4 40 - 99 14 109 103 18 112 99 14 109 2 20 3 30 - 99 14 109 103 18 112 99 14 109 2 20 4 40 - 99 14 109 103 18 112 100 15 109 1 10 3 30 - 99 14 109 103 18 112 100 15 109 1 10 4 40 - 99 14 109 103 18 112 100 15 109 2 20 3 30 - 99 14 109 103 18 112 100 15 109 2 20 4 40 - 99 14 109 103 18 112 101 16 110 1 10 3 30 - 99 14 109 103 18 112 101 16 110 1 10 4 40 - 99 14 109 103 18 112 101 16 110 2 20 3 30 - 99 14 109 103 18 112 101 16 110 2 20 4 40 - 99 14 109 103 18 112 102 17 111 1 10 3 30 - 99 14 109 103 18 112 102 17 111 1 10 4 40 - 99 14 109 103 18 112 102 17 111 2 20 3 30 - 99 14 109 103 18 112 102 17 111 2 20 4 40 - 99 14 109 103 18 112 103 18 112 1 10 3 30 - 99 14 109 103 18 112 103 18 112 1 10 4 40 - 99 14 109 103 18 112 103 18 112 2 20 3 30 - 99 14 109 103 18 112 103 18 112 2 20 4 40 - 100 15 109 98 13 108 98 13 108 1 10 3 30 - 100 15 109 98 13 108 98 13 108 1 10 4 40 - 100 15 109 98 13 108 98 13 108 2 20 3 30 - 100 15 109 98 13 108 98 13 108 2 20 4 40 - 100 15 109 98 13 108 99 14 109 1 10 3 30 - 100 15 109 98 13 108 99 14 109 1 10 4 40 - 100 15 109 98 13 108 99 14 109 2 20 3 30 - 100 15 109 98 13 108 99 14 109 2 20 4 40 - 100 15 109 98 13 108 100 15 109 1 10 3 30 - 100 15 109 98 13 108 100 15 109 1 10 4 40 - 100 15 109 98 13 108 100 15 109 2 20 3 30 - 100 15 109 98 13 108 100 15 109 2 20 4 40 - 100 15 109 98 13 108 101 16 110 1 10 3 30 - 100 15 109 98 13 108 101 16 110 1 10 4 40 - 100 15 109 98 13 108 101 16 110 2 20 3 30 - 100 15 109 98 13 108 101 16 110 2 20 4 40 - 100 15 109 98 13 108 102 17 111 1 10 3 30 - 100 15 109 98 13 108 102 17 111 1 10 4 40 - 100 15 109 98 13 108 102 17 111 2 20 3 30 - 100 15 109 98 13 108 102 17 111 2 20 4 40 - 100 15 109 98 13 108 103 18 112 1 10 3 30 - 100 15 109 98 13 108 103 18 112 1 10 4 40 - 100 15 109 98 13 108 103 18 112 2 20 3 30 - 100 15 109 98 13 108 103 18 112 2 20 4 40 - 100 15 109 99 14 109 98 13 108 1 10 3 30 - 100 15 109 99 14 109 98 13 108 1 10 4 40 - 100 15 109 99 14 109 98 13 108 2 20 3 30 - 100 15 109 99 14 109 98 13 108 2 20 4 40 - 100 15 109 99 14 109 99 14 109 1 10 3 30 - 100 15 109 99 14 109 99 14 109 1 10 4 40 - 100 15 109 99 14 109 99 14 109 2 20 3 30 - 100 15 109 99 14 109 99 14 109 2 20 4 40 - 100 15 109 99 14 109 100 15 109 1 10 3 30 - 100 15 109 99 14 109 100 15 109 1 10 4 40 - 100 15 109 99 14 109 100 15 109 2 20 3 30 - 100 15 109 99 14 109 100 15 109 2 20 4 40 - 100 15 109 99 14 109 101 16 110 1 10 3 30 - 100 15 109 99 14 109 101 16 110 1 10 4 40 - 100 15 109 99 14 109 101 16 110 2 20 3 30 - 100 15 109 99 14 109 101 16 110 2 20 4 40 - 100 15 109 99 14 109 102 17 111 1 10 3 30 - 100 15 109 99 14 109 102 17 111 1 10 4 40 - 100 15 109 99 14 109 102 17 111 2 20 3 30 - 100 15 109 99 14 109 102 17 111 2 20 4 40 - 100 15 109 99 14 109 103 18 112 1 10 3 30 - 100 15 109 99 14 109 103 18 112 1 10 4 40 - 100 15 109 99 14 109 103 18 112 2 20 3 30 - 100 15 109 99 14 109 103 18 112 2 20 4 40 - 100 15 109 100 15 109 98 13 108 1 10 3 30 - 100 15 109 100 15 109 98 13 108 1 10 4 40 - 100 15 109 100 15 109 98 13 108 2 20 3 30 - 100 15 109 100 15 109 98 13 108 2 20 4 40 - 100 15 109 100 15 109 99 14 109 1 10 3 30 - 100 15 109 100 15 109 99 14 109 1 10 4 40 - 100 15 109 100 15 109 99 14 109 2 20 3 30 - 100 15 109 100 15 109 99 14 109 2 20 4 40 - 100 15 109 100 15 109 100 15 109 1 10 3 30 - 100 15 109 100 15 109 100 15 109 1 10 4 40 - 100 15 109 100 15 109 100 15 109 2 20 3 30 - 100 15 109 100 15 109 100 15 109 2 20 4 40 - 100 15 109 100 15 109 101 16 110 1 10 3 30 - 100 15 109 100 15 109 101 16 110 1 10 4 40 - 100 15 109 100 15 109 101 16 110 2 20 3 30 - 100 15 109 100 15 109 101 16 110 2 20 4 40 - 100 15 109 100 15 109 102 17 111 1 10 3 30 - 100 15 109 100 15 109 102 17 111 1 10 4 40 - 100 15 109 100 15 109 102 17 111 2 20 3 30 - 100 15 109 100 15 109 102 17 111 2 20 4 40 - 100 15 109 100 15 109 103 18 112 1 10 3 30 - 100 15 109 100 15 109 103 18 112 1 10 4 40 - 100 15 109 100 15 109 103 18 112 2 20 3 30 - 100 15 109 100 15 109 103 18 112 2 20 4 40 - 100 15 109 101 16 110 98 13 108 1 10 3 30 - 100 15 109 101 16 110 98 13 108 1 10 4 40 - 100 15 109 101 16 110 98 13 108 2 20 3 30 - 100 15 109 101 16 110 98 13 108 2 20 4 40 - 100 15 109 101 16 110 99 14 109 1 10 3 30 - 100 15 109 101 16 110 99 14 109 1 10 4 40 - 100 15 109 101 16 110 99 14 109 2 20 3 30 - 100 15 109 101 16 110 99 14 109 2 20 4 40 - 100 15 109 101 16 110 100 15 109 1 10 3 30 - 100 15 109 101 16 110 100 15 109 1 10 4 40 - 100 15 109 101 16 110 100 15 109 2 20 3 30 - 100 15 109 101 16 110 100 15 109 2 20 4 40 - 100 15 109 101 16 110 101 16 110 1 10 3 30 - 100 15 109 101 16 110 101 16 110 1 10 4 40 - 100 15 109 101 16 110 101 16 110 2 20 3 30 - 100 15 109 101 16 110 101 16 110 2 20 4 40 - 100 15 109 101 16 110 102 17 111 1 10 3 30 - 100 15 109 101 16 110 102 17 111 1 10 4 40 - 100 15 109 101 16 110 102 17 111 2 20 3 30 - 100 15 109 101 16 110 102 17 111 2 20 4 40 - 100 15 109 101 16 110 103 18 112 1 10 3 30 - 100 15 109 101 16 110 103 18 112 1 10 4 40 - 100 15 109 101 16 110 103 18 112 2 20 3 30 - 100 15 109 101 16 110 103 18 112 2 20 4 40 - 100 15 109 102 17 111 98 13 108 1 10 3 30 - 100 15 109 102 17 111 98 13 108 1 10 4 40 - 100 15 109 102 17 111 98 13 108 2 20 3 30 - 100 15 109 102 17 111 98 13 108 2 20 4 40 - 100 15 109 102 17 111 99 14 109 1 10 3 30 - 100 15 109 102 17 111 99 14 109 1 10 4 40 - 100 15 109 102 17 111 99 14 109 2 20 3 30 - 100 15 109 102 17 111 99 14 109 2 20 4 40 - 100 15 109 102 17 111 100 15 109 1 10 3 30 - 100 15 109 102 17 111 100 15 109 1 10 4 40 - 100 15 109 102 17 111 100 15 109 2 20 3 30 - 100 15 109 102 17 111 100 15 109 2 20 4 40 - 100 15 109 102 17 111 101 16 110 1 10 3 30 - 100 15 109 102 17 111 101 16 110 1 10 4 40 - 100 15 109 102 17 111 101 16 110 2 20 3 30 - 100 15 109 102 17 111 101 16 110 2 20 4 40 - 100 15 109 102 17 111 102 17 111 1 10 3 30 - 100 15 109 102 17 111 102 17 111 1 10 4 40 - 100 15 109 102 17 111 102 17 111 2 20 3 30 - 100 15 109 102 17 111 102 17 111 2 20 4 40 - 100 15 109 102 17 111 103 18 112 1 10 3 30 - 100 15 109 102 17 111 103 18 112 1 10 4 40 - 100 15 109 102 17 111 103 18 112 2 20 3 30 - 100 15 109 102 17 111 103 18 112 2 20 4 40 - 100 15 109 103 18 112 98 13 108 1 10 3 30 - 100 15 109 103 18 112 98 13 108 1 10 4 40 - 100 15 109 103 18 112 98 13 108 2 20 3 30 - 100 15 109 103 18 112 98 13 108 2 20 4 40 - 100 15 109 103 18 112 99 14 109 1 10 3 30 - 100 15 109 103 18 112 99 14 109 1 10 4 40 - 100 15 109 103 18 112 99 14 109 2 20 3 30 - 100 15 109 103 18 112 99 14 109 2 20 4 40 - 100 15 109 103 18 112 100 15 109 1 10 3 30 - 100 15 109 103 18 112 100 15 109 1 10 4 40 - 100 15 109 103 18 112 100 15 109 2 20 3 30 - 100 15 109 103 18 112 100 15 109 2 20 4 40 - 100 15 109 103 18 112 101 16 110 1 10 3 30 - 100 15 109 103 18 112 101 16 110 1 10 4 40 - 100 15 109 103 18 112 101 16 110 2 20 3 30 - 100 15 109 103 18 112 101 16 110 2 20 4 40 - 100 15 109 103 18 112 102 17 111 1 10 3 30 - 100 15 109 103 18 112 102 17 111 1 10 4 40 - 100 15 109 103 18 112 102 17 111 2 20 3 30 - 100 15 109 103 18 112 102 17 111 2 20 4 40 - 100 15 109 103 18 112 103 18 112 1 10 3 30 - 100 15 109 103 18 112 103 18 112 1 10 4 40 - 100 15 109 103 18 112 103 18 112 2 20 3 30 - 100 15 109 103 18 112 103 18 112 2 20 4 40 - 101 16 110 98 13 108 98 13 108 1 10 3 30 - 101 16 110 98 13 108 98 13 108 1 10 4 40 - 101 16 110 98 13 108 98 13 108 2 20 3 30 - 101 16 110 98 13 108 98 13 108 2 20 4 40 - 101 16 110 98 13 108 99 14 109 1 10 3 30 - 101 16 110 98 13 108 99 14 109 1 10 4 40 - 101 16 110 98 13 108 99 14 109 2 20 3 30 - 101 16 110 98 13 108 99 14 109 2 20 4 40 - 101 16 110 98 13 108 100 15 109 1 10 3 30 - 101 16 110 98 13 108 100 15 109 1 10 4 40 - 101 16 110 98 13 108 100 15 109 2 20 3 30 - 101 16 110 98 13 108 100 15 109 2 20 4 40 - 101 16 110 98 13 108 101 16 110 1 10 3 30 - 101 16 110 98 13 108 101 16 110 1 10 4 40 - 101 16 110 98 13 108 101 16 110 2 20 3 30 - 101 16 110 98 13 108 101 16 110 2 20 4 40 - 101 16 110 98 13 108 102 17 111 1 10 3 30 - 101 16 110 98 13 108 102 17 111 1 10 4 40 - 101 16 110 98 13 108 102 17 111 2 20 3 30 - 101 16 110 98 13 108 102 17 111 2 20 4 40 - 101 16 110 98 13 108 103 18 112 1 10 3 30 - 101 16 110 98 13 108 103 18 112 1 10 4 40 - 101 16 110 98 13 108 103 18 112 2 20 3 30 - 101 16 110 98 13 108 103 18 112 2 20 4 40 - 101 16 110 99 14 109 98 13 108 1 10 3 30 - 101 16 110 99 14 109 98 13 108 1 10 4 40 - 101 16 110 99 14 109 98 13 108 2 20 3 30 - 101 16 110 99 14 109 98 13 108 2 20 4 40 - 101 16 110 99 14 109 99 14 109 1 10 3 30 - 101 16 110 99 14 109 99 14 109 1 10 4 40 - 101 16 110 99 14 109 99 14 109 2 20 3 30 - 101 16 110 99 14 109 99 14 109 2 20 4 40 - 101 16 110 99 14 109 100 15 109 1 10 3 30 - 101 16 110 99 14 109 100 15 109 1 10 4 40 - 101 16 110 99 14 109 100 15 109 2 20 3 30 - 101 16 110 99 14 109 100 15 109 2 20 4 40 - 101 16 110 99 14 109 101 16 110 1 10 3 30 - 101 16 110 99 14 109 101 16 110 1 10 4 40 - 101 16 110 99 14 109 101 16 110 2 20 3 30 - 101 16 110 99 14 109 101 16 110 2 20 4 40 - 101 16 110 99 14 109 102 17 111 1 10 3 30 - 101 16 110 99 14 109 102 17 111 1 10 4 40 - 101 16 110 99 14 109 102 17 111 2 20 3 30 - 101 16 110 99 14 109 102 17 111 2 20 4 40 - 101 16 110 99 14 109 103 18 112 1 10 3 30 - 101 16 110 99 14 109 103 18 112 1 10 4 40 - 101 16 110 99 14 109 103 18 112 2 20 3 30 - 101 16 110 99 14 109 103 18 112 2 20 4 40 - 101 16 110 100 15 109 98 13 108 1 10 3 30 - 101 16 110 100 15 109 98 13 108 1 10 4 40 - 101 16 110 100 15 109 98 13 108 2 20 3 30 - 101 16 110 100 15 109 98 13 108 2 20 4 40 - 101 16 110 100 15 109 99 14 109 1 10 3 30 - 101 16 110 100 15 109 99 14 109 1 10 4 40 - 101 16 110 100 15 109 99 14 109 2 20 3 30 - 101 16 110 100 15 109 99 14 109 2 20 4 40 - 101 16 110 100 15 109 100 15 109 1 10 3 30 - 101 16 110 100 15 109 100 15 109 1 10 4 40 - 101 16 110 100 15 109 100 15 109 2 20 3 30 - 101 16 110 100 15 109 100 15 109 2 20 4 40 - 101 16 110 100 15 109 101 16 110 1 10 3 30 - 101 16 110 100 15 109 101 16 110 1 10 4 40 - 101 16 110 100 15 109 101 16 110 2 20 3 30 - 101 16 110 100 15 109 101 16 110 2 20 4 40 - 101 16 110 100 15 109 102 17 111 1 10 3 30 - 101 16 110 100 15 109 102 17 111 1 10 4 40 - 101 16 110 100 15 109 102 17 111 2 20 3 30 - 101 16 110 100 15 109 102 17 111 2 20 4 40 - 101 16 110 100 15 109 103 18 112 1 10 3 30 - 101 16 110 100 15 109 103 18 112 1 10 4 40 - 101 16 110 100 15 109 103 18 112 2 20 3 30 - 101 16 110 100 15 109 103 18 112 2 20 4 40 - 101 16 110 101 16 110 98 13 108 1 10 3 30 - 101 16 110 101 16 110 98 13 108 1 10 4 40 - 101 16 110 101 16 110 98 13 108 2 20 3 30 - 101 16 110 101 16 110 98 13 108 2 20 4 40 - 101 16 110 101 16 110 99 14 109 1 10 3 30 - 101 16 110 101 16 110 99 14 109 1 10 4 40 - 101 16 110 101 16 110 99 14 109 2 20 3 30 - 101 16 110 101 16 110 99 14 109 2 20 4 40 - 101 16 110 101 16 110 100 15 109 1 10 3 30 - 101 16 110 101 16 110 100 15 109 1 10 4 40 - 101 16 110 101 16 110 100 15 109 2 20 3 30 - 101 16 110 101 16 110 100 15 109 2 20 4 40 - 101 16 110 101 16 110 101 16 110 1 10 3 30 - 101 16 110 101 16 110 101 16 110 1 10 4 40 - 101 16 110 101 16 110 101 16 110 2 20 3 30 - 101 16 110 101 16 110 101 16 110 2 20 4 40 - 101 16 110 101 16 110 102 17 111 1 10 3 30 - 101 16 110 101 16 110 102 17 111 1 10 4 40 - 101 16 110 101 16 110 102 17 111 2 20 3 30 - 101 16 110 101 16 110 102 17 111 2 20 4 40 - 101 16 110 101 16 110 103 18 112 1 10 3 30 - 101 16 110 101 16 110 103 18 112 1 10 4 40 - 101 16 110 101 16 110 103 18 112 2 20 3 30 - 101 16 110 101 16 110 103 18 112 2 20 4 40 - 101 16 110 102 17 111 98 13 108 1 10 3 30 - 101 16 110 102 17 111 98 13 108 1 10 4 40 - 101 16 110 102 17 111 98 13 108 2 20 3 30 - 101 16 110 102 17 111 98 13 108 2 20 4 40 - 101 16 110 102 17 111 99 14 109 1 10 3 30 - 101 16 110 102 17 111 99 14 109 1 10 4 40 - 101 16 110 102 17 111 99 14 109 2 20 3 30 - 101 16 110 102 17 111 99 14 109 2 20 4 40 - 101 16 110 102 17 111 100 15 109 1 10 3 30 - 101 16 110 102 17 111 100 15 109 1 10 4 40 - 101 16 110 102 17 111 100 15 109 2 20 3 30 - 101 16 110 102 17 111 100 15 109 2 20 4 40 - 101 16 110 102 17 111 101 16 110 1 10 3 30 - 101 16 110 102 17 111 101 16 110 1 10 4 40 - 101 16 110 102 17 111 101 16 110 2 20 3 30 - 101 16 110 102 17 111 101 16 110 2 20 4 40 - 101 16 110 102 17 111 102 17 111 1 10 3 30 - 101 16 110 102 17 111 102 17 111 1 10 4 40 - 101 16 110 102 17 111 102 17 111 2 20 3 30 - 101 16 110 102 17 111 102 17 111 2 20 4 40 - 101 16 110 102 17 111 103 18 112 1 10 3 30 - 101 16 110 102 17 111 103 18 112 1 10 4 40 - 101 16 110 102 17 111 103 18 112 2 20 3 30 - 101 16 110 102 17 111 103 18 112 2 20 4 40 - 101 16 110 103 18 112 98 13 108 1 10 3 30 - 101 16 110 103 18 112 98 13 108 1 10 4 40 - 101 16 110 103 18 112 98 13 108 2 20 3 30 - 101 16 110 103 18 112 98 13 108 2 20 4 40 - 101 16 110 103 18 112 99 14 109 1 10 3 30 - 101 16 110 103 18 112 99 14 109 1 10 4 40 - 101 16 110 103 18 112 99 14 109 2 20 3 30 - 101 16 110 103 18 112 99 14 109 2 20 4 40 - 101 16 110 103 18 112 100 15 109 1 10 3 30 - 101 16 110 103 18 112 100 15 109 1 10 4 40 - 101 16 110 103 18 112 100 15 109 2 20 3 30 - 101 16 110 103 18 112 100 15 109 2 20 4 40 - 101 16 110 103 18 112 101 16 110 1 10 3 30 - 101 16 110 103 18 112 101 16 110 1 10 4 40 - 101 16 110 103 18 112 101 16 110 2 20 3 30 - 101 16 110 103 18 112 101 16 110 2 20 4 40 - 101 16 110 103 18 112 102 17 111 1 10 3 30 - 101 16 110 103 18 112 102 17 111 1 10 4 40 - 101 16 110 103 18 112 102 17 111 2 20 3 30 - 101 16 110 103 18 112 102 17 111 2 20 4 40 - 101 16 110 103 18 112 103 18 112 1 10 3 30 - 101 16 110 103 18 112 103 18 112 1 10 4 40 - 101 16 110 103 18 112 103 18 112 2 20 3 30 - 101 16 110 103 18 112 103 18 112 2 20 4 40 - 102 17 111 98 13 108 98 13 108 1 10 3 30 - 102 17 111 98 13 108 98 13 108 1 10 4 40 - 102 17 111 98 13 108 98 13 108 2 20 3 30 - 102 17 111 98 13 108 98 13 108 2 20 4 40 - 102 17 111 98 13 108 99 14 109 1 10 3 30 - 102 17 111 98 13 108 99 14 109 1 10 4 40 - 102 17 111 98 13 108 99 14 109 2 20 3 30 - 102 17 111 98 13 108 99 14 109 2 20 4 40 - 102 17 111 98 13 108 100 15 109 1 10 3 30 - 102 17 111 98 13 108 100 15 109 1 10 4 40 - 102 17 111 98 13 108 100 15 109 2 20 3 30 - 102 17 111 98 13 108 100 15 109 2 20 4 40 - 102 17 111 98 13 108 101 16 110 1 10 3 30 - 102 17 111 98 13 108 101 16 110 1 10 4 40 - 102 17 111 98 13 108 101 16 110 2 20 3 30 - 102 17 111 98 13 108 101 16 110 2 20 4 40 - 102 17 111 98 13 108 102 17 111 1 10 3 30 - 102 17 111 98 13 108 102 17 111 1 10 4 40 - 102 17 111 98 13 108 102 17 111 2 20 3 30 - 102 17 111 98 13 108 102 17 111 2 20 4 40 - 102 17 111 98 13 108 103 18 112 1 10 3 30 - 102 17 111 98 13 108 103 18 112 1 10 4 40 - 102 17 111 98 13 108 103 18 112 2 20 3 30 - 102 17 111 98 13 108 103 18 112 2 20 4 40 - 102 17 111 99 14 109 98 13 108 1 10 3 30 - 102 17 111 99 14 109 98 13 108 1 10 4 40 - 102 17 111 99 14 109 98 13 108 2 20 3 30 - 102 17 111 99 14 109 98 13 108 2 20 4 40 - 102 17 111 99 14 109 99 14 109 1 10 3 30 - 102 17 111 99 14 109 99 14 109 1 10 4 40 - 102 17 111 99 14 109 99 14 109 2 20 3 30 - 102 17 111 99 14 109 99 14 109 2 20 4 40 - 102 17 111 99 14 109 100 15 109 1 10 3 30 - 102 17 111 99 14 109 100 15 109 1 10 4 40 - 102 17 111 99 14 109 100 15 109 2 20 3 30 - 102 17 111 99 14 109 100 15 109 2 20 4 40 - 102 17 111 99 14 109 101 16 110 1 10 3 30 - 102 17 111 99 14 109 101 16 110 1 10 4 40 - 102 17 111 99 14 109 101 16 110 2 20 3 30 - 102 17 111 99 14 109 101 16 110 2 20 4 40 - 102 17 111 99 14 109 102 17 111 1 10 3 30 - 102 17 111 99 14 109 102 17 111 1 10 4 40 - 102 17 111 99 14 109 102 17 111 2 20 3 30 - 102 17 111 99 14 109 102 17 111 2 20 4 40 - 102 17 111 99 14 109 103 18 112 1 10 3 30 - 102 17 111 99 14 109 103 18 112 1 10 4 40 - 102 17 111 99 14 109 103 18 112 2 20 3 30 - 102 17 111 99 14 109 103 18 112 2 20 4 40 - 102 17 111 100 15 109 98 13 108 1 10 3 30 - 102 17 111 100 15 109 98 13 108 1 10 4 40 - 102 17 111 100 15 109 98 13 108 2 20 3 30 - 102 17 111 100 15 109 98 13 108 2 20 4 40 - 102 17 111 100 15 109 99 14 109 1 10 3 30 - 102 17 111 100 15 109 99 14 109 1 10 4 40 - 102 17 111 100 15 109 99 14 109 2 20 3 30 - 102 17 111 100 15 109 99 14 109 2 20 4 40 - 102 17 111 100 15 109 100 15 109 1 10 3 30 - 102 17 111 100 15 109 100 15 109 1 10 4 40 - 102 17 111 100 15 109 100 15 109 2 20 3 30 - 102 17 111 100 15 109 100 15 109 2 20 4 40 - 102 17 111 100 15 109 101 16 110 1 10 3 30 - 102 17 111 100 15 109 101 16 110 1 10 4 40 - 102 17 111 100 15 109 101 16 110 2 20 3 30 - 102 17 111 100 15 109 101 16 110 2 20 4 40 - 102 17 111 100 15 109 102 17 111 1 10 3 30 - 102 17 111 100 15 109 102 17 111 1 10 4 40 - 102 17 111 100 15 109 102 17 111 2 20 3 30 - 102 17 111 100 15 109 102 17 111 2 20 4 40 - 102 17 111 100 15 109 103 18 112 1 10 3 30 - 102 17 111 100 15 109 103 18 112 1 10 4 40 - 102 17 111 100 15 109 103 18 112 2 20 3 30 - 102 17 111 100 15 109 103 18 112 2 20 4 40 - 102 17 111 101 16 110 98 13 108 1 10 3 30 - 102 17 111 101 16 110 98 13 108 1 10 4 40 - 102 17 111 101 16 110 98 13 108 2 20 3 30 - 102 17 111 101 16 110 98 13 108 2 20 4 40 - 102 17 111 101 16 110 99 14 109 1 10 3 30 - 102 17 111 101 16 110 99 14 109 1 10 4 40 - 102 17 111 101 16 110 99 14 109 2 20 3 30 - 102 17 111 101 16 110 99 14 109 2 20 4 40 - 102 17 111 101 16 110 100 15 109 1 10 3 30 - 102 17 111 101 16 110 100 15 109 1 10 4 40 - 102 17 111 101 16 110 100 15 109 2 20 3 30 - 102 17 111 101 16 110 100 15 109 2 20 4 40 - 102 17 111 101 16 110 101 16 110 1 10 3 30 - 102 17 111 101 16 110 101 16 110 1 10 4 40 - 102 17 111 101 16 110 101 16 110 2 20 3 30 - 102 17 111 101 16 110 101 16 110 2 20 4 40 - 102 17 111 101 16 110 102 17 111 1 10 3 30 - 102 17 111 101 16 110 102 17 111 1 10 4 40 - 102 17 111 101 16 110 102 17 111 2 20 3 30 - 102 17 111 101 16 110 102 17 111 2 20 4 40 - 102 17 111 101 16 110 103 18 112 1 10 3 30 - 102 17 111 101 16 110 103 18 112 1 10 4 40 - 102 17 111 101 16 110 103 18 112 2 20 3 30 - 102 17 111 101 16 110 103 18 112 2 20 4 40 - 102 17 111 102 17 111 98 13 108 1 10 3 30 - 102 17 111 102 17 111 98 13 108 1 10 4 40 - 102 17 111 102 17 111 98 13 108 2 20 3 30 - 102 17 111 102 17 111 98 13 108 2 20 4 40 - 102 17 111 102 17 111 99 14 109 1 10 3 30 - 102 17 111 102 17 111 99 14 109 1 10 4 40 - 102 17 111 102 17 111 99 14 109 2 20 3 30 - 102 17 111 102 17 111 99 14 109 2 20 4 40 - 102 17 111 102 17 111 100 15 109 1 10 3 30 - 102 17 111 102 17 111 100 15 109 1 10 4 40 - 102 17 111 102 17 111 100 15 109 2 20 3 30 - 102 17 111 102 17 111 100 15 109 2 20 4 40 - 102 17 111 102 17 111 101 16 110 1 10 3 30 - 102 17 111 102 17 111 101 16 110 1 10 4 40 - 102 17 111 102 17 111 101 16 110 2 20 3 30 - 102 17 111 102 17 111 101 16 110 2 20 4 40 - 102 17 111 102 17 111 102 17 111 1 10 3 30 - 102 17 111 102 17 111 102 17 111 1 10 4 40 - 102 17 111 102 17 111 102 17 111 2 20 3 30 - 102 17 111 102 17 111 102 17 111 2 20 4 40 - 102 17 111 102 17 111 103 18 112 1 10 3 30 - 102 17 111 102 17 111 103 18 112 1 10 4 40 - 102 17 111 102 17 111 103 18 112 2 20 3 30 - 102 17 111 102 17 111 103 18 112 2 20 4 40 - 102 17 111 103 18 112 98 13 108 1 10 3 30 - 102 17 111 103 18 112 98 13 108 1 10 4 40 - 102 17 111 103 18 112 98 13 108 2 20 3 30 - 102 17 111 103 18 112 98 13 108 2 20 4 40 - 102 17 111 103 18 112 99 14 109 1 10 3 30 - 102 17 111 103 18 112 99 14 109 1 10 4 40 - 102 17 111 103 18 112 99 14 109 2 20 3 30 - 102 17 111 103 18 112 99 14 109 2 20 4 40 - 102 17 111 103 18 112 100 15 109 1 10 3 30 - 102 17 111 103 18 112 100 15 109 1 10 4 40 - 102 17 111 103 18 112 100 15 109 2 20 3 30 - 102 17 111 103 18 112 100 15 109 2 20 4 40 - 102 17 111 103 18 112 101 16 110 1 10 3 30 - 102 17 111 103 18 112 101 16 110 1 10 4 40 - 102 17 111 103 18 112 101 16 110 2 20 3 30 - 102 17 111 103 18 112 101 16 110 2 20 4 40 - 102 17 111 103 18 112 102 17 111 1 10 3 30 - 102 17 111 103 18 112 102 17 111 1 10 4 40 - 102 17 111 103 18 112 102 17 111 2 20 3 30 - 102 17 111 103 18 112 102 17 111 2 20 4 40 - 102 17 111 103 18 112 103 18 112 1 10 3 30 - 102 17 111 103 18 112 103 18 112 1 10 4 40 - 102 17 111 103 18 112 103 18 112 2 20 3 30 - 102 17 111 103 18 112 103 18 112 2 20 4 40 - 103 18 112 98 13 108 98 13 108 1 10 3 30 - 103 18 112 98 13 108 98 13 108 1 10 4 40 - 103 18 112 98 13 108 98 13 108 2 20 3 30 - 103 18 112 98 13 108 98 13 108 2 20 4 40 - 103 18 112 98 13 108 99 14 109 1 10 3 30 - 103 18 112 98 13 108 99 14 109 1 10 4 40 - 103 18 112 98 13 108 99 14 109 2 20 3 30 - 103 18 112 98 13 108 99 14 109 2 20 4 40 - 103 18 112 98 13 108 100 15 109 1 10 3 30 - 103 18 112 98 13 108 100 15 109 1 10 4 40 - 103 18 112 98 13 108 100 15 109 2 20 3 30 - 103 18 112 98 13 108 100 15 109 2 20 4 40 - 103 18 112 98 13 108 101 16 110 1 10 3 30 - 103 18 112 98 13 108 101 16 110 1 10 4 40 - 103 18 112 98 13 108 101 16 110 2 20 3 30 - 103 18 112 98 13 108 101 16 110 2 20 4 40 - 103 18 112 98 13 108 102 17 111 1 10 3 30 - 103 18 112 98 13 108 102 17 111 1 10 4 40 - 103 18 112 98 13 108 102 17 111 2 20 3 30 - 103 18 112 98 13 108 102 17 111 2 20 4 40 - 103 18 112 98 13 108 103 18 112 1 10 3 30 - 103 18 112 98 13 108 103 18 112 1 10 4 40 - 103 18 112 98 13 108 103 18 112 2 20 3 30 - 103 18 112 98 13 108 103 18 112 2 20 4 40 - 103 18 112 99 14 109 98 13 108 1 10 3 30 - 103 18 112 99 14 109 98 13 108 1 10 4 40 - 103 18 112 99 14 109 98 13 108 2 20 3 30 - 103 18 112 99 14 109 98 13 108 2 20 4 40 - 103 18 112 99 14 109 99 14 109 1 10 3 30 - 103 18 112 99 14 109 99 14 109 1 10 4 40 - 103 18 112 99 14 109 99 14 109 2 20 3 30 - 103 18 112 99 14 109 99 14 109 2 20 4 40 - 103 18 112 99 14 109 100 15 109 1 10 3 30 - 103 18 112 99 14 109 100 15 109 1 10 4 40 - 103 18 112 99 14 109 100 15 109 2 20 3 30 - 103 18 112 99 14 109 100 15 109 2 20 4 40 - 103 18 112 99 14 109 101 16 110 1 10 3 30 - 103 18 112 99 14 109 101 16 110 1 10 4 40 - 103 18 112 99 14 109 101 16 110 2 20 3 30 - 103 18 112 99 14 109 101 16 110 2 20 4 40 - 103 18 112 99 14 109 102 17 111 1 10 3 30 - 103 18 112 99 14 109 102 17 111 1 10 4 40 - 103 18 112 99 14 109 102 17 111 2 20 3 30 - 103 18 112 99 14 109 102 17 111 2 20 4 40 - 103 18 112 99 14 109 103 18 112 1 10 3 30 - 103 18 112 99 14 109 103 18 112 1 10 4 40 - 103 18 112 99 14 109 103 18 112 2 20 3 30 - 103 18 112 99 14 109 103 18 112 2 20 4 40 - 103 18 112 100 15 109 98 13 108 1 10 3 30 - 103 18 112 100 15 109 98 13 108 1 10 4 40 - 103 18 112 100 15 109 98 13 108 2 20 3 30 - 103 18 112 100 15 109 98 13 108 2 20 4 40 - 103 18 112 100 15 109 99 14 109 1 10 3 30 - 103 18 112 100 15 109 99 14 109 1 10 4 40 - 103 18 112 100 15 109 99 14 109 2 20 3 30 - 103 18 112 100 15 109 99 14 109 2 20 4 40 - 103 18 112 100 15 109 100 15 109 1 10 3 30 - 103 18 112 100 15 109 100 15 109 1 10 4 40 - 103 18 112 100 15 109 100 15 109 2 20 3 30 - 103 18 112 100 15 109 100 15 109 2 20 4 40 - 103 18 112 100 15 109 101 16 110 1 10 3 30 - 103 18 112 100 15 109 101 16 110 1 10 4 40 - 103 18 112 100 15 109 101 16 110 2 20 3 30 - 103 18 112 100 15 109 101 16 110 2 20 4 40 - 103 18 112 100 15 109 102 17 111 1 10 3 30 - 103 18 112 100 15 109 102 17 111 1 10 4 40 - 103 18 112 100 15 109 102 17 111 2 20 3 30 - 103 18 112 100 15 109 102 17 111 2 20 4 40 - 103 18 112 100 15 109 103 18 112 1 10 3 30 - 103 18 112 100 15 109 103 18 112 1 10 4 40 - 103 18 112 100 15 109 103 18 112 2 20 3 30 - 103 18 112 100 15 109 103 18 112 2 20 4 40 - 103 18 112 101 16 110 98 13 108 1 10 3 30 - 103 18 112 101 16 110 98 13 108 1 10 4 40 - 103 18 112 101 16 110 98 13 108 2 20 3 30 - 103 18 112 101 16 110 98 13 108 2 20 4 40 - 103 18 112 101 16 110 99 14 109 1 10 3 30 - 103 18 112 101 16 110 99 14 109 1 10 4 40 - 103 18 112 101 16 110 99 14 109 2 20 3 30 - 103 18 112 101 16 110 99 14 109 2 20 4 40 - 103 18 112 101 16 110 100 15 109 1 10 3 30 - 103 18 112 101 16 110 100 15 109 1 10 4 40 - 103 18 112 101 16 110 100 15 109 2 20 3 30 - 103 18 112 101 16 110 100 15 109 2 20 4 40 - 103 18 112 101 16 110 101 16 110 1 10 3 30 - 103 18 112 101 16 110 101 16 110 1 10 4 40 - 103 18 112 101 16 110 101 16 110 2 20 3 30 - 103 18 112 101 16 110 101 16 110 2 20 4 40 - 103 18 112 101 16 110 102 17 111 1 10 3 30 - 103 18 112 101 16 110 102 17 111 1 10 4 40 - 103 18 112 101 16 110 102 17 111 2 20 3 30 - 103 18 112 101 16 110 102 17 111 2 20 4 40 - 103 18 112 101 16 110 103 18 112 1 10 3 30 - 103 18 112 101 16 110 103 18 112 1 10 4 40 - 103 18 112 101 16 110 103 18 112 2 20 3 30 - 103 18 112 101 16 110 103 18 112 2 20 4 40 - 103 18 112 102 17 111 98 13 108 1 10 3 30 - 103 18 112 102 17 111 98 13 108 1 10 4 40 - 103 18 112 102 17 111 98 13 108 2 20 3 30 - 103 18 112 102 17 111 98 13 108 2 20 4 40 - 103 18 112 102 17 111 99 14 109 1 10 3 30 - 103 18 112 102 17 111 99 14 109 1 10 4 40 - 103 18 112 102 17 111 99 14 109 2 20 3 30 - 103 18 112 102 17 111 99 14 109 2 20 4 40 - 103 18 112 102 17 111 100 15 109 1 10 3 30 - 103 18 112 102 17 111 100 15 109 1 10 4 40 - 103 18 112 102 17 111 100 15 109 2 20 3 30 - 103 18 112 102 17 111 100 15 109 2 20 4 40 - 103 18 112 102 17 111 101 16 110 1 10 3 30 - 103 18 112 102 17 111 101 16 110 1 10 4 40 - 103 18 112 102 17 111 101 16 110 2 20 3 30 - 103 18 112 102 17 111 101 16 110 2 20 4 40 - 103 18 112 102 17 111 102 17 111 1 10 3 30 - 103 18 112 102 17 111 102 17 111 1 10 4 40 - 103 18 112 102 17 111 102 17 111 2 20 3 30 - 103 18 112 102 17 111 102 17 111 2 20 4 40 - 103 18 112 102 17 111 103 18 112 1 10 3 30 - 103 18 112 102 17 111 103 18 112 1 10 4 40 - 103 18 112 102 17 111 103 18 112 2 20 3 30 - 103 18 112 102 17 111 103 18 112 2 20 4 40 - 103 18 112 103 18 112 98 13 108 1 10 3 30 - 103 18 112 103 18 112 98 13 108 1 10 4 40 - 103 18 112 103 18 112 98 13 108 2 20 3 30 - 103 18 112 103 18 112 98 13 108 2 20 4 40 - 103 18 112 103 18 112 99 14 109 1 10 3 30 - 103 18 112 103 18 112 99 14 109 1 10 4 40 - 103 18 112 103 18 112 99 14 109 2 20 3 30 - 103 18 112 103 18 112 99 14 109 2 20 4 40 - 103 18 112 103 18 112 100 15 109 1 10 3 30 - 103 18 112 103 18 112 100 15 109 1 10 4 40 - 103 18 112 103 18 112 100 15 109 2 20 3 30 - 103 18 112 103 18 112 100 15 109 2 20 4 40 - 103 18 112 103 18 112 101 16 110 1 10 3 30 - 103 18 112 103 18 112 101 16 110 1 10 4 40 - 103 18 112 103 18 112 101 16 110 2 20 3 30 - 103 18 112 103 18 112 101 16 110 2 20 4 40 - 103 18 112 103 18 112 102 17 111 1 10 3 30 - 103 18 112 103 18 112 102 17 111 1 10 4 40 - 103 18 112 103 18 112 102 17 111 2 20 3 30 - 103 18 112 103 18 112 102 17 111 2 20 4 40 - 103 18 112 103 18 112 103 18 112 1 10 3 30 - 103 18 112 103 18 112 103 18 112 1 10 4 40 - 103 18 112 103 18 112 103 18 112 2 20 3 30 - 103 18 112 103 18 112 103 18 112 2 20 4 40 - -echo select * from t1,t2 where t1.f1>100; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t2.f1 t2.f2 t2.f3 ---------------------------------------------------------- - 101 16 110 98 13 108 - 101 16 110 99 14 109 - 101 16 110 100 15 109 - 101 16 110 101 16 110 - 101 16 110 102 17 111 - 101 16 110 103 18 112 - 102 17 111 98 13 108 - 102 17 111 99 14 109 - 102 17 111 100 15 109 - 102 17 111 101 16 110 - 102 17 111 102 17 111 - 102 17 111 103 18 112 - 103 18 112 98 13 108 - 103 18 112 99 14 109 - 103 18 112 100 15 109 - 103 18 112 101 16 110 - 103 18 112 102 17 111 - 103 18 112 103 18 112 - diff --git a/test/sql/Join/exp.test004.ksh b/test/sql/Join/exp.test004.ksh deleted file mode 100644 index 2b516ef0..00000000 --- a/test/sql/Join/exp.test004.ksh +++ /dev/null @@ -1,25 +0,0 @@ -echo select * from t1,t2,t3 where t1.f2=t2.f2 and t1.f3=t3.f2; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t2.f1 t2.f2 t2.f3 t3.f1 t3.f2 t3.f3 ---------------------------------------------------------- - 99 14 109 99 14 109 100 109 109 - 100 15 109 100 15 109 100 109 109 - -echo select * from t1,t2,t3 where t1.f2=t2.f2 or t1.f3=t3.f2; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t2.f1 t2.f2 t2.f3 t3.f1 t3.f2 t3.f3 ---------------------------------------------------------- - 98 13 108 98 13 108 98 13 108 - 98 13 108 98 13 108 100 109 109 - 98 13 108 98 13 108 102 17 111 - 99 14 109 98 13 108 100 109 109 - 99 14 109 99 14 109 98 13 108 - 99 14 109 99 14 109 100 109 109 - 99 14 109 99 14 109 102 17 111 - 99 14 109 100 15 109 100 109 109 - 100 15 109 98 13 108 100 109 109 - 100 15 109 99 14 109 100 109 109 - 100 15 109 100 15 109 98 13 108 - 100 15 109 100 15 109 100 109 109 - 100 15 109 100 15 109 102 17 111 - diff --git a/test/sql/Join/exp.test005.ksh b/test/sql/Join/exp.test005.ksh deleted file mode 100644 index 8d3870b1..00000000 --- a/test/sql/Join/exp.test005.ksh +++ /dev/null @@ -1,21 +0,0 @@ -echo select t1.f1,t2.f1,t3.f1 from t1,t2,t3 where t1.f2=t2.f2 or t1.f1 > 100; ---------------------------------------------------------- - t1.f1 t2.f1 t3.f1 ---------------------------------------------------------- - 98 98 98 - 98 98 100 - 98 98 102 - 99 99 98 - 99 99 100 - 99 99 102 - 100 100 98 - 100 100 100 - 100 100 102 - -echo select t1.f1, t2.f1, t3.f1 from t1,t2,t3 where t1.f2= t2.f2 and t1.f3 = t3.f2; ---------------------------------------------------------- - t1.f1 t2.f1 t3.f1 ---------------------------------------------------------- - 99 99 100 - 100 100 100 - diff --git a/test/sql/Join/exp.test006.ksh b/test/sql/Join/exp.test006.ksh deleted file mode 100644 index 2409b982..00000000 --- a/test/sql/Join/exp.test006.ksh +++ /dev/null @@ -1,3 +0,0 @@ -echo select * from t1,t2 where t1.f1=t2.f100; -Statement prepare failed with error -19 - diff --git a/test/sql/Join/exp.test007.ksh b/test/sql/Join/exp.test007.ksh deleted file mode 100644 index c7b5038a..00000000 --- a/test/sql/Join/exp.test007.ksh +++ /dev/null @@ -1,14 +0,0 @@ -echo select * from t11 where t11.f1=2; ---------------------------------------------------------- - t11.f1 t11.f2 t11.f3 t11.f4 t11.f5 ---------------------------------------------------------- - 2 Y sales 6000 20 - -echo select * from t11 where t11.f1=t11.f1; ---------------------------------------------------------- - t11.f1 t11.f2 t11.f3 t11.f4 t11.f5 ---------------------------------------------------------- - 1 X IT 5000 10 - 2 Y sales 6000 20 - 3 Z IT 7000 10 - diff --git a/test/sql/Join/exp.test008.ksh b/test/sql/Join/exp.test008.ksh deleted file mode 100644 index 1839117c..00000000 --- a/test/sql/Join/exp.test008.ksh +++ /dev/null @@ -1,42 +0,0 @@ -echo select * from t11,t12 where t11.f5=t12.f1; ---------------------------------------------------------- - t11.f1 t11.f2 t11.f3 t11.f4 t11.f5 t12.f1 t12.f2 t12.f3 ---------------------------------------------------------- - 1 X IT 5000 10 10 IT BBSR - 2 Y sales 6000 20 20 HR CTC - 3 Z IT 7000 10 10 IT BBSR - -echo select * from t11,t12 where t11.f5 > t12.f1; ---------------------------------------------------------- - t11.f1 t11.f2 t11.f3 t11.f4 t11.f5 t12.f1 t12.f2 t12.f3 ---------------------------------------------------------- - 2 Y sales 6000 20 10 IT BBSR - -echo select * from t11,t12 where t12.f1 <= t11.f5; ---------------------------------------------------------- - t11.f1 t11.f2 t11.f3 t11.f4 t11.f5 t12.f1 t12.f2 t12.f3 ---------------------------------------------------------- - 1 X IT 5000 10 10 IT BBSR - 2 Y sales 6000 20 10 IT BBSR - 2 Y sales 6000 20 20 HR CTC - 3 Z IT 7000 10 10 IT BBSR - -echo select * from t11,t12 where t12.f1 != t11.f5; ---------------------------------------------------------- - t11.f1 t11.f2 t11.f3 t11.f4 t11.f5 t12.f1 t12.f2 t12.f3 ---------------------------------------------------------- - 1 X IT 5000 10 20 HR CTC - 1 X IT 5000 10 30 R&D DELHI - 2 Y sales 6000 20 10 IT BBSR - 2 Y sales 6000 20 30 R&D DELHI - 3 Z IT 7000 10 20 HR CTC - 3 Z IT 7000 10 30 R&D DELHI - -echo select * from t11,t12 where t12.f1 > 20; ---------------------------------------------------------- - t11.f1 t11.f2 t11.f3 t11.f4 t11.f5 t12.f1 t12.f2 t12.f3 ---------------------------------------------------------- - 1 X IT 5000 10 30 R&D DELHI - 2 Y sales 6000 20 30 R&D DELHI - 3 Z IT 7000 10 30 R&D DELHI - diff --git a/test/sql/Join/exp.test009.ksh b/test/sql/Join/exp.test009.ksh deleted file mode 100644 index f6a6af08..00000000 --- a/test/sql/Join/exp.test009.ksh +++ /dev/null @@ -1,27 +0,0 @@ -echo select t11.f5, t13.f8 from t11,t13 where t11.f5=t13.f8; ---------------------------------------------------------- - t11.f5 t13.f8 ---------------------------------------------------------- - 20 20 - -echo select t11.f1,t11.f5,t13.f8 from t11,t13 where t11.f5=t13.f8; ---------------------------------------------------------- - t11.f1 t11.f5 t13.f8 ---------------------------------------------------------- - 2 20 20 - -echo select * from t11,t13 where t13.f8 > t11.f5; ---------------------------------------------------------- - t11.f1 t11.f2 t11.f3 t11.f4 t11.f5 t13.f7 t13.f8 ---------------------------------------------------------- - 1 X IT 5000 10 2 20 - 1 X IT 5000 10 1 50 - 2 Y sales 6000 20 1 50 - 3 Z IT 7000 10 2 20 - 3 Z IT 7000 10 1 50 - -echo select t11.f1,t11.f5,t13.f8 from t11,t13 where t13.f8 < t11.f5; ---------------------------------------------------------- - t11.f1 t11.f5 t13.f8 ---------------------------------------------------------- - diff --git a/test/sql/Join/exp.test010.ksh b/test/sql/Join/exp.test010.ksh deleted file mode 100644 index 9d9b9419..00000000 --- a/test/sql/Join/exp.test010.ksh +++ /dev/null @@ -1,19 +0,0 @@ -echo select * from t11,t12,t13 where t12.f1=t13.f8 and t13.f7=t11.f1; ---------------------------------------------------------- - t11.f1 t11.f2 t11.f3 t11.f4 t11.f5 t12.f1 t12.f2 t12.f3 t13.f7 t13.f8 ---------------------------------------------------------- - 2 Y sales 6000 20 20 HR CTC 2 20 - -echo select * from t11,t12,t13 where t12.f1=t13.f8 or t13.f7=t11.f1; ---------------------------------------------------------- - t11.f1 t11.f2 t11.f3 t11.f4 t11.f5 t12.f1 t12.f2 t12.f3 t13.f7 t13.f8 ---------------------------------------------------------- - 1 X IT 5000 10 10 IT BBSR 1 50 - 1 X IT 5000 10 20 HR CTC 2 20 - 1 X IT 5000 10 20 HR CTC 1 50 - 1 X IT 5000 10 30 R&D DELHI 1 50 - 2 Y sales 6000 20 10 IT BBSR 2 20 - 2 Y sales 6000 20 20 HR CTC 2 20 - 2 Y sales 6000 20 30 R&D DELHI 2 20 - 3 Z IT 7000 10 20 HR CTC 2 20 - diff --git a/test/sql/Join/exp.test011.ksh b/test/sql/Join/exp.test011.ksh deleted file mode 100644 index 1433a356..00000000 --- a/test/sql/Join/exp.test011.ksh +++ /dev/null @@ -1,13 +0,0 @@ -echo select t11.f1,t12.f7 from t12,t11; -Statement prepare failed with error -19 -echo select t11.f1,t12.f7 from t13,t11; ---------------------------------------------------------- - t11.f1 t13.f7 ---------------------------------------------------------- - 1 2 - 2 2 - 3 2 - 1 1 - 2 1 - 3 1 - diff --git a/test/sql/Join/exp.test012.ksh b/test/sql/Join/exp.test012.ksh deleted file mode 100644 index 777b01ee..00000000 --- a/test/sql/Join/exp.test012.ksh +++ /dev/null @@ -1,102 +0,0 @@ -echo create table emp(eno int,mgrno int,sal float,deptno int); -Statement Executed -echo insert into emp values(1,3,5000,10); -Statement Executed: Rows Affected = 1 -echo insert into emp values(2,4,4000,20); -Statement Executed: Rows Affected = 1 -echo insert into emp values(3,NULL,8000,10); -Statement Executed: Rows Affected = 1 -echo create table dept(deptno int,dname char(10),lid int); -Statement Executed -echo insert into dept values(10,'IT',100); -Statement Executed: Rows Affected = 1 -echo insert into dept values(20,'HR',300); -Statement Executed: Rows Affected = 1 -echo create table loc(lid int,state char(10)); -Statement Executed -echo insert into loc values(100,'Orissa'); -Statement Executed: Rows Affected = 1 -echo insert into loc values(200,'Cal'); -Statement Executed: Rows Affected = 1 -echo insert into loc values(300,'Calif'); -Statement Executed: Rows Affected = 1 -echo select * from emp; ---------------------------------------------------------- - eno mgrno sal deptno ---------------------------------------------------------- - 1 3 5000.000000 10 - 2 4 4000.000000 20 - 3 NULL 8000.000000 10 - -echo select * from dept; ---------------------------------------------------------- - deptno dname lid ---------------------------------------------------------- - 10 IT 100 - 20 HR 300 - -echo select * from loc; ---------------------------------------------------------- - lid state ---------------------------------------------------------- - 100 Orissa - 200 Cal - 300 Calif - -echo select * from emp,dept,loc; ---------------------------------------------------------- - eno mgrno sal deptno deptno dname lid lid state ---------------------------------------------------------- - 1 3 5000.000000 10 10 IT 100 100 Orissa - 1 3 5000.000000 10 10 IT 100 200 Cal - 1 3 5000.000000 10 10 IT 100 300 Calif - 1 3 5000.000000 10 20 HR 300 100 Orissa - 1 3 5000.000000 10 20 HR 300 200 Cal - 1 3 5000.000000 10 20 HR 300 300 Calif - 2 4 4000.000000 20 10 IT 100 100 Orissa - 2 4 4000.000000 20 10 IT 100 200 Cal - 2 4 4000.000000 20 10 IT 100 300 Calif - 2 4 4000.000000 20 20 HR 300 100 Orissa - 2 4 4000.000000 20 20 HR 300 200 Cal - 2 4 4000.000000 20 20 HR 300 300 Calif - 3 NULL 8000.000000 10 10 IT 100 100 Orissa - 3 NULL 8000.000000 10 10 IT 100 200 Cal - 3 NULL 8000.000000 10 10 IT 100 300 Calif - 3 NULL 8000.000000 10 20 HR 300 100 Orissa - 3 NULL 8000.000000 10 20 HR 300 200 Cal - 3 NULL 8000.000000 10 20 HR 300 300 Calif - -echo select * from emp,dept,loc where emp.deptno!=dept.deptno AND dept.lid!=loc.lid; ---------------------------------------------------------- - eno mgrno sal deptno deptno dname lid lid state ---------------------------------------------------------- - 1 3 5000.000000 10 20 HR 300 100 Orissa - 1 3 5000.000000 10 20 HR 300 200 Cal - 2 4 4000.000000 20 10 IT 100 200 Cal - 2 4 4000.000000 20 10 IT 100 300 Calif - 3 NULL 8000.000000 10 20 HR 300 100 Orissa - 3 NULL 8000.000000 10 20 HR 300 200 Cal - -echo select * from emp,dept,loc where NOT(emp.deptno!=dept.deptno AND dept.lid!=loc.lid); ---------------------------------------------------------- - eno mgrno sal deptno deptno dname lid lid state ---------------------------------------------------------- - 1 3 5000.000000 10 10 IT 100 100 Orissa - 1 3 5000.000000 10 10 IT 100 200 Cal - 1 3 5000.000000 10 10 IT 100 300 Calif - 1 3 5000.000000 10 20 HR 300 300 Calif - 2 4 4000.000000 20 10 IT 100 100 Orissa - 2 4 4000.000000 20 20 HR 300 100 Orissa - 2 4 4000.000000 20 20 HR 300 200 Cal - 2 4 4000.000000 20 20 HR 300 300 Calif - 3 NULL 8000.000000 10 10 IT 100 100 Orissa - 3 NULL 8000.000000 10 10 IT 100 200 Cal - 3 NULL 8000.000000 10 10 IT 100 300 Calif - 3 NULL 8000.000000 10 20 HR 300 300 Calif - -echo drop table emp; -Statement Executed -echo drop table dept; -Statement Executed -echo drop table loc; -Statement Executed diff --git a/test/sql/Join/exp.test013.ksh b/test/sql/Join/exp.test013.ksh deleted file mode 100644 index 8e004356..00000000 --- a/test/sql/Join/exp.test013.ksh +++ /dev/null @@ -1,87 +0,0 @@ -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from emp; ---------------------------------------------------------- - emp.eno emp.dno ---------------------------------------------------------- - 1 10 - 2 20 - 4 40 - -echo select * from dept; ---------------------------------------------------------- - dept.deptno dept.dname ---------------------------------------------------------- - 20 Sales - 30 IT - 40 Mkt - 50 HR - -echo select * from emp,dept; ---------------------------------------------------------- - emp.eno emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 1 10 20 Sales - 1 10 30 IT - 1 10 40 Mkt - 1 10 50 HR - 2 20 20 Sales - 2 20 30 IT - 2 20 40 Mkt - 2 20 50 HR - 4 40 20 Sales - 4 40 30 IT - 4 40 40 Mkt - 4 40 50 HR - -echo select * from emp,dept where emp.dno in(20,30); ---------------------------------------------------------- - emp.eno emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 2 20 20 Sales - 2 20 30 IT - 2 20 40 Mkt - 2 20 50 HR - -echo select * from emp,dept where dept.deptno in(20,30); ---------------------------------------------------------- - emp.eno emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 1 10 20 Sales - 1 10 30 IT - 2 20 20 Sales - 2 20 30 IT - 4 40 20 Sales - 4 40 30 IT - -echo select * from emp,dept where emp.dno in(20,30) and dept.deptno in(20,30); ---------------------------------------------------------- - emp.eno emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 2 20 20 Sales - 2 20 30 IT - -echo select * from emp,dept where emp.dno in(20,30) or dept.deptno in(20,30); ---------------------------------------------------------- - emp.eno emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 1 10 20 Sales - 1 10 30 IT - 2 20 20 Sales - 2 20 30 IT - 2 20 40 Mkt - 2 20 50 HR - 4 40 20 Sales - 4 40 30 IT - -echo drop table emp; -Statement Executed -echo drop table dept; -Statement Executed diff --git a/test/sql/Join/exp.test014.ksh b/test/sql/Join/exp.test014.ksh deleted file mode 100644 index 22adc003..00000000 --- a/test/sql/Join/exp.test014.ksh +++ /dev/null @@ -1,82 +0,0 @@ -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from emp; ---------------------------------------------------------- - emp.eno emp.dno ---------------------------------------------------------- - 1 10 - 2 20 - 4 40 - -echo select * from dept; ---------------------------------------------------------- - dept.deptno dept.dname ---------------------------------------------------------- - 20 Sales - 30 IT - 40 Mkt - 50 HR - -echo select * from emp,dept; ---------------------------------------------------------- - emp.eno emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 1 10 20 Sales - 1 10 30 IT - 1 10 40 Mkt - 1 10 50 HR - 2 20 20 Sales - 2 20 30 IT - 2 20 40 Mkt - 2 20 50 HR - 4 40 20 Sales - 4 40 30 IT - 4 40 40 Mkt - 4 40 50 HR - -echo select * from emp,dept where emp.dno between 10 and 30; ---------------------------------------------------------- - emp.eno emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 1 10 20 Sales - 1 10 30 IT - 1 10 40 Mkt - 1 10 50 HR - 2 20 20 Sales - 2 20 30 IT - 2 20 40 Mkt - 2 20 50 HR - -echo select * from emp,dept where dept.deptno between 20 and 40; ---------------------------------------------------------- - emp.eno emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 1 10 20 Sales - 1 10 30 IT - 1 10 40 Mkt - 2 20 20 Sales - 2 20 30 IT - 2 20 40 Mkt - 4 40 20 Sales - 4 40 30 IT - 4 40 40 Mkt - -echo select * from emp,dept where emp.dno between 15 and 30 and dept.deptno between 20 and 40; ---------------------------------------------------------- - emp.eno emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 2 20 20 Sales - 2 20 30 IT - 2 20 40 Mkt - -echo drop table emp; -Statement Executed -echo drop table dept; -Statement Executed diff --git a/test/sql/Join/exp.test015.ksh b/test/sql/Join/exp.test015.ksh deleted file mode 100644 index 26c7b1b4..00000000 --- a/test/sql/Join/exp.test015.ksh +++ /dev/null @@ -1,76 +0,0 @@ -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from emp,dept; ---------------------------------------------------------- - emp.eno emp.ename emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 1 Nihar 10 20 Sales - 1 Nihar 10 40 Mkt - 1 Nihar 10 35 HR - 2 Kishore 20 20 Sales - 2 Kishore 20 40 Mkt - 2 Kishore 20 35 HR - 3 Jiten 30 20 Sales - 3 Jiten 30 40 Mkt - 3 Jiten 30 35 HR - 4 Bijay 40 20 Sales - 4 Bijay 40 40 Mkt - 4 Bijay 40 35 HR - 5 Kailash 50 20 Sales - 5 Kailash 50 40 Mkt - 5 Kailash 50 35 HR - -echo select * from emp,dept where emp.ename LIKE 'K%'; ---------------------------------------------------------- - emp.eno emp.ename emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 2 Kishore 20 20 Sales - 2 Kishore 20 40 Mkt - 2 Kishore 20 35 HR - 5 Kailash 50 20 Sales - 5 Kailash 50 40 Mkt - 5 Kailash 50 35 HR - -echo select * from emp,dept where dept.dname LIKE 'S%'; ---------------------------------------------------------- - emp.eno emp.ename emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 1 Nihar 10 20 Sales - 2 Kishore 20 20 Sales - 3 Jiten 30 20 Sales - 4 Bijay 40 20 Sales - 5 Kailash 50 20 Sales - -echo select * from emp,dept where emp.ename LIKE 'K%' and dept.dname LIKE 'S%'; ---------------------------------------------------------- - emp.eno emp.ename emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 2 Kishore 20 20 Sales - 5 Kailash 50 20 Sales - -echo select * from emp,dept where emp.ename LIKE 'K%' or dept.dname LIKE 'S%'; ---------------------------------------------------------- - emp.eno emp.ename emp.dno dept.deptno dept.dname ---------------------------------------------------------- - 1 Nihar 10 20 Sales - 2 Kishore 20 20 Sales - 2 Kishore 20 40 Mkt - 2 Kishore 20 35 HR - 3 Jiten 30 20 Sales - 4 Bijay 40 20 Sales - 5 Kailash 50 20 Sales - 5 Kailash 50 40 Mkt - 5 Kailash 50 35 HR - -echo drop table emp; -Statement Executed -echo drop table dept; -Statement Executed diff --git a/test/sql/Join/exp.test016.ksh b/test/sql/Join/exp.test016.ksh deleted file mode 100644 index 98430475..00000000 --- a/test/sql/Join/exp.test016.ksh +++ /dev/null @@ -1,60 +0,0 @@ -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - emp.eno emp.ename emp.dno ---------------------------------------------------------- - 1 Nihar 10 - 2 Papu 20 - 3 Sima 30 - 4 Nama 40 - 5 Pinu 50 - ---------------------------------------------------------- - dept.deptno dept.dname dept.lid ---------------------------------------------------------- - 20 IT 101 - 40 Sales 102 - 60 Mkt 103 - 30 Store 104 - ---------------------------------------------------------- - emp.eno emp.ename emp.dno dept.deptno dept.dname dept.lid ---------------------------------------------------------- - 1 Nihar 10 20 IT 101 - 1 Nihar 10 40 Sales 102 - 1 Nihar 10 60 Mkt 103 - 1 Nihar 10 30 Store 104 - 2 Papu 20 20 IT 101 - 2 Papu 20 40 Sales 102 - 2 Papu 20 60 Mkt 103 - 2 Papu 20 30 Store 104 - 3 Sima 30 20 IT 101 - 3 Sima 30 40 Sales 102 - 3 Sima 30 60 Mkt 103 - 3 Sima 30 30 Store 104 - 4 Nama 40 20 IT 101 - 4 Nama 40 40 Sales 102 - 4 Nama 40 60 Mkt 103 - 4 Nama 40 30 Store 104 - 5 Pinu 50 20 IT 101 - 5 Pinu 50 40 Sales 102 - 5 Pinu 50 60 Mkt 103 - 5 Pinu 50 30 Store 104 - -echo select * from emp where emp.deptno in (20,30,40); -Statement prepare failed with error -19 -echo select * from emp,dept where emp.deptno in (20,30,40); -Statement prepare failed with error -19 -echo drop table emp; -Statement Executed -echo drop table dept; -Statement Executed diff --git a/test/sql/Join/exp.test017.ksh b/test/sql/Join/exp.test017.ksh deleted file mode 100644 index 48e2fe16..00000000 --- a/test/sql/Join/exp.test017.ksh +++ /dev/null @@ -1,60 +0,0 @@ -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - emp.eno emp.ename emp.dno ---------------------------------------------------------- - 1 Nihar 10 - 2 Papu 20 - 3 Sima 30 - 4 Nama 40 - 5 Pinu 50 - ---------------------------------------------------------- - dept.deptno dept.dname dept.lid ---------------------------------------------------------- - 20 IT 101 - 40 Sales 102 - 60 Mkt 103 - 30 Store 104 - ---------------------------------------------------------- - emp.eno emp.ename emp.dno dept.deptno dept.dname dept.lid ---------------------------------------------------------- - 1 Nihar 10 20 IT 101 - 1 Nihar 10 40 Sales 102 - 1 Nihar 10 60 Mkt 103 - 1 Nihar 10 30 Store 104 - 2 Papu 20 20 IT 101 - 2 Papu 20 40 Sales 102 - 2 Papu 20 60 Mkt 103 - 2 Papu 20 30 Store 104 - 3 Sima 30 20 IT 101 - 3 Sima 30 40 Sales 102 - 3 Sima 30 60 Mkt 103 - 3 Sima 30 30 Store 104 - 4 Nama 40 20 IT 101 - 4 Nama 40 40 Sales 102 - 4 Nama 40 60 Mkt 103 - 4 Nama 40 30 Store 104 - 5 Pinu 50 20 IT 101 - 5 Pinu 50 40 Sales 102 - 5 Pinu 50 60 Mkt 103 - 5 Pinu 50 30 Store 104 - -echo select * from emp where emp.deptno between 20 and 40; -Statement prepare failed with error -19 -echo select * from emp,dept where emp.deptno between 20 and 40; -Statement prepare failed with error -19 -echo drop table emp; -Statement Executed -echo drop table dept; -Statement Executed diff --git a/test/sql/Join/exp.test018.ksh b/test/sql/Join/exp.test018.ksh deleted file mode 100644 index 00efc8e7..00000000 --- a/test/sql/Join/exp.test018.ksh +++ /dev/null @@ -1,60 +0,0 @@ -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - emp.eno emp.ename emp.dno ---------------------------------------------------------- - 1 Nihar 10 - 2 Papu 20 - 3 Sima 30 - 4 Nama 40 - 5 Pinu 50 - ---------------------------------------------------------- - dept.deptno dept.dname dept.lid ---------------------------------------------------------- - 20 IT 101 - 40 Sales 102 - 60 Mkt 103 - 30 Store 104 - ---------------------------------------------------------- - emp.eno emp.ename emp.dno dept.deptno dept.dname dept.lid ---------------------------------------------------------- - 1 Nihar 10 20 IT 101 - 1 Nihar 10 40 Sales 102 - 1 Nihar 10 60 Mkt 103 - 1 Nihar 10 30 Store 104 - 2 Papu 20 20 IT 101 - 2 Papu 20 40 Sales 102 - 2 Papu 20 60 Mkt 103 - 2 Papu 20 30 Store 104 - 3 Sima 30 20 IT 101 - 3 Sima 30 40 Sales 102 - 3 Sima 30 60 Mkt 103 - 3 Sima 30 30 Store 104 - 4 Nama 40 20 IT 101 - 4 Nama 40 40 Sales 102 - 4 Nama 40 60 Mkt 103 - 4 Nama 40 30 Store 104 - 5 Pinu 50 20 IT 101 - 5 Pinu 50 40 Sales 102 - 5 Pinu 50 60 Mkt 103 - 5 Pinu 50 30 Store 104 - -echo select * from emp where emp.dname like 'S%'; -Statement prepare failed with error -19 -echo select * from emp,dept where emp.dname like 'S%'; -Statement prepare failed with error -19 -echo drop table emp; -Statement Executed -echo drop table dept; -Statement Executed diff --git a/test/sql/Join/exp1.test004.ksh b/test/sql/Join/exp1.test004.ksh deleted file mode 100644 index 99db5a7f..00000000 --- a/test/sql/Join/exp1.test004.ksh +++ /dev/null @@ -1,8 +0,0 @@ - --------------------------- - f1 f1 f2 f2 - --------------------------- - 101 101 16 16 - 102 102 17 17 - 103 103 18 18 - - diff --git a/test/sql/Join/join1.sql b/test/sql/Join/join1.sql deleted file mode 100644 index 64031f40..00000000 --- a/test/sql/Join/join1.sql +++ /dev/null @@ -1,11 +0,0 @@ -echo select t1.f1 from t1; -select t1.f1 from t1; - -echo select t1.f30 from t1; -select t1.f30 from t1; - -echo select * from t1,t55 ; -select * from t1,t55 ; - -echo select t100.f1 from t1; -select t100.f1 from t1; diff --git a/test/sql/Join/join10.sql b/test/sql/Join/join10.sql deleted file mode 100644 index 9a3e1ab8..00000000 --- a/test/sql/Join/join10.sql +++ /dev/null @@ -1,6 +0,0 @@ -echo select * from t11,t12,t13 where t12.f1=t13.f8 and t13.f7=t11.f1; -select * from t11,t12,t13 where t12.f1=t13.f8 and t13.f7=t11.f1; - -echo select * from t11,t12,t13 where t12.f1=t13.f8 or t13.f7=t11.f1; -select * from t11,t12,t13 where t12.f1=t13.f8 or t13.f7=t11.f1; - diff --git a/test/sql/Join/join11.sql b/test/sql/Join/join11.sql deleted file mode 100644 index aaddc97e..00000000 --- a/test/sql/Join/join11.sql +++ /dev/null @@ -1,6 +0,0 @@ -echo select t11.f1,t12.f7 from t12,t11; -select t11.f1,t12.f7 from t12,t11; - -echo select t11.f1,t12.f7 from t13,t11; -select t11.f1,t13.f7 from t13,t11; - diff --git a/test/sql/Join/join2.sql b/test/sql/Join/join2.sql deleted file mode 100644 index 13229971..00000000 --- a/test/sql/Join/join2.sql +++ /dev/null @@ -1,5 +0,0 @@ -echo select * from t1,t2 where t1.f1>100 or t2.f1<100; -select * from t1,t2 where t1.f1>100 or t2.f1<100; - -echo select * from t1,t2 where t1.f1 = t2.f1 and t1.f1 >100; -select * from t1,t2 where t1.f1 = t2.f1 and t1.f1 >100; diff --git a/test/sql/Join/join3.sql b/test/sql/Join/join3.sql deleted file mode 100644 index d59d1adb..00000000 --- a/test/sql/Join/join3.sql +++ /dev/null @@ -1,7 +0,0 @@ -echo select * from t1,t2,t3,t4,t5; -select * from t1,t2,t3,t4,t5; - -echo select * from t1,t2 where t1.f1>100; -select * from t1,t2 where t1.f1>100; - - diff --git a/test/sql/Join/join31.sql b/test/sql/Join/join31.sql deleted file mode 100644 index 10da61ba..00000000 --- a/test/sql/Join/join31.sql +++ /dev/null @@ -1,41 +0,0 @@ -echo create table emp(eno int,mgrno int,sal float,deptno int); -create table emp(eno int,mgrno int,sal float,deptno int); -echo insert into emp values(1,3,5000,10); -insert into emp values(1,3,5000,10); -echo insert into emp values(2,4,4000,20); -insert into emp values(2,4,4000,20); -echo insert into emp values(3,NULL,8000,10); -insert into emp values(3,NULL,8000,10); -echo create table dept(deptno int,dname char(10),lid int); -create table dept(deptno int,dname char(10),lid int); -echo insert into dept values(10,'IT',100); -insert into dept values(10,'IT',100); -echo insert into dept values(20,'HR',300); -insert into dept values(20,'HR',300); -echo create table loc(lid int,state char(10)); -create table loc(lid int,state char(10)); -echo insert into loc values(100,'Orissa'); -insert into loc values(100,'Orissa'); -echo insert into loc values(200,'Cal'); -insert into loc values(200,'Cal'); -echo insert into loc values(300,'Calif'); -insert into loc values(300,'Calif'); -echo select * from emp; -select * from emp; -echo select * from dept; -select * from dept; -echo select * from loc; -select * from loc; -echo select * from emp,dept,loc; -select * from emp,dept,loc; -echo select * from emp,dept,loc where emp.deptno!=dept.deptno AND dept.lid!=loc.lid; -select * from emp,dept,loc where emp.deptno!=dept.deptno AND dept.lid!=loc.lid; -echo select * from emp,dept,loc where NOT(emp.deptno!=dept.deptno AND dept.lid!=loc.lid); -select * from emp,dept,loc where NOT(emp.deptno!=dept.deptno AND dept.lid!=loc.lid); -echo drop table emp; -drop table emp; -echo drop table dept; -drop table dept; -echo drop table loc; -drop table loc; - diff --git a/test/sql/Join/join32.sql b/test/sql/Join/join32.sql deleted file mode 100644 index 2da72cc8..00000000 --- a/test/sql/Join/join32.sql +++ /dev/null @@ -1,18 +0,0 @@ -create table emp(eno int,dno int); -insert into emp values(1,10); -insert into emp values(2,20); -insert into emp values(4,40); - -create table dept(deptno int,dname char(10)); -insert into dept values(20,'Sales'); -insert into dept values(30,'IT'); -insert into dept values(40,'Mkt'); -insert into dept values(50,'HR'); - -echo select * from emp; -select * from emp; -echo select * from dept; -select * from dept; - - - diff --git a/test/sql/Join/join33.sql b/test/sql/Join/join33.sql deleted file mode 100644 index 8b42e4fa..00000000 --- a/test/sql/Join/join33.sql +++ /dev/null @@ -1,11 +0,0 @@ -create table emp(eno int,ename char(10),dno int); -insert into emp values(1,'Nihar',10); -insert into emp values(2,'Kishore',20); -insert into emp values(3,'Jiten',30); -insert into emp values(4,'Bijay',40); -insert into emp values(5,'Kailash',50); -create table dept(deptno int,dname char(10)); -insert into dept values(20,'Sales'); -insert into dept values(40,'Mkt'); -insert into dept values(35,'HR'); - diff --git a/test/sql/Join/join34.sql b/test/sql/Join/join34.sql deleted file mode 100644 index 112da7de..00000000 --- a/test/sql/Join/join34.sql +++ /dev/null @@ -1,16 +0,0 @@ -create table emp(eno int,ename char(10),dno int); -insert into emp values(1,'Nihar',10); -insert into emp values(2,'Papu',20); -insert into emp values(3,'Sima',30); -insert into emp values(4,'Nama',40); -insert into emp values(5,'Pinu',50); -create table dept(deptno int,dname char(10),lid int); -insert into dept values(20,'IT',101); -insert into dept values(40,'Sales',102); -insert into dept values(60,'Mkt',103); -insert into dept values(30,'Store',104); -select * from emp; -select * from dept; -select * from emp,dept; - ~ - diff --git a/test/sql/Join/join4.sql b/test/sql/Join/join4.sql deleted file mode 100644 index 603f5d95..00000000 --- a/test/sql/Join/join4.sql +++ /dev/null @@ -1,7 +0,0 @@ -echo select * from t1,t2,t3 where t1.f2=t2.f2 and t1.f3=t3.f2; -select * from t1,t2,t3 where t1.f2=t2.f2 and t1.f3=t3.f2; - -echo select * from t1,t2,t3 where t1.f2=t2.f2 or t1.f3=t3.f2; -select * from t1,t2,t3 where t1.f2=t2.f2 or t1.f3=t3.f2; - - diff --git a/test/sql/Join/join5.sql b/test/sql/Join/join5.sql deleted file mode 100644 index c14a6f4f..00000000 --- a/test/sql/Join/join5.sql +++ /dev/null @@ -1,4 +0,0 @@ -echo select t1.f1,t2.f1,t3.f1 from t1,t2,t3 where t1.f2=t2.f2 or t1.f1 > 100; -select t1.f1,t2.f1,t3.f1 from t1,t2,t3 where t1.f2=t2.f2 or t1.f1 > 100; -echo select t1.f1, t2.f1, t3.f1 from t1,t2,t3 where t1.f2= t2.f2 and t1.f3 = t3.f2; -select t1.f1, t2.f1, t3.f1 from t1,t2,t3 where t1.f2= t2.f2 and t1.f3 = t3.f2; diff --git a/test/sql/Join/join6.sql b/test/sql/Join/join6.sql deleted file mode 100644 index a69384d2..00000000 --- a/test/sql/Join/join6.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo select * from t1,t2 where t1.f1=t2.f100; -select * from t1,t2 where t1.f1=t2.f100; diff --git a/test/sql/Join/join7.sql b/test/sql/Join/join7.sql deleted file mode 100644 index cfd53b80..00000000 --- a/test/sql/Join/join7.sql +++ /dev/null @@ -1,5 +0,0 @@ -echo select * from t11 where t11.f1=2; -select * from t11 where t11.f1=2; - -echo select * from t11 where t11.f1=t11.f1; -select * from t11 where t11.f1=t11.f1; diff --git a/test/sql/Join/join8.sql b/test/sql/Join/join8.sql deleted file mode 100644 index 4e56b922..00000000 --- a/test/sql/Join/join8.sql +++ /dev/null @@ -1,15 +0,0 @@ -echo select * from t11,t12 where t11.f5=t12.f1; -select * from t11,t12 where t11.f5=t12.f1; - -echo select * from t11,t12 where t11.f5 > t12.f1; -select * from t11,t12 where t11.f5 > t12.f1; - -echo select * from t11,t12 where t12.f1 <= t11.f5; -select * from t11,t12 where t12.f1 <= t11.f5; - -echo select * from t11,t12 where t12.f1 != t11.f5; -select * from t11,t12 where t12.f1 != t11.f5; - -echo select * from t11,t12 where t12.f1 > 20; -select * from t11,t12 where t12.f1 > 20; - diff --git a/test/sql/Join/join9.sql b/test/sql/Join/join9.sql deleted file mode 100644 index f79ee73f..00000000 --- a/test/sql/Join/join9.sql +++ /dev/null @@ -1,11 +0,0 @@ -echo select t11.f5, t13.f8 from t11,t13 where t11.f5=t13.f8; -select t11.f5, t13.f8 from t11,t13 where t11.f5=t13.f8; - -echo select t11.f1,t11.f5,t13.f8 from t11,t13 where t11.f5=t13.f8; -select t11.f1,t11.f5,t13.f8 from t11,t13 where t11.f5=t13.f8; - -echo select * from t11,t13 where t13.f8 > t11.f5; -select * from t11,t13 where t13.f8 > t11.f5; - -echo select t11.f1,t11.f5,t13.f8 from t11,t13 where t13.f8 < t11.f5; -select t11.f1,t11.f5,t13.f8 from t11,t13 where t13.f8 < t11.f5; diff --git a/test/sql/Join/join_between.sql b/test/sql/Join/join_between.sql deleted file mode 100644 index 980a2c26..00000000 --- a/test/sql/Join/join_between.sql +++ /dev/null @@ -1,9 +0,0 @@ -echo select * from emp,dept; -select * from emp,dept; -echo select * from emp,dept where emp.dno between 10 and 30; -select * from emp,dept where emp.dno between 10 and 30; -echo select * from emp,dept where dept.deptno between 20 and 40; -select * from emp,dept where dept.deptno between 20 and 40; -echo select * from emp,dept where emp.dno between 15 and 30 and dept.deptno between 20 and 40; -select * from emp,dept where emp.dno between 15 and 30 and dept.deptno between 20 and 40; - diff --git a/test/sql/Join/join_between_notexist.sql b/test/sql/Join/join_between_notexist.sql deleted file mode 100644 index 4328ee8e..00000000 --- a/test/sql/Join/join_between_notexist.sql +++ /dev/null @@ -1,4 +0,0 @@ -echo select * from emp where emp.deptno between 20 and 40; -select * from emp where emp.deptno between 20 and 40; -echo select * from emp,dept where emp.deptno between 20 and 40; -select * from emp,dept where emp.deptno between 20 and 40; diff --git a/test/sql/Join/join_in.sql b/test/sql/Join/join_in.sql deleted file mode 100644 index 1d743f6a..00000000 --- a/test/sql/Join/join_in.sql +++ /dev/null @@ -1,12 +0,0 @@ -echo select * from emp,dept; -select * from emp,dept; -echo select * from emp,dept where emp.dno in(20,30); -select * from emp,dept where emp.dno in(20,30); -echo select * from emp,dept where dept.deptno in(20,30); -select * from emp,dept where dept.deptno in(20,30); -echo select * from emp,dept where emp.dno in(20,30) and dept.deptno in(20,30); -select * from emp,dept where emp.dno in(20,30) and dept.deptno in(20,30); - -echo select * from emp,dept where emp.dno in(20,30) or dept.deptno in(20,30); - select * from emp,dept where emp.dno in(20,30) or dept.deptno in(20,30); - ~ diff --git a/test/sql/Join/join_in_notexist.sql b/test/sql/Join/join_in_notexist.sql deleted file mode 100644 index 327860b5..00000000 --- a/test/sql/Join/join_in_notexist.sql +++ /dev/null @@ -1,4 +0,0 @@ -echo select * from emp where emp.deptno in (20,30,40); -select * from emp where emp.deptno in (20,30,40); -echo select * from emp,dept where emp.deptno in (20,30,40); -select * from emp,dept where emp.deptno in (20,30,40); diff --git a/test/sql/Join/join_like.sql b/test/sql/Join/join_like.sql deleted file mode 100644 index 57dd365b..00000000 --- a/test/sql/Join/join_like.sql +++ /dev/null @@ -1,10 +0,0 @@ -echo select * from emp,dept; -select * from emp,dept; -echo select * from emp,dept where emp.ename LIKE 'K%'; -select * from emp,dept where emp.ename LIKE 'K%'; -echo select * from emp,dept where dept.dname LIKE 'S%'; -select * from emp,dept where dept.dname LIKE 'S%'; -echo select * from emp,dept where emp.ename LIKE 'K%' and dept.dname LIKE 'S%'; -select * from emp,dept where emp.ename LIKE 'K%' and dept.dname LIKE 'S%'; -echo select * from emp,dept where emp.ename LIKE 'K%' or dept.dname LIKE 'S%'; -select * from emp,dept where emp.ename LIKE 'K%' or dept.dname LIKE 'S%'; diff --git a/test/sql/Join/join_like_notexist1.sql b/test/sql/Join/join_like_notexist1.sql deleted file mode 100644 index 0a47f392..00000000 --- a/test/sql/Join/join_like_notexist1.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo select * from emp where emp.dname like 'S%'; -select * from emp where emp.dname like 'S%'; diff --git a/test/sql/Join/join_like_notexist2.sql b/test/sql/Join/join_like_notexist2.sql deleted file mode 100644 index d1f7c5f3..00000000 --- a/test/sql/Join/join_like_notexist2.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo select * from emp,dept where emp.dname like 'S%'; -select * from emp,dept where emp.dname like 'S%'; diff --git a/test/sql/Join/quit.sql b/test/sql/Join/quit.sql deleted file mode 100644 index 0bc271ce..00000000 --- a/test/sql/Join/quit.sql +++ /dev/null @@ -1,2 +0,0 @@ -quit; - diff --git a/test/sql/Join/tablet11.sql b/test/sql/Join/tablet11.sql deleted file mode 100644 index caee7c79..00000000 --- a/test/sql/Join/tablet11.sql +++ /dev/null @@ -1,5 +0,0 @@ - create table t11(f1 int,f2 char(20),f3 char(10),f4 int,f5 int); - insert into t11 values(1,'X','IT',5000,10); - insert into t11 values(2,'Y','sales',6000,20); - insert into t11 values(3,'Z','IT',7000,10); - commit; diff --git a/test/sql/Join/tablet11t12.sql b/test/sql/Join/tablet11t12.sql deleted file mode 100644 index 629b1293..00000000 --- a/test/sql/Join/tablet11t12.sql +++ /dev/null @@ -1,10 +0,0 @@ -create table t11(f1 int,f2 char(20),f3 char(10),f4 int,f5 int); -insert into t11 values(1,'X','IT',5000,10); -insert into t11 values(2,'Y','sales',6000,20); -insert into t11 values(3,'Z','IT',7000,10); -commit; -create table t12(f1 int,f2 char(10),f3 char(20)); -insert into t12 values(10,'IT','BBSR'); -insert into t12 values(20,'HR','CTC'); -insert into t12 values(30,'R&D','DELHI'); -commit; diff --git a/test/sql/Join/tablet11t12t13.sql b/test/sql/Join/tablet11t12t13.sql deleted file mode 100644 index 6bb06733..00000000 --- a/test/sql/Join/tablet11t12t13.sql +++ /dev/null @@ -1,15 +0,0 @@ -create table t11(f1 int,f2 char(20),f3 char(10),f4 int,f5 int); -insert into t11 values(1,'X','IT',5000,10); -insert into t11 values(2,'Y','sales',6000,20); -insert into t11 values(3,'Z','IT',7000,10); -commit; -create table t12(f1 int,f2 char(10),f3 char(20)); -insert into t12 values(10,'IT','BBSR'); -insert into t12 values(20,'HR','CTC'); -insert into t12 values(30,'R&D','DELHI'); -commit; -create table t13(f7 int,f8 int); -insert into t13 values(2,20); -insert into t13 values(1,50); -commit; - diff --git a/test/sql/Join/tablet11t13.sql b/test/sql/Join/tablet11t13.sql deleted file mode 100644 index 364d9d62..00000000 --- a/test/sql/Join/tablet11t13.sql +++ /dev/null @@ -1,9 +0,0 @@ -create table t11(f1 int,f2 char(20),f3 char(10),f4 int,f5 int); -insert into t11 values(1,'X','IT',5000,10); -insert into t11 values(2,'Y','sales',6000,20); -insert into t11 values(3,'Z','IT',7000,10); -commit; -create table t13(f7 int,f8 int); -insert into t13 values(2,20); -insert into t13 values(1,50); -commit; diff --git a/test/sql/Join/tablet12.sql b/test/sql/Join/tablet12.sql deleted file mode 100644 index ab816b1e..00000000 --- a/test/sql/Join/tablet12.sql +++ /dev/null @@ -1,6 +0,0 @@ -create table t12(f1 int,f2 char(10),f3 char(20)); -insert into t12 values(10,'IT','BBSR'); -insert into t12 values(20,'HR','CTC'); -insert into t12 values(30,'R&D','DELHI'); -commit; - diff --git a/test/sql/Join/tablet13.sql b/test/sql/Join/tablet13.sql deleted file mode 100644 index 233af0dc..00000000 --- a/test/sql/Join/tablet13.sql +++ /dev/null @@ -1,4 +0,0 @@ -create table t13(f7 int,f8 int); -insert into t13 values(2,20); -insert into t13 values(1,50); -commit; diff --git a/test/sql/Join/test001.ksh b/test/sql/Join/test001.ksh deleted file mode 100755 index 63139b1a..00000000 --- a/test/sql/Join/test001.ksh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh -# Test Case -# 1. Create t1 table with 5 records in csql database. -# select t1.f1 from t1; -# select t1.notexist from t1; -# - -# AUTHOR : Jitendra Lenka - -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then -REL_PATH=`pwd`/sql/Join -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1.sql > /dev/null 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join1.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1.sql > /dev/null 2>&1 - exit 2; -fi - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1.sql > /dev/null 2>&1 - exit 0; - diff --git a/test/sql/Join/test002.ksh b/test/sql/Join/test002.ksh deleted file mode 100755 index 589d0924..00000000 --- a/test/sql/Join/test002.ksh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh -# Test Case -# 4. Create t1 and t2 table with 5 records each in csql database. -# select t1.f1, t2.f1, t1.f2, t2.f2 from t1,t2 -# select * from t1,t2 where t1.f1 = t2.f1 and t1.f1 >100 - -# AUTHOR : Jitendra Lenka - -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1t2.sql > /dev/null 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join2.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 - exit 2; -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 - exit 0; - diff --git a/test/sql/Join/test003.ksh b/test/sql/Join/test003.ksh deleted file mode 100755 index 98381b37..00000000 --- a/test/sql/Join/test003.ksh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/sh -# Test Case -# 3. Create t1,t2,t3,t4,t5 table with in csql database. -# Select * from t1,t2,t3,t4,t5; - -# AUTHOR : Jitendra Lenka - -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1t2t3t4t5.sql > /dev/null 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join3.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2t3t4t5.sql > /dev/null 2>&1 - exit 1; -fi - - - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2t3t4t5.sql > /dev/null 2>&1 - exit 0; - diff --git a/test/sql/Join/test004.ksh b/test/sql/Join/test004.ksh deleted file mode 100755 index c279d085..00000000 --- a/test/sql/Join/test004.ksh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh -# Test Case -# 5. -# Create t1,t2,t3 table with 5 each records in csql database. -# select * from t1,t2,t3 where t1.f2= t2.f2 and t1.f3 = t3.f2 -# select * from t1,t2,t3 where t1.f2= t2.f2 or t1.f3 = t3.f2 - -# AUTHOR : Jitendra Lenka - -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] - then -REL_PATH=`pwd`/sql/Join -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1t2t3.sql > /dev/null 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join4.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2t3.sql > /dev/null 2>&1 - exit 2; -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2t3.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Join/test005.ksh b/test/sql/Join/test005.ksh deleted file mode 100755 index 234135f3..00000000 --- a/test/sql/Join/test005.ksh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh -# Test Case -# 5. -# Create t1,t2,t3 table with 5 each records in csql database. -# select t1.f1, t2.f1, t3.f1 from t1,t2,t3 where t1.f2= t2.f2 or t1.f1 >100 - -# AUTHOR : Jitendra Lenka - -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1t2t3.sql > /dev/null 2>&1 -if [ $? -ne 0 ] - then - exit 1; - fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join5.sql - if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2t3.sql > /dev/null 2>&1 - exit 1; - fi - - - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2t3.sql > /dev/null 2>&1 - exit 0; - diff --git a/test/sql/Join/test006.ksh b/test/sql/Join/test006.ksh deleted file mode 100755 index 003b6cc2..00000000 --- a/test/sql/Join/test006.ksh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh -# Test Case -# 6. Create t1,t2 table with 5 each records in csql database. -# select * from t1,t2 where t1.f1 = t2.notexist - -# AUTHOR : Jitendra Lenka - -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/createt1t2.sql > /dev/null 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join6.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt1t2.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Join/test007.ksh b/test/sql/Join/test007.ksh deleted file mode 100755 index 513ce94d..00000000 --- a/test/sql/Join/test007.ksh +++ /dev/null @@ -1,37 +0,0 @@ -#!/bin/sh -# Test Case -# 10. Create t1 table with 5 fields, and insert 3 records in it. - -# (a)select * from t11 where t1.f1=2; -# (b) select * from t11 where t1.f1=t1.f1; - -# AUTHOR : Jitendra Lenka - -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/tablet11.sql > /dev/null 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join7.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/drot11.sql > /dev/null 2>&1 - exit 2; -fi - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt11.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Join/test008.ksh b/test/sql/Join/test008.ksh deleted file mode 100755 index 66a35283..00000000 --- a/test/sql/Join/test008.ksh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -# Test Case -# 11. Create emp table with 5 fields & dept table with 3 fields and insert 3 records in it. - -# (a)select * from t11,t12 where t11.f5=t12.f1; -# (b)select * from t11,t12 where t11.f5 > t12.f1; -# (c) select * from t11,t12 where t12.f1 <= t11.f5; -# (d)select * from t11,t12 where t12.f1 != t11.f5; -# (e)select * from t11,t12 where t12.f1 > 20; - -# AUTHOR : Jitendra Lenka - -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/tablet11t12.sql > /dev/null 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join8.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt11t12.sql > /dev/null 2>&1 - exit 2; -fi - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt11t12.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Join/test009.ksh b/test/sql/Join/test009.ksh deleted file mode 100755 index c975c5bd..00000000 --- a/test/sql/Join/test009.ksh +++ /dev/null @@ -1,41 +0,0 @@ -#!/bin/sh -# Test Case -# 11. Create emp table with 5 fields & dept table with 3 fields and insert 3 records in it. - -# (a)select t11.f1,t11.f2,t13.f7,t13.f8 from t11,t13 where t11.f5=t13.f8; -# (b)select f1,f3,f7,f8 from t11,t13 where t11.f5=t13.f8; -# (c)select t11.f1,t11.f2,t12.f1,t12.f2 from t11,t12,t13 where t13.f8 > t11.f5; -# (d)select f1,f3,f7,f8 from t11,t13 where t13.f8 < t11.f5; -# (e)select f1,f3,f7,f8 from t11,t13 where f5 > f8; - -# AUTHOR : Jitendra Lenka - -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/tablet11t13.sql > /dev/null 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join9.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt11t13.sql > /dev/null 2>&1 - exit 2; -fi - - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt11t13.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Join/test010.ksh b/test/sql/Join/test010.ksh deleted file mode 100755 index bb09b0ca..00000000 --- a/test/sql/Join/test010.ksh +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/sh -# Test Case -# 10. Create emp table with 5 fields, and insert 3 records in it. - -# (a)select * from t11,t12,t13 where t12.f1=t13.f8 and t13.f7=t11.f1; -# (b)select * from t11,t12,t13 where t12.f1=t13.f8 or t13.f7=t11.f1; - -# AUTHOR : Jitendra Lenka - -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/tablet11t12t13.sql > /dev/null 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt11t12t13.sql > /dev/null 2>&1 - exit 2; -fi - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt11t12t13.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Join/test011.ksh b/test/sql/Join/test011.ksh deleted file mode 100755 index 743e0989..00000000 --- a/test/sql/Join/test011.ksh +++ /dev/null @@ -1,37 +0,0 @@ -#!/bin/sh -# Test Case -# 10. Create emp table with 5 fields, and insert 3 records in it. - -# (a)select f1,f7 from t12,t11; -# (b)select t11.f1,t12.f7 from t13,t11; - -# AUTHOR : Jitendra Lenka - -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/tablet11t12t13.sql > /dev/null 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join11.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt11t12t13.sql > /dev/null 2>&1 - exit 2; -fi - - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/dropt11t12t13.sql > /dev/null 2>&1 -exit 0; - diff --git a/test/sql/Join/test012.ksh b/test/sql/Join/test012.ksh deleted file mode 100755 index 14d6411a..00000000 --- a/test/sql/Join/test012.ksh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -# Test Case -#create three tables as: -#create table emp(eno int,mgrno int,sal float,deptno int); -#create table dept(deptno int,dname char(10),lid int); -#create table loc(lid int,state char(10)); -#Insert valid records into the 3 tables. Insert NULL values in some of the field. -#select * from emp,dept,loc where emp.deptno!=dept.deptno AND dept.lid!=loc.lid; -#select * from emp,dept,loc where NOT(emp.deptno!=dept.deptno AND dept.lid!=loc.lid); -# -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join31.sql -if [ $? -ne 0 ] -then - exit 1; -fi diff --git a/test/sql/Join/test013.ksh b/test/sql/Join/test013.ksh deleted file mode 100755 index 10800a37..00000000 --- a/test/sql/Join/test013.ksh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh -#Testing IN operator in Join -#create table emp(eno int,dno int); -#create table dept(deptno int,dname char(10)); -#insert some records into both the tables. -#Test the following Select statements using join and in operator and check the retrieved data are proper or not -#select * from emp,dept where emp.dno in(20,30); -#select * from emp,dept where dept.deptno in(20,30); -#select * from emp,dept where emp.dno in(20,30) and dept.deptno in(20,30); -#select * from emp,dept where emp.dno in(20,30) or dept.deptno in(20,30);(sql/Join/test016.ksh) -# -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join32.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join_in.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/drop_emp_dept.sql -if [ $? -ne 0 ] -then - exit 1; -fi diff --git a/test/sql/Join/test014.ksh b/test/sql/Join/test014.ksh deleted file mode 100755 index eaa65460..00000000 --- a/test/sql/Join/test014.ksh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh -#Testing BETWEEN operator in Join -#create table emp(eno int,dno int); -#create table dept(deptno int,dname char(10)); -#insert some records into both the tables. -#Test the following Select statements using join and BETWEEN operator and check the retrieved data are proper or not -#select * from emp,dept where emp.dno between 10 and 30; -#select * from emp,dept where dept.deptno between 20 and 40; -#select * from emp,dept where emp.dno between 15 and 30 and dept.deptno between 20 and 40; -#select * from emp,dept where emp.dno between 15 and 30 or dept.deptno between 20 and 40; -# -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join32.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join_between.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/drop_emp_dept.sql -if [ $? -ne 0 ] -then - exit 1; -fi diff --git a/test/sql/Join/test015.ksh b/test/sql/Join/test015.ksh deleted file mode 100755 index e07e686b..00000000 --- a/test/sql/Join/test015.ksh +++ /dev/null @@ -1,33 +0,0 @@ -#!/bin/sh -#Testing LIKE operator in Join -#create table emp(eno int,ename char(10),dno int); -#create table dept(deptno int,dname char(10)); -#insert some records into both the tables. -#Test the following Select statements using join and BETWEEN operator and check the retrieved data are proper or not -#select * from emp,dept where emp.ename LIKE 'K%'; -#select * from emp,dept where dept.dname LIKE 'S%'; -#select * from emp,dept where emp.ename LIKE 'K%' and dept.dname LIKE 'S%'; -#select * from emp,dept where emp.ename LIKE 'K%' or dept.dname LIKE 'S%'; -# -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join33.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join_like.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/drop_emp_dept.sql -if [ $? -ne 0 ] -then - exit 1; -fi diff --git a/test/sql/Join/test016.ksh b/test/sql/Join/test016.ksh deleted file mode 100755 index 504a1742..00000000 --- a/test/sql/Join/test016.ksh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/sh - -# -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join34.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join_in_notexist.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/drop_emp_dept.sql -if [ $? -ne 0 ] -then - exit 1; -fi diff --git a/test/sql/Join/test017.ksh b/test/sql/Join/test017.ksh deleted file mode 100755 index c0de0fb3..00000000 --- a/test/sql/Join/test017.ksh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/sh - -# -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join34.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join_between_notexist.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/drop_emp_dept.sql -if [ $? -ne 0 ] -then - exit 1; -fi diff --git a/test/sql/Join/test018.ksh b/test/sql/Join/test018.ksh deleted file mode 100755 index 96657c4c..00000000 --- a/test/sql/Join/test018.ksh +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh - -# -QUITFILE=${PWD}/sql/Join/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/sql/Join -fi - -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join34.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join_like_notexist1.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/drop_emp_dept.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/join_like_notexist2.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/drop_emp_dept.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -s $REL_PATH/drop_emp_dept.sql -if [ $? -ne 0 ] -then - exit 1; -fi diff --git a/test/sqlapi/Connect/Makefile b/test/sqlapi/Connect/Makefile deleted file mode 100644 index 57d01215..00000000 --- a/test/sqlapi/Connect/Makefile +++ /dev/null @@ -1,87 +0,0 @@ -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -g -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/install/include -I../../../include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlsql -lcsql -lcsqlsqllog -lcsqlnw -lcsqlsqlnw - -TARGETS = \ - test001 test001n\ - test002 test002n\ - test003 test003n\ - test004 test004n\ - test005 test005n\ - test006 test006n\ - test007 test007n\ - test008 test008n\ - test009 test009n\ - test010 test010n\ - test011 test011n - - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -test001:conntest1.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test001n:conntest1.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test002:conntest2.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test002n:conntest2.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test003:conntest3.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test003n:conntest3.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test004:conntest4.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test004n:conntest4.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test005:conntest5.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test005n:conntest5.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test006:conntest6.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test006n:conntest6.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test007:conntest7.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test007n:conntest7.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test008:conntest8.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test008n:conntest8.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test009:conntest9.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test009n:conntest9.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test010:conntest10.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test010n:conntest10.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test011:conntest11.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test011n:conntest11.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) - -clean: - rm -f ${TARGETS} diff --git a/test/sqlapi/Connect/common.h b/test/sqlapi/Connect/common.h deleted file mode 100644 index f1ab199a..00000000 --- a/test/sqlapi/Connect/common.h +++ /dev/null @@ -1,37 +0,0 @@ -#include -#include -#include - -AbsSqlConnection *createConnection() -{ -#ifdef NETWORK - AbsSqlConnection *con = SqlFactory::createConnection(CSqlNetwork); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); -#elif defined NETWORKADAPTER - AbsSqlConnection *con = SqlFactory::createConnection(CSqlNetworkAdapter); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); -#elif defined NETWORKGATEWAY - AbsSqlConnection *con = SqlFactory::createConnection(CSqlNetworkGateway); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); -#else - AbsSqlConnection *con = SqlFactory::createConnection(CSql); -#endif - return con; -} - -AbsSqlStatement *createStatement() -{ -#ifdef NETWORK - AbsSqlStatement *stmt = SqlFactory::createStatement(CSqlNetwork); -#elif defined NETWORKADAPTER - AbsSqlStatement *stmt = SqlFactory::createStatement(CSqlNetworkAdapter); -#elif defined NETWORKGATEWAY - AbsSqlStatement *stmt = SqlFactory::createStatement(CSqlNetworkGateway); -#else - AbsSqlStatement *stmt = SqlFactory::createStatement(CSql); -#endif - return stmt; -} diff --git a/test/sqlapi/Connect/conntest1.c b/test/sqlapi/Connect/conntest1.c deleted file mode 100644 index 41e421fa..00000000 --- a/test/sqlapi/Connect/conntest1.c +++ /dev/null @@ -1,26 +0,0 @@ -/* connect ,disconnect and again connect ,it should pass. - - * AUTHOR : Jitendra Lenka - */ - -#include "common.h" - -int main() -{ - DbRetVal rv =OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - printf("Connection opened\n"); - delete con; - con = createConnection(); - rv = con->connect("root","manager"); - if(rv !=OK) { - printf("Test script failed \n"); - return 2; - } - printf("Connection closed\n"); - printf("Test script passed\n"); - delete con; - return 0; -} diff --git a/test/sqlapi/Connect/conntest10.c b/test/sqlapi/Connect/conntest10.c deleted file mode 100644 index 79156648..00000000 --- a/test/sqlapi/Connect/conntest10.c +++ /dev/null @@ -1,72 +0,0 @@ -/* create table T1 ,ISERT ,UPDATE AND COMMIT. - * FETCH UPDATED RECORDS. - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 INT);"); - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - stmt->free(); - printf("Table T1 CREATED\n"); - // insert into statement - strcpy(statement,"INSERT INTO T1 VALUES(1,1);"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - rv = con->beginTrans(); - if(rv!=OK) { delete stmt; delete con; return 5; } - rv = stmt->execute(rows); if(rv!=OK) return 6; - stmt->free(); - printf("One record inserted\n"); - // update statement - printf("update T1 set F2=100\n"); - strcpy(statement,"UPDATE T1 SET F2=100;"); - rv = stmt->prepare(statement); - if(rv !=OK) { delete stmt; delete con; return 7; } - rv = stmt->execute(rows); - if(rv!=OK){ printf ("Hello\n"); return 8; } - rv = con->commit(); if(rv!=OK)return 9; - printf("One row updated\n"); - strcpy(statement,"SELECT F2 FROM T1 ;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 10; } - int id=10; - stmt->bindField(1,&id); - rv = con->beginTrans(); - if(rv!=OK)return 11; - stmt->execute(rows); - int count=0; - while(stmt->fetch()!=NULL) { - printf("F2= %d\n",id); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv!=OK)return 12; - printf("Total record fetched=%d\n",count); - stmt->free(); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 13; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 14; } - printf("TABLE T1 DROPPED SUCCESSFULLY\n"); - stmt->free(); delete stmt; delete con; - printf("Connection closed successfully\n"); - return 0; -} diff --git a/test/sqlapi/Connect/conntest11.c b/test/sqlapi/Connect/conntest11.c deleted file mode 100644 index 08fa36dc..00000000 --- a/test/sqlapi/Connect/conntest11.c +++ /dev/null @@ -1,72 +0,0 @@ -/* create table T1 , insert and update - * then rollback, - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 INT);"); - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - stmt->free(); - printf("Table T1 CREATED\n"); - strcpy(statement,"INSERT INTO T1 VALUES(1,1);"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 3; } - rv = con->beginTrans(); - if(rv!=OK) { delete stmt; delete con; return 4; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 5; } - printf("1 Record inserted\n"); - stmt->free(); - strcpy(statement,"UPDATE T1 SET F2=100;"); - rv = stmt->prepare(statement); - if(rv !=OK) { delete stmt; delete con; return 6; } - rv = stmt->execute(rows); - if(rv!=OK && rows !=1)return 7; - printf("1 Record updated\n"); - // ROLLBACK - rv = con->rollback(); - if(rv!=OK)return 8; - stmt->free(); - strcpy(statement,"SELECT F2 FROM T1 ;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 9; } - int id=10; - stmt->bindField(1,&id); - rv = con->beginTrans(); - if(rv!=OK)return 1; - stmt->execute(rows); - int count=0; - while(stmt->fetch()!=NULL) { - printf("F2= %d\n",id); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv!=OK)return 10; - printf("Total record fetched =%d ,Because transaction rollbacked\n",count); - stmt->free(); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 11; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 12; } - printf("Table droped\n"); - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Connect/conntest2.c b/test/sqlapi/Connect/conntest2.c deleted file mode 100644 index 00ee48c1..00000000 --- a/test/sqlapi/Connect/conntest2.c +++ /dev/null @@ -1,28 +0,0 @@ -/* close the connection and call commit, it should fail - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - printf("Connection opened\n"); - rv = con->beginTrans(); - if(rv!=OK)return 2; - rv = con->disconnect(); - if(rv !=OK)return 3;printf("Connection closed\n"); - rv = con->commit(); - if(rv==OK) { - printf("Test script failed\n"); - return 4; - } - printf("After closing the connection, commit failed\n"); - printf("Test script pased\n"); - delete con; - return 0; -} diff --git a/test/sqlapi/Connect/conntest3.c b/test/sqlapi/Connect/conntest3.c deleted file mode 100644 index 4765bce3..00000000 --- a/test/sqlapi/Connect/conntest3.c +++ /dev/null @@ -1,32 +0,0 @@ -/* close the connection and call prepare ,it should fail - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT);"); - int rows; - rv = con->disconnect(); - if(rv!=OK)return 2; - printf("Connection closed\n"); - rv = stmt->prepare(statement); - if(rv==OK) { - delete stmt; delete con; - printf("Test script failed\n"); - return 3; - } - printf("Test script passed\n"); - delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Connect/conntest4.c b/test/sqlapi/Connect/conntest4.c deleted file mode 100644 index ff7e90e0..00000000 --- a/test/sqlapi/Connect/conntest4.c +++ /dev/null @@ -1,34 +0,0 @@ -// close the connection and call execute,it should fail. - -// Author : Jitendra Lenka - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20)); "); - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - printf("prepared successfully\n"); - rv = con->disconnect(); - if(rv!=OK)return 3; - printf("Disconnect successfully\n"); - rv = stmt->execute(rows); - if(rv == OK) { - printf("Test script failed \n"); - delete stmt; return 4; - } - stmt->free(); - printf("Test script passed\n"); - delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Connect/conntest5.c b/test/sqlapi/Connect/conntest5.c deleted file mode 100644 index 3bddc030..00000000 --- a/test/sqlapi/Connect/conntest5.c +++ /dev/null @@ -1,67 +0,0 @@ -/* create table T1 ,Insert some records in it. - * Close the connection, Fetch should fail. - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 INT);"); - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - stmt->free(); - printf("Table T1 CREATED\n"); - // insert into statement - strcpy(statement,"INSERT INTO T1 VALUES(1,1);"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - rv = con->beginTrans(); - if(rv!=OK) { delete stmt; delete con; return 5; } - rv = stmt->execute(rows); if(rv!=OK) return 6; - rv = con->commit(); - if(rv!=OK) return 7; - stmt->free(); - printf("One record inserted\n"); - strcpy(statement,"SELECT F2 FROM T1 ;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 10; } - int id=10; - stmt->bindField(1,&id); - rv = con->beginTrans(); - if(rv!=OK)return 11; - stmt->execute(rows); - int count=0; - stmt->close(); stmt->free(); - rv = con->disconnect(); //close the connection - void *rettype; - if(rv!=OK)return 8; - rettype = (char*)stmt->fetch(); - if(rettype==NULL && rv == OK) { - printf("After closing the connection,fetch failed\n"); - con->connect("root", "manager"); - stmt->setConnection(con); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - rv = stmt->execute(rows); - if(rv==OK) { printf("Table Dropped successfully\n"); } - stmt->free(); delete stmt; delete con; - printf("Test script passed\n"); - return 0; - } - printf("Test script Failed\n"); - delete stmt; delete con; - return 7; -} diff --git a/test/sqlapi/Connect/conntest6.c b/test/sqlapi/Connect/conntest6.c deleted file mode 100644 index 4b032cdf..00000000 --- a/test/sqlapi/Connect/conntest6.c +++ /dev/null @@ -1,24 +0,0 @@ -/* connect twice without closing the connection, - * second conection should return "user already logged in". - - * Author : Jitendra lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - rv = con->connect("root","manager"); - if(rv==OK) { - printf("testscript failed\n"); - return 1; - } - printf("Test script passed\n"); - delete con; - return 0; -} diff --git a/test/sqlapi/Connect/conntest7.c b/test/sqlapi/Connect/conntest7.c deleted file mode 100644 index e5af0723..00000000 --- a/test/sqlapi/Connect/conntest7.c +++ /dev/null @@ -1,20 +0,0 @@ -// Pass correct user name and password ,it should pass. - -// Author : Jitendra Lenkla - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK) { - printf("Test script failed with error%d\n",rv); - return 1; - } - printf("Connection opened with correct user name and password\n"); - printf("Test script passed\n"); - delete con; - return 0; -} diff --git a/test/sqlapi/Connect/conntest8.c b/test/sqlapi/Connect/conntest8.c deleted file mode 100644 index fe111c49..00000000 --- a/test/sqlapi/Connect/conntest8.c +++ /dev/null @@ -1,20 +0,0 @@ -// Pass incorrect user name and password ,it should fail. - -// Author : Jitendra Lenkla - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root123","manager123"); - if(rv==OK) { - printf("Test script failed with error%d\n",rv); - return 1; - } - printf("Connection failed dueto incorrect user anme and password\n"); - printf("Test script passed\n"); - delete con; - return 0; -} diff --git a/test/sqlapi/Connect/conntest9.c b/test/sqlapi/Connect/conntest9.c deleted file mode 100644 index 73e9545a..00000000 --- a/test/sqlapi/Connect/conntest9.c +++ /dev/null @@ -1,20 +0,0 @@ -// Pass correct username and incorrect password ,it should fail. - -// Author : Jitendra Lenkla - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager123"); - if(rv==OK) { - printf("Test script failed with error%d\n",rv); - return 1; - } - printf("Connection is not opened dueto Incorrect password\n"); - printf("Test script passed\n"); - delete con; - return 0; -} diff --git a/test/sqlapi/Connect/exp.test010 b/test/sqlapi/Connect/exp.test010 deleted file mode 100644 index abd54008..00000000 --- a/test/sqlapi/Connect/exp.test010 +++ /dev/null @@ -1,9 +0,0 @@ -Connection opened -Table T1 CREATED -One record inserted -update T1 set F2=100 -One row updated -F2= 100 -Total record fetched=1 -TABLE T1 DROPPED SUCCESSFULLY -Connection closed successfully diff --git a/test/sqlapi/Connect/exp.test010n b/test/sqlapi/Connect/exp.test010n deleted file mode 100644 index abd54008..00000000 --- a/test/sqlapi/Connect/exp.test010n +++ /dev/null @@ -1,9 +0,0 @@ -Connection opened -Table T1 CREATED -One record inserted -update T1 set F2=100 -One row updated -F2= 100 -Total record fetched=1 -TABLE T1 DROPPED SUCCESSFULLY -Connection closed successfully diff --git a/test/sqlapi/Connect/exp.test011 b/test/sqlapi/Connect/exp.test011 deleted file mode 100644 index eac77069..00000000 --- a/test/sqlapi/Connect/exp.test011 +++ /dev/null @@ -1,6 +0,0 @@ -Connection opened -Table T1 CREATED -1 Record inserted -1 Record updated -Total record fetched =0 ,Because transaction rollbacked -Table droped diff --git a/test/sqlapi/Connect/exp.test011n b/test/sqlapi/Connect/exp.test011n deleted file mode 100644 index eac77069..00000000 --- a/test/sqlapi/Connect/exp.test011n +++ /dev/null @@ -1,6 +0,0 @@ -Connection opened -Table T1 CREATED -1 Record inserted -1 Record updated -Total record fetched =0 ,Because transaction rollbacked -Table droped diff --git a/test/sqlapi/Makefile b/test/sqlapi/Makefile deleted file mode 100644 index 88876187..00000000 --- a/test/sqlapi/Makefile +++ /dev/null @@ -1,35 +0,0 @@ -OSNAME = $(shell uname -s) -MAKE=make - -ifeq ($(OSNAME), SunOS) -PlatForm=supported -else -ifeq ($(OSNAME), Linux) -PlatForm=supported -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - - -ifeq ($(PlatForm), supported) -all: buildall -endif - -buildall: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE); cd ..;\ - fi;\ - done - -clean: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE) clean; cd ..;\ - fi;\ - done diff --git a/test/sqlapi/Parameter/Makefile b/test/sqlapi/Parameter/Makefile deleted file mode 100644 index 9d5bbe2e..00000000 --- a/test/sqlapi/Parameter/Makefile +++ /dev/null @@ -1,56 +0,0 @@ -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -g -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/install/include -I../../../include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlsql -lcsql -lcsqlsqllog -lcsqlnw -lcsqlsqlnw - -TARGETS = \ - test001 test001n\ - test002 test002n\ - test003 test003n\ - test004 test004n\ - test100 test100n - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -test001: paratest1.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test001n: paratest1.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test002:paratest2.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test002n: paratest2.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test003:paratest3.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test003n: paratest3.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test004:paratest4.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test004n: paratest4.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test100:paratest100.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test100n: paratest100.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) - -clean: - rm -f *.o ${TARGETS} diff --git a/test/sqlapi/Parameter/common.h b/test/sqlapi/Parameter/common.h deleted file mode 100644 index f1ab199a..00000000 --- a/test/sqlapi/Parameter/common.h +++ /dev/null @@ -1,37 +0,0 @@ -#include -#include -#include - -AbsSqlConnection *createConnection() -{ -#ifdef NETWORK - AbsSqlConnection *con = SqlFactory::createConnection(CSqlNetwork); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); -#elif defined NETWORKADAPTER - AbsSqlConnection *con = SqlFactory::createConnection(CSqlNetworkAdapter); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); -#elif defined NETWORKGATEWAY - AbsSqlConnection *con = SqlFactory::createConnection(CSqlNetworkGateway); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); -#else - AbsSqlConnection *con = SqlFactory::createConnection(CSql); -#endif - return con; -} - -AbsSqlStatement *createStatement() -{ -#ifdef NETWORK - AbsSqlStatement *stmt = SqlFactory::createStatement(CSqlNetwork); -#elif defined NETWORKADAPTER - AbsSqlStatement *stmt = SqlFactory::createStatement(CSqlNetworkAdapter); -#elif defined NETWORKGATEWAY - AbsSqlStatement *stmt = SqlFactory::createStatement(CSqlNetworkGateway); -#else - AbsSqlStatement *stmt = SqlFactory::createStatement(CSql); -#endif - return stmt; -} diff --git a/test/sqlapi/Parameter/exp.test001 b/test/sqlapi/Parameter/exp.test001 deleted file mode 100644 index 8b968347..00000000 --- a/test/sqlapi/Parameter/exp.test001 +++ /dev/null @@ -1,146 +0,0 @@ -Table created -noOfParamField Returns=11 - -*********************************************** -1 FIELD INFORMATION :: -Field Name :F1 -Data type of the field :0 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -2 FIELD INFORMATION :: -Field Name :F2 -Data type of the field :3 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -3 FIELD INFORMATION :: -Field Name :F3 -Data type of the field :30 -length of the field :32 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -4 FIELD INFORMATION :: -Field Name :F4 -Data type of the field :11 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -5 FIELD INFORMATION :: -Field Name :F5 -Data type of the field :11 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -6 FIELD INFORMATION :: -Field Name :F6 -Data type of the field :20 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -7 FIELD INFORMATION :: -Field Name :F7 -Data type of the field :21 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -8 FIELD INFORMATION :: -Field Name :F8 -Data type of the field :22 -length of the field :8 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -9 FIELD INFORMATION :: -Field Name :F9 -Data type of the field :0 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -10 FIELD INFORMATION :: -Field Name :F10 -Data type of the field :2 -length of the field :8 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -11 FIELD INFORMATION :: -Field Name :F11 -Data type of the field :31 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** -Total rows inserted 10 -F1=0 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=1 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=2 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=3 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=4 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=5 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=6 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=7 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=8 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=9 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -Total row fetched=10 -Table dropped diff --git a/test/sqlapi/Parameter/exp.test001n b/test/sqlapi/Parameter/exp.test001n deleted file mode 100644 index 8b968347..00000000 --- a/test/sqlapi/Parameter/exp.test001n +++ /dev/null @@ -1,146 +0,0 @@ -Table created -noOfParamField Returns=11 - -*********************************************** -1 FIELD INFORMATION :: -Field Name :F1 -Data type of the field :0 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -2 FIELD INFORMATION :: -Field Name :F2 -Data type of the field :3 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -3 FIELD INFORMATION :: -Field Name :F3 -Data type of the field :30 -length of the field :32 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -4 FIELD INFORMATION :: -Field Name :F4 -Data type of the field :11 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -5 FIELD INFORMATION :: -Field Name :F5 -Data type of the field :11 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -6 FIELD INFORMATION :: -Field Name :F6 -Data type of the field :20 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -7 FIELD INFORMATION :: -Field Name :F7 -Data type of the field :21 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -8 FIELD INFORMATION :: -Field Name :F8 -Data type of the field :22 -length of the field :8 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -9 FIELD INFORMATION :: -Field Name :F9 -Data type of the field :0 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -10 FIELD INFORMATION :: -Field Name :F10 -Data type of the field :2 -length of the field :8 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -11 FIELD INFORMATION :: -Field Name :F11 -Data type of the field :31 -length of the field :4 -Offset :0 -Default value : -Null field :0 -Default value :0 -*********************************************** -Total rows inserted 10 -F1=0 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=1 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=2 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=3 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=4 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=5 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=6 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=7 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=8 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -F1=9 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 - | 23FE -Total row fetched=10 -Table dropped diff --git a/test/sqlapi/Parameter/exp.test002 b/test/sqlapi/Parameter/exp.test002 deleted file mode 100644 index ab9f2412..00000000 --- a/test/sqlapi/Parameter/exp.test002 +++ /dev/null @@ -1,14 +0,0 @@ -Table created -Total rows inserted 10 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -10 Tuples fetched -Table dropped diff --git a/test/sqlapi/Parameter/exp.test002n b/test/sqlapi/Parameter/exp.test002n deleted file mode 100644 index ab9f2412..00000000 --- a/test/sqlapi/Parameter/exp.test002n +++ /dev/null @@ -1,14 +0,0 @@ -Table created -Total rows inserted 10 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -10 Tuples fetched -Table dropped diff --git a/test/sqlapi/Parameter/exp.test003 b/test/sqlapi/Parameter/exp.test003 deleted file mode 100644 index eca8b51d..00000000 --- a/test/sqlapi/Parameter/exp.test003 +++ /dev/null @@ -1,10 +0,0 @@ -Table T1 created -Total rows inserted 10 -Total row deleted=5 -F1=0 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=1 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=2 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=3 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=4 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -Total row fetched=5 -Table dropped diff --git a/test/sqlapi/Parameter/exp.test003n b/test/sqlapi/Parameter/exp.test003n deleted file mode 100644 index eca8b51d..00000000 --- a/test/sqlapi/Parameter/exp.test003n +++ /dev/null @@ -1,10 +0,0 @@ -Table T1 created -Total rows inserted 10 -Total row deleted=5 -F1=0 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=1 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=2 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=3 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=4 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -Total row fetched=5 -Table dropped diff --git a/test/sqlapi/Parameter/exp.test004 b/test/sqlapi/Parameter/exp.test004 deleted file mode 100644 index e559a56e..00000000 --- a/test/sqlapi/Parameter/exp.test004 +++ /dev/null @@ -1,17 +0,0 @@ -Table created -10 Rows inserted -noOfParamFields return=8 -5 Rows updated -F1=0 | F2=11 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB12 -F1=1 | F2=12 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB12 -F1=2 | F2=13 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB12 -F1=3 | F2=14 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB12 -F1=4 | F2=15 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB12 - -F1=5 | F2=16 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=6 | F2=17 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=7 | F2=18 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=8 | F2=19 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=9 | F2=20 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -10 Rows fetched=4 -Table dropped diff --git a/test/sqlapi/Parameter/exp.test004n b/test/sqlapi/Parameter/exp.test004n deleted file mode 100644 index e559a56e..00000000 --- a/test/sqlapi/Parameter/exp.test004n +++ /dev/null @@ -1,17 +0,0 @@ -Table created -10 Rows inserted -noOfParamFields return=8 -5 Rows updated -F1=0 | F2=11 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB12 -F1=1 | F2=12 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB12 -F1=2 | F2=13 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB12 -F1=3 | F2=14 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB12 -F1=4 | F2=15 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB12 - -F1=5 | F2=16 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=6 | F2=17 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=7 | F2=18 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=8 | F2=19 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=9 | F2=20 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -10 Rows fetched=4 -Table dropped diff --git a/test/sqlapi/Parameter/paratest1.c b/test/sqlapi/Parameter/paratest1.c deleted file mode 100644 index 5ec0aa99..00000000 --- a/test/sqlapi/Parameter/paratest1.c +++ /dev/null @@ -1,141 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * noOfParamFields() should return 10. - * getParamFldInfo() for all fields and print the field info. - * select * from T1; - - * Author : Jitendra Lenka. - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con= createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT, F11 BINARY(4));"); - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - stmt->free(); - printf("Table created\n"); - // insert into table - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?,?);"); - int f1var = 100; - short int f2var = 10; - char f3var[32]="jitendra"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2007,01,21); - Time f7var; - f7var.set(12,29,30); - TimeStamp f8var; - f8var.setDate(2007,01,21); - f8var.setTime(12,29,30); - int f9var = 20; - long long f10var = 12000; - char f11var[8]="23fe"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } -//**************************************************************************** - int nop; - nop = stmt->noOfParamFields(); - printf("noOfParamField Returns=%d\n",nop); - //getParamFldInfo() - FieldInfo *field = new FieldInfo(); - char fldName[20]; - DataType type; - size_t length; - int offset; - char defaultValueBuf[10]; - bool isNull; - bool isDefault; - for(int i=1;i<=11;i++) { - printf("\n***********************************************\n"); - printf("%d FIELD INFORMATION ::\n",i);; - rv = stmt->getParamFldInfo(i,field); - if(rv!=OK) { delete stmt; delete con; return 1; } - printf("Field Name :%s\n", field->fldName); - printf("Data type of the field :%d\n",field->type); - printf("length of the field :%d\n",field->length); - printf("Offset :%d\n",field->offset); - printf("Default value :%s\n",field->defaultValueBuf); - printf("Null field :%d\n",field->isNull); - printf("Default value :%d\n",field->isDefault); - printf("***********************************************\n"); - } - delete field; - int count=0; - for(int i=0;i<10;i++) { - rv = con->beginTrans(); - if (rv!=OK) break; - f1var=i; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - stmt->setBinaryParam(11,f11var, 4); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("Total rows inserted %d\n",count); - stmt->free(); - //********************************************************** - // SELECT * FROM T1; - strcpy(statement,"SELECT * FROM T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 5; } - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - stmt->bindField(11,f11var); - count=0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch() !=NULL) { - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld \n",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - printf(" | "); - AllDataType::printVal(f11var,typeBinary,4); - printf("\n"); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv !=OK) { delete stmt; delete con; return 7; } - printf("Total row fetched=%d\n",count); - stmt->free(); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 8; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 9; } - printf("Table dropped\n"); - stmt->free(); - delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Parameter/paratest100.c b/test/sqlapi/Parameter/paratest100.c deleted file mode 100644 index 7a76602a..00000000 --- a/test/sqlapi/Parameter/paratest100.c +++ /dev/null @@ -1,157 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * update T1 WITH ALL 7 PARAMETERS. - noOfParamFields() should return 7. - * select * from T1; - - * Author : Jitendra Lenka. - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con= createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT);"); - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 1; } - stmt->free(); - printf("Table created\n"); - // insert into table - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?);"); - int f1var = 0; - short int f2var = 10; - char f3var[32]="jitendra"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2008,01,21); - Time f7var; - f7var.set(12,29,30); - TimeStamp f8var; - f8var.setDate(2008,01,21); - f8var.setTime(12,29,30); - int f9var = 20; - long long f10var = 12000; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - int count=0; - for(int i=0;i<10;i++) { - rv = con->beginTrans(); - if(rv!=OK) break; - f1var=i; - f2var++; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d Rows inserted \n",count); - stmt->free(); - //********************************************************** - // UPDATE TABLE - strcpy(statement,"UPDATE T1 SET F10=?,F8=?,F6=?,F5=?,F4=?,F3=? WHERE F2=?;"); - rv = stmt->prepare(statement); - int nop; - nop = stmt->noOfParamFields(); - printf("noOfParamFields return=%d\n",nop); - if(nop!=7)return 1; - /*stmt->bindField(1,&f10var); - stmt->bindField(2,&f8var); - stmt->bindField(3,&f6var); - stmt->bindField(4,&f5var); - stmt->bindField(5,&f4var); - stmt->bindField(6,f3var); - stmt->bindField(7,&f2var);*/ - long long f10var1=15000; - TimeStamp f8var1; - f8var1.setDate(2007,3,30); - f8var1.setTime(10,25,55); - Date f6var1; - f6var1.set(2007,3,30); - float f5var1=20.25; - float f4var1=11.22; - char f3var1[10]="lakshya"; - short int f2var1=10; - count=0; - for(int i=0;i<5;i++) { - f2var1++; - f5var1++; - f4var1++; - rv = con->beginTrans(); - if(rv!=OK)break; - // f2var1++; - stmt->setShortParam(7,f2var1); - stmt->setLongLongParam(1,f10var1); - stmt->setTimeStampParam(2,f8var1); - stmt->setDateParam(3,f6var1); - stmt->setFloatParam(4,f5var1); - stmt->setFloatParam(5,f4var1); - stmt->setStringParam(6,f3var1); - //stmt->setShortParam(7,f2var1); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - stmt->free(); - printf("%d Rows updated\n",count); - //********************************************************** - // SELECT * FROM T1; - strcpy(statement,"SELECT * FROM T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 5; } - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - count=0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch() !=NULL) { - if(f1var==5)printf("\n"); - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld \n",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv !=OK) { delete stmt; delete con; return 7; } - printf("%d Rows fetched=%d\n",count); - stmt->free(); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 8; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 9; } - printf("Table dropped\n"); - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Parameter/paratest2.c b/test/sqlapi/Parameter/paratest2.c deleted file mode 100644 index 27b6bd8e..00000000 --- a/test/sqlapi/Parameter/paratest2.c +++ /dev/null @@ -1,133 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * select * from T1 with where clause; - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con= createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT, F11 BINARY(4));"); - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - stmt->free(); - printf("Table created\n"); - // insert into table - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?,?);"); - int f1var = 100; - short int f2var = 10; - char f3var[32]="jitendra"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2007,01,21); - Time f7var; - f7var.set(12,29,30); - TimeStamp f8var; - f8var.setDate(2007,01,21); - f8var.setTime(12,29,30); - int f9var = 20; - long long f10var = 12000; - char f11var[8]="23fe"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 3; } - int count=0; - for(int i=0;i<10;i++) { - rv = con->beginTrans(); - if (rv!=OK) break; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - stmt->setBinaryParam(11,f11var, 4); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if (rv != OK) break; - count++; - } - printf("Total rows inserted %d\n",count); - stmt->free(); - //********************************************************** - // SELECT * FROM T1; - strcpy(statement,"SELECT * FROM T1 WHERE F1=? AND F2=? AND F3=? AND F4=? AND F5=? AND F6=? AND F7=? AND F8=? AND F9=? AND F10=? AND F11=?;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - stmt->bindField(11,f11var); - int f1var1=100; - short int f2var1=10; - char f3var1[20]="jitendra"; - float f4var1=5.5; - float f5var1=10.50; - Date f6var1; - f6var1.set(2007,1,21); - Time f7var1; - f7var1.set(12,29,30); - TimeStamp f8var1; - f8var1.setDate(2007,1,21); - f8var1.setTime(12,29,30); - int f9var1=20; - long long f10var1=12000; - char f11var1[8]="23fe"; - count=0; - rv = con->beginTrans(); - if(rv!=OK)return 5; - stmt->setIntParam(1,f1var1); - stmt->setShortParam(2,f2var1); - stmt->setStringParam(3,f3var1); - stmt->setFloatParam(4,f4var1); - stmt->setFloatParam(5,f5var1); - stmt->setDateParam(6,f6var1); - stmt->setTimeParam(7,f7var1); - stmt->setTimeStampParam(8,f8var1); - stmt->setIntParam(9,f9var1); - stmt->setLongLongParam(10,f10var1); - stmt->setBinaryParam(11,f11var1, 4); - stmt->execute(rows); - while(stmt->fetch()!=NULL) { - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - printf(" | "); - AllDataType::printVal(f11var,typeBinary,4); - printf("\n"); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv!=OK)return 6; - stmt->free(); - printf("%d Tuples fetched\n",count); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK){delete stmt; delete con; return -1;} - rv = stmt->execute(rows); - if(rv!=OK){delete stmt;delete con;return -1;} - printf("Table dropped\n"); - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Parameter/paratest3.c b/test/sqlapi/Parameter/paratest3.c deleted file mode 100644 index 47d80944..00000000 --- a/test/sqlapi/Parameter/paratest3.c +++ /dev/null @@ -1,153 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * delete records from T1 with where clause - * select * from T1; - - * Author : Jitendra Lenka. - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT, F11 BINARY(4));"); - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - stmt->free(); - printf("Table T1 created\n"); - // insert into table - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?,?);"); - int f1var = 0; - short int f2var = 1; - char f3var[32]="jitendra"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2007,01,21); - Time f7var; - f7var.set(12,29,30); - TimeStamp f8var; - f8var.setDate(2007,01,21); - f8var.setTime(12,29,30); - int f9var = 20; - long long f10var = 12000; - char f11var[12]="23fe"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - int count=0; - for(int i=0;i<10;i++) { - rv = con->beginTrans(); - if(rv!=OK) break; - f1var=i; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - stmt->setBinaryParam(11,f11var, 6); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("Total rows inserted %d\n",count); - stmt->free(); - //********************************************************* - // delete records from the T1 - strcpy(statement,"DELETE FROM T1 WHERE F10=? AND F9=? AND F8=? AND F7=? AND F6=? AND F5=? AND F4=? AND F3=? AND F2=? AND F1=? AND F11=?;"); - rv = stmt->prepare(statement); - if(rv!=OK){delete stmt;delete con;return -1;} - short int f2var1=1; - char f3var1[32] ="jitendra"; - float f4var1 = 5.5; - float f5var1 = 10.50; - Date f6var1; - f6var1.set(2007,1,21); - Time f7var1; - f7var1.set(12,29,30); - TimeStamp f8var1; - f8var1.setDate(2007,1,21); - f8var1.setTime(12,29,30); - int f9var1=20; - long long f10var1=12000; - char f11var1[12]="23fe"; - count=0; - for(int i=5;i<10;i++) { - rv = con->beginTrans(); - if(rv!=OK)break; - stmt->setLongLongParam(1,f10var1); - stmt->setIntParam(2,f9var1); - stmt->setTimeStampParam(3,f8var1); - stmt->setTimeParam(4,f7var1); - stmt->setDateParam(5,f6var1); - stmt->setFloatParam(6,f5var1); - stmt->setFloatParam(7,f4var1); - stmt->setStringParam(8,f3var1); - stmt->setShortParam(9,f2var1); - stmt->setIntParam(10,i); - stmt->setBinaryParam(11,f11var, 6); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - stmt->free(); - printf("Total row deleted=%d\n",count); - //********************************************************** - // SELECT * FROM T1; - strcpy(statement,"SELECT * FROM T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 5; } - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - stmt->bindField(11,f11var); - count=0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch() !=NULL) { - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld ",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - printf(" | "); - AllDataType::printVal(f11var,typeBinary,4); - printf("\n"); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv !=OK) { delete stmt; delete con; return 7; } - printf("Total row fetched=%d\n",count); - stmt->free(); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 8; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 9; } - printf("Table dropped\n"); - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Parameter/paratest4.c b/test/sqlapi/Parameter/paratest4.c deleted file mode 100644 index 9d81fad2..00000000 --- a/test/sqlapi/Parameter/paratest4.c +++ /dev/null @@ -1,155 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * update T1 WITH ALL 8 PARAMETERS. - noOfParamFields() should return 8. - * select * from T1; - - * Author : Jitendra Lenka. - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT, F11 BINARY(4));"); - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 1; } - stmt->free(); - printf("Table created\n"); - // insert into table - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?,?);"); - int f1var = 0; - short int f2var = 10; - char f3var[32]="jitendra"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2008,01,21); - Time f7var; - f7var.set(12,29,30); - TimeStamp f8var; - f8var.setDate(2008,01,21); - f8var.setTime(12,29,30); - int f9var = 20; - long long f10var = 12000; - char f11var[8]="23fe"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - int count=0; - for(int i=0;i<10;i++) { - rv = con->beginTrans(); - if(rv!=OK) break; - f1var=i; - f2var++; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - stmt->setBinaryParam(11,f11var, 4); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d Rows inserted \n",count); - stmt->free(); - //********************************************************** - // UPDATE TABLE - strcpy(statement,"UPDATE T1 SET F10=?,F8=?,F6=?,F5=?,F4=?,F3=?,F11=? WHERE F2=?;"); - rv = stmt->prepare(statement); - int nop; - nop = stmt->noOfParamFields(); - printf("noOfParamFields return=%d\n",nop); - if(nop!=8)return 1; - long long f10var1=15000; - TimeStamp f8var1; - f8var1.setDate(2007,3,30); - f8var1.setTime(10,25,55); - Date f6var1; - f6var1.set(2007,3,30); - float f5var1=20.25; - float f4var1=11.22; - char f3var1[10]="lakshya"; - char f11var1[8]="ab12"; - short int f2var1=10; - count=0; - for(int i=0;i<5;i++) { - rv = con->beginTrans(); - if(rv!=OK)break; - f2var1++; - stmt->setShortParam(8,f2var1); - stmt->setLongLongParam(1,f10var1); - stmt->setTimeStampParam(2,f8var1); - stmt->setDateParam(3,f6var1); - stmt->setFloatParam(4,f5var1); - stmt->setFloatParam(5,f4var1); - stmt->setStringParam(6,f3var1); - stmt->setBinaryParam(7,f11var1, 4); - //stmt->setShortParam(7,f2var1); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - stmt->free(); - printf("%d Rows updated\n",count); - //********************************************************** - // SELECT * FROM T1; - strcpy(statement,"SELECT * FROM T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 5; } - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - stmt->bindField(11,f11var); - count=0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch() !=NULL) { - if(f1var==5)printf("\n"); - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - printf(" | "); - AllDataType::printVal(f11var,typeBinary,4); - printf("\n"); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv !=OK) { delete stmt; delete con; return 7; } - printf("%d Rows fetched=%d\n",count); - stmt->free(); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 8; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 9; } - printf("Table dropped\n"); - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Select/Makefile b/test/sqlapi/Select/Makefile deleted file mode 100644 index 69ab73f8..00000000 --- a/test/sqlapi/Select/Makefile +++ /dev/null @@ -1,84 +0,0 @@ -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -O2 -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/install/include -I../../../include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlsql -lcsql -lcsqlsqllog -lcsqlnw -lcsqlsqlnw - -TARGETS = \ - test001 test001n\ - test002 test002n\ - test003 test003n\ - test004 test004n\ - test005 test005n\ - test006 test006n\ - test007 test007n\ - test008 test008n\ - test009 test009n\ - test010 test010n\ - test011 - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -test001: selecttest1.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test001n: selecttest1.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test002:selecttest2.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test002n: selecttest2.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test003:selecttest3.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test003n: selecttest3.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test004:selecttest4.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test004n: selecttest4.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test005:selecttest5.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test005n: selecttest5.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test006:selecttest6.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test006n: selecttest6.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test007:selecttest7.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test007n: selecttest7.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test008:selecttest8.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test008n: selecttest8.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test009:selecttest9.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test009n: selecttest9.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test010:selecttest10.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test010n: selecttest10.c common.h - $(CPlus) -DNETWORK $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test011:selecttest11.c common.h - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) - -clean: - rm -f *.o ${TARGETS} diff --git a/test/sqlapi/Select/common.h b/test/sqlapi/Select/common.h deleted file mode 100644 index f1ab199a..00000000 --- a/test/sqlapi/Select/common.h +++ /dev/null @@ -1,37 +0,0 @@ -#include -#include -#include - -AbsSqlConnection *createConnection() -{ -#ifdef NETWORK - AbsSqlConnection *con = SqlFactory::createConnection(CSqlNetwork); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); -#elif defined NETWORKADAPTER - AbsSqlConnection *con = SqlFactory::createConnection(CSqlNetworkAdapter); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); -#elif defined NETWORKGATEWAY - AbsSqlConnection *con = SqlFactory::createConnection(CSqlNetworkGateway); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); -#else - AbsSqlConnection *con = SqlFactory::createConnection(CSql); -#endif - return con; -} - -AbsSqlStatement *createStatement() -{ -#ifdef NETWORK - AbsSqlStatement *stmt = SqlFactory::createStatement(CSqlNetwork); -#elif defined NETWORKADAPTER - AbsSqlStatement *stmt = SqlFactory::createStatement(CSqlNetworkAdapter); -#elif defined NETWORKGATEWAY - AbsSqlStatement *stmt = SqlFactory::createStatement(CSqlNetworkGateway); -#else - AbsSqlStatement *stmt = SqlFactory::createStatement(CSql); -#endif - return stmt; -} diff --git a/test/sqlapi/Select/create.sql b/test/sqlapi/Select/create.sql deleted file mode 100644 index c709af22..00000000 --- a/test/sqlapi/Select/create.sql +++ /dev/null @@ -1,61 +0,0 @@ -echo create table t1 (f1 int,f2 int); -create table t1 (f1 int,f2 int); -echo check for SET AUTOCOMMIT OFF; -SET AUTOCOMMIT OFFer; -echo insert some record; -insert into t1 values(10,20); -insert into t1 values(20,30); -insert into t1 values(30,40); -insert into t1 values(40,50); -insert into t1 values(50,60); -echo rollback; -rollback; -echo select * from t1; -select * from t1; - -SET AUTOCOMMIT OFF; -insert into t1 values(30,40); -insert into t1 values(30,40); -insert into t1 values(30,40); -insert into t1 values(30,40); -insert into t1 values(30,40); -insert into t1 values(30,40); -insert into t1 values(30,40); -insert into t1 values(30,40); -insert into t1 values(30,40); -insert into t1 values(30,40); -echo test for commit; -commiter; -rollback; -select * from t1; - -echo test for rollback; -echo insert 5 records; - -insert into t1 values(20,40); -insert into t1 values(20,40); -insert into t1 values(20,40); -insert into t1 values(20,40); -insert into t1 values(20,40); -rollbacked; -commit; -select * from t1; - -echo check for show tables; -show tablesss; - -echo check for SET AUTOCOMMIT ON; - -SET AUTOCOMMIT ONNER; -echo insert some records; - -insert into t1 values(50,60); -insert into t1 values(50,60); -insert into t1 values(50,60); -insert into t1 values(50,60); -insert into t1 values(50,60); -rollback; -select * from t1; - -echo drop teble; -drop table t1; diff --git a/test/sqlapi/Select/csql.conf b/test/sqlapi/Select/csql.conf deleted file mode 100644 index e33cef74..00000000 --- a/test/sqlapi/Select/csql.conf +++ /dev/null @@ -1,70 +0,0 @@ -# CSQL System Configuration File - -#####################################Server Section######################## -#Important: For Server section parameters, make sure that the value is same for the -# server process and all the csql client process which connects to it. otherwise, -# behavior is undefined - -# Page size. Each database is logically divided into pages and allocation happens -# in this unit of pages. Increasing this value will reduce frequent allocation of pages. -PAGE_SIZE= 8192 - -#Total number of client process which can connect and work with the -# database concurrently -MAX_PROCS = 100 - -# Maximum size of the system database. -MAX_SYS_DB_SIZE=1048576 - -#Maximum size of the user database file. -MAX_DB_SIZE=10485760 - -#Shared memory key to be used by the system to create and locate system database. -SYS_DB_KEY=1199 - -#Shared memory key to be used by the system to create and locate user database. -USER_DB_KEY=2277 - -#Give full path for the log file where important system actions are stored. -LOG_FILE=/tmp/log/csql/log.out - -#The virtual memory start address at which the shared memory segment -# will be created and attached. -MAP_ADDRESS=400000000 - -#Give full path for the database file where table and record information will -#be stored for durability -DATABASE_FILE=/tmp/csql/csql.db - -#Important: For Server section parameters, make sure that the value is same for the -# server process and all the csql client process which connects to it. otherwise, -# behavior is undefined -#####################################Client Section######################## - -#Mutex timeout interval seconds -MUTEX_TIMEOUT_SECS=0 -MUTEX_TIMEOUT_USECS=5000 -MUTEX_TIMEOUT_RETRIES=10 - -#Lock timeout interval seconds -LOCK_TIMEOUT_SECS=0 -LOCK_TIMEOUT_USECS=5000 -LOCK_TIMEOUT_RETRIES=10 - -#####################################Cache Section######################## - -#Whether to enable caching of tables from target database -CACHE_TABLE=false - -#DSN Name to connect to the target database. -#This should be present in ~/odbc.ini file -DSN=myodbc3 - -ENABLE_BIDIRECTIONAL_CACHE=false - -CACHE_RECEIVER_WAIT_SECS=10 - -#Give full path for the file where all the cached table information is stored -TABLE_CONFIG_FILE=/tmp/csql/csqltable.conf - -#####################################End Section######################## diff --git a/test/sqlapi/Select/exp.test001 b/test/sqlapi/Select/exp.test001 deleted file mode 100644 index 01d6bb5f..00000000 --- a/test/sqlapi/Select/exp.test001 +++ /dev/null @@ -1,11 +0,0 @@ -'T1' table created -10 Rows Inserted -noOfProjFields returns=10 -Fetching starts on table 'T1' : -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -5 Rows fetched -'T1' table dropped diff --git a/test/sqlapi/Select/exp.test002 b/test/sqlapi/Select/exp.test002 deleted file mode 100644 index 65a3399d..00000000 --- a/test/sqlapi/Select/exp.test002 +++ /dev/null @@ -1,62 +0,0 @@ -'T1' Table created -10 Rows Inserted -Total number of projection fields in the select statement=5 - -FIELD INFORMATION : - -*********************************************** -Field Name :F8 -Data type of the field :22 -length of the field :8 -Offset :56 -Default value Buffer : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F10 -Data type of the field :2 -length of the field :8 -Offset :68 -Default value Buffer : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F2 -Data type of the field :3 -length of the field :4 -Offset :4 -Default value Buffer : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F6 -Data type of the field :20 -length of the field :4 -Offset :48 -Default value Buffer : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F3 -Data type of the field :30 -length of the field :32 -Offset :8 -Default value Buffer : -Null field :0 -Default value :0 -*********************************************** -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -Total row fetched=5 -Table dropped diff --git a/test/sqlapi/Select/exp.test005.ksh b/test/sqlapi/Select/exp.test005.ksh deleted file mode 100644 index f0581d21..00000000 --- a/test/sqlapi/Select/exp.test005.ksh +++ /dev/null @@ -1,97 +0,0 @@ -Case 1: create table t1 ,test for SET AUTOCOMMIT OFF and some records -[Parser: syntax error] SET -[Parser: syntax error] commiter -[Parser: syntax error] rollbacked -[Parser: syntax error] show -[Parser: syntax error] SET -echo create table t1 (f1 int,f2 int); -Statement Executed -echo check for SET AUTOCOMMIT OFF; -Statement prepare failed with error -19 -echo insert some record; -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 20 30 - 30 40 - 40 50 - 50 60 - -AUTOCOMMIT Mode is set to OFF -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo test for commit; -Statement prepare failed with error -19 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 20 30 - 30 40 - 40 50 - 50 60 - -echo test for rollback; -echo insert 5 records; -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement prepare failed with error -19 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 20 30 - 30 40 - 40 50 - 50 60 - 20 40 - 20 40 - 20 40 - 20 40 - 20 40 - -echo check for show tables; -Statement prepare failed with error -19 -echo check for SET AUTOCOMMIT ON; -Statement prepare failed with error -19 -echo insert some records; -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 20 30 - 30 40 - 40 50 - 50 60 - 20 40 - 20 40 - 20 40 - 20 40 - 20 40 - -echo drop teble; -Statement Executed diff --git a/test/sqlapi/Select/exp.test010 b/test/sqlapi/Select/exp.test010 deleted file mode 100644 index 943a7bcf..00000000 --- a/test/sqlapi/Select/exp.test010 +++ /dev/null @@ -1,62 +0,0 @@ -'T1' Table created -10 Rows Inserted -Total number of projection fields in the select statement=5 - -FIELD INFORMATION : - -*********************************************** -Field Name :F8 -Data type of the field :22 -length of the field :8 -Offset :56 -Default value Buffer : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F10 -Data type of the field :2 -length of the field :8 -Offset :68 -Default value Buffer : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F2 -Data type of the field :3 -length of the field :4 -Offset :4 -Default value Buffer : -Null field :1 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F6 -Data type of the field :20 -length of the field :4 -Offset :48 -Default value Buffer : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F3 -Data type of the field :30 -length of the field :32 -Offset :8 -Default value Buffer :LAKSHYA -Null field :0 -Default value :1 -*********************************************** -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -Total row fetched=5 -Table dropped diff --git a/test/sqlapi/Select/exp.test010n b/test/sqlapi/Select/exp.test010n deleted file mode 100644 index 943a7bcf..00000000 --- a/test/sqlapi/Select/exp.test010n +++ /dev/null @@ -1,62 +0,0 @@ -'T1' Table created -10 Rows Inserted -Total number of projection fields in the select statement=5 - -FIELD INFORMATION : - -*********************************************** -Field Name :F8 -Data type of the field :22 -length of the field :8 -Offset :56 -Default value Buffer : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F10 -Data type of the field :2 -length of the field :8 -Offset :68 -Default value Buffer : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F2 -Data type of the field :3 -length of the field :4 -Offset :4 -Default value Buffer : -Null field :1 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F6 -Data type of the field :20 -length of the field :4 -Offset :48 -Default value Buffer : -Null field :0 -Default value :0 -*********************************************** - -*********************************************** -Field Name :F3 -Data type of the field :30 -length of the field :32 -Offset :8 -Default value Buffer :LAKSHYA -Null field :0 -Default value :1 -*********************************************** -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -Total row fetched=5 -Table dropped diff --git a/test/sqlapi/Select/exp.test011 b/test/sqlapi/Select/exp.test011 deleted file mode 100644 index 8b320bf9..00000000 --- a/test/sqlapi/Select/exp.test011 +++ /dev/null @@ -1,9 +0,0 @@ -Table T1 created -Total rows inserted 10 -F1=5 | F2=1 | F3=jitendra | F4=5.500000 | F5=5 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=6 | F2=1 | F3=jitendra | F4=5.500000 | F5=6 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=7 | F2=1 | F3=jitendra | F4=5.500000 | F5=7 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=8 | F2=1 | F3=jitendra | F4=5.500000 | F5=8 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -F1=9 | F2=1 | F3=jitendra | F4=5.500000 | F5=9 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE -Total row fetched=5 -Table dropped diff --git a/test/sqlapi/Select/paratest1.c b/test/sqlapi/Select/paratest1.c deleted file mode 100644 index a3f13acc..00000000 --- a/test/sqlapi/Select/paratest1.c +++ /dev/null @@ -1,196 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * noOfParamFields() should return zero. - * getParamFldInfo() for all fields and print the field info. - * select * from T1; - - * Author : Jitendra Lenka. - */ - -#include -#include -#include -int main() -{ - DbRetVal rv = OK; - SqlConnection *con= new SqlConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - SqlStatement *stmt = new SqlStatement(); - stmt->setSqlConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT);"); - - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 1; - } - - rv = stmt->execute(rows); - if(rv!=OK) - { - delete stmt; - delete con; - return 1; - } - - stmt->free(); - printf("Table created\n"); - - // insert into table - - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?);"); - - int f1var = 0; - short int f2var = 1; - char f3var[20]="jitendra"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2008,01,21); - - Time f7var; - f7var.set(12,29,30); - - TimeStamp f8var; - f8var.setDate(2008,01,21); - f8var.setTime(12,29,30); - - int f9var = 20; - long long f10var = 12000; - - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 1; - } - - int count=0; - - for(int i=0;i<10;i++) - { - rv = con->beginTrans(); - if(rv!=OK) break; - f1var=i; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("Total rows inserted %d\n",count); - - - int nop; - nop = stmt->noOfParamFields(); - printf("Total parameter in the statement=%d\n",nop); - - FieldInfo * field = new FieldInfo(); - - - char fldName[20]; - DataType type; - size_t length; - int offset; - char defaultValueBuf[10]; - bool isNull; - bool isDefault; - - rv = stmt->getParamFldInfo(1,field); - if(rv !=OK)return -1; - printf("fldname of field is %s\n", field->fldName); - printf("data type of the field=%d\n",field->type); - printf("length of the field=%d\n",field->length); - printf("offset=%d\n",field->offset); - printf("default value=%s\n",field->defaultValueBuf); - printf("null field=%d\n",field->isNull); - printf("default value is set for the field=%d\n",field->isDefault); - - stmt->free(); - - //********************************************************** - - // SELECT * FROM T1; - - strcpy(statement,"SELECT * FROM T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 5; - } - - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - - count=0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch() !=NULL) - { - count++; - } - - stmt->close(); - rv = con->commit(); - if(rv !=OK) - { - delete stmt; - delete con; - return 7; - } - - printf("Total row fetched=%d\n",count); - stmt->free(); - - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 8; - } - rv = stmt->execute(rows); - if(rv!=OK) - { - delete stmt; - delete con; - return 9; - } - stmt->free(); - printf("Table dropped\n"); - - delete stmt; - delete con; - return 0; -} diff --git a/test/sqlapi/Select/selecttest1.c b/test/sqlapi/Select/selecttest1.c deleted file mode 100644 index f515e71a..00000000 --- a/test/sqlapi/Select/selecttest1.c +++ /dev/null @@ -1,110 +0,0 @@ -/* create table T1 with 10 fields, - * insert 10 rows into the table , - * noofprojFields shoul dreturn 10. - * call fetch and count the record. - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT);"); - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - stmt->free(); - printf("'T1' table created\n"); - //insert records - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?);"); - int f1var = 99; - short int f2var = 1; - char f3var[32] = "lakshya"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2008,1,21); - Time f7var; - f7var.set(12,29,30); - TimeStamp f8var; - f8var.setDate(2008,1,21); - f8var.setTime(12,29,30); - int f9var = 20; - long long f10var = 12000; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - int count=0; - for(int i=0;i<2;i++) { - f1var = f1var+i; - for(int j=0;j<5;j++) { - rv = con->beginTrans(); - if(rv!=OK)break; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - } - printf("%d Rows Inserted\n",count); - stmt->free(); -//******************************************* - strcpy(statement,"SELECT * FROM T1 WHERE F1=100;"); - rv = stmt->prepare(statement); - int nop; - nop = stmt->noOfProjFields(); - printf("noOfProjFields returns=%d\n",nop); - if(rv !=OK) { delete stmt; delete con; return 5; } - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - printf("Fetching starts on table 'T1' :\n"); - while(stmt->fetch()!=NULL) { - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld \n",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv!=OK) { delete stmt; delete con; return 7; } - printf("%d Rows fetched\n",count); - stmt->free(); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 8; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 9; } - printf("'T1' table dropped\n"); - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Select/selecttest10.c b/test/sqlapi/Select/selecttest10.c deleted file mode 100644 index 8a79b5b1..00000000 --- a/test/sqlapi/Select/selecttest10.c +++ /dev/null @@ -1,130 +0,0 @@ -/* create table T1 with 10 fields,( F2 NOT NULL , F3 CHAR(20) DEFAULT 'LAKSHYA') - * - * insert 10 rows for 9 Fields except F3 Field into the table - * noofprojFields should return 5. - * getProjFldInfo() for all fields. - * select with 5 parameters withIwhere clause.(WHERE F1=100) - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT NOT NULL,F3 CHAR(30) DEFAULT 'LAKSHYA',F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT);"); - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - stmt->free(); - printf("'T1' Table created\n"); -// insert records - strcpy(statement,"INSERT INTO T1(F1,F2,F4,F5,F6,F7,F8,F9,F10)VALUES(?,?,?,?,?,?,?,?,?);"); - int f1var = 99; - short int f2var = 1; -// char f3var[20] = "prabakaran"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2008,1,21); - Time f7var; - f7var.set(12,29,30); - TimeStamp f8var; - f8var.setDate(2008,1,21); - f8var.setTime(12,29,30); - int f9var = 20; - long long f10var = 12000; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - int count=0; - for(int i=0;i<2;i++) { - f1var = f1var+i; - for(int j=0;j<5;j++) { - rv = con->beginTrans(); - if(rv!=OK)break; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - //stmt->setStringParam(3,f3var); - stmt->setFloatParam(3,f4var); - stmt->setFloatParam(4,f5var); - stmt->setDateParam(5,f6var); - stmt->setTimeParam(6,f7var); - stmt->setTimeStampParam(7,f8var); - stmt->setIntParam(8,f9var); - stmt->setLongLongParam(9,f10var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - } - printf("%d Rows Inserted\n",count); - stmt->free(); -//******************************************* - strcpy(statement,"SELECT F8,F10,F2,F6,F3 FROM T1 WHERE F1=100;"); - rv = stmt->prepare(statement); - int nop; - nop = stmt->noOfProjFields(); - if(nop!=5)return 1; - printf("Total number of projection fields in the select statement=%d\n",nop); - // getParamFldInfo() - FieldInfo *field = new FieldInfo(); - printf("\nFIELD INFORMATION :\n"); - char fldName[20]; - DataType type; - size_t length; - int offset; - char defaultValueBuf[10]; - bool isNull; - bool isDefault; - for(int i=0;i<=4;i++) { - printf("\n***********************************************\n"); - rv = stmt->getProjFldInfo(i+1,field); - if(rv!=OK)return 1; - printf("Field Name :%s\n", field->fldName); - printf("Data type of the field :%d\n",field->type); - printf("length of the field :%d\n",field->length); - printf("Offset :%d\n",field->offset); - printf("Default value Buffer :%s\n",field->defaultValueBuf); - printf("Null field :%d\n",field->isNull); - printf("Default value :%d\n",field->isDefault); - printf("***********************************************\n"); - } - char f3var[32]="jitu"; - stmt->bindField(1,&f8var); - stmt->bindField(2,&f10var); - stmt->bindField(3,&f2var); - stmt->bindField(4,&f6var); - stmt->bindField(5,f3var); - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch()!=NULL) { - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld \n",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv!=OK) { delete stmt; delete con; return 6; } - printf("Total row fetched=%d\n",count); - stmt->free(); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 7; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 8; } - printf("Table dropped\n"); - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Select/selecttest11.c b/test/sqlapi/Select/selecttest11.c deleted file mode 100644 index d16cd3a8..00000000 --- a/test/sqlapi/Select/selecttest11.c +++ /dev/null @@ -1,112 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * select * from T1 where F5= ?; Test for - * stmt->setByteIntParam(1,f5var); - - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 TINYINT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT, F11 BINARY(4));"); - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - stmt->free(); - printf("Table T1 created\n"); - // insert into table - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?,?);"); - int f1var = 0; - short int f2var = 1; - char f3var[32]="jitendra"; - float f4var = 5.5; - int f5var = 10; - Date f6var; - f6var.set(2007,01,21); - Time f7var; - f7var.set(12,29,30); - TimeStamp f8var; - f8var.setDate(2007,01,21); - f8var.setTime(12,29,30); - int f9var = 20; - long long f10var = 12000; - char f11var[12]="23fe"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - int count=0; - for(int i=0;i<10;i++) { - rv = con->beginTrans(); - if(rv!=OK) break; - f1var=i; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setIntParam(5,i); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - stmt->setBinaryParam(11,f11var, 6); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("Total rows inserted %d\n",count); - stmt->free(); - //********************************************************* - // SELECT * FROM T1; - strcpy(statement,"SELECT * FROM T1 where F5 > ?;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 5; } - f5var=4; - stmt->setByteIntParam(1,f5var); - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - stmt->bindField(11,f11var); - count=0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch() !=NULL) { - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%d | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld ",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - printf(" | "); - AllDataType::printVal(f11var,typeBinary,4); - printf("\n"); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv !=OK) { delete stmt; delete con; return 7; } - printf("Total row fetched=%d\n",count); - stmt->free(); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 8; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 9; } - printf("Table dropped\n"); - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Select/selecttest2.c b/test/sqlapi/Select/selecttest2.c deleted file mode 100644 index 11f6d012..00000000 --- a/test/sqlapi/Select/selecttest2.c +++ /dev/null @@ -1,130 +0,0 @@ -/* create table T1 with 10 fields, - * insert 10 rows into the table , - * noofprojFields should return 5. - * getProjFldInfo() for all fields. - * select with 5 parameters withIwhere clause.(WHERE F1=100) - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT);"); - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - stmt->free(); - printf("'T1' Table created\n"); - // insert records - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?);"); - int f1var = 99; - short int f2var = 1; - char f3var[32] = "lakshya"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2008,1,21); - Time f7var; - f7var.set(12,29,30); - TimeStamp f8var; - f8var.setDate(2008,1,21); - f8var.setTime(12,29,30); - int f9var = 20; - long long f10var = 12000; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - int count=0; - for(int i=0;i<2;i++) { - f1var = f1var+i; - for(int j=0;j<5;j++) { - rv = con->beginTrans(); - if(rv!=OK)break; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - } - printf("%d Rows Inserted\n",count); - stmt->free(); -//******************************************* - strcpy(statement,"SELECT F8,F10,F2,F6,F3 FROM T1 WHERE F1=100;"); - rv = stmt->prepare(statement); - int nop; - nop = stmt->noOfProjFields(); - if(nop!=5)return 1; - printf("Total number of projection fields in the select statement=%d\n",nop); - // getParamFldInfo() - FieldInfo *field = new FieldInfo(); - - printf("\nFIELD INFORMATION :\n"); - char fldName[20]; - DataType type; - size_t length; - int offset; - char defaultValueBuf[10]; - bool isNull; - bool isDefault; - for(int i=0;i<=4;i++) { - printf("\n***********************************************\n"); - rv = stmt->getProjFldInfo(i+1,field); - if(rv!=OK)return 1; - printf("Field Name :%s\n", field->fldName); - printf("Data type of the field :%d\n",field->type); - printf("length of the field :%d\n",field->length); - printf("Offset :%d\n",field->offset); - printf("Default value Buffer :%s\n",field->defaultValueBuf); - printf("Null field :%d\n",field->isNull); - printf("Default value :%d\n",field->isDefault); - printf("***********************************************\n"); - } - delete field; - stmt->bindField(1,&f8var); - stmt->bindField(2,&f10var); - stmt->bindField(3,&f2var); - stmt->bindField(4,&f6var); - stmt->bindField(5,f3var); - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch()!=NULL) { - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld \n",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv!=OK) { delete stmt; delete con; return 6; } - printf("Total row fetched=%d\n",count); - stmt->free(); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 7; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 8; } - printf("Table dropped\n"); - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Select/selecttest3.c b/test/sqlapi/Select/selecttest3.c deleted file mode 100644 index 2728b0f2..00000000 --- a/test/sqlapi/Select/selecttest3.c +++ /dev/null @@ -1,79 +0,0 @@ -/* create table T1 with two fields, - * insert 10 rows into the table , - * select from nonexisting table. - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20));"); - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - stmt->free(); - printf("Table created\n"); - // insert records - strcpy(statement,"INSERT INTO T1 VALUES(?,?);"); - int f1var = 1; - char f2var[32] = "lakshya"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 3; } - int count=0; - for(int i=0;i<2;i++) { - for(int j=0;j<5;j++) { - f1var = j; - rv = con->beginTrans(); - if(rv!=OK)break; - stmt->setIntParam(1,f1var); - stmt->setStringParam(2,f2var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d rows inserted\n",count); - } - stmt->free(); - //******************************************* - strcpy(statement,"SELECT * FROM T11;"); - rv = stmt->prepare(statement); - if(rv !=OK) { - printf("test script passed\n"); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - rv = stmt->execute(rows); - if(rv==OK){printf("Table dropped\n");} - stmt->free(); delete stmt; delete con; - return 0; - } else if(rv==OK) { - printf("Test script failed\n"); - return 5; - } else { - stmt->bindField(1,&f1var); - stmt->bindField(2,f2var); - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch()!=NULL) { count++; } - stmt->close(); - rv = con->commit(); - if(rv!=OK) { delete stmt; delete con; return 7; } - printf("Total row fetched=%d\n",count); - } - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Select/selecttest4.c b/test/sqlapi/Select/selecttest4.c deleted file mode 100644 index a5b46178..00000000 --- a/test/sqlapi/Select/selecttest4.c +++ /dev/null @@ -1,66 +0,0 @@ -/* create table T1 with two fields, - * insert 10 rows into the table , - * select with nonexisting fields. - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 INT);"); - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - stmt->free(); - printf("Table created\n"); - // insert records - strcpy(statement,"INSERT INTO T1 VALUES(?,?);"); - int f1var = 1; - int f2var= 110; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 3; } - int count=0; - for(int i=0;i<2;i++) { - for(int j=0;j<5;j++) { - f1var = j; - rv = con->beginTrans(); - if(rv!=OK)break; - stmt->setIntParam(1,f1var); - stmt->setIntParam(2,f2var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d rows inserted\n",count); - } - stmt->free(); -//******************************************* - strcpy(statement,"SELECT F3 ,F2 FROM T1;"); - rv = stmt->prepare(statement); - if(rv !=OK) { - printf("Test script passed\n"); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - rv = stmt->execute(rows); - if(rv==OK)printf("Table dropped\n"); - stmt->free(); delete stmt; delete con; - return 0; - } else { - printf("Test script failed\n"); - delete stmt; delete con; - return 4; - } -} diff --git a/test/sqlapi/Select/selecttest5.c b/test/sqlapi/Select/selecttest5.c deleted file mode 100644 index 92abb083..00000000 --- a/test/sqlapi/Select/selecttest5.c +++ /dev/null @@ -1,28 +0,0 @@ -/* call execute without calling prepare. it should fail. - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 INT);"); - int rows=0; - rv = stmt->execute(rows); - if(rv!=OK) { - delete stmt; delete con; - printf("Execute failed without call prepare\n"); - return 0; - } - printf("Test script failed\n"); - stmt->free(); delete stmt; delete con; - return 1; -} diff --git a/test/sqlapi/Select/selecttest6.c b/test/sqlapi/Select/selecttest6.c deleted file mode 100644 index 838ffe1b..00000000 --- a/test/sqlapi/Select/selecttest6.c +++ /dev/null @@ -1,73 +0,0 @@ -/* create table T1 with two fields, - * insert 10 rows into the table , - * fetch without prepare. - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20));"); - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - stmt->free(); - printf("Table created\n"); -// insert records - strcpy(statement,"INSERT INTO T1 VALUES(?,?);"); - int f1var = 1; - char f2var[24] = "lakshya"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 3; } - int count=0; - for(int i=0;i<2;i++) { - for(int j=0;j<5;j++) { - f1var = j; - rv = con->beginTrans(); - if(rv!=OK)break; - stmt->setIntParam(1,f1var); - stmt->setStringParam(2,f2var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d rows inserted\n",count); - } - stmt->free(); -//******************************************* - strcpy(statement,"SELECT * FROM T1;"); - stmt->bindField(1,&f1var); - stmt->bindField(2,f2var); - void *ret; - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(1) { - ret = ((char*)stmt->fetch()); - if(ret ==NULL) { - printf("fetch failed without prepare\n"); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - rv = stmt->execute(rows); - if(rv==OK){printf("Table dropped successfully\n");} - stmt->free(); delete stmt; delete con; return 0; - } - printf("Test script failed\n"); - } - delete stmt; delete con; - return 8; -} diff --git a/test/sqlapi/Select/selecttest7.c b/test/sqlapi/Select/selecttest7.c deleted file mode 100644 index 793a7c10..00000000 --- a/test/sqlapi/Select/selecttest7.c +++ /dev/null @@ -1,79 +0,0 @@ -/* create table T1 with two fields, - * insert 10 rows into the table , - * call fetch without call execute,it returns NULL. - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20));"); - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - stmt->free(); - printf("Table created\n"); -// insert records - strcpy(statement,"INSERT INTO T1 VALUES(?,?);"); - int f1var = 1; - char f2var[24] = "lakshya"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 3; } - int count=0; - for(int i=0;i<2;i++) { - for(int j=0;j<5;j++) { - f1var = j; - rv = con->beginTrans(); - if(rv!=OK)break; - stmt->setIntParam(1,f1var); - stmt->setStringParam(2,f2var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d rows inserted\n",count); - } - stmt->free(); -//******************************************* - strcpy(statement,"SELECT * FROM T1;"); - rv = stmt->prepare(statement); - if(rv !=OK) { delete stmt; delete con; return 4; } - stmt->bindField(1,&f1var); - stmt->bindField(2,f2var); - void *ret; - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 5; - //stmt->execute(rows); - while(1) { - ret = ((char*)stmt->fetch()); - if(ret==NULL) { - printf("without prepare,Fetch failed\n"); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - rv = stmt->execute(rows); - if(rv==OK){printf("Table dropped successfully\n");} - stmt->free(); - delete stmt; - delete con; - return 0; - } - printf("Test script failed\n"); - } - stmt->free(); delete stmt; delete con; - return 7; -} - diff --git a/test/sqlapi/Select/selecttest8.c b/test/sqlapi/Select/selecttest8.c deleted file mode 100644 index ca579909..00000000 --- a/test/sqlapi/Select/selecttest8.c +++ /dev/null @@ -1,42 +0,0 @@ -/* prepare,execute,free,prepare, second prepare should pass. - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20));"); - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - printf("Prepare the Statement\n"); - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - printf("Execute the Statement\n"); - stmt->free(); - printf("free all the resources\n"); - //again prepare - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { - printf("Test script failed\n"); - delete stmt; delete con; return 3; - } - printf("Again prepare passed\n"); - //Drop the table - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - rv = stmt->execute(rows); - if(rv==OK)printf("Table dropped successfully\n"); - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Select/selecttest9.c b/test/sqlapi/Select/selecttest9.c deleted file mode 100644 index 1ec7cb28..00000000 --- a/test/sqlapi/Select/selecttest9.c +++ /dev/null @@ -1,37 +0,0 @@ -/* prepare,execute,prepare...., - * second prepare should pass. - - * Author : Jitendra Lenka - */ - -#include"common.h" - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = createConnection(); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = createStatement(); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20));"); - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - printf("Prepared the statement\n"); - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - printf("Execute the statement\n"); - //again prepare - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { - printf("Test script failed\n"); - delete stmt; delete con; return 3; - } - printf("Test script passed\n"); - stmt->execute(rows); - stmt->free(); delete stmt; delete con; - return 0; -} diff --git a/test/sqlapi/Select/test005.ksh b/test/sqlapi/Select/test005.ksh deleted file mode 100755 index b109d523..00000000 --- a/test/sqlapi/Select/test005.ksh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/sh -# Test Case -# check options -D chunk with empty database -#create table t1 (f1,f2) check with -D chunk -#drop t1 check with -D chunk - -CSQL_CONF=${PWD}/sqlapi/Select/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/sqlapi/Select -fi -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf - -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 5 -echo "Case 1: create table t1 ,test for SET AUTOCOMMIT OFF and some records " -$CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/create.sql 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - -kill -9 $pid -ipcrm -M 1199 -M 2277 -exit 0; - diff --git a/test/sqlnetwork/Connect/Makefile b/test/sqlnetwork/Connect/Makefile deleted file mode 100644 index 5859ffa4..00000000 --- a/test/sqlnetwork/Connect/Makefile +++ /dev/null @@ -1,67 +0,0 @@ -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -g -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/install/include -I../../../include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlsql -lcsql -lcsqlsqllog -lcsqlnw -lcacheload -lcsqlsqlnw - -TARGETS = \ - test001\ - test002\ - test003\ - test004\ - test005\ - test006\ - test007\ - test008\ - test009\ - test010\ - test011\ - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -.c.o:.c - $(CPlus) $(CPlusFlags) $(INCL) -c -o $@ $< - -test001:conntest1.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test002:conntest2.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test003:conntest3.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test004:conntest4.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test005:conntest5.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test006:conntest6.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test007:conntest7.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test008:conntest8.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test009:conntest9.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test010:conntest10.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test011:conntest11.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - -clean: - rm -f *.o ${TARGETS} diff --git a/test/sqlnetwork/Connect/conntest1.c b/test/sqlnetwork/Connect/conntest1.c deleted file mode 100644 index e492e2fb..00000000 --- a/test/sqlnetwork/Connect/conntest1.c +++ /dev/null @@ -1,33 +0,0 @@ -/* connect ,disconnect and again connect ,it should pass. - - * AUTHOR : Jitendra Lenka - */ - -#include -#include - -int main() -{ - DbRetVal rv =OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - printf("Connection opened\n"); - rv = con->disconnect(); - if (rv != OK) { printf("disconnect failed\n"); return 2; } - rv = con->connect("root","manager"); - if(rv !=OK) - { - printf("Test script failed \n"); - return 3; - } - printf("Connection opened\n"); - printf("Test script passed\n"); - delete con; - return 0; -} - - diff --git a/test/sqlnetwork/Connect/conntest10.c b/test/sqlnetwork/Connect/conntest10.c deleted file mode 100644 index c273d194..00000000 --- a/test/sqlnetwork/Connect/conntest10.c +++ /dev/null @@ -1,95 +0,0 @@ -/* create table T1 ,INSERT ,UPDATE AND COMMIT. - * FETCH UPDATED RECORDS. - - * Author : Jitendra Lenka - */ - -#include -#include -#include - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 INT);"); - - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - printf("Table T1 CREATED\n"); - - // insert into statement - strcpy(statement,"INSERT INTO T1 VALUES(1,1);"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - - rv = con->beginTrans(); - if(rv!=OK) { delete stmt; delete con; return 5; } - - rv = stmt->execute(rows); if(rv!=OK) return 6; - printf("One record inserted\n"); - - // update statement - - printf("update T1 set F2=100\n"); - strcpy(statement,"UPDATE T1 SET F2=100;"); - - rv = stmt->prepare(statement); - if(rv !=OK) { delete stmt; delete con; return 7; } - - - rv = stmt->execute(rows); - if(rv!=OK){ printf ("Hello\n"); return 8; } - rv = con->commit(); if(rv!=OK)return 9; - printf("One row updated\n"); - - - strcpy(statement,"SELECT F2 FROM T1 ;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 10; } - - int id=10; - stmt->bindField(1,&id); - rv = con->beginTrans(); - if(rv!=OK)return 11; - stmt->execute(rows); - int count=0; - while(stmt->fetch()!=NULL) - { - printf("F2= %d\n",id); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv!=OK)return 12; - printf("Total reccord fetchec=%d\n",count); - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 13; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 14; } - - printf("TABLE T1 DROPPED SUCCESSFULLY\n"); - delete stmt; - delete con; - printf("Connection closed successfully\n"); - return 0; -} - diff --git a/test/sqlnetwork/Connect/conntest11.c b/test/sqlnetwork/Connect/conntest11.c deleted file mode 100644 index c849fd36..00000000 --- a/test/sqlnetwork/Connect/conntest11.c +++ /dev/null @@ -1,87 +0,0 @@ -/* create table T1 , insert and update - * then rollback, - - * Author : Jitendra Lenka - */ - -#include -#include -#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 INT);"); - - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - - printf("Table T1 CREATED\n"); - - strcpy(statement,"INSERT INTO T1 VALUES(1,1);"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 3; } - - rv = con->beginTrans(); - if(rv!=OK) { delete stmt; delete con; return 4; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 5; } - printf("1 Record inserted\n"); - - strcpy(statement,"UPDATE T1 SET F2=100;"); - - rv = stmt->prepare(statement); - if(rv !=OK) { delete stmt; delete con; return 6; } - - rv = stmt->execute(rows); - if(rv!=OK && rows !=1)return 7; - printf("1 Record updated\n"); - // ROLLBACK - - rv = con->rollback(); - if(rv!=OK)return 8; - - strcpy(statement,"SELECT F2 FROM T1 ;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 9; } - - int id=10; - stmt->bindField(1,&id); - rv = con->beginTrans(); - if(rv!=OK)return 1; - stmt->execute(rows); - int count=0; - while(stmt->fetch()!=NULL) { printf("F2= %d\n",id); count++; } - stmt->close(); - rv = con->commit(); - if(rv!=OK)return 10; - - printf("Total record fetched =%d ,Because transaction rollbacked\n",count); - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 11; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 12; } - printf("Table droped\n"); - delete stmt; - delete con; - return 0; -} - diff --git a/test/sqlnetwork/Connect/conntest2.c b/test/sqlnetwork/Connect/conntest2.c deleted file mode 100644 index 949105f9..00000000 --- a/test/sqlnetwork/Connect/conntest2.c +++ /dev/null @@ -1,38 +0,0 @@ -/* close the connection and call commit, it should fail - - * Author : Jitendra Lenka - */ - -#include -#include - -int main() -{ - DbRetVal rv = OK; - - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - printf("Connection opened\n"); - rv = con->beginTrans(); - if(rv!=OK)return 2; - rv = con->disconnect(); - if(rv !=OK)return 3; - printf("Connection closed\n"); - rv = con->commit(); - if(rv==OK) - { - printf("Test script failed\n"); - return 4; - } - printf("After closing the connection, commit failed\n"); - printf("Test script pased\n"); - delete con; - return 0; -} - - - diff --git a/test/sqlnetwork/Connect/conntest3.c b/test/sqlnetwork/Connect/conntest3.c deleted file mode 100644 index ce4dcd03..00000000 --- a/test/sqlnetwork/Connect/conntest3.c +++ /dev/null @@ -1,46 +0,0 @@ -/* close the connection and call prepare ,it should fail - - * Author : Jitendra Lenka - */ -#include -#include -#include - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT);"); - - int rows; - rv = con->disconnect(); - if(rv!=OK)return 2; - printf("Connection closed\n"); - - rv = stmt->prepare(statement); - if(rv==OK) - { - - delete stmt; - delete con; - printf("Test script failed\n"); - return 3; - } - printf("Test script passed\n"); - delete stmt; - delete con; - return 0; -} - - diff --git a/test/sqlnetwork/Connect/conntest4.c b/test/sqlnetwork/Connect/conntest4.c deleted file mode 100644 index d7a365e6..00000000 --- a/test/sqlnetwork/Connect/conntest4.c +++ /dev/null @@ -1,41 +0,0 @@ -// close the connection and call execute,it should fail. - -// Author : Jitendra Lenka - -#include -#include -#include - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20)); "); - - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - printf("prepared successfully\n"); - - rv = con->disconnect(); - if(rv!=OK)return 3; - printf("Disconnect successfully\n"); - - rv = stmt->execute(rows); - if(rv == OK) { printf("Test script failed \n"); delete stmt; return 4; } - printf("Test script passed\n"); - delete stmt; - delete con; - return 0; -} diff --git a/test/sqlnetwork/Connect/conntest5.c b/test/sqlnetwork/Connect/conntest5.c deleted file mode 100644 index 25771ec6..00000000 --- a/test/sqlnetwork/Connect/conntest5.c +++ /dev/null @@ -1,86 +0,0 @@ -/* create table T1 ,Insert some records in it. - * Close the connection, Fetch should fail. - - * Author : Jitendra Lenka - */ - -# include -# include -#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 INT);"); - - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - printf("Table T1 CREATED\n"); - - // insert into statement - strcpy(statement,"INSERT INTO T1 VALUES(1,1);"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - - rv = con->beginTrans(); - if(rv!=OK) { delete stmt; delete con; return 5; } - - rv = stmt->execute(rows); if(rv!=OK) return 6; - rv = con->commit(); - if(rv!=OK) return 7; - printf("One record inserted\n"); - - strcpy(statement,"SELECT F2 FROM T1 ;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 10; } - - int id=10; - stmt->bindField(1,&id); - rv = con->beginTrans(); - if(rv!=OK)return 11; - stmt->execute(rows); - int count=0; - stmt->close(); - stmt->free(); - rv = con->disconnect(); //close the connection - - void *rettype; - if(rv!=OK)return 8; - rettype = (char*)stmt->fetch(rv); - if(rettype==NULL && rv == ErrNoConnection) { - con->connect("root", "manager"); - stmt->setConnection(con); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if (rv != OK) { return 9; } - rv = stmt->execute(rows); - if(rv==OK){printf("Table Dropped successfully\n");} - printf("Test script passed\n"); - delete stmt; - delete con; - return 0; - } - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - rv = stmt->execute(rows); - if(rv==OK){printf("Table Dropped successfully\n");} - printf("Test script Failed\n"); - delete stmt; - delete con; - return 7; -} diff --git a/test/sqlnetwork/Connect/conntest6.c b/test/sqlnetwork/Connect/conntest6.c deleted file mode 100644 index 3d08b14f..00000000 --- a/test/sqlnetwork/Connect/conntest6.c +++ /dev/null @@ -1,28 +0,0 @@ -/* connect twice without closing the connection, - * second conection should return "user already logged in". - - * Author : Jitendra lenka - */ -#include -#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv !=OK)return 1; - printf("Connection opened\n"); - - rv = con->connect("root","manager"); - if(rv==OK) - { - printf("testscript failed\n"); - return 1; - } - printf("Test script passed\n"); - delete con; - return 0; -} diff --git a/test/sqlnetwork/Connect/conntest7.c b/test/sqlnetwork/Connect/conntest7.c deleted file mode 100644 index 8d21a48b..00000000 --- a/test/sqlnetwork/Connect/conntest7.c +++ /dev/null @@ -1,24 +0,0 @@ -// Pass correct user name and password ,it should pass. - -// Author : Jitendra Lenkla - -#include -#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK) - { - printf("Test script failed with error%d\n",rv); - return 1; - } - printf("Connection opened with correct user name and password\n"); - printf("Test script passed\n"); - delete con; - return 0; -} diff --git a/test/sqlnetwork/Connect/conntest8.c b/test/sqlnetwork/Connect/conntest8.c deleted file mode 100644 index d7cb8864..00000000 --- a/test/sqlnetwork/Connect/conntest8.c +++ /dev/null @@ -1,24 +0,0 @@ -// Pass incorrect user name and password ,it should fail. - -// Author : Jitendra Lenkla - -#include -#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn =(SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root123","manager123"); - if(rv==OK) - { - printf("Test script failed with error%d\n",rv); - return 1; - } - printf("Connection failed dueto incorrect user anme and password\n"); - printf("Test script passed\n"); - delete con; - return 0; -} diff --git a/test/sqlnetwork/Connect/conntest9.c b/test/sqlnetwork/Connect/conntest9.c deleted file mode 100644 index 077f61f2..00000000 --- a/test/sqlnetwork/Connect/conntest9.c +++ /dev/null @@ -1,24 +0,0 @@ -// Pass correct username and incorrect password ,it should fail. - -// Author : Jitendra Lenkla - -#include -#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *) con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager123"); - if(rv==OK) - { - printf("Test script failed with error%d\n",rv); - return 1; - } - printf("Connection is not opened dueto Incorrect password\n"); - printf("Test script passed\n"); - delete con; - return 0; -} diff --git a/test/sqlnetwork/Connect/exp.test010 b/test/sqlnetwork/Connect/exp.test010 deleted file mode 100644 index ced7af8c..00000000 --- a/test/sqlnetwork/Connect/exp.test010 +++ /dev/null @@ -1,96 +0,0 @@ -NW:TCP connecting -Response from peer site is 1 -NW:TCP Send -Sent bytes 16 -Sent bytes 256 -NW:TCP receive -Connection opened -NW:TCP Send -Sent bytes 16 -Sent bytes 36 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table T1 CREATED -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 32 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -One record inserted -update T1 set F2=100 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 26 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -One row updated -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 24 -NW:TCP receive -HEADER says packet type is 104 -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F2= 100 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -Total reccord fetchec=1 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 19 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -TABLE T1 DROPPED SUCCESSFULLY -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP disconnect kishor 5678 -Sent bytes 16 -NW:TCP receive -Connection closed successfully diff --git a/test/sqlnetwork/Connect/exp.test011 b/test/sqlnetwork/Connect/exp.test011 deleted file mode 100644 index ec70c10e..00000000 --- a/test/sqlnetwork/Connect/exp.test011 +++ /dev/null @@ -1,88 +0,0 @@ -NW:TCP connecting -Response from peer site is 1 -NW:TCP Send -Sent bytes 16 -Sent bytes 256 -NW:TCP receive -Connection opened -NW:TCP Send -Sent bytes 16 -Sent bytes 36 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table T1 CREATED -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 32 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -1 Record inserted -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 26 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -1 Record updated -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 24 -NW:TCP receive -HEADER says packet type is 104 -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -Total record fetched =0 ,Because transaction rollbacked -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 19 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table droped -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP disconnect kishor 5678 -Sent bytes 16 -NW:TCP receive diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest1.java b/test/sqlnetwork/Jdbcnetwork/ConnTest1.java deleted file mode 100755 index c6300a63..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest1.java +++ /dev/null @@ -1,20 +0,0 @@ -//Connect with connect string "jdbc:csql://localhost:5678/csql" and give correct "user" and "password" in properties object. It should pass. -import java.sql.*; -public class ConnTest1 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - if ( con == null ) System.exit(1); - con.close(); - System.exit(0); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.getStackTrace(); - System.exit(1); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest10.java b/test/sqlnetwork/Jdbcnetwork/ConnTest10.java deleted file mode 100644 index f13d3ee3..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest10.java +++ /dev/null @@ -1,19 +0,0 @@ -//Connect with "jdbc:csql://5678:localhost/csql" and give correct "user" and "password" in properties object. It should fail - -import java.sql.*; -public class ConnTest10 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://5678:localhost/csql", "root", "manager"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest11.java b/test/sqlnetwork/Jdbcnetwork/ConnTest11.java deleted file mode 100644 index 30a2266e..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest11.java +++ /dev/null @@ -1,19 +0,0 @@ -// Connect with "jdbc:csql://localhost:5678" and give correct "user" and "password" in properties object. It should pass as for csql default database is csql -import java.sql.*; -public class ConnTest11 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678", "root", "manager"); - if (con == null) System.exit(1); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit (1); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest12.java b/test/sqlnetwork/Jdbcnetwork/ConnTest12.java deleted file mode 100644 index 8d9a88cb..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest12.java +++ /dev/null @@ -1,18 +0,0 @@ -//Connect with "jdbc:csql://local/host:5678/csql" and give correct "user" and "password" in properties object. It should fail -import java.sql.*; -public class ConnTest12 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://local/host:5678/csql", "root", "manager"); - if (con != null) System.exit (1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest13.java b/test/sqlnetwork/Jdbcnetwork/ConnTest13.java deleted file mode 100644 index dcda009e..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest13.java +++ /dev/null @@ -1,18 +0,0 @@ -//Connect with "jdbc:csql:localhost:5678" and give correct "user" and "password" in properties object. It should fail -import java.sql.*; -public class ConnTest13 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql:localhost:5678", "root", "manager"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest14.java b/test/sqlnetwork/Jdbcnetwork/ConnTest14.java deleted file mode 100644 index f88486a9..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest14.java +++ /dev/null @@ -1,18 +0,0 @@ -//Connect with "jdbc:csql://localhost:5678csql" and give correct "user" and "password" in properties object. It should fail -import java.sql.*; -public class ConnTest14 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678csql", "root", "manager"); - if (con != null) System.exit (1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit (0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest15.java b/test/sqlnetwork/Jdbcnetwork/ConnTest15.java deleted file mode 100644 index f6c59d38..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest15.java +++ /dev/null @@ -1,18 +0,0 @@ -//Connect with "jdbc:csql//localhost:5678/csql" and give correct "user" and "password" in properties object. It should fail -import java.sql.*; -public class ConnTest15 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql//localhost:5678/csql","root","manager"); - if(con!=null) {con.close(); System.exit(1);} - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest16.java b/test/sqlnetwork/Jdbcnetwork/ConnTest16.java deleted file mode 100644 index 5955227e..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest16.java +++ /dev/null @@ -1,25 +0,0 @@ -//Try to open , close , open . it should pass -import java.sql.*; -public class ConnTest16 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - if ( con == null ) - System.exit(1); - con.close(); - con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql","root","manager"); - if ( con == null ) - System.exit(1); - con.close(); - System.exit(0); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - System.exit(1); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest17.java b/test/sqlnetwork/Jdbcnetwork/ConnTest17.java deleted file mode 100644 index 395a7846..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest17.java +++ /dev/null @@ -1,24 +0,0 @@ -//Close the connection and they call commit(). It should fail. -import java.sql.*; -public class ConnTest17 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - if ( con == null ) - System.exit(1); - con.close(); - con.commit(); - System.exit(1); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - if (e.getMessage().equals("Invalid state")) System.exit(0); - else System.exit(1); - - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest18.java b/test/sqlnetwork/Jdbcnetwork/ConnTest18.java deleted file mode 100644 index fd09600b..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest18.java +++ /dev/null @@ -1,24 +0,0 @@ -//Close the connection and then call createStatement(). It should fail. -import java.sql.*; -public class ConnTest18 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - if ( con == null ) - System.exit(1); - con.close(); - Statement cStmt = con.createStatement(); - if (cStmt != null) - System.exit(1); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - if (e.getMessage().equals("Invalid state")) System.exit(0); - else System.exit(1); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest19.java b/test/sqlnetwork/Jdbcnetwork/ConnTest19.java deleted file mode 100644 index dd2b2b68..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest19.java +++ /dev/null @@ -1,26 +0,0 @@ -//Close the connection and then call preparedStatement(). It should fail -import java.sql.*; -public class ConnTest19 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - if ( con == null ) - System.exit(1); - con.close(); - PreparedStatement pStmt = null; - pStmt = con.prepareStatement("create table t1(f1 integer);"); - if (pStmt != null) - System.exit(1); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - if (e.getMessage().equals("Invalid state")) System.exit(0); - else System.exit(1); - - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest2.java b/test/sqlnetwork/Jdbcnetwork/ConnTest2.java deleted file mode 100755 index 79bfe9ed..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest2.java +++ /dev/null @@ -1,18 +0,0 @@ -//Connect with connect string "jdbc:csql://localhost:5678/csql" and null for username and password. It should fail. -import java.sql.*; -public class ConnTest2 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", null, null); - if (con != null) {con.close(); System.exit(1);} - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest20.java b/test/sqlnetwork/Jdbcnetwork/ConnTest20.java deleted file mode 100644 index d4a677a3..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest20.java +++ /dev/null @@ -1,23 +0,0 @@ -//Open the connection and then call isClosed(). It should return false. -//Close the connection and then call isClosed(). It should return true. -import java.sql.*; -public class ConnTest20 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - if ( con == null ) - System.exit(1); - if(con.isClosed()) System.exit(1); - con.close(); - if(!con.isClosed()) System.exit(1); - }catch(Exception e) { - System.out.println(e.getMessage()); - e.getStackTrace(); - System.exit(1); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest3.java b/test/sqlnetwork/Jdbcnetwork/ConnTest3.java deleted file mode 100644 index 682999f9..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest3.java +++ /dev/null @@ -1,18 +0,0 @@ -//Connect only with connect string "jdbc:csql://localhost:5678/csql" and no username and password. It should fail. -import java.sql.*; -public class ConnTest3 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest4.java b/test/sqlnetwork/Jdbcnetwork/ConnTest4.java deleted file mode 100644 index 43bf218b..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest4.java +++ /dev/null @@ -1,19 +0,0 @@ -//Connect with connect string "jdbc:sql://localhost:5678/csql" and give correct "user" and "password" in properties object. It should fail. - -import java.sql.*; -public class ConnTest4 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:sql://localhost:5678/csql", "root", "manager"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest5.java b/test/sqlnetwork/Jdbcnetwork/ConnTest5.java deleted file mode 100644 index 1a3fbec4..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest5.java +++ /dev/null @@ -1,18 +0,0 @@ -//Connect with connectstring "odbc:csql://localhost:5678/csql" and give correct "user" and "password" in properties object. It should fail. -import java.sql.*; -public class ConnTest5 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("odbc:csql://localhost:5678/csql", "root", "manager"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit (0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest6.java b/test/sqlnetwork/Jdbcnetwork/ConnTest6.java deleted file mode 100644 index e65a22b8..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest6.java +++ /dev/null @@ -1,18 +0,0 @@ -//Connect with connectstring "jdbc:csql://localhost:5678/csql" and give incorrect "user" and "password" in properties object. It should fail. -import java.sql.*; -public class ConnTest6 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "wrongusertest", "manager"); - if (con != null) System.exit (1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest7.java b/test/sqlnetwork/Jdbcnetwork/ConnTest7.java deleted file mode 100755 index 71e004e0..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest7.java +++ /dev/null @@ -1,18 +0,0 @@ -//Connect with connectstring "jdbc:csql://localhost:5678/csql" and give correct "user" and incorrect "password" in properties object. It should fail. -import java.sql.*; -public class ConnTest7 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "wrongpasswd"); - if (con != null) System.exit(1); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest8.java b/test/sqlnetwork/Jdbcnetwork/ConnTest8.java deleted file mode 100644 index d100dbbf..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest8.java +++ /dev/null @@ -1,18 +0,0 @@ -//Connect with "jdbc:csql:5678:localhost:csql" and give correct "user" and "password" in properties object. It should fail -import java.sql.*; -public class ConnTest8 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql:5678:localhost:csql", "root", "manager"); - if (con != null) {con.close(); System.exit(1);} - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/ConnTest9.java b/test/sqlnetwork/Jdbcnetwork/ConnTest9.java deleted file mode 100644 index 88905e18..00000000 --- a/test/sqlnetwork/Jdbcnetwork/ConnTest9.java +++ /dev/null @@ -1,18 +0,0 @@ -// Connect with connectstring "jdbc:csql://localhost:5678/csql" and with very long username and "password" in properties object. It should fail but no overflow -// -import java.sql.*; -public class ConnTest9 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "wrongusertiiiiiiiiiisooooooooooooooooooooooooooooooooooooooooooooooooolllllllllllllllllllllllloooooooooooooooonnnnnnnnnnnnnnnnnnnnnggggggggggggggggggggg11111111111111111111111111222222222222222222222222222222233333333333333333333333333444444444444444444444444455555555555555555555555555555556666666666666666666666666666666667777777777777777777777777777777777788888888888888888888888888888888888888899999999999999999999999999999999999999999999999999999999999999999xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiieeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeeellllllllllllllllllllllllllllllllllllllllllllllllllllllliiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiiaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaannnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnnggggggggggggggggggggggggggggggggggghhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhhaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaatttttttttttttttttttttttttttteeeeeeeeeeeeeeeeeeeeeeeeesssssssssssssssstttttttttttttttttttttttttttttttttttttttttttttt", "manager"); - }catch(Exception e) { - System.out.println("Exception in Test: "+e.getMessage()); - e.getStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/Makefile b/test/sqlnetwork/Jdbcnetwork/Makefile deleted file mode 100644 index 87b5a74d..00000000 --- a/test/sqlnetwork/Jdbcnetwork/Makefile +++ /dev/null @@ -1,13 +0,0 @@ -OSNAME = $(shell uname -s) -JAVAC = javac -TARGETS = ConnTests -TARGETS:ConnTest1.java ConnTest2.java ConnTest3.java \ - ConnTest4.java ConnTest5.java ConnTest6.java \ - ConnTest7.java ConnTest8.java ConnTest9.java \ - ConnTest10.java ConnTest11.java ConnTest12.java ConnTest13.java \ - ConnTest14.java ConnTest15.java ConnTest16.java ConnTest17.java \ - ConnTest18.java ConnTest19.java ConnTest20.java - ${JAVAC} *.java - chmod +x *.ksh -clean: - rm -rf *.class diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest1.java b/test/sqlnetwork/Jdbcnetwork/StmtTest1.java deleted file mode 100644 index bf45afb8..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest1.java +++ /dev/null @@ -1,87 +0,0 @@ -//reate a table and index for that table. Then do (INSERT/UPDATE/DELETE/SELECT) with params statement. -import java.sql.*; -public class StmtTest1 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - cStmt.execute("CREATE INDEX IDX ON T1 ( f1);"); - con.commit(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i+100)); - stmt.executeUpdate(); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 where f1 = ?;"); - ResultSet rs = null; - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - int ret=0; - stmt = con.prepareStatement("UPDATE T1 SET f2 = ? WHERE f1 = ?;"); - for (int i =0 ; i< 10 ; i +=2) { - stmt.setString(1, String.valueOf(i+200)); - stmt.setInt(2, i); - ret = stmt.executeUpdate(); - if (ret != 1) break; - } - stmt.close(); - con.commit(); - - System.out.println("After update, listing tuples:"); - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - con.commit(); - - - - stmt = con.prepareStatement("DELETE FROM T1 WHERE f1 = ?;"); - for (int i =0 ; i< 10 ; i +=3) { - stmt.setInt(1, i); - ret = stmt.executeUpdate(); - if (ret !=1) break; - } - stmt.close(); - con.commit(); - - System.out.println("After delete, listing tuples:"); - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - con.commit(); - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest10.java b/test/sqlnetwork/Jdbcnetwork/StmtTest10.java deleted file mode 100644 index e9a65645..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest10.java +++ /dev/null @@ -1,91 +0,0 @@ -//Create table. At the time of insertion , Insert some record with Null Value -//Check null inserted or not -// Test For setNull() -import java.sql.*; -/** - * - * @author bijaya - */ -public class StmtTest10 { - - public static void main(String[] args) { - - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql://localhost:5678/csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - if(i==2 ) { - stmt.setNull(1,java.sql.Types.INTEGER); - stmt.setNull(2,java.sql.Types.SMALLINT); - stmt.setNull(3,java.sql.Types.TINYINT); - stmt.setNull(4,java.sql.Types.BIGINT); - stmt.setNull(5,java.sql.Types.FLOAT); - stmt.setNull(6,java.sql.Types.CHAR); - stmt.setNull(7,java.sql.Types.DATE); - stmt.setNull(8,java.sql.Types.TIME); - stmt.setNull(9,java.sql.Types.TIMESTAMP); - }else{ - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("India"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - } - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("SELECT * FROM T1 ;"); - ResultSet rs=null; - selStmt.setInt(1,2); - selStmt.setShort(2,(short)3); - selStmt.setByte(3,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - - System.out.print("Tuple value is " + rs.getInt(1)+ " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getShort(2) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getByte(3) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getLong(4) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getFloat(5) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getString(6) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getDate(7) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.print(rs.getTime(8) + " "); - if(rs.wasNull()) System.out.print(" NULL"); - System.out.println(rs.getTimestamp(9) + " "); - if(rs.wasNull()) System.out.println(" NULL"); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest11.java b/test/sqlnetwork/Jdbcnetwork/StmtTest11.java deleted file mode 100644 index 92539755..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest11.java +++ /dev/null @@ -1,53 +0,0 @@ -//select Null test -import java.sql.*; - -/** - * - * @author bijaya - */ -public class StmtTest11{ - - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, NULL);"); - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.executeUpdate(); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 ;"); - ResultSet rs = null; - //selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - int f1=rs.getInt(1); - if(rs.wasNull()) - System.out.print(" NULL"); - else - System.out.print(" "+ f1); - String f2=rs.getString(2); - if(rs.wasNull()) - System.out.println(" NULL"); - else - System.out.println(" "+ f2); - } - rs.close(); - - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } - -} diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest12.java b/test/sqlnetwork/Jdbcnetwork/StmtTest12.java deleted file mode 100644 index 8df0292b..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest12.java +++ /dev/null @@ -1,99 +0,0 @@ -//ExecuteUpdate Should return no of records updated - -import java.sql.Connection; -import java.sql.DriverManager; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.Statement; - -/** - * - * @author bijaya - */ -public class StmtTest12{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - cStmt.execute("CREATE INDEX IDX ON T1 ( f1);"); - con.commit(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, ?);"); - int ret=0; - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.setString(2, String.valueOf(i+100)); - ret=stmt.executeUpdate(); - if (ret != 1){ - System.out.println("ExecuteUpdate doesnot return proper values in Insert "+ret); - break; - } - System.out.println("ExecuteUpdate return proper values in Insert "); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 where f1 = ?;"); - ResultSet rs = null; - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - int a=5; - stmt = con.prepareStatement("UPDATE T1 SET f2 = ? WHERE f1 >5;"); - - stmt.setString(1, String.valueOf(a+200)); - - ret = stmt.executeUpdate(); - if (ret != 4){ - System.out.println("ExecuteUpdate doesnot return proper values for Update "+ret); - } - System.out.println("ExecuteUpdate return proper values fro Update "+ret); - - stmt.close(); - con.commit(); - - System.out.println("After update, listing tuples:"); - for (int i =0 ; i< 10 ; i++) { - selStmt.setInt(1, i); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - } - con.commit(); - - stmt = con.prepareStatement("DELETE FROM T1 ;"); - - - ret = stmt.executeUpdate(); - if (ret !=10) - { - System.out.println("ExecuteUpdate doesnot return proper vslues for Delete "+ret); - } - System.out.println("ExecuteUpdate returns proper vslues for delete "+ret); - - stmt.close(); - con.commit(); - - - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest13.java b/test/sqlnetwork/Jdbcnetwork/StmtTest13.java deleted file mode 100644 index b1e17801..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest13.java +++ /dev/null @@ -1,58 +0,0 @@ -//ExecuteUpdate for SELECT statement it should not return resultset throw exception - -import java.sql.Connection; -import java.sql.DriverManager; -import java.sql.PreparedStatement; -import java.sql.ResultSet; -import java.sql.Statement; - -/** - * - * @author bijaya - */ -public class StmtTest13 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?, NULL);"); - for (int i =0 ; i< 10 ; i++) { - stmt.setInt(1, i); - stmt.executeUpdate(); - } - stmt.close(); - con.commit(); - selStmt = con.prepareStatement("SELECT * from T1 ;"); - ResultSet rs = null; - System.out.println("yes"); - int result = selStmt.executeUpdate(); - /* while (rs.next()) - { - int f1=rs.getInt(1); - if(rs.wasNull()) - System.out.print(" NULL"); - else - System.out.print(" "+ f1); - String f2=rs.getString(2); - if(rs.wasNull()) - System.out.println(" NULL"); - else - System.out.println(" "+ f2); - } - rs.close(); - */ - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(0); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest2.java b/test/sqlnetwork/Jdbcnetwork/StmtTest2.java deleted file mode 100644 index fd22d7f3..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest2.java +++ /dev/null @@ -1,61 +0,0 @@ -//Create a table and index for that table. Then do (INSERT/UPDATE/DELETE/SELECT) with no params statement. -import java.sql.*; -public class StmtTest2 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - cStmt.execute("CREATE INDEX IDX ON T1 ( f1);"); - con.commit(); - - cStmt.execute("INSERT INTO T1 VALUES (1, 'FIRST');"); - cStmt.executeUpdate("INSERT INTO T1 VALUES (2, 'SECOND');"); - con.commit(); - - ResultSet rs = null; - rs = cStmt.executeQuery("SELECT * from T1 where f1 = 1;"); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - - - cStmt.execute("SELECT * from T1 where f1 = 2;"); - rs = cStmt.getResultSet(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - con.commit(); - - cStmt.executeUpdate("UPDATE T1 SET f2 = 'CHANGED' WHERE f1 = 1;"); - con.commit(); - - - - cStmt.executeUpdate("DELETE FROM T1 WHERE f1 = 2;"); - con.commit(); - - System.out.println("After delete, listing tuples:"); - rs = cStmt.executeQuery("SELECT * from T1 ;"); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1)+ " "+ rs.getString(2)); - } - rs.close(); - con.commit(); - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest3.java b/test/sqlnetwork/Jdbcnetwork/StmtTest3.java deleted file mode 100644 index 6885324c..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest3.java +++ /dev/null @@ -1,63 +0,0 @@ -//Open a connection and then close it. After that execute INSERT/QUERY/UPDATE statement. It should fail [StmtTest3.java] -import java.sql.*; -public class StmtTest3 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 char (20));"); - cStmt.execute("CREATE INDEX IDX ON T1 ( f1);"); - con.commit(); - con.close(); - - //after close the connection,execute "INSERT" statement,it should fail - try - { - cStmt.execute("INSERT INTO T1 VALUES (1, 'FIRST');"); - System.exit(1); - } - catch(Exception e) - { - System.out.println("insert exception---" + e.getMessage()); - } - - //after close the connection,execute "QUERY" statement,it should fail - try - { - cStmt.executeQuery("SELECT * from T1 where f1 = 1;"); - System.exit(2); - } - catch(Exception e) - { - System.out.println("query exception---" + e.getMessage()); - } - - //after close the connection,execute "UPDATE" statement,it should fail - try - { - cStmt.executeUpdate("UPDATE T1 SET f2 = 'CHANGED' WHERE f1 = 1;"); - System.exit(3); - } - catch(Exception e) - { - System.out.println("update exception---" + e.getMessage()); - } - - //cleanup - cStmt.close(); - Connection con1 = DriverManager.getConnection("jdbc:csql", "root", "manager"); - Statement cStmt1 = con1.createStatement(); - cStmt1.execute("DROP TABLE T1 ;"); - cStmt1.close(); - con1.close(); - }catch(Exception e) { - System.out.println("Exception in Test: " + e.getMessage()); - e.printStackTrace(); - System.exit(4); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest4.java b/test/sqlnetwork/Jdbcnetwork/StmtTest4.java deleted file mode 100644 index b37524ca..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest4.java +++ /dev/null @@ -1,19 +0,0 @@ -//Open a connection and close it twice. It should give no error -import java.sql.*; -public class StmtTest4 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - con.close(); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - System.exit(1); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest5.java b/test/sqlnetwork/Jdbcnetwork/StmtTest5.java deleted file mode 100644 index 88e67a09..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest5.java +++ /dev/null @@ -1,57 +0,0 @@ -//CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint,f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp); -import java.sql.*; -public class StmtTest5 -{ - public static void main(String[] args) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con = DriverManager.getConnection("jdbc:csql://localhost:5678/csql", "root", "manager"); - Statement cStmt = con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt = null, selStmt= null; - stmt = con.prepareStatement("INSERT INTO T1 VALUES (?,?,?,?,?,?,?,?,?);"); - stmt.setInt(1, 1); - stmt.setShort(2,(short)2); - stmt.setByte(3,(byte)3); - stmt.setLong(4,(long)4); - stmt.setFloat(5,(float)5); - stmt.setString(6, String.valueOf(5)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - stmt.executeUpdate(); - stmt.close(); - con.commit(); - - selStmt = con.prepareStatement("SELECT * from T1 where f1 = ?;"); - ResultSet rs = null; - - selStmt.setInt(1, 1); - rs = selStmt.executeQuery(); - while (rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - } - rs.close(); - selStmt.close(); - - cStmt.execute("DROP TABLE T1 ;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest6.java b/test/sqlnetwork/Jdbcnetwork/StmtTest6.java deleted file mode 100644 index fcbadca1..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest6.java +++ /dev/null @@ -1,63 +0,0 @@ -//select tuple with WHERE clause having param for some fields(SELECT * FROM T1 WHERE f1=?AND f2=? AND f3=?) -import java.sql.*; -public class StmtTest6 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql://localhost:5678/csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Nihar"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("SELECT * FROM T1 where f1 = ? and f2 = ? and f3 = ?"); - ResultSet rs=null; - selStmt.setInt(1,2); - selStmt.setShort(2,(short)3); - selStmt.setByte(3,(byte)4); - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest7.java b/test/sqlnetwork/Jdbcnetwork/StmtTest7.java deleted file mode 100644 index 7758fe39..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest7.java +++ /dev/null @@ -1,93 +0,0 @@ -//update tuple with SET and WHERE clause having params (UPDATE T1 SET f2=?, f8=? WHERE f1=?AND f9=?) -import java.sql.*; -public class StmtTest7 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql://localhost:5678/csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Nihar"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - ret=0; - stmt=con.prepareStatement("UPDATE T1 SET f2=?, f8=? WHERE f1=?AND f9=?;"); - for(int i=0;i<10;i++) - { - stmt.setShort(1,(short)100); - stmt.setTime(2,Time.valueOf("19:38:25")); - stmt.setInt(3,3); - stmt.setTimestamp(4,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - rs=null; - rs=selStmt.executeQuery(); - System.out.println(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest8.java b/test/sqlnetwork/Jdbcnetwork/StmtTest8.java deleted file mode 100644 index c58ceb7e..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest8.java +++ /dev/null @@ -1,64 +0,0 @@ -//NULL Tset "INSERT null values to some fields with and without parameters" -import java.sql.*; -public class StmtTest8 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql://localhost:5678/csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1(f1,f3,f5,f6,f7,f8,f9) VALUES(?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setByte(2,(byte)(i+2)); - stmt.setFloat(3,(float)1000+i); - stmt.setString(4, String.valueOf("Nihar"+i)); - stmt.setDate(5,Date.valueOf("2008-03-21")); - stmt.setTime(6,Time.valueOf("18:00:00")); - stmt.setTimestamp(7,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - con.commit(); - stmt=con.prepareStatement("INSERT INTO T1(f1,f2,f4,f6,f7,f8,f9) values(10,11,101,'Nihar10','2008-03-21','18:00:00','2008-03-21 18:00:00');"); - stmt.executeUpdate(); - - stmt.close(); - con.commit(); - - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/sqlnetwork/Jdbcnetwork/StmtTest9.java b/test/sqlnetwork/Jdbcnetwork/StmtTest9.java deleted file mode 100644 index 45281a0b..00000000 --- a/test/sqlnetwork/Jdbcnetwork/StmtTest9.java +++ /dev/null @@ -1,93 +0,0 @@ -//update tuple with SET and WHERE clause having params (UPDATE T1 SET f2=NULL, f6=NULL WHERE f1=?AND f9=?) -import java.sql.*; -public class StmtTest9 -{ - public static void main(String[] arg) - { - try - { - Class.forName("csql.jdbc.JdbcSqlDriver"); - Connection con=DriverManager.getConnection("jdbc:csql://localhost:5678/csql","root","manager"); - Statement cStmt=con.createStatement(); - cStmt.execute("CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint, f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp);"); - con.commit(); - PreparedStatement stmt=null,selStmt=null; - stmt=con.prepareStatement("INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?);"); - int ret=0; - for(int i=0;i<10;i++) - { - stmt.setInt(1,i); - stmt.setShort(2,(short)(i+1)); - stmt.setByte(3,(byte)(i+2)); - stmt.setLong(4,(long)i); - stmt.setFloat(5,(float)1000+i); - stmt.setString(6, String.valueOf("Nihar"+i)); - stmt.setDate(7,Date.valueOf("2008-03-21")); - stmt.setTime(8,Time.valueOf("18:00:00")); - stmt.setTimestamp(9,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - ResultSet rs=null; - rs=selStmt.executeQuery(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - ret=0; - stmt=con.prepareStatement("UPDATE T1 SET f2=NULL, f5=NULL WHERE f1=?AND f9=?;"); - for(int i=0;i<10;i++) - { - //stmt.setShort(1,(short)null); - //stmt.setTime(2,null); - stmt.setInt(1,3); - stmt.setTimestamp(2,Timestamp.valueOf("2008-03-21 18:00:00")); - ret=stmt.executeUpdate(); - if(ret!=1) break; - } - stmt.close(); - con.commit(); - selStmt=con.prepareStatement("Select * from T1"); - rs=null; - rs=selStmt.executeQuery(); - System.out.println(); - while(rs.next()) - { - System.out.println("Tuple value is " + rs.getInt(1) + " "+ - rs.getShort(2) + " "+ - rs.getByte(3) + " "+ - rs.getLong(4) + " "+ - rs.getFloat(5) + " "+ - rs.getString(6) + " "+ - rs.getDate(7) + " "+ - rs.getTime(8) + " "+ - rs.getTimestamp(9) + " " - ); - - } - rs.close(); - con.commit(); - cStmt.executeUpdate("Drop table T1;"); - con.close(); - }catch(Exception e) { - System.out.println("Exception in Test: "+e); - e.printStackTrace(); - } - } -} - diff --git a/test/sqlnetwork/Jdbcnetwork/test001.ksh b/test/sqlnetwork/Jdbcnetwork/test001.ksh deleted file mode 100755 index df45bd92..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test001.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Connect with connect string "jdbc:csql:lllocalhost:5678/csql" and give correct "user" and "password" in properties object. It should pass. -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest1 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test002.ksh b/test/sqlnetwork/Jdbcnetwork/test002.ksh deleted file mode 100755 index e8382c5b..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test002.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Connect with connect string "jdbc:csql:lllocalhost:5678/csql" and null for username and password. It should fail. -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest2 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test003.ksh b/test/sqlnetwork/Jdbcnetwork/test003.ksh deleted file mode 100755 index 4ec43615..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test003.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# Connect only with connect string "jdbc:csql://localhost:5678/csql" and no username and password. It should fail. -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java -Xms256m -Xmx256m ConnTest3 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test004.ksh b/test/sqlnetwork/Jdbcnetwork/test004.ksh deleted file mode 100755 index 7c8be9c6..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test004.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Connect with connect string "jdbc:sql://localhost:5678/csql" and give correct "user" and "password" in properties object. It should fail. -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest4 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test005.ksh b/test/sqlnetwork/Jdbcnetwork/test005.ksh deleted file mode 100755 index 80a57023..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test005.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Connect with connectstring "odbc:csql://localhost:5678/csql" and give correct "user" and "password" in properties object. It should fail. -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest5 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test006.ksh b/test/sqlnetwork/Jdbcnetwork/test006.ksh deleted file mode 100755 index 11c43919..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test006.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Connect with connectstring "jdbc:csql://localhost:5678/csql" and give incorrect "user" and "password" in properties object. It should fail. -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest6 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test007.ksh b/test/sqlnetwork/Jdbcnetwork/test007.ksh deleted file mode 100755 index afb0e9eb..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test007.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Connect with connectstring "jdbc:csql://localhost:5678/csql" and give correct "user" and incorrect "password" in properties object. It should fail. -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest1 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test008.ksh b/test/sqlnetwork/Jdbcnetwork/test008.ksh deleted file mode 100755 index 44d06a4d..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test008.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Connect with "jdbc:csql:5678:localhost:csql" and give correct "user" and "password" in properties object. It should fail -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest8 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test009.ksh b/test/sqlnetwork/Jdbcnetwork/test009.ksh deleted file mode 100755 index eadf5fc9..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test009.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# Connect with connectstring "jdbc:csql://localhost:5678/csql" and with very long username and "password" in properties object. It should fail but no overflow -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest9 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test010.ksh b/test/sqlnetwork/Jdbcnetwork/test010.ksh deleted file mode 100755 index b4bb832b..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test010.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# Connect with "jdbc:csql://5678:localhost/csql" and give correct "user" and "password" in properties object. It should fail -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest10 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test011.ksh b/test/sqlnetwork/Jdbcnetwork/test011.ksh deleted file mode 100755 index 646b847e..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test011.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# Connect with "jdbc:csql://localhost:5678" and give correct "user" and "password" in properties object. It should pass as for csql default database is csql -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest11 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test012.ksh b/test/sqlnetwork/Jdbcnetwork/test012.ksh deleted file mode 100755 index 8a0fc599..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test012.ksh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/sh -#Connect with "jdbc:csql://local/host:5678/csql" and give correct "user" and "password" in properties object. It should fail - -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest12 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test013.ksh b/test/sqlnetwork/Jdbcnetwork/test013.ksh deleted file mode 100755 index 9350ed5a..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test013.ksh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/sh -#Connect with "jdbc:csql:localhost:5678" and give correct "user" and "password" in properties object. It should fail - -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest13 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test014.ksh b/test/sqlnetwork/Jdbcnetwork/test014.ksh deleted file mode 100755 index f00bf38e..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test014.ksh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/sh -#Connect with "jdbc:csql://localhost:5678csql" and give correct "user" and "password" in properties object. It should fail - -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest14 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test015.ksh b/test/sqlnetwork/Jdbcnetwork/test015.ksh deleted file mode 100755 index cfb207a4..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test015.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Connect with "jdbc:csql//localhost:5678/csql" and give correct "user" and "password" in properties object. It should fail -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest15 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test016.ksh b/test/sqlnetwork/Jdbcnetwork/test016.ksh deleted file mode 100755 index 55e62cb7..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test016.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Try to open , close , open . it should pass -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest16 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test017.ksh b/test/sqlnetwork/Jdbcnetwork/test017.ksh deleted file mode 100755 index 91c250c3..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test017.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Close the connection and they call commit(). It should fail. -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest17 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test018.ksh b/test/sqlnetwork/Jdbcnetwork/test018.ksh deleted file mode 100755 index 811b6036..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test018.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Close the connection and then call createStatement(). It should fail. -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest18 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test019.ksh b/test/sqlnetwork/Jdbcnetwork/test019.ksh deleted file mode 100755 index 11cad031..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test019.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# Close the connection and then call preparedStatement(). It should fail -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest19 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test020.ksh b/test/sqlnetwork/Jdbcnetwork/test020.ksh deleted file mode 100755 index 197876f9..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test020.ksh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/sh -#Open the connection and then call isClosed(). It should return false. -#Close the connection and then call isClosed(). It should return true. -TESTFILE=${PWD}/jdbc/Connection/ConnTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/jdbc/Connection -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java ConnTest20 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test021.ksh b/test/sqlnetwork/Jdbcnetwork/test021.ksh deleted file mode 100755 index ff511de0..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test021.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# Create a table and index for that table. Then do (INSERT/UPDATE/DELETE/SELECT) with params statement. -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest1 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test022.ksh b/test/sqlnetwork/Jdbcnetwork/test022.ksh deleted file mode 100755 index e5302593..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test022.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# Create a table and index for that table. Then do (INSERT/UPDATE/DELETE/SELECT) with no params statement. -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest2 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test023.ksh b/test/sqlnetwork/Jdbcnetwork/test023.ksh deleted file mode 100755 index 3ce71b69..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test023.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -#Open a connection and then close it. After that execute INSERT/QUERY/UPDATE statement. It should fail [StmtTest3.java] -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest3 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test024.ksh b/test/sqlnetwork/Jdbcnetwork/test024.ksh deleted file mode 100755 index 91fcf607..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test024.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# Open a connection and close it twice. It should give no error -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest4 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test025.ksh b/test/sqlnetwork/Jdbcnetwork/test025.ksh deleted file mode 100755 index e829217e..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test025.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# CREATE TABLE T1 (f1 integer, f2 smallint, f3 tinyint,f4 bigint, f5 float, f6 char(10), f7 date, f8 time, f9 timestamp); -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest5 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test026.ksh b/test/sqlnetwork/Jdbcnetwork/test026.ksh deleted file mode 100755 index 25d164ea..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test026.ksh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/sh -# select tuple with WHERE clause having param for some fields(SELECT * FROM T1 WHERE f1=?AND f2=? AND f3=?) -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest6.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -echo "SELECT * FROM T1 WHERE f1=?AND f2=? AND f3=?" -java StmtTest6 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test027.ksh b/test/sqlnetwork/Jdbcnetwork/test027.ksh deleted file mode 100755 index 8d6f84c6..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test027.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# update tuple with SET and WHERE clause having params (UPDATE T1 SET f2=?, f8=? WHERE f1=?AND f9=?) -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest7.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest7 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test028.ksh b/test/sqlnetwork/Jdbcnetwork/test028.ksh deleted file mode 100755 index 76d4456e..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test028.ksh +++ /dev/null @@ -1,15 +0,0 @@ -#!/bin/sh -# NULL Tset INSERT null values to some fields with and without parameters -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest8.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest8 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test029.ksh b/test/sqlnetwork/Jdbcnetwork/test029.ksh deleted file mode 100755 index 52b8f6b6..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test029.ksh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/sh -# update tuple with SET and WHERE clause having params (UPDATE T1 SET f2=NULL, f6=NULL WHERE f1=?AND f9=?) - -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest9.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest9 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test030.ksh b/test/sqlnetwork/Jdbcnetwork/test030.ksh deleted file mode 100755 index fa9f9fe6..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test030.ksh +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh -# Create table. At the time of insertion , Insert some record with Null Value -# Check null inserted or not -# Test For setNull() - - -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest10 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test031.ksh b/test/sqlnetwork/Jdbcnetwork/test031.ksh deleted file mode 100755 index 2bab95e2..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test031.ksh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/sh -# select Null test - -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest11 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test032.ksh b/test/sqlnetwork/Jdbcnetwork/test032.ksh deleted file mode 100755 index 9d6138be..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test032.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# ExecuteUpdate Should return no of records updated - - -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest12 -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/sqlnetwork/Jdbcnetwork/test033.ksh b/test/sqlnetwork/Jdbcnetwork/test033.ksh deleted file mode 100755 index 59830cf8..00000000 --- a/test/sqlnetwork/Jdbcnetwork/test033.ksh +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh -# ExecuteUpdate for SELECT statement it should not return resultset throw exception - - -TESTFILE=${PWD}/sqlnetwork/Jdbcnetwork/StmtTest1.java -REL_PATH=. -if [ -s "$TESTFILE" ] -then - REL_PATH=`pwd`/sqlnetwork/Jdbcnetwork -fi -export CLASSPATH=$CLASSPATH:${REL_PATH} -java StmtTest13 -if [ $? -ne 0 ] -then - echo "Drop table T1;"| $CSQL_INSTALL_ROOT/bin/csql - exit 1; -fi -echo "Drop table T1;"| $CSQL_INSTALL_ROOT/bin/csql -exit 0; diff --git a/test/sqlnetwork/Parameter/Makefile b/test/sqlnetwork/Parameter/Makefile deleted file mode 100644 index 72913541..00000000 --- a/test/sqlnetwork/Parameter/Makefile +++ /dev/null @@ -1,54 +0,0 @@ -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -g -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/install/include -I../../../include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlsql -lcsql -lcsqlsqllog -lcsqlnw -lcacheload -lcsqlsqlnw -lcsqlsqlnw - -TARGETS = \ - test001\ - test002\ - test003\ - test004\ - test100 - - - - - - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -.c.o:.c - $(CPlus) $(CPlusFlags) $(INCL) -c -o $@ $< - -test001: paratest1.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test002:paratest2.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test003:paratest3.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test004:paratest4.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test100 :paratest100.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - -clean: - rm -f *.o ${TARGETS} diff --git a/test/sqlnetwork/Parameter/exp.test001 b/test/sqlnetwork/Parameter/exp.test001 deleted file mode 100644 index 9e494b89..00000000 --- a/test/sqlnetwork/Parameter/exp.test001 +++ /dev/null @@ -1,207 +0,0 @@ -NW:TCP connecting -Response from peer site is 1 -NW:TCP Send -Sent bytes 16 -Sent bytes 256 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 130 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table created -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 48 -NW:TCP receive -HEADER says packet type is 103 -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -Total rows inserted 10 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 22 -NW:TCP receive -HEADER says packet type is 104 -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=0 | F2=1234 | F3=12345678 | F4=0.500000 | F5=12345.500000 | F6:DATE=2000-1-1 | F7:TIME= 1: 1: 1 | F8:TIMESTAMP=2000- 1- 1 1: 1: 1 | F9=string0 | F10=ABCDEF00 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=1 | F2=1235 | F3=12345679 | F4=1.500000 | F5=12346.500000 | F6:DATE=2001-2-2 | F7:TIME= 2: 2: 2 | F8:TIMESTAMP=2001- 2- 2 2: 2: 2 | F9=string1 | F10=ABCDEF10 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=2 | F2=1236 | F3=12345680 | F4=2.500000 | F5=12347.500000 | F6:DATE=2002-3-3 | F7:TIME= 3: 3: 3 | F8:TIMESTAMP=2002- 3- 3 3: 3: 3 | F9=string2 | F10=ABCDEF20 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=3 | F2=1237 | F3=12345681 | F4=3.500000 | F5=12348.500000 | F6:DATE=2003-4-4 | F7:TIME= 4: 4: 4 | F8:TIMESTAMP=2003- 4- 4 4: 4: 4 | F9=string3 | F10=ABCDEF30 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=4 | F2=1238 | F3=12345682 | F4=4.500000 | F5=12349.500000 | F6:DATE=2004-5-5 | F7:TIME= 5: 5: 5 | F8:TIMESTAMP=2004- 5- 5 5: 5: 5 | F9=string4 | F10=ABCDEF40 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=5 | F2=1239 | F3=12345683 | F4=5.500000 | F5=12350.500000 | F6:DATE=2005-6-6 | F7:TIME= 6: 6: 6 | F8:TIMESTAMP=2005- 6- 6 6: 6: 6 | F9=string5 | F10=ABCDEF50 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=6 | F2=1240 | F3=12345684 | F4=6.500000 | F5=12351.500000 | F6:DATE=2006-7-7 | F7:TIME= 7: 7: 7 | F8:TIMESTAMP=2006- 7- 7 7: 7: 7 | F9=string6 | F10=ABCDEF60 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=7 | F2=1241 | F3=12345685 | F4=7.500000 | F5=12352.500000 | F6:DATE=2007-8-8 | F7:TIME= 8: 8: 8 | F8:TIMESTAMP=2007- 8- 8 8: 8: 8 | F9=string7 | F10=ABCDEF70 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=8 | F2=1242 | F3=12345686 | F4=8.500000 | F5=12353.500000 | F6:DATE=2008-9-9 | F7:TIME= 9: 9: 9 | F8:TIMESTAMP=2008- 9- 9 9: 9: 9 | F9=string8 | F10=ABCDEF80 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=9 | F2=1243 | F3=12345687 | F4=9.500000 | F5=12354.500000 | F6:DATE=2009-10-10 | F7:TIME=10:10:10 | F8:TIMESTAMP=2009-10-10 10:10:10 | F9=string9 | F10=ABCDEF90 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -Total row fetched=10 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 19 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table dropped -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP disconnect kishor 5678 -Sent bytes 16 -NW:TCP receive diff --git a/test/sqlnetwork/Parameter/exp.test002 b/test/sqlnetwork/Parameter/exp.test002 deleted file mode 100644 index 4ce29b7f..00000000 --- a/test/sqlnetwork/Parameter/exp.test002 +++ /dev/null @@ -1,208 +0,0 @@ -NW:TCP connecting -Response from peer site is 1 -NW:TCP Send -Sent bytes 16 -Sent bytes 256 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 133 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table created -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -HEADER says packet type is 103 -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -Total rows inserted 10 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 125 -NW:TCP receive -HEADER says packet type is 103 -HEADER says packet type is 104 -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=10 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -10 Tuples fetched -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 19 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table dropped -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP disconnect kishor 5678 -Sent bytes 16 -NW:TCP receive diff --git a/test/sqlnetwork/Parameter/exp.test003 b/test/sqlnetwork/Parameter/exp.test003 deleted file mode 100644 index 839accb8..00000000 --- a/test/sqlnetwork/Parameter/exp.test003 +++ /dev/null @@ -1,227 +0,0 @@ -NW:TCP connecting -Response from peer site is 1 -NW:TCP Send -Sent bytes 16 -Sent bytes 256 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 133 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table T1 created -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -HEADER says packet type is 103 -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -Total rows inserted 10 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 125 -NW:TCP receive -HEADER says packet type is 103 -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -Total row deleted=5 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 22 -NW:TCP receive -HEADER says packet type is 104 -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=0 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=1 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=2 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=3 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=4 | F2=1 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2007-1-21 | TIME=12:29:30 | TIMESTAMP=2007-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -Total row fetched=5 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 19 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table dropped -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP disconnect kishor 5678 -Sent bytes 16 -NW:TCP receive diff --git a/test/sqlnetwork/Parameter/exp.test004 b/test/sqlnetwork/Parameter/exp.test004 deleted file mode 100644 index 7a125e1b..00000000 --- a/test/sqlnetwork/Parameter/exp.test004 +++ /dev/null @@ -1,258 +0,0 @@ -NW:TCP connecting -Response from peer site is 1 -NW:TCP Send -Sent bytes 16 -Sent bytes 256 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 133 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table created -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -HEADER says packet type is 103 -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 89 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -10 Rows inserted -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 67 -NW:TCP receive -HEADER says packet type is 103 -NW:TCP Send -Sent bytes 16 -Sent bytes 77 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 77 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 77 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 77 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 77 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -5 Rows updated -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 22 -NW:TCP receive -HEADER says packet type is 104 -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=0 | F2=11 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB120000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=1 | F2=12 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB120000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=2 | F2=13 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB120000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=3 | F2=14 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB120000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=4 | F2=15 | F3=lakshya | F4=11.220000 | F5=20.250000 | DATE=2007-3-30 | TIME=12:29:30 | TIMESTAMP=2007-3-30 10:25:55 | F9=20 | F10=15000 | AB120000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 - -F1=5 | F2=16 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=6 | F2=17 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=7 | F2=18 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=8 | F2=19 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=9 | F2=20 | F3=jitendra | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 | 23FE0000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -10 Rows fetched=4 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 19 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table dropped -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP disconnect kishor 5678 -Sent bytes 16 -NW:TCP receive diff --git a/test/sqlnetwork/Parameter/paratest1.c b/test/sqlnetwork/Parameter/paratest1.c deleted file mode 100644 index 2a0ddbeb..00000000 --- a/test/sqlnetwork/Parameter/paratest1.c +++ /dev/null @@ -1,170 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * noOfParamFields() should return 10. - * getParamFldInfo() for all fields and print the field info. - * select * from T1; - - * Author : Jitendra Lenka. - */ - -#include -#include -#include -#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con= new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 SMALLINT,F2 INT, F3 BIGINT, F4 FLOAT, F5 DOUBLE, F6 DATE,F7 TIME,F8 TIMESTAMP,F9 CHAR(30), F10 BINARY(4));"); - - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - printf("Table created\n"); - - // insert into table - - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?);"); - short f1var = 100; - int f2var = 10; - long long f3var = 12000; - float f4var = 5.5; - double f5var = 123.45; - Date f6var; - f6var.set(2007,01,21); - Time f7var; - f7var.set(12,29,30); - TimeStamp f8var; - f8var.setDate(2007,01,21); - f8var.setTime(12,29,30); - char f9var[31]="jitendra"; - char f10var[8]="abcdef"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } -//****************************************************************************** -/* int nop; - nop = stmt->noOfParamFields(); - printf("noOfParamField Returns=%d\n",nop); - - - //getParamFldInfo() - FieldInfo *field = new FieldInfo(); - - - char fldName[20]; - DataType type; - size_t length; - int offset; - char defaultValueBuf[10]; - bool isNull; - bool isDefault; - - for(int i=1;i<=11;i++) - { - printf("\n***********************************************\n"); - printf("%d FIELD INFORMATION ::\n",i);; - rv = stmt->getParamFldInfo(i,field); - if(rv!=OK)return 1; - printf("Field Name :%s\n", field->fldName); - printf("Data type of the field :%d\n",field->type); - printf("length of the field :%d\n",field->length); - printf("Offset :%d\n",field->offset); - printf("Default value :%s\n",field->defaultValueBuf); - printf("Null field :%d\n",field->isNull); - printf("Default value :%d\n",field->isDefault); - printf("***********************************************\n"); - } - */ - int count=0; - - for(int i=0;i<10;i++) { - rv = con->beginTrans(); - if(rv!=OK) break; - f1var=i; - f2var= 1234+i; - f3var= 12345678+i; - f4var = 0.5 + i; - f5var = 12345.5 + i; - f6var.set(2000 + i, i + 1, i + 1); - f7var.set(i+1, i+1, i+1); - f8var.setDate(2000 + i, i + 1, i + 1); - f8var.setTime(i+1, i+1, i+1); - sprintf(f9var, "string%d", i); - sprintf(f10var, "abcdef%d", i); - stmt->setShortParam(1,f1var); - stmt->setIntParam(2,f2var); - stmt->setLongLongParam(3, f3var); - stmt->setFloatParam(4,f4var); - stmt->setDoubleParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setStringParam(9,f9var); - stmt->setBinaryParam(10,f10var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("Total rows inserted %d\n",count); - - //********************************************************** - - - // SELECT * FROM T1; - - strcpy(statement,"SELECT * FROM T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 5; } - - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,&f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,f9var); - stmt->bindField(10,f10var); - count=0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch(rv) !=NULL) - { - printf("F1=%hd | F2=%d | F3=%lld | F4=%f | F5=%lf | F6:DATE=%0d-%0d-%0d | F7:TIME=%2d:%2d:%2d | F8:TIMESTAMP=%4d-%2d-%2d %2d:%2d:%2d | F9=%s ",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var); - printf("| F10="); - AllDataType::printVal(f10var, typeBinary, 4); - printf("\n"); - count++; - } - stmt->close(); - rv = con->commit(); - if(rv !=OK) { delete stmt; delete con; return 7; } - printf("Total row fetched=%d\n",count); - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 8; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 9; } - printf("Table dropped\n"); - - delete stmt; - delete con; - return 0; -} diff --git a/test/sqlnetwork/Parameter/paratest100.c b/test/sqlnetwork/Parameter/paratest100.c deleted file mode 100644 index b7d4c869..00000000 --- a/test/sqlnetwork/Parameter/paratest100.c +++ /dev/null @@ -1,189 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * update T1 WITH ALL 7 PARAMETERS. - noOfParamFields() should return 7. - * select * from T1; - - * Author : Jitendra Lenka. - */ -#include -#include -#include -#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con= new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT);"); - - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 1; } - - printf("Table created\n"); - - // insert into table - - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?);"); - - int f1var = 0; - short int f2var = 10; - char f3var[31]="jitendra"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2008,01,21); - - Time f7var; - f7var.set(12,29,30); - - TimeStamp f8var; - f8var.setDate(2008,01,21); - f8var.setTime(12,29,30); - - int f9var = 20; - long long f10var = 12000; - - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - - int count=0; - - for(int i=0;i<10;i++) - { - rv = con->beginTrans(); - if(rv!=OK) break; - f1var=i; - f2var++; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d Rows inserted \n",count); - - //********************************************************** - // UPDATE TABLE - - strcpy(statement,"UPDATE T1 SET F10=?,F8=?,F6=?,F5=?,F4=?,F3=? WHERE F2=?;"); - rv = stmt->prepare(statement); - - // int nop; - // nop = stmt->noOfParamFields(); - // printf("noOfParamFields return=%d\n",nop); - // if(nop!=7)return 1; - - long long f10var1=15000; - TimeStamp f8var1; - f8var1.setDate(2007,3,30); - f8var1.setTime(10,25,55); - - Date f6var1; - f6var1.set(2007,3,30); - - float f5var1=20.25; - float f4var1=11.22; - char f3var1[10]="lakshya"; - - short int f2var1=10; - count=0; - - for(int i=0;i<5;i++) - { - - f2var1++; - f5var1++; - f4var1++; - rv = con->beginTrans(); - if(rv!=OK)break; - - stmt->setShortParam(7,f2var1); - stmt->setLongLongParam(1,f10var1); - stmt->setTimeStampParam(2,f8var1); - stmt->setDateParam(3,f6var1); - stmt->setFloatParam(4,f5var1); - stmt->setFloatParam(5,f4var1); - stmt->setStringParam(6,f3var1); - - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - - printf("%d Rows updated\n",count); - - //********************************************************** - // SELECT * FROM T1; - - strcpy(statement,"SELECT * FROM T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 5; } - - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - - count=0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch() !=NULL) - { - if(f1var==5)printf("\n"); - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld \n",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - - - count++; - } - - stmt->close(); - rv = con->commit(); - if(rv !=OK) { delete stmt; delete con; return 7; } - - printf("%d Rows fetched=%d\n",count); - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 8; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 9; } - printf("Table dropped\n"); - - delete stmt; - delete con; - return 0; -} diff --git a/test/sqlnetwork/Parameter/paratest2.c b/test/sqlnetwork/Parameter/paratest2.c deleted file mode 100644 index 6dd1bd7f..00000000 --- a/test/sqlnetwork/Parameter/paratest2.c +++ /dev/null @@ -1,166 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * select * from T1 with where clause; - */ - -#include -#include -#include -#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con= new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT, F11 BINARY(4));"); - - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - - printf("Table created\n"); - - // insert into table - - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?,?);"); - - int f1var = 100; - short int f2var = 10; - char f3var[31]="jitendra"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2007,01,21); - - Time f7var; - f7var.set(12,29,30); - - TimeStamp f8var; - f8var.setDate(2007,01,21); - f8var.setTime(12,29,30); - - int f9var = 20; - long long f10var = 12000; - char f11var[8]="23fe"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 3; } - - int count=0; - - for(int i=0;i<10;i++) - { - rv = con->beginTrans(); - if(rv!=OK) break; - - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - stmt->setBinaryParam(11,f11var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("Total rows inserted %d\n",count); - - - //********************************************************** - - // SELECT * FROM T1; - strcpy(statement,"SELECT * FROM T1 WHERE F1=? AND F2=? AND F3=? AND F4=? AND F5=? AND F6=? AND F7=? AND F8=? AND F9=? AND F10=? AND F11=?;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - stmt->bindField(11,f11var); - int f1var1=100; - short int f2var1=10; - char f3var1[20]="jitendra"; - float f4var1=5.5; - float f5var1=10.50; - Date f6var1; - f6var1.set(2007,1,21); - - Time f7var1; - f7var1.set(12,29,30); - - TimeStamp f8var1; - f8var1.setDate(2007,1,21); - f8var1.setTime(12,29,30); - - int f9var1=20; - long long f10var1=12000; - char f11var1[8]="23fe"; - count=0; - - rv = con->beginTrans(); - if(rv!=OK)return 5; - stmt->setIntParam(1,f1var1); - stmt->setShortParam(2,f2var1); - stmt->setStringParam(3,f3var1); - stmt->setFloatParam(4,f4var1); - stmt->setFloatParam(5,f5var1); - stmt->setDateParam(6,f6var1); - stmt->setTimeParam(7,f7var1); - stmt->setTimeStampParam(8,f8var1); - stmt->setIntParam(9,f9var1); - stmt->setLongLongParam(10,f10var1); - stmt->setBinaryParam(11,f11var1); - - stmt->execute(rows); - - while(stmt->fetch(rv)!=NULL) - { - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - printf(" | "); - AllDataType::printVal(f11var,typeBinary,4); - printf("\n"); - count++; - } - stmt->close(); - - rv = con->commit(); - if(rv!=OK)return 6; - - printf("%d Tuples fetched\n",count); - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK){delete stmt; delete con; return -1;} - - rv = stmt->execute(rows); - if(rv!=OK){delete stmt;delete con;return -1;} - - printf("Table dropped\n"); - - delete stmt; - delete con; - return 0; -} diff --git a/test/sqlnetwork/Parameter/paratest3.c b/test/sqlnetwork/Parameter/paratest3.c deleted file mode 100644 index 4a5fd173..00000000 --- a/test/sqlnetwork/Parameter/paratest3.c +++ /dev/null @@ -1,192 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * delete records from T1 with where clause - * select * from T1; - - * Author : Jitendra Lenka. - */ - -#include -#include -#include - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT, F11 BINARY(4));"); - - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - printf("Table T1 created\n"); - - // insert into table - - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?,?);"); - - int f1var = 0; - short int f2var = 1; - char f3var[31]="jitendra"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2007,01,21); - - Time f7var; - f7var.set(12,29,30); - - TimeStamp f8var; - f8var.setDate(2007,01,21); - f8var.setTime(12,29,30); - - int f9var = 20; - long long f10var = 12000; - char f11var[8]="23fe"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - - int count=0; - - for(int i=0;i<10;i++) - { - rv = con->beginTrans(); - if(rv!=OK) break; - f1var=i; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - stmt->setBinaryParam(11,f11var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("Total rows inserted %d\n",count); - - - //********************************************************* - // delete records from the T1 - strcpy(statement,"DELETE FROM T1 WHERE F10=? AND F9=? AND F8=? AND F7=? AND F6=? AND F5=? AND F4=? AND F3=? AND F2=? AND F1=? AND F11=? ;"); - - rv = stmt->prepare(statement); - if(rv!=OK){delete stmt;delete con;return -1;} - - short int f2var1=1; - char f3var1[20] ="jitendra"; - float f4var1 = 5.5; - float f5var1 = 10.50; - Date f6var1; - f6var1.set(2007,1,21); - - Time f7var1; - f7var1.set(12,29,30); - - TimeStamp f8var1; - f8var1.setDate(2007,1,21); - f8var1.setTime(12,29,30); - - int f9var1=20; - long long f10var1=12000; - char f11var1[8]="23fe"; - count=0; - - for(int i=5;i<10;i++) - { - rv = con->beginTrans(); - if(rv!=OK)break; - - stmt->setLongLongParam(1,f10var1); - stmt->setIntParam(2,f9var1); - stmt->setTimeStampParam(3,f8var1); - stmt->setTimeParam(4,f7var1); - stmt->setDateParam(5,f6var1); - stmt->setFloatParam(6,f5var1); - stmt->setFloatParam(7,f4var1); - stmt->setStringParam(8,f3var1); - stmt->setShortParam(9,f2var1); - stmt->setIntParam(10,i); - stmt->setBinaryParam(11,f11var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("Total row deleted=%d\n",count); - - - - - //********************************************************** - - // SELECT * FROM T1; - strcpy(statement,"SELECT * FROM T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 5; } - - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - stmt->bindField(11,f11var); - count=0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch() !=NULL) - { - - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld ",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - printf(" | "); - AllDataType::printVal(f11var,typeBinary,4); - printf("\n"); - count++; - } - - stmt->close(); - rv = con->commit(); - if(rv !=OK) - { delete stmt; delete con; return 7; } - - printf("Total row fetched=%d\n",count); - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 8; } - rv = stmt->execute(rows); - if(rv!=OK) - { delete stmt; delete con; return 9; } - printf("Table dropped\n"); - - delete stmt; - delete con; - return 0; -} diff --git a/test/sqlnetwork/Parameter/paratest4.c b/test/sqlnetwork/Parameter/paratest4.c deleted file mode 100644 index 8fe56747..00000000 --- a/test/sqlnetwork/Parameter/paratest4.c +++ /dev/null @@ -1,198 +0,0 @@ -/* create table T1 with 10 fields. - * insert some records into it. - * update T1 WITH ALL 8 PARAMETERS. - noOfParamFields() should return 8. - * select * from T1; - - * Author : Jitendra Lenka. - */ - -#include -#include -#include -#include -#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT, F11 BINARY(4));"); - - int rows = 0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 1; } - - printf("Table created\n"); - - // insert into table - - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?,?);"); - - int f1var = 0; - short int f2var = 10; - char f3var[31]="jitendra"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2008,01,21); - - Time f7var; - f7var.set(12,29,30); - - TimeStamp f8var; - f8var.setDate(2008,01,21); - f8var.setTime(12,29,30); - - int f9var = 20; - long long f10var = 12000; - char f11var[8]="23fe"; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - - int count=0; - - for(int i=0;i<10;i++) - { - rv = con->beginTrans(); - if(rv!=OK) break; - f1var=i; - f2var++; - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - stmt->setBinaryParam(11,f11var); - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d Rows inserted \n",count); - - - //********************************************************** - // UPDATE TABLE - - strcpy(statement,"UPDATE T1 SET F10=?,F8=?,F6=?,F5=?,F4=?,F3=?,F11=? WHERE F2=?;"); - rv = stmt->prepare(statement); - if(rv!=OK) { printf("prepare failed\n"); delete stmt; delete con; return 5; } - - //int nop; - //nop = stmt->noOfParamFields(); - //printf("noOfParamFields return=%d\n",nop); - //if(nop!=8)return 1; - - long long f10var1=15000; - TimeStamp f8var1; - f8var1.setDate(2007,3,30); - f8var1.setTime(10,25,55); - - Date f6var1; - f6var1.set(2007,3,30); - - float f5var1=20.25; - float f4var1=11.22; - char f3var1[10]="lakshya"; - char f11var1[8]="ab12"; - short int f2var1=10; - count=0; - - for(int i=0;i<5;i++) - { - - rv = con->beginTrans(); - if(rv!=OK)break; - - f2var1++; - stmt->setShortParam(8,f2var1); - stmt->setLongLongParam(1,f10var1); - stmt->setTimeStampParam(2,f8var1); - stmt->setDateParam(3,f6var1); - stmt->setFloatParam(4,f5var1); - stmt->setFloatParam(5,f4var1); - stmt->setStringParam(6,f3var1); - stmt->setBinaryParam(7,f11var1); - - //stmt->setShortParam(7,f2var1); - - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - - printf("%d Rows updated\n",count); - - //********************************************************** - // SELECT * FROM T1; - - strcpy(statement,"SELECT * FROM T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 5; } - - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - stmt->bindField(11,f11var); - count=0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch() !=NULL) - { - if(f1var==5)printf("\n"); - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - printf(" | "); - AllDataType::printVal(f11var,typeBinary,4); - printf("\n"); - - - count++; - } - - stmt->close(); - rv = con->commit(); - if(rv !=OK) { delete stmt; delete con; return 7; } - - printf("%d Rows fetched=%d\n",count); - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 8; } - rv = stmt->execute(rows); - if(rv!=OK) - { delete stmt; delete con; return 9; } - printf("Table dropped\n"); - - delete stmt; - delete con; - return 0; -} diff --git a/test/sqlnetwork/Select/Makefile b/test/sqlnetwork/Select/Makefile deleted file mode 100644 index 2c578684..00000000 --- a/test/sqlnetwork/Select/Makefile +++ /dev/null @@ -1,66 +0,0 @@ -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -g -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/install/include -I../../../include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsqlsql -lcsql -lcsqlsqllog -lcsqlnw -lcacheload -lcsqlsqlnw - -TARGETS = \ - test001\ - test002\ - test003\ - test004\ - test005\ - test006\ - test007\ - test008\ - test009\ - test010 - - - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -.c.o:.c - $(CPlus) $(CPlusFlags) $(INCL) -c -o $@ $< - -test001: selecttest1.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test002:selecttest2.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test003:selecttest3.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test004:selecttest4.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test005:selecttest5.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test006:selecttest6.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test007:selecttest7.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test008:selecttest8.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test009:selecttest9.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) -test010:selecttest10.o - $(CPlus) $(CPlusFlags) -o $@ $< $(LIBS) $(SYSLIBS) - -clean: - rm -f *.o ${TARGETS} diff --git a/test/sqlnetwork/Select/exp.test001 b/test/sqlnetwork/Select/exp.test001 deleted file mode 100644 index c6accd58..00000000 --- a/test/sqlnetwork/Select/exp.test001 +++ /dev/null @@ -1,179 +0,0 @@ -NW:TCP connecting -Response from peer site is 1 -NW:TCP Send -Sent bytes 16 -Sent bytes 256 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 118 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -'T1' table created -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 48 -NW:TCP receive -HEADER says packet type is 103 -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -10 Rows Inserted -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 35 -NW:TCP receive -HEADER says packet type is 104 -noOfProjFields returns=0 -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Fetching starts on table 'T1' : -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -5 Rows fetched -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 19 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -'T1' table dropped -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP disconnect kishor 5678 -Sent bytes 16 -NW:TCP receive diff --git a/test/sqlnetwork/Select/exp.test002 b/test/sqlnetwork/Select/exp.test002 deleted file mode 100644 index a0271430..00000000 --- a/test/sqlnetwork/Select/exp.test002 +++ /dev/null @@ -1,177 +0,0 @@ -NW:TCP connecting -Response from peer site is 1 -NW:TCP Send -Sent bytes 16 -Sent bytes 256 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 118 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -'T1' Table created -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 48 -NW:TCP receive -HEADER says packet type is 103 -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 81 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -10 Rows Inserted -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -HEADER says packet type is 104 -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=lakshya | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -Total row fetched=5 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 19 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table dropped -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP disconnect kishor 5678 -Sent bytes 16 -NW:TCP receive diff --git a/test/sqlnetwork/Select/exp.test010 b/test/sqlnetwork/Select/exp.test010 deleted file mode 100644 index 71c8955d..00000000 --- a/test/sqlnetwork/Select/exp.test010 +++ /dev/null @@ -1,177 +0,0 @@ -NW:TCP connecting -Response from peer site is 1 -NW:TCP Send -Sent bytes 16 -Sent bytes 256 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 145 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -'T1' Table created -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 74 -NW:TCP receive -HEADER says packet type is 103 -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -10 Rows Inserted -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 50 -NW:TCP receive -HEADER says packet type is 104 -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -HEADER says packet type is 107 -F1=100 | F2=1 | F3=LAKSHYA | F4=5.500000 | F5=10.500000 | DATE=2008-1-21 | TIME=12:29:30 | TIMESTAMP=2008-1-21 12:29:30 | F9=20 | F10=12000 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 0 -NW:TCP receive -Total row fetched=5 -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 19 -NW:TCP receive -NW:TCP Send -Sent bytes 16 -Sent bytes 8 -NW:TCP receive -Table dropped -NW:TCP Send -Sent bytes 16 -Sent bytes 4 -NW:TCP receive -NW:TCP disconnect kishor 5678 -Sent bytes 16 -NW:TCP receive diff --git a/test/sqlnetwork/Select/selecttest1.c b/test/sqlnetwork/Select/selecttest1.c deleted file mode 100644 index 5b39e14f..00000000 --- a/test/sqlnetwork/Select/selecttest1.c +++ /dev/null @@ -1,151 +0,0 @@ -/* create table T1 with 10 fields, - * insert 10 rows into the table , - * noofprojFields shoul dreturn 10. - * call fetch and count the record. - - * Author : Jitendra Lenka - */ - -#include -#include -#include -#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT);"); - - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - printf("'T1' table created\n"); - - // insert records - - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?);"); - - int f1var = 99; - short int f2var = 1; - char f3var[31] = "lakshya"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2008,1,21); - - Time f7var; - f7var.set(12,29,30); - - TimeStamp f8var; - f8var.setDate(2008,1,21); - f8var.setTime(12,29,30); - - int f9var = 20; - long long f10var = 12000; - - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - - - int count=0; - - for(int i=0;i<2;i++) - { - f1var = f1var+i; - for(int j=0;j<5;j++) - { - rv = con->beginTrans(); - if(rv!=OK)break; - - - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - - } - printf("%d Rows Inserted\n",count); - -//******************************************* - - strcpy(statement,"SELECT * FROM T1 WHERE F1=100;"); - rv = stmt->prepare(statement); - - int nop; - nop = stmt->noOfProjFields(); - printf("noOfProjFields returns=%d\n",nop); - - if(rv !=OK) { delete stmt; delete con; return 5; } - - stmt->bindField(1,&f1var); - stmt->bindField(2,&f2var); - stmt->bindField(3,f3var); - stmt->bindField(4,&f4var); - stmt->bindField(5,&f5var); - stmt->bindField(6,&f6var); - stmt->bindField(7,&f7var); - stmt->bindField(8,&f8var); - stmt->bindField(9,&f9var); - stmt->bindField(10,&f10var); - - - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - printf("Fetching starts on table 'T1' :\n"); - while(stmt->fetch()!=NULL) - { - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld \n",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - - count++; - } - - stmt->close(); - rv = con->commit(); - if(rv!=OK) { delete stmt; delete con; return 7; } - - printf("%d Rows fetched\n",count); - - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 8; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 9; } - printf("'T1' table dropped\n"); - - delete stmt; - delete con; - return 0; -} - - - diff --git a/test/sqlnetwork/Select/selecttest10.c b/test/sqlnetwork/Select/selecttest10.c deleted file mode 100644 index bcae4f68..00000000 --- a/test/sqlnetwork/Select/selecttest10.c +++ /dev/null @@ -1,212 +0,0 @@ -/* create table T1 with 10 fields,( F2 NOT NULL , F3 CHAR(20) DEFAULT 'LAKSHYA') - * - * insert 10 rows for 9 Fields except F3 Field into the table - * noofprojFields should return 5. - * getProjFldInfo() for all fields. - * select with 5 parameters withIwhere clause.(WHERE F1=100) - - * Author : Jitendra Lenka - */ - -#include -#include -#include - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT NOT NULL,F3 CHAR(30) DEFAULT 'LAKSHYA',F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT);"); - - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 2; - } - - rv = stmt->execute(rows); - if(rv!=OK) - { - delete stmt; - delete con; - return 3; - } - printf("'T1' Table created\n"); - - // insert records - - strcpy(statement,"INSERT INTO T1(F1,F2,F4,F5,F6,F7,F8,F9,F10)VALUES(?,?,?,?,?,?,?,?,?);"); - - int f1var = 99; - short int f2var = 1; -// char f3var[20] = "prabakaran"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2008,1,21); - - Time f7var; - f7var.set(12,29,30); - - TimeStamp f8var; - f8var.setDate(2008,1,21); - f8var.setTime(12,29,30); - - int f9var = 20; - long long f10var = 12000; - - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 4; - } - - int count=0; - - for(int i=0;i<2;i++) - { - f1var = f1var+i; - for(int j=0;j<5;j++) - { - rv = con->beginTrans(); - if(rv!=OK)break; - - - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - //stmt->setStringParam(3,f3var); - stmt->setFloatParam(3,f4var); - stmt->setFloatParam(4,f5var); - stmt->setDateParam(5,f6var); - stmt->setTimeParam(6,f7var); - stmt->setTimeStampParam(7,f8var); - stmt->setIntParam(8,f9var); - stmt->setLongLongParam(9,f10var); - - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - - } - printf("%d Rows Inserted\n",count); - -//******************************************* - - strcpy(statement,"SELECT F8,F10,F2,F6,F3 FROM T1 WHERE F1=100;"); - rv = stmt->prepare(statement); - /* - int nop; - nop = stmt->noOfProjFields(); - if(nop!=5)return 1; - printf("Total number of projection fields in the select statement=%d\n",nop); - - // getParamFldInfo() - FieldInfo *field = new FieldInfo(); - - printf("\nFIELD INFORMATION :\n"); - char fldName[20]; - DataType type; - size_t length; - int offset; - char defaultValueBuf[10]; - bool isNull; - bool isDefault; - - for(int i=0;i<=4;i++) - { - - printf("\n***********************************************\n"); - - rv = stmt->getProjFldInfo(i,field); - if(rv!=OK)return 1; - printf("Field Name :%s\n", field->fldName); - printf("Data type of the field :%d\n",field->type); - printf("length of the field :%d\n",field->length); - printf("Offset :%d\n",field->offset); - printf("Default value Buffer :%s\n",field->defaultValueBuf); - printf("Null field :%d\n",field->isNull); - printf("Default value :%d\n",field->isDefault); - printf("***********************************************\n"); - - } - - if(rv !=OK) - { - delete stmt; - delete con; - return 5; - } -*/ - char f3var[31]="jitu"; - - stmt->bindField(1,&f8var); - stmt->bindField(2,&f10var); - stmt->bindField(3,&f2var); - stmt->bindField(4,&f6var); - stmt->bindField(5,f3var); - - - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch()!=NULL) - { - - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld \n",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - - count++; - } - - stmt->close(); - rv = con->commit(); - if(rv!=OK) - { - delete stmt; - delete con; - return 6; - } - - printf("Total row fetched=%d\n",count); - - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 7; - } - rv = stmt->execute(rows); - if(rv!=OK) - { - delete stmt; - delete con; - return 8; - } - printf("Table dropped\n"); - - delete stmt; - delete con; - return 0; -} diff --git a/test/sqlnetwork/Select/selecttest2.c b/test/sqlnetwork/Select/selecttest2.c deleted file mode 100644 index 6d70019c..00000000 --- a/test/sqlnetwork/Select/selecttest2.c +++ /dev/null @@ -1,177 +0,0 @@ -/* create table T1 with 10 fields, - * insert 10 rows into the table , - * noofprojFields should return 5. - * getProjFldInfo() for all fields. - * select with 5 parameters withIwhere clause.(WHERE F1=100) - - * Author : Jitendra Lenka - */ - -#include -#include -#include - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - - char statement[200]; - - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 SMALLINT,F3 CHAR(30),F4 FLOAT,F5 FLOAT,F6 DATE,F7 TIME,F8 TIMESTAMP,F9 INT,F10 BIGINT);"); - - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 2; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 3; } - printf("'T1' Table created\n"); - - // insert records - - strcpy(statement,"INSERT INTO T1 VALUES(?,?,?,?,?,?,?,?,?,?);"); - - int f1var = 99; - short int f2var = 1; - char f3var[31] = "lakshya"; - float f4var = 5.5; - float f5var = 10.50; - Date f6var; - f6var.set(2008,1,21); - - Time f7var; - f7var.set(12,29,30); - - TimeStamp f8var; - f8var.setDate(2008,1,21); - f8var.setTime(12,29,30); - - int f9var = 20; - long long f10var = 12000; - - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 4; } - - int count=0; - - for(int i=0;i<2;i++) - { - f1var = f1var+i; - for(int j=0;j<5;j++) - { - rv = con->beginTrans(); - if(rv!=OK)break; - - - stmt->setIntParam(1,f1var); - stmt->setShortParam(2,f2var); - stmt->setStringParam(3,f3var); - stmt->setFloatParam(4,f4var); - stmt->setFloatParam(5,f5var); - stmt->setDateParam(6,f6var); - stmt->setTimeParam(7,f7var); - stmt->setTimeStampParam(8,f8var); - stmt->setIntParam(9,f9var); - stmt->setLongLongParam(10,f10var); - - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - - } - printf("%d Rows Inserted\n",count); - -//******************************************* - - strcpy(statement,"SELECT F8,F10,F2,F6,F3 FROM T1 WHERE F1=100;"); - rv = stmt->prepare(statement); - - int nop; - // nop = stmt->noOfProjFields(); - // if(nop!=5)return 1; - // printf("Total number of projection fields in the select statement=%d\n",nop); - - // getParamFldInfo() -/* - FieldInfo *field = new FieldInfo(); - - printf("\nFIELD INFORMATION :\n"); - char fldName[20]; - DataType type; - size_t length; - int offset; - char defaultValueBuf[10]; - bool isNull; - bool isDefault; - - for(int i=0;i<=4;i++) - { - - printf("\n***********************************************\n"); - - rv = stmt->getProjFldInfo(i,field); - if(rv!=OK)return 1; - printf("Field Name :%s\n", field->fldName); - printf("Data type of the field :%d\n",field->type); - printf("length of the field :%d\n",field->length); - printf("Offset :%d\n",field->offset); - printf("Default value Buffer :%s\n",field->defaultValueBuf); - printf("Null field :%d\n",field->isNull); - printf("Default value :%d\n",field->isDefault); - printf("***********************************************\n"); - - } - delete field; - - if(rv !=OK) { delete stmt; delete con; return 5; } -*/ - stmt->bindField(1,&f8var); - stmt->bindField(2,&f10var); - stmt->bindField(3,&f2var); - stmt->bindField(4,&f6var); - stmt->bindField(5,f3var); - - - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch()!=NULL) - { - - printf("F1=%d | F2=%hd | F3=%s | F4=%f | F5=%f | DATE=%d-%d-%d | TIME=%d:%d:%d | TIMESTAMP=%d-%d-%d %d:%d:%d | F9=%d | F10=%lld \n",f1var,f2var,f3var,f4var,f5var,f6var.year(),f6var.month(),f6var.dayOfMonth(),f7var.hours(),f7var.minutes(),f7var.seconds(),f8var.year(),f8var.month(),f8var.dayOfMonth(),f8var.hours(),f8var.minutes(),f8var.seconds(),f9var,f10var); - - count++; - } - - stmt->close(); - rv = con->commit(); - if(rv!=OK) { delete stmt; delete con; return 6; } - - printf("Total row fetched=%d\n",count); - - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 7; } - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 8; } - printf("Table dropped\n"); - - delete stmt; - delete con; - return 0; -} diff --git a/test/sqlnetwork/Select/selecttest3.c b/test/sqlnetwork/Select/selecttest3.c deleted file mode 100644 index f2b645cb..00000000 --- a/test/sqlnetwork/Select/selecttest3.c +++ /dev/null @@ -1,144 +0,0 @@ -/* create table T1 with two fields, - * insert 10 rows into the table , - * select from nonexisting table. - - * Author : Jitendra Lenka - */ -#include -#include -#include - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20));"); - - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 1; - } - - rv = stmt->execute(rows); - if(rv!=OK) - { - delete stmt; - delete con; - return 2; - } - printf("Table created\n"); - - // insert records - - strcpy(statement,"INSERT INTO T1 VALUES(?,?);"); - - int f1var = 1; - char f2var[21] = "lakshya"; - - - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 3; - } - - int count=0; - - for(int i=0;i<2;i++) - { - - for(int j=0;j<5;j++) - { - f1var = j; - rv = con->beginTrans(); - if(rv!=OK)break; - - - stmt->setIntParam(1,f1var); - stmt->setStringParam(2,f2var); - - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d rows inserted\n",count); - } - -//******************************************* - - strcpy(statement,"SELECT * FROM T11;"); - rv = stmt->prepare(statement); - - if(rv !=OK) - { - printf("test script passed\n"); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - rv = stmt->execute(rows); - if(rv==OK){printf("Table dropped\n");} - delete stmt; - delete con; - return 0; - } - - else if(rv==OK) - { - - printf("Test script failed\n"); - return 5; - } - - else - { - stmt->bindField(1,&f1var); - stmt->bindField(2,f2var); - - - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(stmt->fetch()!=NULL) - { - count++; - } - - stmt->close(); - rv = con->commit(); - if(rv!=OK) - { - delete stmt; - delete con; - return 7; - } - - printf("Total row fetched=%d\n",count); - - } - - delete stmt; - delete con; - return 0; -} - - - diff --git a/test/sqlnetwork/Select/selecttest4.c b/test/sqlnetwork/Select/selecttest4.c deleted file mode 100644 index fcbcb6d9..00000000 --- a/test/sqlnetwork/Select/selecttest4.c +++ /dev/null @@ -1,94 +0,0 @@ -/* create table T1 with two fields, - * insert 10 rows into the table , - * select with nonexisting fields. - - * Author : Jitendra Lenka - */ -#include -#include -#include - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 INT);"); - - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - printf("Table created\n"); - - // insert records - - strcpy(statement,"INSERT INTO T1 VALUES(?,?);"); - - int f1var = 1; - int f2var= 110; - - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 3; } - - int count=0; - - for(int i=0;i<2;i++) - { - - for(int j=0;j<5;j++) - { - f1var = j; - rv = con->beginTrans(); - if(rv!=OK)break; - - - stmt->setIntParam(1,f1var); - stmt->setIntParam(2,f2var); - - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d rows inserted\n",count); - } - -//******************************************* - - strcpy(statement,"SELECT F3 ,F2 FROM T1;"); - rv = stmt->prepare(statement); - if(rv !=OK) - { - printf("Test script passed\n"); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK)printf("Table drop prepare failed\n"); - rv = stmt->execute(rows); - if(rv==OK)printf("Table dropped\n"); - delete stmt; - delete con; - return 0; - } - else - { - printf("Test script failed\n"); - delete stmt; - delete con; - return 4; - } - -} diff --git a/test/sqlnetwork/Select/selecttest5.c b/test/sqlnetwork/Select/selecttest5.c deleted file mode 100644 index 7ac83811..00000000 --- a/test/sqlnetwork/Select/selecttest5.c +++ /dev/null @@ -1,51 +0,0 @@ -/* call execute without calling prepare. it should fail. - - * Author : Jitendra Lenka - */ - -#include -#include -#include - -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 INT);"); - - int rows=0; - /*rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 1; - }*/ - - rv = stmt->execute(rows); - if(rv!=OK) - { - delete stmt; - delete con; - printf("Execute failed without call prepare\n"); - return 0; - } - printf("Test script failed\n"); - - - delete stmt; - delete con; - return 1; - } - diff --git a/test/sqlnetwork/Select/selecttest6.c b/test/sqlnetwork/Select/selecttest6.c deleted file mode 100644 index d3d81dac..00000000 --- a/test/sqlnetwork/Select/selecttest6.c +++ /dev/null @@ -1,124 +0,0 @@ -/* create table T1 with two fields, - * insert 10 rows into the table , - * fetch without prepare. - - * Author : Jitendra Lenka - */ -#include -#include -#include -//#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20));"); - - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 1; - } - - rv = stmt->execute(rows); - if(rv!=OK) - { - delete stmt; - delete con; - return 2; - } - printf("Table created\n"); - - // insert records - - strcpy(statement,"INSERT INTO T1 VALUES(?,?);"); - - int f1var = 1; - char f2var[20] = "lakshya"; - - - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 3; - } - - int count=0; - - for(int i=0;i<2;i++) - { - - for(int j=0;j<5;j++) - { - f1var = j; - rv = con->beginTrans(); - if(rv!=OK)break; - - - stmt->setIntParam(1,f1var); - stmt->setStringParam(2,f2var); - - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d rows inserted\n",count); - } - stmt->free(); -//******************************************* - - strcpy(statement,"SELECT * FROM T1;"); - /*rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 1; - } */ - stmt->bindField(1,&f1var); - stmt->bindField(2,f2var); - - void *ret; - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 6; - stmt->execute(rows); - while(1) - { - ret = ((char*)stmt->fetch()); - if(ret ==NULL) - { - - printf("fetch failed without prepare\n"); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - rv = stmt->execute(rows); - if(rv==OK){printf("Table dropped successfully\n");} - delete stmt; - delete con; - return 0; - } - printf("Test script failed\n"); - } - delete stmt; - delete con; - return 8; -} diff --git a/test/sqlnetwork/Select/selecttest7.c b/test/sqlnetwork/Select/selecttest7.c deleted file mode 100644 index 41b11926..00000000 --- a/test/sqlnetwork/Select/selecttest7.c +++ /dev/null @@ -1,125 +0,0 @@ -/* create table T1 with two fields, - * insert 10 rows into the table , - * call fetch without call execute,it returns NULL. - - * Author : Jitendra Lenka - */ - -#include -#include -#include -//#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20));"); - - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 1; - } - - rv = stmt->execute(rows); - if(rv!=OK) - { - delete stmt; - delete con; - return 2; - } - printf("Table created\n"); - - // insert records - - strcpy(statement,"INSERT INTO T1 VALUES(?,?);"); - - int f1var = 1; - char f2var[20] = "lakshya"; - - - rv = stmt->prepare(statement); - if(rv!=OK) - { - delete stmt; - delete con; - return 3; - } - - int count=0; - - for(int i=0;i<2;i++) - { - - for(int j=0;j<5;j++) - { - f1var = j; - rv = con->beginTrans(); - if(rv!=OK)break; - - - stmt->setIntParam(1,f1var); - stmt->setStringParam(2,f2var); - - rv = stmt->execute(rows); - if(rv!=OK)break; - rv = con->commit(); - if(rv!=OK)break; - count++; - } - printf("%d rows inserted\n",count); - } - -//******************************************* - - strcpy(statement,"SELECT * FROM T1;"); - rv = stmt->prepare(statement); - - if(rv !=OK) - { - delete stmt; - delete con; - return 4; - } - - - stmt->bindField(1,&f1var); - stmt->bindField(2,f2var); - - void *ret; - count = 0; - rv = con->beginTrans(); - if(rv!=OK)return 5; - //stmt->execute(rows); - while (stmt->fetch(rv)!=NULL && rv == OK) { - printf("Test script failed\n"); - } - if (rv!=OK) { - printf("without execute, Fetch failed\n"); - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - rv = stmt->execute(rows); - if(rv==OK){printf("Table dropped successfully\n");} - delete stmt; - delete con; - return 0; - } - delete stmt; - delete con; - return 7; -} - diff --git a/test/sqlnetwork/Select/selecttest8.c b/test/sqlnetwork/Select/selecttest8.c deleted file mode 100644 index e0e0e065..00000000 --- a/test/sqlnetwork/Select/selecttest8.c +++ /dev/null @@ -1,49 +0,0 @@ -/* prepare,execute,free,prepare, second prepare should pass. - - * Author : Jitendra Lenka - */ -#include -#include -#include -//#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20));"); - int rows=0; - - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - printf("Prepare the Statement\n"); - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - printf("Execute the Statement\n"); - - //again prepare - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { printf("Test script failed\n"); delete stmt; delete con; return 3; } - printf("Again prepare passed\n"); - - rv = stmt->execute(rows); - if(rv==OK)printf("Table dropped successfully\n"); - delete stmt; - delete con; - return 0; -} - - - - diff --git a/test/sqlnetwork/Select/selecttest9.c b/test/sqlnetwork/Select/selecttest9.c deleted file mode 100644 index 5aad65bf..00000000 --- a/test/sqlnetwork/Select/selecttest9.c +++ /dev/null @@ -1,47 +0,0 @@ -/* prepare,execute,prepare...., - * second prepare should pass. - - * Author : Jitendra Lenka - */ -#include -#include -#include -//#include -int main() -{ - DbRetVal rv = OK; - AbsSqlConnection *con = new SqlNwConnection(); - con->setInnerConnection(NULL); - SqlNwConnection *conn = (SqlNwConnection *)con; - conn->setHost("localhost", 5678); - rv = con->connect("root","manager"); - if(rv!=OK)return 1; - - AbsSqlStatement *stmt = new SqlNwStatement(); - stmt->setInnerStatement(NULL); - stmt->setConnection(con); - char statement[200]; - - strcpy(statement,"CREATE TABLE T1(F1 INT,F2 CHAR(20));"); - - int rows=0; - rv = stmt->prepare(statement); - if(rv!=OK) { delete stmt; delete con; return 1; } - printf("Prepared the statement\n"); - - rv = stmt->execute(rows); - if(rv!=OK) { delete stmt; delete con; return 2; } - printf("Execute the statement\n"); - - - //again prepare - - strcpy(statement,"DROP TABLE T1;"); - rv = stmt->prepare(statement); - if(rv!=OK) { printf("Test script failed\n"); delete stmt; delete con; return 3; } - printf("Test script passed\n"); - stmt->execute(rows); - delete stmt; - delete con; - return 0; -} diff --git a/test/system/Allocator/Makefile b/test/system/Allocator/Makefile deleted file mode 100644 index 2f05ef00..00000000 --- a/test/system/Allocator/Makefile +++ /dev/null @@ -1,69 +0,0 @@ - -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -g -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsql - -TARGETS = \ - create createNoIndex drop \ - insert1 insert100 insert1000 delete1 delete100 delete1000 deleteAll \ - test010 \ - test025 test021 test022 test023 test024 - - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -create: create.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -createNoIndex: createNoIndex.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -drop: drop.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -insert1: insert1.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -insert1000: insert1000.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -insert100: insert100.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -delete1: delete1.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -delete1000: delete1000.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -delete100: delete100.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -deleteAll: deleteAll.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test010: dbsizelimit.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test021: tuplesize1.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test022: tuplesize2.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test023: tuplesize3.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test024: tuplesize4.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test025: tuplesize5.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -clean: - rm -f $(TARGETS) - diff --git a/test/system/Allocator/TODO b/test/system/Allocator/TODO deleted file mode 100644 index a39f1859..00000000 --- a/test/system/Allocator/TODO +++ /dev/null @@ -1,2 +0,0 @@ -test008.ksh - -dbsize to 100 MB, insert 1 million tuples, select 1 million tuples (READ_REPEATED) which generaes lot of lock nodes. check whether that returns proper error diff --git a/test/system/Allocator/common.h b/test/system/Allocator/common.h deleted file mode 100644 index 32b61b64..00000000 --- a/test/system/Allocator/common.h +++ /dev/null @@ -1,153 +0,0 @@ -#include -DbRetVal createIndex(DatabaseManager *dbMgr, char *tblname, char *fldname, char *indname) -{ - HashIndexInitInfo *idxInfo = new HashIndexInitInfo(); - strcpy(idxInfo->tableName, tblname); - idxInfo->list.append(fldname); - idxInfo->indType = hashIndex; - idxInfo->isUnique = true; - DbRetVal rv = dbMgr->createIndex(indname, idxInfo); - if (rv != OK) { - printf("Index creation failed\n"); - delete idxInfo; - return rv; - } - printf("Index created for %s\n", fldname); - delete idxInfo; - return OK; -} -DbRetVal createTable(DatabaseManager *dbMgr, char *tblname) -{ - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - tabDef.addField("f2", typeInt); - DbRetVal rv = dbMgr->createTable(tblname, tabDef); - if (rv != OK) { printf("Table creation failed\n"); return rv; } - printf("Table created\n"); - return OK; -} -DbRetVal dropTable(DatabaseManager *dbMgr, char *tblname) -{ - DbRetVal rv = dbMgr->dropTable(tblname); - if (rv != OK) { printf("Table drop failed\n"); return rv; } - printf("Table Dropped\n"); - return OK; -} -int insertTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - int id1 = 0; - table->bindFld("f1", &id1); - table->bindFld("f2", &id1); - int icount =0; - DbRetVal rv = OK; - rv = conn.startTransaction(); - if (rv != OK) { dbMgr->closeTable(table); return 1; } - for (int i = 0 ; i < count ; i++) - { - id1= i; - rv = table->insertTuple(); - if (rv != OK) break; - icount++; - - } - conn.commit(); - printf("Total Tuples inserted is %d\n", icount); - dbMgr->closeTable(table); - return icount; -} -int deleteTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - DbRetVal rv = OK; - - Condition p1; - int val1 = 0; - p1.setTerm("f1", OpEquals, &val1); - table->setCondition(&p1); - - rv = conn.startTransaction(); - if (rv != OK) { dbMgr->closeTable(table); return 1; } - int i =0; - void *tuple; - for (i = 0 ; i < count ; i++) - { - val1 = i; - table->execute(); - if (rv != OK) break; - tuple = (char*)table->fetch() ; - if (tuple == NULL) break; - rv = table->deleteTuple(); - if (rv != OK) break; - table->closeScan(); - } - conn.commit(); - printf("Total Tuples deleted is %d\n", i); - dbMgr->closeTable(table); - return i; -} -int deleteAllTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - DbRetVal rv = OK; - - table->setCondition(NULL); - - rv = conn.startTransaction(); - if (rv != OK) { dbMgr->closeTable(table); return 1; } - int count =0; - table->execute(); - void *tuple; - while ((tuple = (char*) table->fetch())) { - rv = table->deleteTuple(); - if (rv != OK) break; - count++; - } - table->closeScan(); - - conn.commit(); - printf("Total Tuples deleted is %d\n", count); - dbMgr->closeTable(table); - return count; -} -int totalTuples(DatabaseManager *dbMgr, Connection &conn, char *tblname) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - DbRetVal rv = OK; - - table->setCondition(NULL); - - rv = conn.startTransaction(); - if (rv != OK) { dbMgr->closeTable(table); return 1; } - int count =0; - table->execute(); - void *tuple; - while ((tuple = (char*) table->fetch())) { - count++; - } - table->closeScan(); - - conn.commit(); - dbMgr->closeTable(table); - return count; -} diff --git a/test/system/Allocator/create.c b/test/system/Allocator/create.c deleted file mode 100644 index d6fdc37f..00000000 --- a/test/system/Allocator/create.c +++ /dev/null @@ -1,17 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - if ( createTable(dbMgr, "t1") != 0 ) { ret = 3; } - if ( createIndex(dbMgr, "t1", "f1", "t1idx1") != 0 ) { ret= 3; } - - conn.close(); - return ret; - -} diff --git a/test/system/Allocator/createNoIndex.c b/test/system/Allocator/createNoIndex.c deleted file mode 100644 index e0aea7ec..00000000 --- a/test/system/Allocator/createNoIndex.c +++ /dev/null @@ -1,15 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - if ( createTable(dbMgr, "t1") != 0 ) { ret = 3; } - conn.close(); - return ret; - -} diff --git a/test/system/Allocator/dbsizelimit.c b/test/system/Allocator/dbsizelimit.c deleted file mode 100644 index 845a4249..00000000 --- a/test/system/Allocator/dbsizelimit.c +++ /dev/null @@ -1,47 +0,0 @@ -//Test Case: -//Insert 20 K tuples -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - tabDef.addField("f2", typeString, 196); - rv = dbMgr->createTable("t1", tabDef); - if (rv != OK) { printf("Table creation failed\n"); conn.close(); return 3; } - printf("Table created\n"); - - Table *table = dbMgr->openTable("t1"); - if (table == NULL) - { - printf("Unable to open table\n"); - dbMgr->dropTable("t1"); - conn.close(); - return -1; - } - int id1 = 0, id2 = 5; - char name[20] = "PRAVEEN"; - table->bindFld("f1", &id1); - table->bindFld("f2", &id2); - int icount =0; - for (int i = 0 ; i < 10 ; i++) - { - conn.startTransaction(); - for (int j = 0 ; j < 10000 ; j++) { - id1= icount++; - rv = table->insertTuple(); - if (rv != OK) break; - } - if (rv != OK) break; - conn.commit(); - } - dbMgr->closeTable(table); - dbMgr->dropTable("t1"); - conn.close(); - return 0; -} diff --git a/test/system/Allocator/delete1.c b/test/system/Allocator/delete1.c deleted file mode 100644 index b757f24f..00000000 --- a/test/system/Allocator/delete1.c +++ /dev/null @@ -1,15 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - ret = deleteTuple(dbMgr, conn, "t1", 1); - conn.close(); - return ret; - -} diff --git a/test/system/Allocator/delete100.c b/test/system/Allocator/delete100.c deleted file mode 100644 index a9a1f64e..00000000 --- a/test/system/Allocator/delete100.c +++ /dev/null @@ -1,15 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - ret = deleteTuple(dbMgr, conn, "t1", 1000); - conn.close(); - return ret; - -} diff --git a/test/system/Allocator/delete1000.c b/test/system/Allocator/delete1000.c deleted file mode 100644 index a9a1f64e..00000000 --- a/test/system/Allocator/delete1000.c +++ /dev/null @@ -1,15 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - ret = deleteTuple(dbMgr, conn, "t1", 1000); - conn.close(); - return ret; - -} diff --git a/test/system/Allocator/deleteAll.c b/test/system/Allocator/deleteAll.c deleted file mode 100644 index 3e4062a4..00000000 --- a/test/system/Allocator/deleteAll.c +++ /dev/null @@ -1,15 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - ret = deleteAllTuple(dbMgr, conn, "t1"); - conn.close(); - return ret; - -} diff --git a/test/system/Allocator/drop.c b/test/system/Allocator/drop.c deleted file mode 100644 index 88eec578..00000000 --- a/test/system/Allocator/drop.c +++ /dev/null @@ -1,15 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - if ( dropTable(dbMgr, "t1") != 0 ) { ret = 3; } - conn.close(); - return ret; - -} diff --git a/test/system/Allocator/exp.test001.ksh b/test/system/Allocator/exp.test001.ksh deleted file mode 100644 index 6200cd06..00000000 --- a/test/system/Allocator/exp.test001.ksh +++ /dev/null @@ -1,61 +0,0 @@ -Table created -Index created for f1 -Tables and Indexes are created -Total Tuples inserted is 1 -Tuples inserted into table -Case 1: -T option for t1: with 1 tuple - - t1 - 1 - 1 - 32 - 1 - 12 - 2 - - t1idx1 - -
-Case 2: -I option for idx1 of t1, with 1 tuple - - t1idx1 - 1 - - 1 - 1009 - - - 1 - 1 - - -Total Tuples deleted is 1 -Tuples deleted from table -Case 3: -T option for t1: after removing 1 tuple - - t1 - 0 - 1 - 16 - 1 - 12 - 2 - - t1idx1 - -
-Case 4: -I option for idx1 of t1, after removing 1 tuple - - t1idx1 - 1 - - 1 - 1009 - - - 1 - 0 - - -Table Dropped -Tables and Indexes are dropped diff --git a/test/system/Allocator/exp.test002.ksh b/test/system/Allocator/exp.test002.ksh deleted file mode 100644 index c34949cf..00000000 --- a/test/system/Allocator/exp.test002.ksh +++ /dev/null @@ -1,61 +0,0 @@ -Table created -Index created for f1 -Tables and Indexes are created -Total Tuples inserted is 1000 -Tuples inserted into table -Case 1: -T option for t1: with 1000 tuple - - t1 - 1000 - 2 - 16032 - 1 - 12 - 2 - - t1idx1 - -
-Case 2: -I option for idx1 of t1, with 1000 tuple - - t1idx1 - 1 - - 1 - 1009 - - - 2 - 1000 - - -Total Tuples deleted is 1000 -Tuples deleted from table -Case 3: -T option for t1: after removing 1000 tuple - - t1 - 0 - 2 - 32 - 1 - 12 - 2 - - t1idx1 - -
-Case 4: -I option for idx1 of t1, after removing 1000 tuple - - t1idx1 - 1 - - 1 - 1009 - - - 2 - 0 - - -Table Dropped -Tables and Indexes are dropped diff --git a/test/system/Allocator/exp.test003.ksh b/test/system/Allocator/exp.test003.ksh deleted file mode 100644 index d988a68d..00000000 --- a/test/system/Allocator/exp.test003.ksh +++ /dev/null @@ -1,61 +0,0 @@ -Table created -Index created for f1 -Tables and Indexes are created -Total Tuples inserted is 100 -Tuples inserted into table -Case 1: -T option for t1: with 100 tuple - - t1 - 100 - 1 - 1616 - 1 - 12 - 2 - - t1idx1 - -
-Case 2: -I option for idx1 of t1, with 100 tuple - - t1idx1 - 1 - - 1 - 1009 - - - 1 - 100 - - -Total Tuples deleted is 1 -Tuples deleted from table -Case 3: -T option for t1: after removing 1 tuple - - t1 - 99 - 1 - 1600 - 1 - 12 - 2 - - t1idx1 - -
-Case 4: -I option for idx1 of t1, after removing 1 tuple - - t1idx1 - 1 - - 1 - 1009 - - - 1 - 99 - - -Table Dropped -Tables and Indexes are dropped diff --git a/test/system/Allocator/exp.test004.ksh b/test/system/Allocator/exp.test004.ksh deleted file mode 100644 index 933aeedf..00000000 --- a/test/system/Allocator/exp.test004.ksh +++ /dev/null @@ -1,61 +0,0 @@ -Table created -Index created for f1 -Tables and Indexes are created -Total Tuples inserted is 100 -Tuples inserted into table -Case 1: -T option for t1: with 100 tuple - - t1 - 100 - 1 - 1616 - 1 - 12 - 2 - - t1idx1 - -
-Case 2: -I option for idx1 of t1, with 100 tuple - - t1idx1 - 1 - - 1 - 1009 - - - 1 - 100 - - -Total Tuples deleted is 100 -Tuples deleted from table -Case 3: -T option for t1: after removing all tuple - - t1 - 0 - 1 - 16 - 1 - 12 - 2 - - t1idx1 - -
-Case 4: -I option for idx1 of t1, after removing all tuple - - t1idx1 - 1 - - 1 - 1009 - - - 1 - 0 - - -Table Dropped -Tables and Indexes are dropped diff --git a/test/system/Allocator/exp.test005.ksh b/test/system/Allocator/exp.test005.ksh deleted file mode 100644 index cdae6cfe..00000000 --- a/test/system/Allocator/exp.test005.ksh +++ /dev/null @@ -1,114 +0,0 @@ -Case 1: -d option with no table - - - SYSTEMDB - 1048576 - 17d84000 - 109 - 11 - 2 - 13 - - - 1 - 99 - - - 0 - 100 - - 0 - - - - 2048 - 0 - 0 - - - userdb - 10485760 - 17e7a000 - 1279 - 0 - 0 - 0 - - -Table created -Tables and Indexes are created -Case 2: -d option with 1 table - - - SYSTEMDB - 1048576 - 17d84000 - 109 - 11 - 2 - 13 - - - 1 - 99 - - - 0 - 100 - - 0 - - - - 2048 - 0 - 0 - - - userdb - 10485760 - 17e7a000 - 1279 - 1 - 0 - 1 - - -Table Dropped -Case 3: -d option after removing table - - - SYSTEMDB - 1048576 - 17d84000 - 109 - 11 - 2 - 13 - - - 1 - 99 - - - 0 - 100 - - 0 - - - - 2048 - 0 - 0 - - - userdb - 10485760 - 17e7a000 - 1279 - 0 - 0 - 0 - - diff --git a/test/system/Allocator/exp.test006.ksh b/test/system/Allocator/exp.test006.ksh deleted file mode 100644 index 0a7b8319..00000000 --- a/test/system/Allocator/exp.test006.ksh +++ /dev/null @@ -1,115 +0,0 @@ -Case 1: -d option with no table - - - SYSTEMDB - 1048576 - 17d84000 - 109 - 11 - 2 - 13 - - - 1 - 99 - - - 0 - 100 - - 0 - - - - 2048 - 0 - 0 - - - userdb - 10485760 - 17e7a000 - 1279 - 0 - 0 - 0 - - -Table created -Index created for f1 -Tables and Indexes are created -Case 2: -d option with 1 table - - - SYSTEMDB - 1048576 - 17d84000 - 109 - 11 - 2 - 13 - - - 1 - 99 - - - 0 - 100 - - 0 - - - - 2048 - 0 - 0 - - - userdb - 10485760 - 17e7a000 - 1276 - 2 - 1 - 3 - - -Table Dropped -Case 3: -d option after removing table - - - SYSTEMDB - 1048576 - 17d84000 - 109 - 11 - 2 - 13 - - - 1 - 99 - - - 0 - 100 - - 0 - - - - 2048 - 0 - 0 - - - userdb - 10485760 - 17e7a000 - 1279 - 0 - 0 - 0 - - diff --git a/test/system/Allocator/exp.test007.ksh b/test/system/Allocator/exp.test007.ksh deleted file mode 100644 index 2e537c5c..00000000 --- a/test/system/Allocator/exp.test007.ksh +++ /dev/null @@ -1,375 +0,0 @@ -Case 1: -d option with no table - - - SYSTEMDB - 1048576 - 17d84000 - 109 - 11 - 2 - 13 - - - 1 - 99 - - - 0 - 100 - - 0 - - - - 2048 - 0 - 0 - - - userdb - 10485760 - 17e7a000 - 1279 - 0 - 0 - 0 - - -Tables and Indexes are created -Case 2: -d option with 1 table -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped -Table created -Index created for f1 -Table Dropped - - - SYSTEMDB - 1048576 - 17d84000 - 109 - 11 - 2 - 13 - - - 1 - 99 - - - 0 - 100 - - 0 - - - - 2048 - 0 - 0 - - - userdb - 10485760 - 17e7a000 - 1279 - 0 - 0 - 0 - - diff --git a/test/system/Allocator/exp.test008.ksh b/test/system/Allocator/exp.test008.ksh deleted file mode 100644 index 8b137891..00000000 --- a/test/system/Allocator/exp.test008.ksh +++ /dev/null @@ -1 +0,0 @@ - diff --git a/test/system/Allocator/exp.test021 b/test/system/Allocator/exp.test021 deleted file mode 100644 index 2ee9d5fa..00000000 --- a/test/system/Allocator/exp.test021 +++ /dev/null @@ -1,10 +0,0 @@ -Table created - t1 - 0 - 1 - 16 - 0 - 8 - 1 - - diff --git a/test/system/Allocator/exp.test022 b/test/system/Allocator/exp.test022 deleted file mode 100644 index f7fc98ee..00000000 --- a/test/system/Allocator/exp.test022 +++ /dev/null @@ -1,10 +0,0 @@ -Table created - t1 - 0 - 1 - 16 - 0 - 12 - 2 - - diff --git a/test/system/Allocator/exp.test023 b/test/system/Allocator/exp.test023 deleted file mode 100644 index 1b5cf587..00000000 --- a/test/system/Allocator/exp.test023 +++ /dev/null @@ -1,10 +0,0 @@ -Table created - t1 - 0 - 1 - 16 - 0 - 16 - 3 - - diff --git a/test/system/Allocator/exp.test024 b/test/system/Allocator/exp.test024 deleted file mode 100644 index 48c07c6c..00000000 --- a/test/system/Allocator/exp.test024 +++ /dev/null @@ -1,10 +0,0 @@ -Table created - t1 - 0 - 1 - 16 - 0 - 24 - 4 - - diff --git a/test/system/Allocator/exp.test025 b/test/system/Allocator/exp.test025 deleted file mode 100644 index 6d52c88a..00000000 --- a/test/system/Allocator/exp.test025 +++ /dev/null @@ -1,10 +0,0 @@ -Table created - t1 - 0 - 1 - 16 - 0 - 28 - 5 - - diff --git a/test/system/Allocator/insert1.c b/test/system/Allocator/insert1.c deleted file mode 100644 index a1ecf244..00000000 --- a/test/system/Allocator/insert1.c +++ /dev/null @@ -1,15 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - ret = insertTuple(dbMgr, conn, "t1", 1); - conn.close(); - return ret; - -} diff --git a/test/system/Allocator/insert100.c b/test/system/Allocator/insert100.c deleted file mode 100644 index ccca77a0..00000000 --- a/test/system/Allocator/insert100.c +++ /dev/null @@ -1,15 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - ret = insertTuple(dbMgr, conn, "t1", 100); - conn.close(); - return ret; - -} diff --git a/test/system/Allocator/insert1000.c b/test/system/Allocator/insert1000.c deleted file mode 100644 index 015c12ef..00000000 --- a/test/system/Allocator/insert1000.c +++ /dev/null @@ -1,14 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - ret = insertTuple(dbMgr, conn, "t1", 1000); - conn.close(); - return ret; -} diff --git a/test/system/Allocator/test001.ksh b/test/system/Allocator/test001.ksh deleted file mode 100755 index 2bbd510d..00000000 --- a/test/system/Allocator/test001.ksh +++ /dev/null @@ -1,79 +0,0 @@ -#!/bin/sh -# TestCase: -# create table with two fields and index on first field -# insert 1 tuple -# check number of tuples, totalPagesused -# check pagesUsed for storing hash bucket -# check number of index nodes, pagesUsed for storing index nodes -# delete 1 tuple -# check number of tuples, totalPagesused -# check pagesUsed for storing hash bucket -# check number of index nodes, pagesUsed for storing index nodes - -# Note: spaceused for table = noOfDataNodes * sizeofTuple + noOfPages * sizeofPageInfo -#Note:Thats why we see spaceused as 16 even when no tuple exist - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -EXECUTABLE=${PWD}/system/Allocator/create -REL_PATH=. -if [ -s "$EXECUTABLE" ] -then - REL_PATH=${PWD}/system/Allocator -fi - -${REL_PATH}/create -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are created" -${REL_PATH}/insert1 -if [ $? -ne 1 ] -then - exit 100; -fi -echo "Tuples inserted into table" -echo "Case 1: -T option for t1: with 1 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t1 -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 2: -I option for idx1 of t1, with 1 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -I t1idx1 -if [ $? -ne 0 ] -then - exit 2; -fi - -${REL_PATH}/delete1 -if [ $? -ne 1 ] -then - exit 100; -fi - -echo "Tuples deleted from table" -echo "Case 3: -T option for t1: after removing 1 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t1 -if [ $? -ne 0 ] -then - exit 3; -fi - -echo "Case 4: -I option for idx1 of t1, after removing 1 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -I t1idx1 -if [ $? -ne 0 ] -then - exit 4; -fi - -${REL_PATH}/drop -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are dropped" - -exit 0 diff --git a/test/system/Allocator/test002.ksh b/test/system/Allocator/test002.ksh deleted file mode 100755 index ba4cf369..00000000 --- a/test/system/Allocator/test002.ksh +++ /dev/null @@ -1,68 +0,0 @@ -#!/bin/sh -# TestCase: -# create table with two fields and index on first field -# insert 1000 tuple -# check number of tuples, totalPagesused -# check pagesUsed for storing hash bucket -# check number of index nodes, pagesUsed for storing index nodes -# delete 1000 tuple -# check number of tuples, totalPagesused -# check pagesUsed for storing hash bucket -# check number of index nodes, pagesUsed for storing index nodes - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -EXECUTABLE=${PWD}/system/Allocator/create -REL_PATH=. -if [ -s "$EXECUTABLE" ] -then - REL_PATH=${PWD}/system/Allocator -fi - -${REL_PATH}/create -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are created" -${REL_PATH}/insert1000 -echo "Tuples inserted into table" -echo "Case 1: -T option for t1: with 1000 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t1 -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 2: -I option for idx1 of t1, with 1000 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -I t1idx1 -if [ $? -ne 0 ] -then - exit 2; -fi - -${REL_PATH}/delete1000 - -echo "Tuples deleted from table" -echo "Case 3: -T option for t1: after removing 1000 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t1 -if [ $? -ne 0 ] -then - exit 3; -fi - -echo "Case 4: -I option for idx1 of t1, after removing 1000 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -I t1idx1 -if [ $? -ne 0 ] -then - exit 4; -fi - -${REL_PATH}/drop -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are dropped" - -exit 0 diff --git a/test/system/Allocator/test003.ksh b/test/system/Allocator/test003.ksh deleted file mode 100755 index 6b04723f..00000000 --- a/test/system/Allocator/test003.ksh +++ /dev/null @@ -1,77 +0,0 @@ -#!/bin/sh -# TestCase: -# create table with two fields and index on first field -# insert 100 tuple -# check number of tuples, totalPagesused -# check pagesUsed for storing hash bucket -# check number of index nodes, pagesUsed for storing index nodes -# delete 1 tuple -# check number of tuples, totalPagesused -# check pagesUsed for storing hash bucket -# check number of index nodes, pagesUsed for storing index nodes - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -EXECUTABLE=${PWD}/system/Allocator/create -REL_PATH=. -if [ -s "$EXECUTABLE" ] -then - REL_PATH=${PWD}/system/Allocator -fi - -${REL_PATH}/create -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are created" -${REL_PATH}/insert100 -if [ $? -ne 100 ] -then - exit 100; -fi -echo "Tuples inserted into table" -echo "Case 1: -T option for t1: with 100 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t1 -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 2: -I option for idx1 of t1, with 100 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -I t1idx1 -if [ $? -ne 0 ] -then - exit 2; -fi - -${REL_PATH}/delete1 -if [ $? -ne 1 ] -then - exit 100; -fi - -echo "Tuples deleted from table" -echo "Case 3: -T option for t1: after removing 1 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t1 -if [ $? -ne 0 ] -then - exit 3; -fi - -echo "Case 4: -I option for idx1 of t1, after removing 1 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -I t1idx1 -if [ $? -ne 0 ] -then - exit 4; -fi - -${REL_PATH}/drop -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are dropped" - -exit 0 diff --git a/test/system/Allocator/test004.ksh b/test/system/Allocator/test004.ksh deleted file mode 100755 index 96b20094..00000000 --- a/test/system/Allocator/test004.ksh +++ /dev/null @@ -1,72 +0,0 @@ -#!/bin/sh -# TestCase: -# create table with two fields and index on first field -# insert 100 tuple -# check number of tuples, totalPagesused -# check pagesUsed for storing hash bucket -# check number of index nodes, pagesUsed for storing index nodes -# delete all tuples -# check number of tuples, totalPagesused -# check pagesUsed for storing hash bucket -# check number of index nodes, pagesUsed for storing index nodes - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -EXECUTABLE=${PWD}/system/Allocator/create -REL_PATH=. -if [ -s "$EXECUTABLE" ] -then - REL_PATH=${PWD}/system/Allocator -fi - -${REL_PATH}/create -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are created" -${REL_PATH}/insert100 -if [ $? -ne 100 ] -then - exit 100; -fi -echo "Tuples inserted into table" -echo "Case 1: -T option for t1: with 100 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t1 -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 2: -I option for idx1 of t1, with 100 tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -I t1idx1 -if [ $? -ne 0 ] -then - exit 2; -fi - -${REL_PATH}/deleteAll - -echo "Tuples deleted from table" -echo "Case 3: -T option for t1: after removing all tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t1 -if [ $? -ne 0 ] -then - exit 3; -fi - -echo "Case 4: -I option for idx1 of t1, after removing all tuple" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -I t1idx1 -if [ $? -ne 0 ] -then - exit 4; -fi - -${REL_PATH}/drop -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are dropped" - -exit 0 diff --git a/test/system/Allocator/test005.ksh b/test/system/Allocator/test005.ksh deleted file mode 100755 index 9347532e..00000000 --- a/test/system/Allocator/test005.ksh +++ /dev/null @@ -1,52 +0,0 @@ -#!/bin/sh -# TestCase: -# check pages used(normal and merged) and chunks used for user database -# create table t1 with two fields -# check pages used(normal and merged) and chunks used for user database -# drop table t1 -# check pages used(normal and merged) and chunks used for user database - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -EXECUTABLE=${PWD}/system/Allocator/create -REL_PATH=. -if [ -s "$EXECUTABLE" ] -then - REL_PATH=${PWD}/system/Allocator -fi - -echo "Case 1: -d option with no table" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d -if [ $? -ne 0 ] -then - exit 1; -fi - -${REL_PATH}/createNoIndex -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are created" - -echo "Case 2: -d option with 1 table" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d -if [ $? -ne 0 ] -then - exit 1; -fi - -${REL_PATH}/drop -if [ $? -ne 0 ] -then - exit 100; -fi - -echo "Case 3: -d option after removing table" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d -if [ $? -ne 0 ] -then - exit 3; -fi - -exit 0; diff --git a/test/system/Allocator/test006.ksh b/test/system/Allocator/test006.ksh deleted file mode 100755 index 23307690..00000000 --- a/test/system/Allocator/test006.ksh +++ /dev/null @@ -1,53 +0,0 @@ -#!/bin/sh -# TestCase: -# check pages used(normal and merged) and chunks used for user database -# create table t1 with two fields and index on first field -# create index idx1 on t1 (f1) -# check pages used(normal and merged) and chunks used for user database -# drop table t1 -# check pages used(normal and merged) and chunks used for user database - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -EXECUTABLE=${PWD}/system/Allocator/create -REL_PATH=. -if [ -s "$EXECUTABLE" ] -then - REL_PATH=${PWD}/system/Allocator -fi - -echo "Case 1: -d option with no table" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d -if [ $? -ne 0 ] -then - exit 1; -fi - -${REL_PATH}/create -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are created" - -echo "Case 2: -d option with 1 table" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d -if [ $? -ne 0 ] -then - exit 1; -fi - -${REL_PATH}/drop -if [ $? -ne 0 ] -then - exit 100; -fi - -echo "Case 3: -d option after removing table" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d -if [ $? -ne 0 ] -then - exit 3; -fi - -exit 0 diff --git a/test/system/Allocator/test007.ksh b/test/system/Allocator/test007.ksh deleted file mode 100755 index 6584c961..00000000 --- a/test/system/Allocator/test007.ksh +++ /dev/null @@ -1,52 +0,0 @@ -#!/bin/sh -# TestCase: -# check pages used(normal and merged) and chunks used for user database -# for i = 1 to 100 -# create table t1 with two fields and index on first field -# create index idx1 on t1 (f1) -# drop table t1 -# end for -# check pages used(normal and merged) and chunks used for user database - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -EXECUTABLE=${PWD}/system/Allocator/create -REL_PATH=. -if [ -s "$EXECUTABLE" ] -then - REL_PATH=${PWD}/system/Allocator -fi - -echo "Case 1: -d option with no table" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Tables and Indexes are created" - -echo "Case 2: -d option with 1 table" -count=100 -while [ ${count} -gt 0 ] -do - count=`expr ${count} - 1` - ${REL_PATH}/create - if [ $? -ne 0 ] - then - echo "create table failed" - exit 100; - fi - ${REL_PATH}/drop - if [ $? -ne 0 ] - then - echo "drop table failed" - exit 100; - fi -done -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0 diff --git a/test/system/Allocator/test008.ksh b/test/system/Allocator/test008.ksh deleted file mode 100755 index c517ed32..00000000 --- a/test/system/Allocator/test008.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -#Test Case: undo log allocation should return error message -#when db is full -#this test starts a large transaction which generates huge -#undo logs - -#Run this test only under csql/test or on this directory. -FILENAME=${PWD}/system/Allocator/dbsizelimit -REL_PATH=. -if [ -s "$FILENAME" ] -then - REL_PATH=`pwd`/system/Allocator -fi -${REL_PATH}/dbsizelimit 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out - diff --git a/test/system/Allocator/tuplesize1.c b/test/system/Allocator/tuplesize1.c deleted file mode 100644 index 40ed02d9..00000000 --- a/test/system/Allocator/tuplesize1.c +++ /dev/null @@ -1,32 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 with int -* create index if specified -* check table information for tuple size -*/ -#include -#include -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - rv = dbMgr->createTable("t1", tabDef); - if (rv != OK) { printf("Table creation failed\n"); return rv; } - printf("Table created\n"); - - if (rv != OK) ret = 5; - TableImpl *table = (TableImpl*) dbMgr->openTable("t1"); - table->printInfo(); - dbMgr->closeTable((Table*)table); - dbMgr->dropTable("t1"); - conn.close(); - return ret; -} diff --git a/test/system/Allocator/tuplesize2.c b/test/system/Allocator/tuplesize2.c deleted file mode 100644 index 8454ee7c..00000000 --- a/test/system/Allocator/tuplesize2.c +++ /dev/null @@ -1,33 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 with int -* create index if specified -* check table information for tuple size -*/ -#include -#include -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - tabDef.addField("f2", typeString, 1); - rv = dbMgr->createTable("t1", tabDef); - if (rv != OK) { printf("Table creation failed\n"); return rv; } - printf("Table created\n"); - - if (rv != OK) ret = 5; - TableImpl *table = (TableImpl*) dbMgr->openTable("t1"); - table->printInfo(); - dbMgr->closeTable((Table*)table); - dbMgr->dropTable("t1"); - conn.close(); - return ret; -} diff --git a/test/system/Allocator/tuplesize3.c b/test/system/Allocator/tuplesize3.c deleted file mode 100644 index 3d4a4d19..00000000 --- a/test/system/Allocator/tuplesize3.c +++ /dev/null @@ -1,34 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 with int -* create index if specified -* check table information for tuple size -*/ -#include -#include -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - tabDef.addField("f2", typeString, 1); - tabDef.addField("f3", typeInt); - rv = dbMgr->createTable("t1", tabDef); - if (rv != OK) { printf("Table creation failed\n"); return rv; } - printf("Table created\n"); - - if (rv != OK) ret = 5; - TableImpl *table = (TableImpl*) dbMgr->openTable("t1"); - table->printInfo(); - dbMgr->closeTable((Table*)table); - dbMgr->dropTable("t1"); - conn.close(); - return ret; -} diff --git a/test/system/Allocator/tuplesize4.c b/test/system/Allocator/tuplesize4.c deleted file mode 100644 index 974cbe8b..00000000 --- a/test/system/Allocator/tuplesize4.c +++ /dev/null @@ -1,35 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 with int -* create index if specified -* check table information for tuple size -*/ -#include -#include -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - tabDef.addField("f2", typeString, 1); - tabDef.addField("f3", typeString, 5); - tabDef.addField("f4", typeInt); - rv = dbMgr->createTable("t1", tabDef); - if (rv != OK) { printf("Table creation failed\n"); return rv; } - printf("Table created\n"); - - if (rv != OK) ret = 5; - TableImpl *table = (TableImpl*) dbMgr->openTable("t1"); - table->printInfo(); - dbMgr->closeTable((Table*)table); - dbMgr->dropTable("t1"); - conn.close(); - return ret; -} diff --git a/test/system/Allocator/tuplesize5.c b/test/system/Allocator/tuplesize5.c deleted file mode 100644 index 29bb9fda..00000000 --- a/test/system/Allocator/tuplesize5.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 with int -* create index if specified -* check table information for tuple size -*/ -#include -#include -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - tabDef.addField("f2", typeString, 1); - tabDef.addField("f3", typeInt); - tabDef.addField("f4", typeString, 5); - tabDef.addField("f5", typeInt); - rv = dbMgr->createTable("t1", tabDef); - if (rv != OK) { printf("Table creation failed\n"); return rv; } - printf("Table created\n"); - - if (rv != OK) ret = 5; - TableImpl *table = (TableImpl*) dbMgr->openTable("t1"); - table->printInfo(); - dbMgr->closeTable((Table*)table); - dbMgr->dropTable("t1"); - conn.close(); - return ret; -} diff --git a/test/system/Makefile b/test/system/Makefile deleted file mode 100644 index 88876187..00000000 --- a/test/system/Makefile +++ /dev/null @@ -1,35 +0,0 @@ -OSNAME = $(shell uname -s) -MAKE=make - -ifeq ($(OSNAME), SunOS) -PlatForm=supported -else -ifeq ($(OSNAME), Linux) -PlatForm=supported -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - - -ifeq ($(PlatForm), supported) -all: buildall -endif - -buildall: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE); cd ..;\ - fi;\ - done - -clean: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE) clean; cd ..;\ - fi;\ - done diff --git a/test/system/config/Makefile b/test/system/config/Makefile deleted file mode 100644 index c4ebc208..00000000 --- a/test/system/config/Makefile +++ /dev/null @@ -1,42 +0,0 @@ - -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -O2 -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsql - -TARGETS = \ - connect \ - test001 \ - test002 - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -connect: connect.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test001: conftest1.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test002: conftest2.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) - -clean: - rm -f $(TARGETS) - diff --git a/test/system/config/conftest1.c b/test/system/config/conftest1.c deleted file mode 100644 index 7598378d..00000000 --- a/test/system/config/conftest1.c +++ /dev/null @@ -1,10 +0,0 @@ -#include -int main() -{ - Connection conn; - DbRetVal rv = OK; - os::setenv("CSQL_CONFIG_FILE", "./noexistcsql.conf"); - rv = conn.open("root", "manager"); - if (rv == OK) return 1; - return 0; -} diff --git a/test/system/config/conftest2.c b/test/system/config/conftest2.c deleted file mode 100644 index 555872d2..00000000 --- a/test/system/config/conftest2.c +++ /dev/null @@ -1,20 +0,0 @@ -//print values of the config file -#include -int main() -{ - Connection conn; - DbRetVal rv = OK; - char *root = os::getenv("PWD"); - char conf[512]; - char *s = root + (strlen(root) - 9); - if (strcmp(s, "csql/test") == 0) - sprintf(conf, "%s/system/config/csql.conf", root); - else - sprintf(conf, "%s/csql.conf", root); - os::setenv("CSQL_CONFIG_FILE", conf); - rv = conn.open("root", "manager"); - if (rv != OK) return 1; - Conf::config.print(); - conn.close(); - return 0; -} diff --git a/test/system/config/connect.c b/test/system/config/connect.c deleted file mode 100644 index 2bd12d9f..00000000 --- a/test/system/config/connect.c +++ /dev/null @@ -1,10 +0,0 @@ -//print values of the config file -#include -int main() -{ - Connection conn; - DbRetVal rv = OK; - rv = conn.open("root", "manager"); - if (rv == OK) return 1; - return 0; -} diff --git a/test/system/config/csql.conf b/test/system/config/csql.conf deleted file mode 100644 index 2bd341b6..00000000 --- a/test/system/config/csql.conf +++ /dev/null @@ -1,45 +0,0 @@ -# CSQL System Configuration File - -# Page size. Each database is logically divided into pages and allocation happens -# in this unit of pages. Increasing this value will reduce frequent allocation of pages. -PAGE_SIZE= 8192 - -#Total number of active transactions that can run concurrently in the system -MAX_TRANS = 10 - -#Total number of client process which can connect and work with the -# database concurrently -MAX_PROCS = 10 - -#Total number of threads in a process which can connect and work with the -# database concurrently -MAX_THREADS = 10 - -# Maximum size of the system database. -MAX_SYS_DB_SIZE=1048576 - -#Maximum size of the user database file. -MAX_DB_SIZE=10485760 - -#Shared memory key to be used by the system to create and locate system database. -SYS_DB_KEY=2222 - -#Shared memory key to be used by the system to create and locate user database. -USER_DB_KEY=3333 - -#Give full path for the log file where important system actions are stored. -LOG_FILE=/tmp/log/csql/log.out - -#The virtual memory start address at which the shared memory segment -# will be created and attached. -MAP_ADDRESS=400000000 - -#Mutex timeout interval seconds -MUTEX_TIMEOUT_SECS=0 -MUTEX_TIMEOUT_USECS=10 -MUTEX_TIMEOUT_RETRIES=10 - -#Lock timeout interval seconds -LOCK_TIMEOUT_SECS=0 -LOCK_TIMEOUT_USECS=10 -LOCK_TIMEOUT_RETRIES=10 diff --git a/test/system/config/exp.test002 b/test/system/config/exp.test002 deleted file mode 100644 index b87a96ff..00000000 --- a/test/system/config/exp.test002 +++ /dev/null @@ -1,23 +0,0 @@ -ConfigValues - getPageSize 8192 - getMaxProcs 10 - getMaxSysDbSize 1048576 - getMaxDbSize 10485760 - getSysDbKey 2222 - getUserDbKey 3333 - getLogFile /tmp/log/csql/log.out - getDatabaseFile /tmp/csql/csql.db - getMapAddress 400000000 - getMutexSecs 0 - getMutexUSecs 10 - getMutexRetries 10 - getLockSecs 0 - getLockUSecs 10 - getLockRetries 10 - useCache 0 - getDSN myodbc3 - getTableConfigFile /tmp/csql/csqltable.conf - isTwoWayCache 1 - getCacheWaitSecs 10 - useCsqlSqlServer 0 - getPort 5678 diff --git a/test/system/config/exp.test003.ksh b/test/system/config/exp.test003.ksh deleted file mode 100644 index 05c6ddb5..00000000 --- a/test/system/config/exp.test003.ksh +++ /dev/null @@ -1,3 +0,0 @@ -PAGE_SIZE should be >= 8192 and <= 10 MB -Configuration file read failed - diff --git a/test/system/config/exp.test004.ksh b/test/system/config/exp.test004.ksh deleted file mode 100644 index 3a4f6b3d..00000000 --- a/test/system/config/exp.test004.ksh +++ /dev/null @@ -1,3 +0,0 @@ -PAGE_SIZE should be multiples of 1024 -Configuration file read failed - diff --git a/test/system/config/exp.test005.ksh b/test/system/config/exp.test005.ksh deleted file mode 100644 index 6a056fbc..00000000 --- a/test/system/config/exp.test005.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MAX_TRANS should be >= 10 and <= 8192 -Configuration file read failed - diff --git a/test/system/config/exp.test006.ksh b/test/system/config/exp.test006.ksh deleted file mode 100644 index 0ee75bfa..00000000 --- a/test/system/config/exp.test006.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MAX_PROCS should be >= 10 and <= 8192 -Configuration file read failed - diff --git a/test/system/config/exp.test007.ksh b/test/system/config/exp.test007.ksh deleted file mode 100644 index b9423d45..00000000 --- a/test/system/config/exp.test007.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MAX_THREADS should be >= 1 and <= 64 -Configuration file read failed - diff --git a/test/system/config/exp.test008.ksh b/test/system/config/exp.test008.ksh deleted file mode 100644 index 525b4f90..00000000 --- a/test/system/config/exp.test008.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MAX_SYS_DB_SIZE should be >= 1 MB and <= 1 GB -Configuration file read failed - diff --git a/test/system/config/exp.test009.ksh b/test/system/config/exp.test009.ksh deleted file mode 100644 index 525b4f90..00000000 --- a/test/system/config/exp.test009.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MAX_SYS_DB_SIZE should be >= 1 MB and <= 1 GB -Configuration file read failed - diff --git a/test/system/config/exp.test010.ksh b/test/system/config/exp.test010.ksh deleted file mode 100644 index 3c91ea48..00000000 --- a/test/system/config/exp.test010.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MAX_SYS_DB_SIZE should be multiples of 8192 -Configuration file read failed - diff --git a/test/system/config/exp.test011.ksh b/test/system/config/exp.test011.ksh deleted file mode 100644 index be8302fd..00000000 --- a/test/system/config/exp.test011.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MAX_DB_SIZE should be >= 1 MB and <= 2 GB -Configuration file read failed - diff --git a/test/system/config/exp.test012.ksh b/test/system/config/exp.test012.ksh deleted file mode 100644 index be8302fd..00000000 --- a/test/system/config/exp.test012.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MAX_DB_SIZE should be >= 1 MB and <= 2 GB -Configuration file read failed - diff --git a/test/system/config/exp.test013.ksh b/test/system/config/exp.test013.ksh deleted file mode 100644 index 6b882233..00000000 --- a/test/system/config/exp.test013.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MAX_DB_SIZE should be multiples of 8192 -Configuration file read failed - diff --git a/test/system/config/exp.test014.ksh b/test/system/config/exp.test014.ksh deleted file mode 100644 index be8302fd..00000000 --- a/test/system/config/exp.test014.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MAX_DB_SIZE should be >= 1 MB and <= 2 GB -Configuration file read failed - diff --git a/test/system/config/exp.test015.ksh b/test/system/config/exp.test015.ksh deleted file mode 100644 index 9d7e4b5d..00000000 --- a/test/system/config/exp.test015.ksh +++ /dev/null @@ -1,3 +0,0 @@ -SYS_DB_KEY should be >= 10 and <= 8192 -Configuration file read failed - diff --git a/test/system/config/exp.test016.ksh b/test/system/config/exp.test016.ksh deleted file mode 100644 index a97515ef..00000000 --- a/test/system/config/exp.test016.ksh +++ /dev/null @@ -1,3 +0,0 @@ -USER_DB_KEY should be >= 10 and <= 8192 -Configuration file read failed - diff --git a/test/system/config/exp.test017.ksh b/test/system/config/exp.test017.ksh deleted file mode 100644 index 8765b5e3..00000000 --- a/test/system/config/exp.test017.ksh +++ /dev/null @@ -1,3 +0,0 @@ -USER_DB_KEY and SYS_DB_KEY have same value 1000 -Configuration file read failed - diff --git a/test/system/config/exp.test018.ksh b/test/system/config/exp.test018.ksh deleted file mode 100644 index f194d2d1..00000000 --- a/test/system/config/exp.test018.ksh +++ /dev/null @@ -1,3 +0,0 @@ -LOG_FILE is set to NULL -Configuration file read failed - diff --git a/test/system/config/exp.test019.ksh b/test/system/config/exp.test019.ksh deleted file mode 100644 index 15d2dff4..00000000 --- a/test/system/config/exp.test019.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MAP_ADDRESS should be >= 400000000 and <= 2000000000 -Configuration file read failed - diff --git a/test/system/config/exp.test021.ksh b/test/system/config/exp.test021.ksh deleted file mode 100644 index ad58a529..00000000 --- a/test/system/config/exp.test021.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MUTEX_TIMEOUT_SECS should be >= 0 and <= 360 -Configuration file read failed - diff --git a/test/system/config/exp.test022.ksh b/test/system/config/exp.test022.ksh deleted file mode 100644 index ad58a529..00000000 --- a/test/system/config/exp.test022.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MUTEX_TIMEOUT_SECS should be >= 0 and <= 360 -Configuration file read failed - diff --git a/test/system/config/exp.test023.ksh b/test/system/config/exp.test023.ksh deleted file mode 100644 index 092a569b..00000000 --- a/test/system/config/exp.test023.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MUTEX_TIMEOUT_USECS should be >= 0 and <= 1000000 -Configuration file read failed - diff --git a/test/system/config/exp.test024.ksh b/test/system/config/exp.test024.ksh deleted file mode 100644 index 092a569b..00000000 --- a/test/system/config/exp.test024.ksh +++ /dev/null @@ -1,3 +0,0 @@ -MUTEX_TIMEOUT_USECS should be >= 0 and <= 1000000 -Configuration file read failed - diff --git a/test/system/config/exp.test027.ksh b/test/system/config/exp.test027.ksh deleted file mode 100644 index 5ccfd864..00000000 --- a/test/system/config/exp.test027.ksh +++ /dev/null @@ -1,3 +0,0 @@ -LOCK_TIMEOUT_SECS should be >= 0 and <= 360 -Configuration file read failed - diff --git a/test/system/config/exp.test028.ksh b/test/system/config/exp.test028.ksh deleted file mode 100644 index 5ccfd864..00000000 --- a/test/system/config/exp.test028.ksh +++ /dev/null @@ -1,3 +0,0 @@ -LOCK_TIMEOUT_SECS should be >= 0 and <= 360 -Configuration file read failed - diff --git a/test/system/config/exp.test029.ksh b/test/system/config/exp.test029.ksh deleted file mode 100644 index b1b10f10..00000000 --- a/test/system/config/exp.test029.ksh +++ /dev/null @@ -1,3 +0,0 @@ -LOCK_TIMEOUT_USECS should be >= 0 and <= 1000000 -Configuration file read failed - diff --git a/test/system/config/exp.test030.ksh b/test/system/config/exp.test030.ksh deleted file mode 100644 index b1b10f10..00000000 --- a/test/system/config/exp.test030.ksh +++ /dev/null @@ -1,3 +0,0 @@ -LOCK_TIMEOUT_USECS should be >= 0 and <= 1000000 -Configuration file read failed - diff --git a/test/system/config/test003.ksh b/test/system/config/test003.ksh deleted file mode 100755 index 71d1a1ae..00000000 --- a/test/system/config/test003.ksh +++ /dev/null @@ -1,16 +0,0 @@ -#!/bin/sh -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "PAGE_SIZE= 512" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -#cat ${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test004.ksh b/test/system/config/test004.ksh deleted file mode 100755 index 50295e99..00000000 --- a/test/system/config/test004.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#PAGE_SIZE should not accept value which are not multiples of 1024 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "PAGE_SIZE= 8193" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test005.ksh b/test/system/config/test005.ksh deleted file mode 100755 index 2de60c6b..00000000 --- a/test/system/config/test005.ksh +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh -#MAX_TRANS should not accept value <10 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -mkdir -p /tmp/log -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAX_TRANS=8" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test006.ksh b/test/system/config/test006.ksh deleted file mode 100755 index a57d692b..00000000 --- a/test/system/config/test006.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MAX_PROCS should not accept value >8192 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAX_PROCS=10000" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test007.ksh b/test/system/config/test007.ksh deleted file mode 100755 index 6e74df1b..00000000 --- a/test/system/config/test007.ksh +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh -#MAX_THREADs should not accept value >64 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -mkdir -p /tmp/log -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAX_THREADS=100" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test008.ksh b/test/system/config/test008.ksh deleted file mode 100755 index 0f390e44..00000000 --- a/test/system/config/test008.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MAX_SYS_DB_SIZE should be >1MB - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAX_SYS_DB_SIZE=1000000" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test009.ksh b/test/system/config/test009.ksh deleted file mode 100755 index d321a989..00000000 --- a/test/system/config/test009.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MAX_SYS_DB_SIZE should be <1GB - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAX_SYS_DB_SIZE=2000000000" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test010.ksh b/test/system/config/test010.ksh deleted file mode 100755 index 823f94d8..00000000 --- a/test/system/config/test010.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MAX_SYS_DB_SIZE should be multiples of 8192 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAX_SYS_DB_SIZE=8388609" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test011.ksh b/test/system/config/test011.ksh deleted file mode 100755 index 092f9cf0..00000000 --- a/test/system/config/test011.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MAX_DB_SIZE should be >1MB - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAX_DB_SIZE=1000000" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test012.ksh b/test/system/config/test012.ksh deleted file mode 100755 index e2a5cc4e..00000000 --- a/test/system/config/test012.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MAX_DB_SIZE should be <2GB - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAX_DB_SIZE=3000000000" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test013.ksh b/test/system/config/test013.ksh deleted file mode 100755 index bbec6795..00000000 --- a/test/system/config/test013.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MAX_DB_SIZE should be multiples of 8192 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAX_DB_SIZE=8388609" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test014.ksh b/test/system/config/test014.ksh deleted file mode 100755 index 764ae20c..00000000 --- a/test/system/config/test014.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MAX_DB_SIZE should not accept string values - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAX_DB_SIZE=mywrongvalue" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test015.ksh b/test/system/config/test015.ksh deleted file mode 100755 index 8190faf1..00000000 --- a/test/system/config/test015.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#SYS_DB_KEY should not accept < 10 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "SYS_DB_KEY=5" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test016.ksh b/test/system/config/test016.ksh deleted file mode 100755 index 459e62e7..00000000 --- a/test/system/config/test016.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#USER_DB_KEY should not accept > 8192 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "USER_DB_KEY=10000" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test017.ksh b/test/system/config/test017.ksh deleted file mode 100755 index 4e57edf8..00000000 --- a/test/system/config/test017.ksh +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh -#SYS_DB_KEY and USER_DB_KEY should not have same value - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "USER_DB_KEY=1000" >>${REL_PATH}/csqltmp.conf -echo "SYS_DB_KEY=1000" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test018.ksh b/test/system/config/test018.ksh deleted file mode 100755 index 8adad591..00000000 --- a/test/system/config/test018.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#LOG_FILE should not be empty - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "LOG_FILE=" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test019.ksh b/test/system/config/test019.ksh deleted file mode 100755 index 6a5bbb4c..00000000 --- a/test/system/config/test019.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MAP_ADDRESS should not be <4MB - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAP_ADDRESS=300000000" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test020.ksh b/test/system/config/test020.ksh deleted file mode 100755 index fbb283bd..00000000 --- a/test/system/config/test020.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MAP_ADDRESS should not be >2GB - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MAP_ADDRESS=3000000000" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test021.ksh b/test/system/config/test021.ksh deleted file mode 100755 index 8ac4e916..00000000 --- a/test/system/config/test021.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MUTEX_TIMEOUT_SECS should not be -ve value - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MUTEX_TIMEOUT_SECS=-1" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test022.ksh b/test/system/config/test022.ksh deleted file mode 100755 index 86081db0..00000000 --- a/test/system/config/test022.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MUTEX_TIMEOUT_SECS should not be >360 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MUTEX_TIMEOUT_SECS=380" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test023.ksh b/test/system/config/test023.ksh deleted file mode 100755 index 6de18f62..00000000 --- a/test/system/config/test023.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MUTEX_TIMEOUT_USECS should not be -ve value - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MUTEX_TIMEOUT_USECS=-1" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test024.ksh b/test/system/config/test024.ksh deleted file mode 100755 index c95ca469..00000000 --- a/test/system/config/test024.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MUTEX_TIMEOUT_USECS should not be >1000000 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MUTEX_TIMEOUT_USECS=2000000" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test025.ksh b/test/system/config/test025.ksh deleted file mode 100755 index a614d8d3..00000000 --- a/test/system/config/test025.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MUTEX_TIMEOUT_RETRY should not be -ve value - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MUTEX_TIMEOUT_RETRY=-1" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test026.ksh b/test/system/config/test026.ksh deleted file mode 100755 index 9b04a0bc..00000000 --- a/test/system/config/test026.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#MUTEX_TIMEOUT_RETRY should not be >100 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "MUTEX_TIMEOUT_RETRY=200" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test027.ksh b/test/system/config/test027.ksh deleted file mode 100755 index acdd239f..00000000 --- a/test/system/config/test027.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#LOCK_TIMEOUT_SECS should not be -ve value - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "LOCK_TIMEOUT_SECS=-1" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test028.ksh b/test/system/config/test028.ksh deleted file mode 100755 index 9780bcca..00000000 --- a/test/system/config/test028.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#LOCK_TIMEOUT_SECS should not be >360 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "LOCK_TIMEOUT_SECS=380" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test029.ksh b/test/system/config/test029.ksh deleted file mode 100755 index 569ce88f..00000000 --- a/test/system/config/test029.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#LOCK_TIMEOUT_USECS should not be -ve value - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "LOCK_TIMEOUT_USECS=-1" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test030.ksh b/test/system/config/test030.ksh deleted file mode 100755 index eb8e1424..00000000 --- a/test/system/config/test030.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#LOCK_TIMEOUT_USECS should not be >1000000 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "LOCK_TIMEOUT_USECS=2000000" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test031.ksh b/test/system/config/test031.ksh deleted file mode 100755 index 0875f6c5..00000000 --- a/test/system/config/test031.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#LOCK_TIMEOUT_RETRY should not be -ve value - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "LOCK_TIMEOUT_RETRY=-1" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/config/test032.ksh b/test/system/config/test032.ksh deleted file mode 100755 index 4dc8addc..00000000 --- a/test/system/config/test032.ksh +++ /dev/null @@ -1,18 +0,0 @@ -#!/bin/sh -#LOCK_TIMEOUT_RETRY should not be >100 - - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail as CSQL_CONFIG_FILE may not be able to read -CSQL_CONF=${PWD}/system/config/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=`pwd`/system/config -fi -cp ${REL_PATH}/csql.conf ${REL_PATH}/csqltmp.conf -export CSQL_CONFIG_FILE=${REL_PATH}/csqltmp.conf -echo "LOCK_TIMEOUT_RETRY=200" >>${REL_PATH}/csqltmp.conf -${REL_PATH}/connect 2>${REL_PATH}/tmp.out -cat ${REL_PATH}/tmp.out | gawk -F: '{ print $5 }' -rm ${REL_PATH}/tmp.out ${REL_PATH}/csqltmp.conf diff --git a/test/system/index/TODO b/test/system/index/TODO deleted file mode 100644 index 546810ef..00000000 --- a/test/system/index/TODO +++ /dev/null @@ -1,24 +0,0 @@ -1.create table -.insert 10 tuples -.check for 0 index nodes -.create index -.insert 10 tuples -.check for 20 index nodes - -2.create table -.create index -.insert 10 tuples -.drop index -.check for 0 index nodes - -3.create table -.create two index -.insert 10 tuples -.check for 10 index nodes in both indexes - -4.create table -.create two index -.insert 10 tuples -.drop index idx2 -.insert 10 tuples -.check for 20 nodes in idx1 and 0 nodes in idx2 diff --git a/test/system/lock/Makefile b/test/system/lock/Makefile deleted file mode 100644 index 5bdf283a..00000000 --- a/test/system/lock/Makefile +++ /dev/null @@ -1,78 +0,0 @@ - -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -g -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsql - -TARGETS = \ - test001 test001a \ - test003 test003a \ - test004 test004a \ - test005 test005a \ - test006 test006a \ - test007 test007a \ - test008 test008a \ - test009 test009a \ - test002 test002a - - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -test001: locktest001.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test001a: locktest001.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test002: locktest002.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test002a: locktest002.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test003: locktest003.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test003a: locktest003.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test004: locktest004.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test004a: locktest004.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test005: locktest005.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test005a: locktest005.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test006: locktest006.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test006a: locktest006.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test007: locktest007.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test007a: locktest007.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test008: locktest008.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test008a: locktest008.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test009: locktest009.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test009a: locktest009.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -clean: - rm -f $(TARGETS) - diff --git a/test/system/lock/TODO b/test/system/lock/TODO deleted file mode 100644 index 2bb71a86..00000000 --- a/test/system/lock/TODO +++ /dev/null @@ -1,2 +0,0 @@ -1.create two threads, two READ_REPEATABLE trans, select 10 tuples, check noOfReaders -2. diff --git a/test/system/lock/common.h b/test/system/lock/common.h deleted file mode 100644 index a96442a6..00000000 --- a/test/system/lock/common.h +++ /dev/null @@ -1,153 +0,0 @@ -#include -DbRetVal createIndex(DatabaseManager *dbMgr, char *tblname, char *fldname, char *indname) -{ - HashIndexInitInfo *idxInfo = new HashIndexInitInfo(); - strcpy(idxInfo->tableName, tblname); - idxInfo->list.append(fldname); - idxInfo->indType = hashIndex; - idxInfo->isUnique = true; - idxInfo->isPrimary = true; - DbRetVal rv = dbMgr->createIndex(indname, idxInfo); - if (rv != OK) { printf("Index creation failed\n"); return rv; } - printf("Index created for %s\n", fldname); - delete idxInfo; - return OK; -} -DbRetVal createTable(DatabaseManager *dbMgr, char *tblname) -{ - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - tabDef.addField("f2", typeInt, 0 ,NULL, true); - DbRetVal rv = dbMgr->createTable(tblname, tabDef); - if (rv != OK) { printf("Table creation failed\n"); return rv; } - printf("Table created\n"); - return OK; -} -DbRetVal dropTable(DatabaseManager *dbMgr, char *tblname) -{ - DbRetVal rv = dbMgr->dropTable(tblname); - if (rv != OK) { printf("Table drop failed\n"); return rv; } - printf("Table Dropped\n"); - return OK; -} -int insertTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - int id1 = 0; - table->bindFld("f1", &id1); - table->bindFld("f2", &id1); - int icount =0; - DbRetVal rv = OK; - for (int i = 0 ; i < count ; i++) - { - id1= i; - rv = table->insertTuple(); - if (rv != OK) break; - icount++; - - } - printf("Total Tuples inserted is %d\n", icount); - dbMgr->closeTable(table); - return icount; -} - -int selectTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - DbRetVal rv = OK; - - Condition p1; - int val1 = 0; - p1.setTerm("f1", OpEquals, &val1); - table->setCondition(&p1); - int i =0; - void *tuple; - for (i = 0 ; i < count ; i++) - { - val1 = i; - table->execute(); - if (rv != OK) break; - tuple = (char*)table->fetch() ; - if (tuple == NULL) break; - table->closeScan(); - } - printf("Total Tuples selected is %d\n", i); - dbMgr->closeTable(table); - return i; -} -int updateTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - DbRetVal rv = OK; - - int id1 = 0, id2 =0; - table->bindFld("f1", &id1); - table->bindFld("f2", &id2); - Condition p1; - int val1 = 0; - p1.setTerm("f1", OpEquals, &val1); - table->setCondition(&p1); - int i =0; - void *tuple; - for (i = 0 ; i < count ; i++) - { - val1 = i; - table->execute(); - if (rv != OK) break; - tuple = (char*)table->fetch() ; - if (tuple == NULL) break; - id2 = 1000 + i; - rv = table->updateTuple(); - if (rv != OK) break; - table->closeScan(); - } - printf("Total Tuples updated is %d\n", i); - dbMgr->closeTable(table); - return i; -} -int deleteTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - DbRetVal rv = OK; - - Condition p1; - int val1 = 0; - p1.setTerm("f1", OpEquals, &val1); - table->setCondition(&p1); - int i =0; - void *tuple; - for (i = 0 ; i < count ; i++) - { - val1 = i; - table->execute(); - if (rv != OK) break; - tuple = (char*)table->fetch() ; - if (tuple == NULL) break; - rv = table->deleteTuple(); - if (rv != OK) break; - table->closeScan(); - } - printf("Total Tuples deleted is %d\n", i); - dbMgr->closeTable(table); - return i; -} diff --git a/test/system/lock/exp.test001 b/test/system/lock/exp.test001 deleted file mode 100644 index e69de29b..00000000 diff --git a/test/system/lock/exp.test001a b/test/system/lock/exp.test001a deleted file mode 100644 index 7de3f8cb..00000000 --- a/test/system/lock/exp.test001a +++ /dev/null @@ -1,114 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Before commit - - - 17e7a014 - -1 - 0 - 0 - - - 20 - 1 - - - 17e7a024 - -1 - 0 - 0 - - - 36 - 1 - - - 17e7a034 - -1 - 0 - 0 - - - 52 - 1 - - - 17e7a044 - -1 - 0 - 0 - - - 68 - 1 - - - 17e7a054 - -1 - 0 - 0 - - - 84 - 1 - - - 17e7a064 - -1 - 0 - 0 - - - 100 - 1 - - - 17e7a074 - -1 - 0 - 0 - - - 116 - 1 - - - 17e7a084 - -1 - 0 - 0 - - - 132 - 1 - - - 17e7a094 - -1 - 0 - 0 - - - 148 - 1 - - - 17e7a0a4 - -1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After commit - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test002 b/test/system/lock/exp.test002 deleted file mode 100644 index ff29f208..00000000 --- a/test/system/lock/exp.test002 +++ /dev/null @@ -1,113 +0,0 @@ -Table created -Total Tuples inserted is 10 -Before rollback - - - 17e84014 - -1 - 0 - 0 - - - 20 - 1 - - - 17e84024 - -1 - 0 - 0 - - - 36 - 1 - - - 17e84034 - -1 - 0 - 0 - - - 52 - 1 - - - 17e84044 - -1 - 0 - 0 - - - 68 - 1 - - - 17e84054 - -1 - 0 - 0 - - - 84 - 1 - - - 17e84064 - -1 - 0 - 0 - - - 100 - 1 - - - 17e84074 - -1 - 0 - 0 - - - 116 - 1 - - - 17e84084 - -1 - 0 - 0 - - - 132 - 1 - - - 17e84094 - -1 - 0 - 0 - - - 148 - 1 - - - 17e840a4 - -1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After rollback - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test002a b/test/system/lock/exp.test002a deleted file mode 100644 index b7e184b7..00000000 --- a/test/system/lock/exp.test002a +++ /dev/null @@ -1,114 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Before rollback - - - 17e84014 - -1 - 0 - 0 - - - 20 - 1 - - - 17e84024 - -1 - 0 - 0 - - - 36 - 1 - - - 17e84034 - -1 - 0 - 0 - - - 52 - 1 - - - 17e84044 - -1 - 0 - 0 - - - 68 - 1 - - - 17e84054 - -1 - 0 - 0 - - - 84 - 1 - - - 17e84064 - -1 - 0 - 0 - - - 100 - 1 - - - 17e84074 - -1 - 0 - 0 - - - 116 - 1 - - - 17e84084 - -1 - 0 - 0 - - - 132 - 1 - - - 17e84094 - -1 - 0 - 0 - - - 148 - 1 - - - 17e840a4 - -1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After rollback - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test003 b/test/system/lock/exp.test003 deleted file mode 100644 index b1156a6b..00000000 --- a/test/system/lock/exp.test003 +++ /dev/null @@ -1,14 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples selected is 10 -Before commit - - 0 - 1 - -After commit - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test003a b/test/system/lock/exp.test003a deleted file mode 100644 index 13121947..00000000 --- a/test/system/lock/exp.test003a +++ /dev/null @@ -1,15 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples selected is 10 -Before commit - - 0 - 1 - -After commit - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test004 b/test/system/lock/exp.test004 deleted file mode 100644 index b0b80091..00000000 --- a/test/system/lock/exp.test004 +++ /dev/null @@ -1,114 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples selected is 10 -Before commit - - - 17e84014 - 1 - 0 - 0 - - - 20 - 1 - - - 17e84024 - 1 - 0 - 0 - - - 36 - 1 - - - 17e84034 - 1 - 0 - 0 - - - 52 - 1 - - - 17e84044 - 1 - 0 - 0 - - - 68 - 1 - - - 17e84054 - 1 - 0 - 0 - - - 84 - 1 - - - 17e84064 - 1 - 0 - 0 - - - 100 - 1 - - - 17e84074 - 1 - 0 - 0 - - - 116 - 1 - - - 17e84084 - 1 - 0 - 0 - - - 132 - 1 - - - 17e84094 - 1 - 0 - 0 - - - 148 - 1 - - - 17e840a4 - 1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After commit - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test004a b/test/system/lock/exp.test004a deleted file mode 100644 index 3714a2ad..00000000 --- a/test/system/lock/exp.test004a +++ /dev/null @@ -1,115 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples selected is 10 -Before commit - - - 17e84014 - 1 - 0 - 0 - - - 20 - 1 - - - 17e84024 - 1 - 0 - 0 - - - 36 - 1 - - - 17e84034 - 1 - 0 - 0 - - - 52 - 1 - - - 17e84044 - 1 - 0 - 0 - - - 68 - 1 - - - 17e84054 - 1 - 0 - 0 - - - 84 - 1 - - - 17e84064 - 1 - 0 - 0 - - - 100 - 1 - - - 17e84074 - 1 - 0 - 0 - - - 116 - 1 - - - 17e84084 - 1 - 0 - 0 - - - 132 - 1 - - - 17e84094 - 1 - 0 - 0 - - - 148 - 1 - - - 17e840a4 - 1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After commit - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test005 b/test/system/lock/exp.test005 deleted file mode 100644 index 6c45bdad..00000000 --- a/test/system/lock/exp.test005 +++ /dev/null @@ -1,114 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples selected is 10 -Before rollback - - - 17e82014 - 1 - 0 - 0 - - - 20 - 1 - - - 17e82024 - 1 - 0 - 0 - - - 36 - 1 - - - 17e82034 - 1 - 0 - 0 - - - 52 - 1 - - - 17e82044 - 1 - 0 - 0 - - - 68 - 1 - - - 17e82054 - 1 - 0 - 0 - - - 84 - 1 - - - 17e82064 - 1 - 0 - 0 - - - 100 - 1 - - - 17e82074 - 1 - 0 - 0 - - - 116 - 1 - - - 17e82084 - 1 - 0 - 0 - - - 132 - 1 - - - 17e82094 - 1 - 0 - 0 - - - 148 - 1 - - - 17e820a4 - 1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After rollback - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test005a b/test/system/lock/exp.test005a deleted file mode 100644 index 00827f69..00000000 --- a/test/system/lock/exp.test005a +++ /dev/null @@ -1,115 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples selected is 10 -Before rollback - - - 17e82014 - 1 - 0 - 0 - - - 20 - 1 - - - 17e82024 - 1 - 0 - 0 - - - 36 - 1 - - - 17e82034 - 1 - 0 - 0 - - - 52 - 1 - - - 17e82044 - 1 - 0 - 0 - - - 68 - 1 - - - 17e82054 - 1 - 0 - 0 - - - 84 - 1 - - - 17e82064 - 1 - 0 - 0 - - - 100 - 1 - - - 17e82074 - 1 - 0 - 0 - - - 116 - 1 - - - 17e82084 - 1 - 0 - 0 - - - 132 - 1 - - - 17e82094 - 1 - 0 - 0 - - - 148 - 1 - - - 17e820a4 - 1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After rollback - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test006 b/test/system/lock/exp.test006 deleted file mode 100644 index 1730f56d..00000000 --- a/test/system/lock/exp.test006 +++ /dev/null @@ -1,114 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples updated is 10 -Before commit - - - 17e84014 - -1 - 0 - 0 - - - 20 - 1 - - - 17e84024 - -1 - 0 - 0 - - - 36 - 1 - - - 17e84034 - -1 - 0 - 0 - - - 52 - 1 - - - 17e84044 - -1 - 0 - 0 - - - 68 - 1 - - - 17e84054 - -1 - 0 - 0 - - - 84 - 1 - - - 17e84064 - -1 - 0 - 0 - - - 100 - 1 - - - 17e84074 - -1 - 0 - 0 - - - 116 - 1 - - - 17e84084 - -1 - 0 - 0 - - - 132 - 1 - - - 17e84094 - -1 - 0 - 0 - - - 148 - 1 - - - 17e840a4 - -1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After commit - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test006a b/test/system/lock/exp.test006a deleted file mode 100644 index 4f0b9f02..00000000 --- a/test/system/lock/exp.test006a +++ /dev/null @@ -1,115 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples updated is 10 -Before commit - - - 17e84014 - -1 - 0 - 0 - - - 20 - 1 - - - 17e84024 - -1 - 0 - 0 - - - 36 - 1 - - - 17e84034 - -1 - 0 - 0 - - - 52 - 1 - - - 17e84044 - -1 - 0 - 0 - - - 68 - 1 - - - 17e84054 - -1 - 0 - 0 - - - 84 - 1 - - - 17e84064 - -1 - 0 - 0 - - - 100 - 1 - - - 17e84074 - -1 - 0 - 0 - - - 116 - 1 - - - 17e84084 - -1 - 0 - 0 - - - 132 - 1 - - - 17e84094 - -1 - 0 - 0 - - - 148 - 1 - - - 17e840a4 - -1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After commit - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test007 b/test/system/lock/exp.test007 deleted file mode 100644 index 2f3ca8fd..00000000 --- a/test/system/lock/exp.test007 +++ /dev/null @@ -1,114 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples updated is 10 -Before abort - - - 17e82014 - -1 - 0 - 0 - - - 20 - 1 - - - 17e82024 - -1 - 0 - 0 - - - 36 - 1 - - - 17e82034 - -1 - 0 - 0 - - - 52 - 1 - - - 17e82044 - -1 - 0 - 0 - - - 68 - 1 - - - 17e82054 - -1 - 0 - 0 - - - 84 - 1 - - - 17e82064 - -1 - 0 - 0 - - - 100 - 1 - - - 17e82074 - -1 - 0 - 0 - - - 116 - 1 - - - 17e82084 - -1 - 0 - 0 - - - 132 - 1 - - - 17e82094 - -1 - 0 - 0 - - - 148 - 1 - - - 17e820a4 - -1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After abort - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test007a b/test/system/lock/exp.test007a deleted file mode 100644 index 7791589b..00000000 --- a/test/system/lock/exp.test007a +++ /dev/null @@ -1,115 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples updated is 10 -Before abort - - - 17e82014 - -1 - 0 - 0 - - - 20 - 1 - - - 17e82024 - -1 - 0 - 0 - - - 36 - 1 - - - 17e82034 - -1 - 0 - 0 - - - 52 - 1 - - - 17e82044 - -1 - 0 - 0 - - - 68 - 1 - - - 17e82054 - -1 - 0 - 0 - - - 84 - 1 - - - 17e82064 - -1 - 0 - 0 - - - 100 - 1 - - - 17e82074 - -1 - 0 - 0 - - - 116 - 1 - - - 17e82084 - -1 - 0 - 0 - - - 132 - 1 - - - 17e82094 - -1 - 0 - 0 - - - 148 - 1 - - - 17e820a4 - -1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After abort - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test008 b/test/system/lock/exp.test008 deleted file mode 100644 index 01cf9ee3..00000000 --- a/test/system/lock/exp.test008 +++ /dev/null @@ -1,114 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples deleted is 10 -Before commit - - - 17e84014 - -1 - 0 - 0 - - - 20 - 1 - - - 17e84024 - -1 - 0 - 0 - - - 36 - 1 - - - 17e84034 - -1 - 0 - 0 - - - 52 - 1 - - - 17e84044 - -1 - 0 - 0 - - - 68 - 1 - - - 17e84054 - -1 - 0 - 0 - - - 84 - 1 - - - 17e84064 - -1 - 0 - 0 - - - 100 - 1 - - - 17e84074 - -1 - 0 - 0 - - - 116 - 1 - - - 17e84084 - -1 - 0 - 0 - - - 132 - 1 - - - 17e84094 - -1 - 0 - 0 - - - 148 - 1 - - - 17e840a4 - -1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After commit - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test008a b/test/system/lock/exp.test008a deleted file mode 100644 index 2a282b6e..00000000 --- a/test/system/lock/exp.test008a +++ /dev/null @@ -1,115 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples deleted is 10 -Before commit - - - 17e84014 - -1 - 0 - 0 - - - 20 - 1 - - - 17e84024 - -1 - 0 - 0 - - - 36 - 1 - - - 17e84034 - -1 - 0 - 0 - - - 52 - 1 - - - 17e84044 - -1 - 0 - 0 - - - 68 - 1 - - - 17e84054 - -1 - 0 - 0 - - - 84 - 1 - - - 17e84064 - -1 - 0 - 0 - - - 100 - 1 - - - 17e84074 - -1 - 0 - 0 - - - 116 - 1 - - - 17e84084 - -1 - 0 - 0 - - - 132 - 1 - - - 17e84094 - -1 - 0 - 0 - - - 148 - 1 - - - 17e840a4 - -1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After commit - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test009 b/test/system/lock/exp.test009 deleted file mode 100644 index c019d246..00000000 --- a/test/system/lock/exp.test009 +++ /dev/null @@ -1,114 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples deleted is 10 -Before abort - - - 17e82014 - -1 - 0 - 0 - - - 20 - 1 - - - 17e82024 - -1 - 0 - 0 - - - 36 - 1 - - - 17e82034 - -1 - 0 - 0 - - - 52 - 1 - - - 17e82044 - -1 - 0 - 0 - - - 68 - 1 - - - 17e82054 - -1 - 0 - 0 - - - 84 - 1 - - - 17e82064 - -1 - 0 - 0 - - - 100 - 1 - - - 17e82074 - -1 - 0 - 0 - - - 116 - 1 - - - 17e82084 - -1 - 0 - 0 - - - 132 - 1 - - - 17e82094 - -1 - 0 - 0 - - - 148 - 1 - - - 17e820a4 - -1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After abort - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/exp.test009a b/test/system/lock/exp.test009a deleted file mode 100644 index 0eddf0c2..00000000 --- a/test/system/lock/exp.test009a +++ /dev/null @@ -1,115 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples deleted is 10 -Before abort - - - 17e82014 - -1 - 0 - 0 - - - 20 - 1 - - - 17e82024 - -1 - 0 - 0 - - - 36 - 1 - - - 17e82034 - -1 - 0 - 0 - - - 52 - 1 - - - 17e82044 - -1 - 0 - 0 - - - 68 - 1 - - - 17e82054 - -1 - 0 - 0 - - - 84 - 1 - - - 17e82064 - -1 - 0 - 0 - - - 100 - 1 - - - 17e82074 - -1 - 0 - 0 - - - 116 - 1 - - - 17e82084 - -1 - 0 - 0 - - - 132 - 1 - - - 17e82094 - -1 - 0 - 0 - - - 148 - 1 - - - 17e820a4 - -1 - 0 - 0 - - - 164 - 1 - - 10 - 1 - -After abort - - 0 - 1 - -Table Dropped diff --git a/test/system/lock/locktest001.c b/test/system/lock/locktest001.c deleted file mode 100644 index 72833cd1..00000000 --- a/test/system/lock/locktest001.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* insert 10 tuples -* check lock statistics -* commit transation -* check lock statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - printf("Before commit\n"); - dbMgr->printDebugLockInfo(); - conn.commit(); - printf("After commit\n"); - dbMgr->printDebugLockInfo(); - dropTable(dbMgr, "t1"); - conn.close(); - return ret; -} diff --git a/test/system/lock/locktest002.c b/test/system/lock/locktest002.c deleted file mode 100644 index bd3b64d5..00000000 --- a/test/system/lock/locktest002.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* insert 10 tuples -* check lock statistics -* abort transation -* check lock statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - printf("Before rollback\n"); - dbMgr->printDebugLockInfo(); - conn.rollback(); - printf("After rollback\n"); - dbMgr->printDebugLockInfo(); - dropTable(dbMgr, "t1"); - conn.close(); - return ret; -} diff --git a/test/system/lock/locktest003.c b/test/system/lock/locktest003.c deleted file mode 100644 index 6e962977..00000000 --- a/test/system/lock/locktest003.c +++ /dev/null @@ -1,43 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* start transaction with default isolation level -* select 10 tuples -* check lock statistics -* commit transation -* check lock statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = selectTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - printf("Before commit\n"); - dbMgr->printDebugLockInfo(); - conn.commit(); - printf("After commit\n"); - dbMgr->printDebugLockInfo(); - dropTable(dbMgr, "t1"); - conn.close(); - return ret; -} diff --git a/test/system/lock/locktest004.c b/test/system/lock/locktest004.c deleted file mode 100644 index b788051a..00000000 --- a/test/system/lock/locktest004.c +++ /dev/null @@ -1,43 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* start transaction with READ_REPEATABLE isolation level -* select 10 tuples -* check lock statistics -* commit transation -* check lock statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(READ_REPEATABLE); - if (rv != OK) ret = 5; - rc = selectTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - printf("Before commit\n"); - dbMgr->printDebugLockInfo(); - conn.commit(); - printf("After commit\n"); - dbMgr->printDebugLockInfo(); - dropTable(dbMgr, "t1"); - conn.close(); - return ret; -} diff --git a/test/system/lock/locktest005.c b/test/system/lock/locktest005.c deleted file mode 100644 index eb3ef5ee..00000000 --- a/test/system/lock/locktest005.c +++ /dev/null @@ -1,43 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* start transaction with READ_REPEATABLE isolation level -* select 10 tuples -* check lock statistics -* abort transation -* check lock statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(READ_REPEATABLE); - if (rv != OK) ret = 5; - rc = selectTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - printf("Before rollback\n"); - dbMgr->printDebugLockInfo(); - conn.rollback(); - printf("After rollback\n"); - dbMgr->printDebugLockInfo(); - dropTable(dbMgr, "t1"); - conn.close(); - return ret; -} diff --git a/test/system/lock/locktest006.c b/test/system/lock/locktest006.c deleted file mode 100644 index e85dd445..00000000 --- a/test/system/lock/locktest006.c +++ /dev/null @@ -1,43 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* start transaction with READ_REPEATABLE isolation level -* update 10 tuples -* check lock statistics -* commit transation -* check lock statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(READ_REPEATABLE); - if (rv != OK) ret = 5; - rc = updateTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - printf("Before commit\n"); - dbMgr->printDebugLockInfo(); - conn.commit(); - printf("After commit\n"); - dbMgr->printDebugLockInfo(); - dropTable(dbMgr, "t1"); - conn.close(); - return ret; -} diff --git a/test/system/lock/locktest007.c b/test/system/lock/locktest007.c deleted file mode 100644 index cc533c9f..00000000 --- a/test/system/lock/locktest007.c +++ /dev/null @@ -1,43 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* start transaction with READ_REPEATABLE isolation level -* update 10 tuples -* check lock statistics -* abort transation -* check lock statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(READ_REPEATABLE); - if (rv != OK) ret = 5; - rc = updateTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - printf("Before abort\n"); - dbMgr->printDebugLockInfo(); - conn.rollback(); - printf("After abort\n"); - dbMgr->printDebugLockInfo(); - dropTable(dbMgr, "t1"); - conn.close(); - return ret; -} diff --git a/test/system/lock/locktest008.c b/test/system/lock/locktest008.c deleted file mode 100644 index 02a0956f..00000000 --- a/test/system/lock/locktest008.c +++ /dev/null @@ -1,43 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* start transaction with READ_REPEATABLE isolation level -* delete 10 tuples -* check lock statistics -* commit transation -* check lock statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(READ_REPEATABLE); - if (rv != OK) ret = 5; - rc = deleteTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - printf("Before commit\n"); - dbMgr->printDebugLockInfo(); - conn.commit(); - printf("After commit\n"); - dbMgr->printDebugLockInfo(); - dropTable(dbMgr, "t1"); - conn.close(); - return ret; -} diff --git a/test/system/lock/locktest009.c b/test/system/lock/locktest009.c deleted file mode 100644 index b5cc8f83..00000000 --- a/test/system/lock/locktest009.c +++ /dev/null @@ -1,43 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* start transaction with READ_REPEATABLE isolation level -* delete 10 tuples -* check lock statistics -* abort transation -* check lock statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(READ_REPEATABLE); - if (rv != OK) ret = 5; - rc = deleteTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - printf("Before abort\n"); - dbMgr->printDebugLockInfo(); - conn.rollback(); - printf("After abort\n"); - dbMgr->printDebugLockInfo(); - dropTable(dbMgr, "t1"); - conn.close(); - return ret; -} diff --git a/test/system/proc/TODO b/test/system/proc/TODO deleted file mode 100644 index 15a41c5a..00000000 --- a/test/system/proc/TODO +++ /dev/null @@ -1,25 +0,0 @@ -1.process 1 does insert and sleep (no commit), kill thread 1. -.check if the inserted row is seen in the database. -2.Do 1 with index, check for index nodes after that. -3.Do the above for update -5.Do the above for delete -7.Do the above for mixed insert, update and delete -8.Do 7 with index -9.proc 1 doing insert and sleep, kill proc1 with SIGINT, SIGTERM. -.check if the tuple is seen.check log whether it did cleanup. -10.proc 1 doing insert continously, kill proc1 with SIGINT, SIGTERM. -.check if the tuple is seen.check log whether it did cleanup. - - -Fault: -1.process 1 does insert and sleeps after inserting in chunk and before it inserts into hash index. kill the process -.check if the inserted row is seen. check the number of index nodes. -2.process 1 does insert and sleeps after inserting in chunk and idx1 and before it inserts into idx2. kill the process -.check if the inserted row is seen. check the number of index nodes in both idx -3.Do 1 for update -4.Do 2 for update -5.Do 1 for delete -6.Do 2 for delete -7.For all mutexes in system, take mutex and sleep. kill the proc. -.call apis which acquire that mutex and check if it works (Not now) - diff --git a/test/system/proc/exp.test001.ksh b/test/system/proc/exp.test001.ksh deleted file mode 100644 index 52a98c11..00000000 --- a/test/system/proc/exp.test001.ksh +++ /dev/null @@ -1,6 +0,0 @@ -Case 1: -d option with no connections - 1 - 99 -Case 2: -d option after 120 connect/disconnect - 1 - 99 diff --git a/test/system/proc/test001.ksh b/test/system/proc/test001.ksh deleted file mode 100755 index 2e8fd2e1..00000000 --- a/test/system/proc/test001.ksh +++ /dev/null @@ -1,36 +0,0 @@ -#!/bin/sh -# TestCase: -# check proc slots used and free in proctable -# for i = 1 to 120 -# catalog -# end for -# check proc slots used and free in proctable -# check if any proc slot holds mutexes -# Note: catalog tool with no option specified connects and disconnects - -echo "Case 1: -d option with no connections" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D proc |grep Slots -if [ $? -ne 0 ] -then - exit 1; -fi - - -count=120 -while [ ${count} -gt 0 ] -do - count=`expr ${count} - 1` - $CSQL_INSTALL_ROOT/bin/catalog >/dev/null - if [ $? -ne 0 ] - then - echo "create table failed" - exit 100; - fi -done -echo "Case 2: -d option after 120 connect/disconnect" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D proc |grep Slots -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0 diff --git a/test/system/trans/Makefile b/test/system/trans/Makefile deleted file mode 100644 index fdf16ed5..00000000 --- a/test/system/trans/Makefile +++ /dev/null @@ -1,83 +0,0 @@ - -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -g -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsql - -TARGETS = \ - create drop \ - insert1andCommit insert1andAbort \ - test003 test003a \ - test004 test004a \ - test005 test005a \ - test006 test006a \ - test007 test007a \ - test008 test008a \ - test009 test009a \ - test010 test010a - - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -create: create.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -drop: drop.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -insert1andCommit: insert1andCommit.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -insert1andAbort: insert1andAbort.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test003: transtest003.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test003a: transtest003.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test004: transtest004.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test004a: transtest004.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test005: transtest005.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test005a: transtest005.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test006: transtest006.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test006a: transtest006.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test007: transtest007.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test007a: transtest007.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test008: transtest008.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test008a: transtest008.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test009: transtest009.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test009a: transtest009.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test010: transtest010.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -test010a: transtest010.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -clean: - rm -f $(TARGETS) - diff --git a/test/system/trans/common.h b/test/system/trans/common.h deleted file mode 100644 index 70460a1a..00000000 --- a/test/system/trans/common.h +++ /dev/null @@ -1,153 +0,0 @@ -#include -DbRetVal createIndex(DatabaseManager *dbMgr, char *tblname, char *fldname, char *indname) -{ - HashIndexInitInfo *idxInfo = new HashIndexInitInfo(); - strcpy(idxInfo->tableName, tblname); - idxInfo->list.append(fldname); - idxInfo->indType = hashIndex; - idxInfo->isPrimary = true; - idxInfo->isUnique = true; - DbRetVal rv = dbMgr->createIndex(indname, idxInfo); - if (rv != OK) { printf("Index creation failed\n"); return rv; } - printf("Index created for %s\n", fldname); - delete idxInfo; - return OK; -} -DbRetVal createTable(DatabaseManager *dbMgr, char *tblname) -{ - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - tabDef.addField("f2", typeInt); - DbRetVal rv = dbMgr->createTable(tblname, tabDef); - if (rv != OK) { printf("Table creation failed\n"); return rv; } - printf("Table created\n"); - return OK; -} -DbRetVal dropTable(DatabaseManager *dbMgr, char *tblname) -{ - DbRetVal rv = dbMgr->dropTable(tblname); - if (rv != OK) { printf("Table drop failed\n"); return rv; } - printf("Table Dropped\n"); - return OK; -} -int insertTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - int id1 = 0; - table->bindFld("f1", &id1); - table->bindFld("f2", &id1); - int icount =0; - DbRetVal rv = OK; - for (int i = 0 ; i < count ; i++) - { - id1= i; - rv = table->insertTuple(); - if (rv != OK) break; - icount++; - - } - printf("Total Tuples inserted is %d\n", icount); - dbMgr->closeTable(table); - return icount; -} - -int selectTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - DbRetVal rv = OK; - - Condition p1; - int val1 = 0; - p1.setTerm("f1", OpEquals, &val1); - table->setCondition(&p1); - int i =0; - void *tuple; - for (i = 0 ; i < count ; i++) - { - val1 = i; - table->execute(); - if (rv != OK) break; - tuple = (char*)table->fetch() ; - if (tuple == NULL) break; - table->closeScan(); - } - printf("Total Tuples selected is %d\n", i); - dbMgr->closeTable(table); - return i; -} -int updateTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - DbRetVal rv = OK; - - int id1 = 0, id2 =0; - table->bindFld("f1", &id1); - table->bindFld("f2", &id2); - Condition p1; - int val1 = 0; - p1.setTerm("f1", OpEquals, &val1); - table->setCondition(&p1); - int i =0; - void *tuple; - for (i = 0 ; i < count ; i++) - { - val1 = i; - table->execute(); - if (rv != OK) break; - tuple = (char*)table->fetch() ; - if (tuple == NULL) break; - id2 = 1000 + i; - rv = table->updateTuple(); - if (rv != OK) break; - table->closeScan(); - } - printf("Total Tuples updated is %d\n", i); - dbMgr->closeTable(table); - return i; -} -int deleteTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - DbRetVal rv = OK; - - Condition p1; - int val1 = 0; - p1.setTerm("f1", OpEquals, &val1); - table->setCondition(&p1); - int i =0; - void *tuple; - for (i = 0 ; i < count ; i++) - { - val1 = i; - table->execute(); - if (rv != OK) break; - tuple = (char*)table->fetch() ; - if (tuple == NULL) break; - rv = table->deleteTuple(); - if (rv != OK) break; - table->closeScan(); - } - printf("Total Tuples deleted is %d\n", i); - dbMgr->closeTable(table); - return i; -} diff --git a/test/system/trans/create.c b/test/system/trans/create.c deleted file mode 100644 index 2fa248b9..00000000 --- a/test/system/trans/create.c +++ /dev/null @@ -1,16 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - if ( createTable(dbMgr, "t1") != 0 ) { ret = 3; } - - conn.close(); - return ret; - -} diff --git a/test/system/trans/drop.c b/test/system/trans/drop.c deleted file mode 100644 index 88eec578..00000000 --- a/test/system/trans/drop.c +++ /dev/null @@ -1,15 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - if ( dropTable(dbMgr, "t1") != 0 ) { ret = 3; } - conn.close(); - return ret; - -} diff --git a/test/system/trans/exp.test001.ksh b/test/system/trans/exp.test001.ksh deleted file mode 100644 index dfe248b2..00000000 --- a/test/system/trans/exp.test001.ksh +++ /dev/null @@ -1,20 +0,0 @@ -Table created -Case 1: -d option with no transactions - - 0 - 100 - - 0 - 1 - - -Case 2: -d option after 120 commits - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test002.ksh b/test/system/trans/exp.test002.ksh deleted file mode 100644 index 1b0559f6..00000000 --- a/test/system/trans/exp.test002.ksh +++ /dev/null @@ -1,20 +0,0 @@ -Table created -Case 1: -d option with no transactions - - 0 - 100 - - 0 - 1 - - -Case 2: -d option after 120 aborts - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test003 b/test/system/trans/exp.test003 deleted file mode 100644 index fe546f6d..00000000 --- a/test/system/trans/exp.test003 +++ /dev/null @@ -1,141 +0,0 @@ -Table created -Total Tuples inserted is 10 -Before commit - - - - 1 - - 12 - 0 - 17e840a4 - - - 12 - 0 - 17e84094 - - - 12 - 0 - 17e84084 - - - 12 - 0 - 17e84074 - - - 12 - 0 - 17e84064 - - - 12 - 0 - 17e84054 - - - 12 - 0 - 17e84044 - - - 12 - 0 - 17e84034 - - - 12 - 0 - 17e84024 - - - 12 - 0 - 17e84014 - - 10 - - - 1 - - 17e84014 - -1 - 0 - 0 - - - 17e84024 - -1 - 0 - 0 - - - 17e84034 - -1 - 0 - 0 - - - 17e84044 - -1 - 0 - 0 - - - 17e84054 - -1 - 0 - 0 - - - 17e84064 - -1 - 0 - 0 - - - 17e84074 - -1 - 0 - 0 - - - 17e84084 - -1 - 0 - 0 - - - 17e84094 - -1 - 0 - 0 - - - 17e840a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 10 - 1 - - -After commit - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test003a b/test/system/trans/exp.test003a deleted file mode 100644 index eced5589..00000000 --- a/test/system/trans/exp.test003a +++ /dev/null @@ -1,192 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Before commit - - - - 1 - - 12 - 0 - 17e840a4 - - - 20 - 3 - 17e840a4 - - - 12 - 0 - 17e84094 - - - 20 - 3 - 17e84094 - - - 12 - 0 - 17e84084 - - - 20 - 3 - 17e84084 - - - 12 - 0 - 17e84074 - - - 20 - 3 - 17e84074 - - - 12 - 0 - 17e84064 - - - 20 - 3 - 17e84064 - - - 12 - 0 - 17e84054 - - - 20 - 3 - 17e84054 - - - 12 - 0 - 17e84044 - - - 20 - 3 - 17e84044 - - - 12 - 0 - 17e84034 - - - 20 - 3 - 17e84034 - - - 12 - 0 - 17e84024 - - - 20 - 3 - 17e84024 - - - 12 - 0 - 17e84014 - - - 20 - 3 - 17e84014 - - 20 - - - 1 - - 17e84014 - -1 - 0 - 0 - - - 17e84024 - -1 - 0 - 0 - - - 17e84034 - -1 - 0 - 0 - - - 17e84044 - -1 - 0 - 0 - - - 17e84054 - -1 - 0 - 0 - - - 17e84064 - -1 - 0 - 0 - - - 17e84074 - -1 - 0 - 0 - - - 17e84084 - -1 - 0 - 0 - - - 17e84094 - -1 - 0 - 0 - - - 17e840a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 20 - 1 - - -After commit - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test004 b/test/system/trans/exp.test004 deleted file mode 100644 index 43defc9f..00000000 --- a/test/system/trans/exp.test004 +++ /dev/null @@ -1,141 +0,0 @@ -Table created -Total Tuples inserted is 10 -Before abort - - - - 1 - - 12 - 0 - 17e820a4 - - - 12 - 0 - 17e82094 - - - 12 - 0 - 17e82084 - - - 12 - 0 - 17e82074 - - - 12 - 0 - 17e82064 - - - 12 - 0 - 17e82054 - - - 12 - 0 - 17e82044 - - - 12 - 0 - 17e82034 - - - 12 - 0 - 17e82024 - - - 12 - 0 - 17e82014 - - 10 - - - 1 - - 17e82014 - -1 - 0 - 0 - - - 17e82024 - -1 - 0 - 0 - - - 17e82034 - -1 - 0 - 0 - - - 17e82044 - -1 - 0 - 0 - - - 17e82054 - -1 - 0 - 0 - - - 17e82064 - -1 - 0 - 0 - - - 17e82074 - -1 - 0 - 0 - - - 17e82084 - -1 - 0 - 0 - - - 17e82094 - -1 - 0 - 0 - - - 17e820a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 10 - 1 - - -After abort - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test004a b/test/system/trans/exp.test004a deleted file mode 100644 index 9a91b849..00000000 --- a/test/system/trans/exp.test004a +++ /dev/null @@ -1,192 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Before abort - - - - 1 - - 12 - 0 - 17e820a4 - - - 20 - 3 - 17e820a4 - - - 12 - 0 - 17e82094 - - - 20 - 3 - 17e82094 - - - 12 - 0 - 17e82084 - - - 20 - 3 - 17e82084 - - - 12 - 0 - 17e82074 - - - 20 - 3 - 17e82074 - - - 12 - 0 - 17e82064 - - - 20 - 3 - 17e82064 - - - 12 - 0 - 17e82054 - - - 20 - 3 - 17e82054 - - - 12 - 0 - 17e82044 - - - 20 - 3 - 17e82044 - - - 12 - 0 - 17e82034 - - - 20 - 3 - 17e82034 - - - 12 - 0 - 17e82024 - - - 20 - 3 - 17e82024 - - - 12 - 0 - 17e82014 - - - 20 - 3 - 17e82014 - - 20 - - - 1 - - 17e82014 - -1 - 0 - 0 - - - 17e82024 - -1 - 0 - 0 - - - 17e82034 - -1 - 0 - 0 - - - 17e82044 - -1 - 0 - 0 - - - 17e82054 - -1 - 0 - 0 - - - 17e82064 - -1 - 0 - 0 - - - 17e82074 - -1 - 0 - 0 - - - 17e82084 - -1 - 0 - 0 - - - 17e82094 - -1 - 0 - 0 - - - 17e820a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 20 - 1 - - -After abort - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test005 b/test/system/trans/exp.test005 deleted file mode 100644 index eca46961..00000000 --- a/test/system/trans/exp.test005 +++ /dev/null @@ -1,32 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples selected is 10 -Before commit - - - - 1 - 0 - - - 1 - 0 - - - 1 - 99 - - 0 - 1 - - -After commit - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test005a b/test/system/trans/exp.test005a deleted file mode 100644 index 94387f5a..00000000 --- a/test/system/trans/exp.test005a +++ /dev/null @@ -1,33 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples selected is 10 -Before commit - - - - 1 - 0 - - - 1 - 0 - - - 1 - 99 - - 0 - 1 - - -After commit - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test006 b/test/system/trans/exp.test006 deleted file mode 100644 index 7a12c3a9..00000000 --- a/test/system/trans/exp.test006 +++ /dev/null @@ -1,32 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples selected is 10 -Before abort - - - - 1 - 0 - - - 1 - 0 - - - 1 - 99 - - 0 - 1 - - -After abort - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test006a b/test/system/trans/exp.test006a deleted file mode 100644 index ac667dfd..00000000 --- a/test/system/trans/exp.test006a +++ /dev/null @@ -1,33 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples selected is 10 -Before abort - - - - 1 - 0 - - - 1 - 0 - - - 1 - 99 - - 0 - 1 - - -After abort - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test007 b/test/system/trans/exp.test007 deleted file mode 100644 index 79ac37bf..00000000 --- a/test/system/trans/exp.test007 +++ /dev/null @@ -1,142 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples updated is 10 -Before commit - - - - 1 - - 12 - 2 - 17e840a4 - - - 12 - 2 - 17e84094 - - - 12 - 2 - 17e84084 - - - 12 - 2 - 17e84074 - - - 12 - 2 - 17e84064 - - - 12 - 2 - 17e84054 - - - 12 - 2 - 17e84044 - - - 12 - 2 - 17e84034 - - - 12 - 2 - 17e84024 - - - 12 - 2 - 17e84014 - - 10 - - - 1 - - 17e84014 - -1 - 0 - 0 - - - 17e84024 - -1 - 0 - 0 - - - 17e84034 - -1 - 0 - 0 - - - 17e84044 - -1 - 0 - 0 - - - 17e84054 - -1 - 0 - 0 - - - 17e84064 - -1 - 0 - 0 - - - 17e84074 - -1 - 0 - 0 - - - 17e84084 - -1 - 0 - 0 - - - 17e84094 - -1 - 0 - 0 - - - 17e840a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 10 - 1 - - -After commit - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test007a b/test/system/trans/exp.test007a deleted file mode 100644 index 08ddb559..00000000 --- a/test/system/trans/exp.test007a +++ /dev/null @@ -1,143 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples updated is 10 -Before commit - - - - 1 - - 12 - 2 - 17e840a4 - - - 12 - 2 - 17e84094 - - - 12 - 2 - 17e84084 - - - 12 - 2 - 17e84074 - - - 12 - 2 - 17e84064 - - - 12 - 2 - 17e84054 - - - 12 - 2 - 17e84044 - - - 12 - 2 - 17e84034 - - - 12 - 2 - 17e84024 - - - 12 - 2 - 17e84014 - - 10 - - - 1 - - 17e84014 - -1 - 0 - 0 - - - 17e84024 - -1 - 0 - 0 - - - 17e84034 - -1 - 0 - 0 - - - 17e84044 - -1 - 0 - 0 - - - 17e84054 - -1 - 0 - 0 - - - 17e84064 - -1 - 0 - 0 - - - 17e84074 - -1 - 0 - 0 - - - 17e84084 - -1 - 0 - 0 - - - 17e84094 - -1 - 0 - 0 - - - 17e840a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 10 - 1 - - -After commit - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test008 b/test/system/trans/exp.test008 deleted file mode 100644 index 33fad78b..00000000 --- a/test/system/trans/exp.test008 +++ /dev/null @@ -1,142 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples updated is 10 -Before abort - - - - 1 - - 12 - 2 - 17e820a4 - - - 12 - 2 - 17e82094 - - - 12 - 2 - 17e82084 - - - 12 - 2 - 17e82074 - - - 12 - 2 - 17e82064 - - - 12 - 2 - 17e82054 - - - 12 - 2 - 17e82044 - - - 12 - 2 - 17e82034 - - - 12 - 2 - 17e82024 - - - 12 - 2 - 17e82014 - - 10 - - - 1 - - 17e82014 - -1 - 0 - 0 - - - 17e82024 - -1 - 0 - 0 - - - 17e82034 - -1 - 0 - 0 - - - 17e82044 - -1 - 0 - 0 - - - 17e82054 - -1 - 0 - 0 - - - 17e82064 - -1 - 0 - 0 - - - 17e82074 - -1 - 0 - 0 - - - 17e82084 - -1 - 0 - 0 - - - 17e82094 - -1 - 0 - 0 - - - 17e820a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 10 - 1 - - -After abort - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test008a b/test/system/trans/exp.test008a deleted file mode 100644 index 0ae14c73..00000000 --- a/test/system/trans/exp.test008a +++ /dev/null @@ -1,143 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples updated is 10 -Before abort - - - - 1 - - 12 - 2 - 17e820a4 - - - 12 - 2 - 17e82094 - - - 12 - 2 - 17e82084 - - - 12 - 2 - 17e82074 - - - 12 - 2 - 17e82064 - - - 12 - 2 - 17e82054 - - - 12 - 2 - 17e82044 - - - 12 - 2 - 17e82034 - - - 12 - 2 - 17e82024 - - - 12 - 2 - 17e82014 - - 10 - - - 1 - - 17e82014 - -1 - 0 - 0 - - - 17e82024 - -1 - 0 - 0 - - - 17e82034 - -1 - 0 - 0 - - - 17e82044 - -1 - 0 - 0 - - - 17e82054 - -1 - 0 - 0 - - - 17e82064 - -1 - 0 - 0 - - - 17e82074 - -1 - 0 - 0 - - - 17e82084 - -1 - 0 - 0 - - - 17e82094 - -1 - 0 - 0 - - - 17e820a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 10 - 1 - - -After abort - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test009 b/test/system/trans/exp.test009 deleted file mode 100644 index 2858e020..00000000 --- a/test/system/trans/exp.test009 +++ /dev/null @@ -1,142 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples deleted is 10 -Before commit - - - - 1 - - 12 - 1 - 17e840a4 - - - 12 - 1 - 17e84094 - - - 12 - 1 - 17e84084 - - - 12 - 1 - 17e84074 - - - 12 - 1 - 17e84064 - - - 12 - 1 - 17e84054 - - - 12 - 1 - 17e84044 - - - 12 - 1 - 17e84034 - - - 12 - 1 - 17e84024 - - - 12 - 1 - 17e84014 - - 10 - - - 1 - - 17e84014 - -1 - 0 - 0 - - - 17e84024 - -1 - 0 - 0 - - - 17e84034 - -1 - 0 - 0 - - - 17e84044 - -1 - 0 - 0 - - - 17e84054 - -1 - 0 - 0 - - - 17e84064 - -1 - 0 - 0 - - - 17e84074 - -1 - 0 - 0 - - - 17e84084 - -1 - 0 - 0 - - - 17e84094 - -1 - 0 - 0 - - - 17e840a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 10 - 1 - - -After commit - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test009a b/test/system/trans/exp.test009a deleted file mode 100644 index 956b9fdc..00000000 --- a/test/system/trans/exp.test009a +++ /dev/null @@ -1,193 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples deleted is 10 -Before commit - - - - 1 - - 12 - 1 - 17e840a4 - - - 20 - 5 - 17e840a4 - - - 12 - 1 - 17e84094 - - - 20 - 5 - 17e84094 - - - 12 - 1 - 17e84084 - - - 20 - 5 - 17e84084 - - - 12 - 1 - 17e84074 - - - 20 - 5 - 17e84074 - - - 12 - 1 - 17e84064 - - - 20 - 5 - 17e84064 - - - 12 - 1 - 17e84054 - - - 20 - 5 - 17e84054 - - - 12 - 1 - 17e84044 - - - 20 - 5 - 17e84044 - - - 12 - 1 - 17e84034 - - - 20 - 5 - 17e84034 - - - 12 - 1 - 17e84024 - - - 20 - 5 - 17e84024 - - - 12 - 1 - 17e84014 - - - 20 - 5 - 17e84014 - - 20 - - - 1 - - 17e84014 - -1 - 0 - 0 - - - 17e84024 - -1 - 0 - 0 - - - 17e84034 - -1 - 0 - 0 - - - 17e84044 - -1 - 0 - 0 - - - 17e84054 - -1 - 0 - 0 - - - 17e84064 - -1 - 0 - 0 - - - 17e84074 - -1 - 0 - 0 - - - 17e84084 - -1 - 0 - 0 - - - 17e84094 - -1 - 0 - 0 - - - 17e840a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 20 - 1 - - -After commit - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test010 b/test/system/trans/exp.test010 deleted file mode 100644 index a1240376..00000000 --- a/test/system/trans/exp.test010 +++ /dev/null @@ -1,142 +0,0 @@ -Table created -Total Tuples inserted is 10 -Total Tuples deleted is 10 -Before abort - - - - 1 - - 12 - 1 - 17e820a4 - - - 12 - 1 - 17e82094 - - - 12 - 1 - 17e82084 - - - 12 - 1 - 17e82074 - - - 12 - 1 - 17e82064 - - - 12 - 1 - 17e82054 - - - 12 - 1 - 17e82044 - - - 12 - 1 - 17e82034 - - - 12 - 1 - 17e82024 - - - 12 - 1 - 17e82014 - - 10 - - - 1 - - 17e82014 - -1 - 0 - 0 - - - 17e82024 - -1 - 0 - 0 - - - 17e82034 - -1 - 0 - 0 - - - 17e82044 - -1 - 0 - 0 - - - 17e82054 - -1 - 0 - 0 - - - 17e82064 - -1 - 0 - 0 - - - 17e82074 - -1 - 0 - 0 - - - 17e82084 - -1 - 0 - 0 - - - 17e82094 - -1 - 0 - 0 - - - 17e820a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 10 - 1 - - -After abort - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/exp.test010a b/test/system/trans/exp.test010a deleted file mode 100644 index 2d28bd4f..00000000 --- a/test/system/trans/exp.test010a +++ /dev/null @@ -1,193 +0,0 @@ -Table created -Index created for f1 -Total Tuples inserted is 10 -Total Tuples deleted is 10 -Before abort - - - - 1 - - 12 - 1 - 17e820a4 - - - 20 - 5 - 17e820a4 - - - 12 - 1 - 17e82094 - - - 20 - 5 - 17e82094 - - - 12 - 1 - 17e82084 - - - 20 - 5 - 17e82084 - - - 12 - 1 - 17e82074 - - - 20 - 5 - 17e82074 - - - 12 - 1 - 17e82064 - - - 20 - 5 - 17e82064 - - - 12 - 1 - 17e82054 - - - 20 - 5 - 17e82054 - - - 12 - 1 - 17e82044 - - - 20 - 5 - 17e82044 - - - 12 - 1 - 17e82034 - - - 20 - 5 - 17e82034 - - - 12 - 1 - 17e82024 - - - 20 - 5 - 17e82024 - - - 12 - 1 - 17e82014 - - - 20 - 5 - 17e82014 - - 20 - - - 1 - - 17e82014 - -1 - 0 - 0 - - - 17e82024 - -1 - 0 - 0 - - - 17e82034 - -1 - 0 - 0 - - - 17e82044 - -1 - 0 - 0 - - - 17e82054 - -1 - 0 - 0 - - - 17e82064 - -1 - 0 - 0 - - - 17e82074 - -1 - 0 - 0 - - - 17e82084 - -1 - 0 - 0 - - - 17e82094 - -1 - 0 - 0 - - - 17e820a4 - -1 - 0 - 0 - - 10 - - - 1 - 99 - - 20 - 1 - - -After abort - - 0 - 100 - - 0 - 1 - - -Table Dropped diff --git a/test/system/trans/insert1andAbort.c b/test/system/trans/insert1andAbort.c deleted file mode 100644 index 778e0cb0..00000000 --- a/test/system/trans/insert1andAbort.c +++ /dev/null @@ -1,17 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - conn.startTransaction(); - ret = insertTuple(dbMgr, conn, "t1", 1); - conn.rollback(); - conn.close(); - return ret; - -} diff --git a/test/system/trans/insert1andCommit.c b/test/system/trans/insert1andCommit.c deleted file mode 100644 index 39e669d4..00000000 --- a/test/system/trans/insert1andCommit.c +++ /dev/null @@ -1,17 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - conn.startTransaction(); - ret = insertTuple(dbMgr, conn, "t1", 1); - conn.commit(); - conn.close(); - return ret; - -} diff --git a/test/system/trans/locktest009.c b/test/system/trans/locktest009.c deleted file mode 100644 index 448b33d8..00000000 --- a/test/system/trans/locktest009.c +++ /dev/null @@ -1,44 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* insert 10 tuples -* start new transaction -* delete 10 tuples -* check transaction statistics -* commit transation -* check transaction statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = deleteTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - - printf("Before commit\n"); - dbMgr->printDebugTransInfo(); - conn.commit(); - printf("After commit\n"); - dbMgr->printDebugTransInfo(); - conn.close(); - return ret; -} diff --git a/test/system/trans/test001.ksh b/test/system/trans/test001.ksh deleted file mode 100755 index 757aa8b5..00000000 --- a/test/system/trans/test001.ksh +++ /dev/null @@ -1,56 +0,0 @@ -#!/bin/sh -# TestCase: -# check used and free transacation slots in transaction table -# create table -# for i = 1 to 120 -# insert 1 tuple in 1 transaction and commit -# end for -# check used and free transacation slots in transaction table - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -EXECUTABLE=${PWD}/system/trans/create -REL_PATH=. -if [ -s "$EXECUTABLE" ] -then - REL_PATH=${PWD}/system/trans -fi -${REL_PATH}/create -if [ $? -ne 0 ] -then - echo "create table failed" - exit 100; -fi - -echo "Case 1: -d option with no transactions" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D trans -if [ $? -ne 0 ] -then - exit 1; -fi - - -count=120 -while [ ${count} -gt 0 ] -do - count=`expr ${count} - 1` - ${REL_PATH}/insert1andCommit >/tmp/tstlog - if [ $? -ne 1 ] - then - echo "insert failed" - exit 100; - fi -done -echo "Case 2: -d option after 120 commits" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D trans -if [ $? -ne 0 ] -then - exit 1; -fi -${REL_PATH}/drop -if [ $? -ne 0 ] -then - echo "drop table failed" - exit 100; -fi -exit 0 diff --git a/test/system/trans/test002.ksh b/test/system/trans/test002.ksh deleted file mode 100755 index 36e300ec..00000000 --- a/test/system/trans/test002.ksh +++ /dev/null @@ -1,56 +0,0 @@ -#!/bin/sh -# TestCase: -# check used and free transacation slots in transaction table -# create table -# for i = 1 to 120 -# insert 1 tuple in 1 transaction and abort -# end for -# check used and free transacation slots in transaction table - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -EXECUTABLE=${PWD}/system/trans/create -REL_PATH=. -if [ -s "$EXECUTABLE" ] -then - REL_PATH=${PWD}/system/trans -fi -${REL_PATH}/create -if [ $? -ne 0 ] -then - echo "create table failed" - exit 100; -fi - -echo "Case 1: -d option with no transactions" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D trans -if [ $? -ne 0 ] -then - exit 1; -fi - - -count=120 -while [ ${count} -gt 0 ] -do - count=`expr ${count} - 1` - ${REL_PATH}/insert1andAbort >/tmp/tstlog - if [ $? -ne 1 ] - then - echo "insert failed" - exit 100; - fi -done -echo "Case 2: -d option after 120 aborts" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D trans -if [ $? -ne 0 ] -then - exit 1; -fi -${REL_PATH}/drop -if [ $? -ne 0 ] -then - echo "drop table failed" - exit 100; -fi -exit 0 diff --git a/test/system/trans/transtest003.c b/test/system/trans/transtest003.c deleted file mode 100644 index 48a9a3c1..00000000 --- a/test/system/trans/transtest003.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* insert 10 tuples -* check transaction statistics -* commit transation -* check transaction statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - printf("Before commit\n"); - dbMgr->printDebugTransInfo(); - conn.commit(); - printf("After commit\n"); - dbMgr->printDebugTransInfo(); - dropTable(dbMgr ,"t1"); - conn.close(); - return ret; -} diff --git a/test/system/trans/transtest004.c b/test/system/trans/transtest004.c deleted file mode 100644 index d75cde06..00000000 --- a/test/system/trans/transtest004.c +++ /dev/null @@ -1,36 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* insert 10 tuples -* check transaction statistics -* abort transation -* check transaction statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - printf("Before abort\n"); - dbMgr->printDebugTransInfo(); - conn.rollback(); - printf("After abort\n"); - dbMgr->printDebugTransInfo(); - dropTable(dbMgr ,"t1"); - conn.close(); - return ret; -} diff --git a/test/system/trans/transtest005.c b/test/system/trans/transtest005.c deleted file mode 100644 index f989dc86..00000000 --- a/test/system/trans/transtest005.c +++ /dev/null @@ -1,45 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* insert 10 tuples -* start new transaction -* select 10 tuples -* check transaction statistics -* commit transation -* check transaction statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = selectTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - - printf("Before commit\n"); - dbMgr->printDebugTransInfo(); - conn.commit(); - printf("After commit\n"); - dbMgr->printDebugTransInfo(); - dropTable(dbMgr ,"t1"); - conn.close(); - return ret; -} diff --git a/test/system/trans/transtest006.c b/test/system/trans/transtest006.c deleted file mode 100644 index 02649f56..00000000 --- a/test/system/trans/transtest006.c +++ /dev/null @@ -1,45 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* insert 10 tuples -* start new transaction -* select 10 tuples -* check transaction statistics -* abort transation -* check transaction statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = selectTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - - printf("Before abort\n"); - dbMgr->printDebugTransInfo(); - conn.rollback(); - printf("After abort\n"); - dbMgr->printDebugTransInfo(); - dropTable(dbMgr ,"t1"); - conn.close(); - return ret; -} diff --git a/test/system/trans/transtest007.c b/test/system/trans/transtest007.c deleted file mode 100644 index 7acc2e3c..00000000 --- a/test/system/trans/transtest007.c +++ /dev/null @@ -1,45 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* insert 10 tuples -* start new transaction -* update 10 tuples -* check transaction statistics -* commit transation -* check transaction statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = updateTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - - printf("Before commit\n"); - dbMgr->printDebugTransInfo(); - conn.commit(); - printf("After commit\n"); - dbMgr->printDebugTransInfo(); - dropTable(dbMgr ,"t1"); - conn.close(); - return ret; -} diff --git a/test/system/trans/transtest008.c b/test/system/trans/transtest008.c deleted file mode 100644 index e8408b7f..00000000 --- a/test/system/trans/transtest008.c +++ /dev/null @@ -1,45 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* insert 10 tuples -* start new transaction -* update 10 tuples -* check transaction statistics -* abort transation -* check transaction statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = updateTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - - printf("Before abort\n"); - dbMgr->printDebugTransInfo(); - conn.rollback(); - printf("After abort\n"); - dbMgr->printDebugTransInfo(); - dropTable(dbMgr ,"t1"); - conn.close(); - return ret; -} diff --git a/test/system/trans/transtest009.c b/test/system/trans/transtest009.c deleted file mode 100644 index e822f0aa..00000000 --- a/test/system/trans/transtest009.c +++ /dev/null @@ -1,45 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* insert 10 tuples -* start new transaction -* delete 10 tuples -* check transaction statistics -* commit transation -* check transaction statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = deleteTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - - printf("Before commit\n"); - dbMgr->printDebugTransInfo(); - conn.commit(); - printf("After commit\n"); - dbMgr->printDebugTransInfo(); - dropTable(dbMgr ,"t1"); - conn.close(); - return ret; -} diff --git a/test/system/trans/transtest010.c b/test/system/trans/transtest010.c deleted file mode 100644 index 2ec9d2d4..00000000 --- a/test/system/trans/transtest010.c +++ /dev/null @@ -1,45 +0,0 @@ -/********************************************************** -* Test Case -* create table t1 -* create index if specified -* insert 10 tuples -* start new transaction -* delete 10 tuples -* check transaction statistics -* abort transation -* check transaction statistics -*/ -#include "common.h" -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManagerImpl *dbMgr = (DatabaseManagerImpl*) conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0, rc =0; - if (createTable(dbMgr, "t1") != 0 ) { ret = 3; } -#ifdef WITHINDEX - if (createIndex(dbMgr, "t1","f1", "idx1") != 0 ) { ret = 4; } -#endif - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = insertTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - conn.commit(); - - rv = conn.startTransaction(); - if (rv != OK) ret = 5; - rc = deleteTuple(dbMgr, conn, "t1", 10); - if (rc != 10) ret = 6; - - printf("Before abort\n"); - dbMgr->printDebugTransInfo(); - conn.rollback(); - printf("After abort\n"); - dbMgr->printDebugTransInfo(); - dropTable(dbMgr ,"t1"); - conn.close(); - return ret; -} diff --git a/test/tools/Durability/auto.sql b/test/tools/Durability/auto.sql deleted file mode 100644 index 31aa7fdf..00000000 --- a/test/tools/Durability/auto.sql +++ /dev/null @@ -1 +0,0 @@ -SET AUTOCOMMIT OFF diff --git a/test/tools/Durability/compo_index2_10.sql b/test/tools/Durability/compo_index2_10.sql deleted file mode 100644 index e6488de4..00000000 --- a/test/tools/Durability/compo_index2_10.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo CREATE INDEX idx1 ON T1(f2,f1) UNIQUE; -CREATE INDEX idx1 ON T1(f2,f1) UNIQUE; -echo CREATE INDEX idx2 ON T2(f2,f1) UNIQUE; -CREATE INDEX idx2 ON T2(f2,f1) UNIQUE; -echo CREATE INDEX idx3 ON T3(f2,f1) UNIQUE; -CREATE INDEX idx3 ON T3(f2,f1) UNIQUE; -echo CREATE INDEX idx4 ON T4(f2,f1) UNIQUE; -CREATE INDEX idx4 ON T4(f2,f1) UNIQUE; -echo CREATE INDEX idx5 ON T5(f2,f1) UNIQUE; -CREATE INDEX idx5 ON T5(f2,f1) UNIQUE; -echo CREATE INDEX idx6 ON T6(f2,f1) UNIQUE; -CREATE INDEX idx6 ON T6(f2,f1) UNIQUE; -echo CREATE INDEX idx7 ON T7(f2,f1) UNIQUE; -CREATE INDEX idx7 ON T7(f2,f1) UNIQUE; -echo CREATE INDEX idx8 ON T8(f2,f1) UNIQUE; -CREATE INDEX idx8 ON T8(f2,f1) UNIQUE; -echo CREATE INDEX idx9 ON T9(f2,f1) UNIQUE; -CREATE INDEX idx9 ON T9(f2,f1) UNIQUE; -echo CREATE INDEX idx10 ON T10(f2,f1) UNIQUE; -CREATE INDEX idx10 ON T10(f2,f1) UNIQUE; diff --git a/test/tools/Durability/create_10.sql b/test/tools/Durability/create_10.sql deleted file mode 100644 index 6362b47e..00000000 --- a/test/tools/Durability/create_10.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo CREATE TABLE T1(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -CREATE TABLE T1(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -echo CREATE TABLE T2(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -CREATE TABLE T2(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -echo CREATE TABLE T3(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -CREATE TABLE T3(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -echo CREATE TABLE T4(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -CREATE TABLE T4(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -echo CREATE TABLE T5(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -CREATE TABLE T5(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -echo CREATE TABLE T6(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -CREATE TABLE T6(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -echo CREATE TABLE T7(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -CREATE TABLE T7(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -echo CREATE TABLE T8(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -CREATE TABLE T8(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -echo CREATE TABLE T9(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -CREATE TABLE T9(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -echo CREATE TABLE T10(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -CREATE TABLE T10(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); diff --git a/test/tools/Durability/create_pri_10.sql b/test/tools/Durability/create_pri_10.sql deleted file mode 100644 index 8c9e6a84..00000000 --- a/test/tools/Durability/create_pri_10.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo CREATE TABLE T1(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -CREATE TABLE T1(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -echo CREATE TABLE T2(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -CREATE TABLE T2(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -echo CREATE TABLE T3(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -CREATE TABLE T3(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -echo CREATE TABLE T4(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -CREATE TABLE T4(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -echo CREATE TABLE T5(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -CREATE TABLE T5(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -echo CREATE TABLE T6(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -CREATE TABLE T6(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -echo CREATE TABLE T7(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -CREATE TABLE T7(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -echo CREATE TABLE T8(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -CREATE TABLE T8(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -echo CREATE TABLE T9(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -CREATE TABLE T9(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -echo CREATE TABLE T10(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -CREATE TABLE T10(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); diff --git a/test/tools/Durability/create_t1.sql b/test/tools/Durability/create_t1.sql deleted file mode 100644 index cab65d30..00000000 --- a/test/tools/Durability/create_t1.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo create table t1 (f1 char(10), f2 tinyint, f3 smallint,f4 int, f5 bigint,f6 integer, f7 float, f8 real,f9 double,f10 long,f11 binary(128),f12 date,f13 time,f14 timestamp); -create table t1 (f1 char(10), f2 tinyint, f3 smallint,f4 int, f5 bigint,f6 integer, f7 float, f8 real,f9 double,f10 long,f11 binary(128),f12 date,f13 time,f14 timestamp); diff --git a/test/tools/Durability/create_t2.sql b/test/tools/Durability/create_t2.sql deleted file mode 100644 index 5f5451d3..00000000 --- a/test/tools/Durability/create_t2.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo create table t2(f1 int,f2 float,f3 date); -create table t2(f1 int,f2 float,f3 date); diff --git a/test/tools/Durability/csql.conf b/test/tools/Durability/csql.conf deleted file mode 100644 index d4e47de0..00000000 --- a/test/tools/Durability/csql.conf +++ /dev/null @@ -1,103 +0,0 @@ -# CSQL System Configuration File - -#####################################Server Section######################## -#Important: For Server section parameters, make sure that the value is same for the -# server process and all the csql client process which connects to it. otherwise, -# behavior is undefined - -# Page size. Each database is logically divided into pages and allocation happens -# in this unit of pages. Increasing this value will reduce frequent allocation of pages. -PAGE_SIZE= 8192 - -#Total number of client process which can connect and work with the -# database concurrently -MAX_PROCS = 100 - -# Maximum size of the system database. -MAX_SYS_DB_SIZE=1048576 - -#Maximum size of the user database file. -MAX_DB_SIZE=10485760 - -#Shared memory key to be used by the system to create and locate system database. -SYS_DB_KEY=2222 - -#Shared memory key to be used by the system to create and locate user database. -USER_DB_KEY=3333 - -#Give full path for the log file where important system actions are stored. -LOG_FILE=/tmp/csql/log/log.out - -#The virtual memory start address at which the shared memory segment -# will be created and attached. -MAP_ADDRESS=400000000 - -# Whether to enable durability -DURABILITY=false - -#Give full path for the database file where table and record information will -#be stored for durability -DATABASE_FILE=/tmp/csql/db - -#Important: For Server section parameters, make sure that the value is same for the -# server process and all the csql client process which connects to it. otherwise, -# behavior is undefined -#####################################Client Section######################## - -#Mutex timeout interval seconds -MUTEX_TIMEOUT_SECS=0 -MUTEX_TIMEOUT_USECS=5000 -MUTEX_TIMEOUT_RETRIES=10 - -#Lock timeout interval seconds -LOCK_TIMEOUT_SECS=0 -LOCK_TIMEOUT_USECS=5000 -LOCK_TIMEOUT_RETRIES=10 - -#####################################Cache Section######################## - -#Whether to enable caching of tables from target database -CACHE_TABLE=false - -#Set cache id for multiple bidirectional cache node for single data source -CACHE_ID=1 -#DSN Name to connect to the target database. -#This should be present in ~/odbc.ini file -DSN=myodbc3 - -USER= - -PASSWORD= - -ENABLE_BIDIRECTIONAL_CACHE=false - -CACHE_RECEIVER_WAIT_SECS=10 - -#Give full path for the file where all the cached table information is stored -TABLE_CONFIG_FILE=/tmp/csql/csqltable.conf - -#Mode of operation SYNC or ASYNC -CACHE_MODE=SYNC - -##########################SqlNetworkServer Section######################## - -# Whether to enable SqlNetwork server -CSQL_SQL_SERVER=false - -#Set port for Network access -PORT=5678 - -#Whether to enable Replication across the sites -REPLICATION=false - -#No of sites to replicate -REPLICATION_SITES=16 - -#Give full path for the file where all the peer site information is stored -NETWORK_CONFIG_FILE=/tmp/csql/csqlnw.conf - -# MSGKEY for creating msg queue for MsgQueue Server -MSG_KEY=2525 - -ID_SHM_KEY=1947 -#####################################End Section######################## diff --git a/test/tools/Durability/delete_10.sql b/test/tools/Durability/delete_10.sql deleted file mode 100644 index 22fcfd8d..00000000 --- a/test/tools/Durability/delete_10.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo DELETE FROM T1 WHERE f1 = 1; -DELETE FROM T1 WHERE f1 = 1; -echo DELETE FROM T2 WHERE f1 = 1; -DELETE FROM T2 WHERE f1 = 1; -echo DELETE FROM T3 WHERE f1 = 1; -DELETE FROM T3 WHERE f1 = 1; -echo DELETE FROM T4 WHERE f1 = 1; -DELETE FROM T4 WHERE f1 = 1; -echo DELETE FROM T5 WHERE f1 = 1; -DELETE FROM T5 WHERE f1 = 1; -echo DELETE FROM T6 WHERE f1 = 1; -DELETE FROM T6 WHERE f1 = 1; -echo DELETE FROM T7 WHERE f1 = 1; -DELETE FROM T7 WHERE f1 = 1; -echo DELETE FROM T8 WHERE f1 = 1; -DELETE FROM T8 WHERE f1 = 1; -echo DELETE FROM T9 WHERE f1 = 1; -DELETE FROM T9 WHERE f1 = 1; -echo DELETE FROM T10 WHERE f1 = 1; -DELETE FROM T10 WHERE f1 = 1; diff --git a/test/tools/Durability/delete_t1.sql b/test/tools/Durability/delete_t1.sql deleted file mode 100644 index 94a48230..00000000 --- a/test/tools/Durability/delete_t1.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo delete from t1; -delete from t1; diff --git a/test/tools/Durability/drop_10.sql b/test/tools/Durability/drop_10.sql deleted file mode 100644 index 45e57147..00000000 --- a/test/tools/Durability/drop_10.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo DROP TABLE T1; -DROP TABLE T1; -echo DROP TABLE T2; -DROP TABLE T2; -echo DROP TABLE T3; -DROP TABLE T3; -echo DROP TABLE T4; -DROP TABLE T4; -echo DROP TABLE T5; -DROP TABLE T5; -echo DROP TABLE T6; -DROP TABLE T6; -echo DROP TABLE T7; -DROP TABLE T7; -echo DROP TABLE T8; -DROP TABLE T8; -echo DROP TABLE T9; -DROP TABLE T9; -echo DROP TABLE T10; -DROP TABLE T10; diff --git a/test/tools/Durability/drop_t1.sql b/test/tools/Durability/drop_t1.sql deleted file mode 100644 index 0bf7a82b..00000000 --- a/test/tools/Durability/drop_t1.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo drop table t1; -drop table t1; diff --git a/test/tools/Durability/exp.test001.ksh b/test/tools/Durability/exp.test001.ksh deleted file mode 100644 index bd2c2ce5..00000000 --- a/test/tools/Durability/exp.test001.ksh +++ /dev/null @@ -1,12 +0,0 @@ -Durablity = FALSE -Server Started -Statement Executed -Server Killed - -Durablity = FALSE -Checking Durability -Server Started - -1,2d0 -< CREATE TABLE laks (f1 INT ); -< SET AUTOCOMMIT OFF; diff --git a/test/tools/Durability/exp.test002.ksh b/test/tools/Durability/exp.test002.ksh deleted file mode 100644 index beb76be6..00000000 --- a/test/tools/Durability/exp.test002.ksh +++ /dev/null @@ -1,9 +0,0 @@ -Durablity = TRUE -Server Started -Statement Executed -Server Killed - -Durablity = TRUE -Checking Durability -Server Started - diff --git a/test/tools/Durability/exp.test003.ksh b/test/tools/Durability/exp.test003.ksh deleted file mode 100644 index 119c0977..00000000 --- a/test/tools/Durability/exp.test003.ksh +++ /dev/null @@ -1,12 +0,0 @@ -Durablity = TRUE -Server Started -Statement Executed -Server Killed - -Durablity = FALSE -Checking Durability -Server Started - -1,2d0 -< CREATE TABLE laks (f1 INT ); -< SET AUTOCOMMIT OFF; diff --git a/test/tools/Durability/exp.test004.ksh b/test/tools/Durability/exp.test004.ksh deleted file mode 100644 index 86ac8653..00000000 --- a/test/tools/Durability/exp.test004.ksh +++ /dev/null @@ -1,12 +0,0 @@ -Durablity = FALSE -Server Started -Statement Executed -Server Killed - -Durablity = TRUE -Checking Durability -Server Started - -1,2d0 -< CREATE TABLE laks (f1 INT ); -< SET AUTOCOMMIT OFF; diff --git a/test/tools/Durability/exp.test005.ksh b/test/tools/Durability/exp.test005.ksh deleted file mode 100644 index ca94b545..00000000 --- a/test/tools/Durability/exp.test005.ksh +++ /dev/null @@ -1,39 +0,0 @@ -Durablity = TRUE -Server Started -CREATING TABLE -echo create table t1 (f1 char(10), f2 tinyint, f3 smallint,f4 int, f5 bigint,f6 integer, f7 float, f8 real,f9 double,f10 long,f11 binary(128),f12 date,f13 time,f14 timestamp); -Statement Executed -Server Killed - -Durablity = TRUE -Checking Durability -Server Started -INSERTING INTO TABLE -echo insert into t1 values('NIHAR', 1,1,-2147483648,9223372036854775807, 2147483648,1.1, 1000000000.000000,10000001.10000001,99999,'ABCDEF0123456789','2001-1-1', '01:01:01', '2001-11-30 01:01:01'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL); -Statement Executed: Rows Affected = 1 -Server Killed - -Durablity = TRUE -Checking Durability -Server Started -UPDATING RECORDS IN TABLE -echo UPDATE t1 set f1='PAPU', f2=10, f3=2, f4=2147483647, f5=-9223372036854775808, f6=-2147483647, f7=10.01, f8=2000000002.000002, f9=20000002.200002, f10=2147483647, f11='9876543210DcAbEf', f12='2003-3-3', f13='03:03:03', f14='2003-3-3 03:03:03'; -Statement Executed: Rows Affected = 2 -Server Killed - -Durablity = TRUE -Checking Durability -Server Started -DELETING RECORDS FROM TABLE -echo delete from t1; -Statement Executed: Rows Affected = 2 -Server Killed - -Durablity = TRUE -Checking Durability -Server Started -DROPPING TABLE -echo drop table t1; -Statement Executed diff --git a/test/tools/Durability/exp.test006.ksh b/test/tools/Durability/exp.test006.ksh deleted file mode 100644 index a5b02493..00000000 --- a/test/tools/Durability/exp.test006.ksh +++ /dev/null @@ -1,51 +0,0 @@ -Durablity = TRUE -Server Started -CREATING TABLE -echo create table t2(f1 int,f2 float,f3 date); -Statement Executed -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(20,200.002,'2002-2-2'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(30,300.003,'2003-3-3'); -Statement Executed: Rows Affected = 1 -echo SET AUTOCOMMIT OFF; -AUTOCOMMIT Mode is set to OFF -echo insert into t2 values(100,1000.0001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(500,5000.0005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(100,1000.0001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(200,2000.0002,'2002-2-2'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(300,3000.0003,'2003-3-3'); -Statement Executed: Rows Affected = 1 -echo select * from t2; ---------------------------------------------------------- - t2.f1 t2.f2 t2.f3 ---------------------------------------------------------- - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 20 200.001999 2002/2/2 - 30 300.002991 2003/3/3 - 100 1000.000122 2001/1/1 - 500 5000.000488 2005/5/5 - 100 1000.000122 2001/1/1 - 200 2000.000244 2002/2/2 - 300 3000.000244 2003/3/3 - -echo ROLLBACK; -Server Killed - -Durablity = TRUE -Checking Durability -Server Started -Statement Executed diff --git a/test/tools/Durability/exp.test007.ksh b/test/tools/Durability/exp.test007.ksh deleted file mode 100644 index ee23f2a9..00000000 --- a/test/tools/Durability/exp.test007.ksh +++ /dev/null @@ -1,64 +0,0 @@ -Durablity = TRUE -Server Started -CREATING TABLE -echo create table t2(f1 int,f2 float,f3 date); -Statement Executed -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(20,200.002,'2002-2-2'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(30,300.003,'2003-3-3'); -Statement Executed: Rows Affected = 1 -echo SET AUTOCOMMIT OFF; -AUTOCOMMIT Mode is set to OFF -echo insert into t2 values(100,1000.0001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(500,5000.0005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(100,1000.0001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(200,2000.0002,'2002-2-2'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(300,3000.0003,'2003-3-3'); -Statement Executed: Rows Affected = 1 -echo select * from t2; ---------------------------------------------------------- - t2.f1 t2.f2 t2.f3 ---------------------------------------------------------- - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 20 200.001999 2002/2/2 - 30 300.002991 2003/3/3 - 100 1000.000122 2001/1/1 - 500 5000.000488 2005/5/5 - 100 1000.000122 2001/1/1 - 200 2000.000244 2002/2/2 - 300 3000.000244 2003/3/3 - -echo COMMIT; -Server Killed -Durablity = TRUE -Checking Durability -Server Started ---------------------------------------------------------- - t2.f1 t2.f2 t2.f3 ---------------------------------------------------------- - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 20 200.001999 2002/2/2 - 30 300.002991 2003/3/3 - 100 1000.000122 2001/1/1 - 500 5000.000488 2005/5/5 - 100 1000.000122 2001/1/1 - 200 2000.000244 2002/2/2 - 300 3000.000244 2003/3/3 - -Statement Executed diff --git a/test/tools/Durability/exp.test008.ksh b/test/tools/Durability/exp.test008.ksh deleted file mode 100644 index 65664152..00000000 --- a/test/tools/Durability/exp.test008.ksh +++ /dev/null @@ -1,31 +0,0 @@ -Durablity = TRUE -Server Started -CREATING TABLE -echo create table t2(f1 int,f2 float,f3 date); -Statement Executed -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed - -Durablity = TRUE -Server Started -Checking Durability -Durability Works Fine -echo SET AUTOCOMMIT OFF; -AUTOCOMMIT Mode is set to OFF -echo insert into t2 values(100,1000.0001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(500,5000.0005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -echo ROLLBACK; -Server Killed - -Durablity = TRUE -Server Started -Checking Durability -Durability Works Fine -Statement Executed diff --git a/test/tools/Durability/exp.test009.ksh b/test/tools/Durability/exp.test009.ksh deleted file mode 100644 index 0dad9422..00000000 --- a/test/tools/Durability/exp.test009.ksh +++ /dev/null @@ -1,675 +0,0 @@ -Durablity = TRUE -Server Started -CREATING TABLE -echo create table t2(f1 int,f2 float,f3 date); -Statement Executed -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=1 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=2 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=3 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=4 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=5 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=6 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=7 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=8 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=9 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=10 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=11 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=12 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=13 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=14 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=15 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=16 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=17 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=18 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=19 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=20 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=21 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=22 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=23 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=24 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=25 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=26 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=27 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=28 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=29 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=30 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=31 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=32 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=33 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=34 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=35 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=36 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=37 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=38 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=39 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=40 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=41 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=42 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=43 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=44 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=45 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=46 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=47 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=48 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=49 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -count=50 -Server Started -Checking Durability -Durability Works Fine -INSERTING INTO TABLE -DEFAULT AUTOCOMMIT MODE ON -echo insert into t2 values(10,100.001,'2001-1-1'); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,500.005,'2005-5-5'); -Statement Executed: Rows Affected = 1 -Server Killed -Durablity = TRUE -Checking Durability -Server Started -Checking Durability -Durability Works Fine ---------------------------------------------------------- - t2.f1 t2.f2 t2.f3 ---------------------------------------------------------- - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - 10 100.000999 2001/1/1 - 50 500.005005 2005/5/5 - -Statement Executed -Server Killed diff --git a/test/tools/Durability/exp.test010.ksh b/test/tools/Durability/exp.test010.ksh deleted file mode 100644 index c5f67d6d..00000000 --- a/test/tools/Durability/exp.test010.ksh +++ /dev/null @@ -1,318 +0,0 @@ -Durablity = TRUE -Server Started -CREATING TABLE -echo CREATE TABLE T1(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T2(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T3(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T4(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T5(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T6(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T7(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T8(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T9(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T10(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -Server Killed -count=1 -Durablity = TRUE -Checking Durability -Server Started -Durability Works Fine -INSERTING INTO TABLE -echo CREATE INDEX idx1 ON T1(f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx2 ON T2(f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx3 ON T3(f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx4 ON T4(f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx5 ON T5(f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx6 ON T6(f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx7 ON T7(f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx8 ON T8(f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx9 ON T9(f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx10 ON T10(f1) UNIQUE; -Statement Executed -Server Killed -count=2 -Durablity = TRUE -Checking Durability -Server Started -Durability Works Fine -INSERTING INTO TABLE -echo INSERT INTO T1 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T1 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T1 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T1 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T1 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T1 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -Server Killed -count=3 -Durablity = TRUE -Checking Durability -Server Started -Durability Works Fine -UPDATING RECORDS IN TABLE -echo UPDATE T1 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 1 -echo UPDATE T1 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T2 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 1 -echo UPDATE T2 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T3 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 1 -echo UPDATE T3 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T4 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 1 -echo UPDATE T4 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T5 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 1 -echo UPDATE T5 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T6 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 1 -echo UPDATE T6 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T7 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 1 -echo UPDATE T7 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T8 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 1 -echo UPDATE T8 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T9 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 1 -echo UPDATE T9 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T10 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 1 -echo UPDATE T10 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -Server Killed -count=4 -Durablity = TRUE -Checking Durability -Server Started -Durability Works Fine -DELETING RECORDS FROM TABLE -echo DELETE FROM T1 WHERE f1 = 1; -Statement Executed: Rows Affected = 1 -echo DELETE FROM T2 WHERE f1 = 1; -Statement Executed: Rows Affected = 1 -echo DELETE FROM T3 WHERE f1 = 1; -Statement Executed: Rows Affected = 1 -echo DELETE FROM T4 WHERE f1 = 1; -Statement Executed: Rows Affected = 1 -echo DELETE FROM T5 WHERE f1 = 1; -Statement Executed: Rows Affected = 1 -echo DELETE FROM T6 WHERE f1 = 1; -Statement Executed: Rows Affected = 1 -echo DELETE FROM T7 WHERE f1 = 1; -Statement Executed: Rows Affected = 1 -echo DELETE FROM T8 WHERE f1 = 1; -Statement Executed: Rows Affected = 1 -echo DELETE FROM T9 WHERE f1 = 1; -Statement Executed: Rows Affected = 1 -echo DELETE FROM T10 WHERE f1 = 1; -Statement Executed: Rows Affected = 1 -Server Killed -count=5 -Durablity = TRUE -Checking Durability -Server Started -Durability Works Fine -DROPPING TABLE -echo DROP TABLE T1; -Statement Executed -echo DROP TABLE T2; -Statement Executed -echo DROP TABLE T3; -Statement Executed -echo DROP TABLE T4; -Statement Executed -echo DROP TABLE T5; -Statement Executed -echo DROP TABLE T6; -Statement Executed -echo DROP TABLE T7; -Statement Executed -echo DROP TABLE T8; -Statement Executed -echo DROP TABLE T9; -Statement Executed -echo DROP TABLE T10; -Statement Executed diff --git a/test/tools/Durability/exp.test011.ksh b/test/tools/Durability/exp.test011.ksh deleted file mode 100644 index 643f65e0..00000000 --- a/test/tools/Durability/exp.test011.ksh +++ /dev/null @@ -1,318 +0,0 @@ -Durablity = TRUE -Server Started -CREATING TABLE -echo CREATE TABLE T1(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T2(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T3(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T4(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T5(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T6(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T7(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T8(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T9(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -echo CREATE TABLE T10(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10)); -Statement Executed -Server Killed -count=1 -Durablity = TRUE -Checking Durability -Server Started -Durability Works Fine -INSERTING INTO TABLE -echo CREATE INDEX idx1 ON T1(f2,f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx2 ON T2(f2,f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx3 ON T3(f2,f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx4 ON T4(f2,f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx5 ON T5(f2,f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx6 ON T6(f2,f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx7 ON T7(f2,f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx8 ON T8(f2,f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx9 ON T9(f2,f1) UNIQUE; -Statement Executed -echo CREATE INDEX idx10 ON T10(f2,f1) UNIQUE; -Statement Executed -Server Killed -count=2 -Durablity = TRUE -Checking Durability -Server Started -Durability Works Fine -INSERTING INTO TABLE -echo INSERT INTO T1 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T1 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T1 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T1 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -Server Killed -count=3 -Durablity = TRUE -Checking Durability -Server Started -Durability Works Fine -UPDATING RECORDS IN TABLE -echo UPDATE T1 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 2 -echo UPDATE T1 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T2 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 2 -echo UPDATE T2 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T3 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 2 -echo UPDATE T3 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T4 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 2 -echo UPDATE T4 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T5 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 2 -echo UPDATE T5 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T6 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 2 -echo UPDATE T6 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T7 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 2 -echo UPDATE T7 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T8 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 2 -echo UPDATE T8 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T9 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 2 -echo UPDATE T9 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T10 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 2 -echo UPDATE T10 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -Server Killed -count=4 -Durablity = TRUE -Checking Durability -Server Started -Durability Works Fine -DELETING RECORDS FROM TABLE -echo DELETE FROM T1 WHERE f1 = 1; -Statement Executed: Rows Affected = 2 -echo DELETE FROM T2 WHERE f1 = 1; -Statement Executed: Rows Affected = 2 -echo DELETE FROM T3 WHERE f1 = 1; -Statement Executed: Rows Affected = 2 -echo DELETE FROM T4 WHERE f1 = 1; -Statement Executed: Rows Affected = 2 -echo DELETE FROM T5 WHERE f1 = 1; -Statement Executed: Rows Affected = 2 -echo DELETE FROM T6 WHERE f1 = 1; -Statement Executed: Rows Affected = 2 -echo DELETE FROM T7 WHERE f1 = 1; -Statement Executed: Rows Affected = 2 -echo DELETE FROM T8 WHERE f1 = 1; -Statement Executed: Rows Affected = 2 -echo DELETE FROM T9 WHERE f1 = 1; -Statement Executed: Rows Affected = 2 -echo DELETE FROM T10 WHERE f1 = 1; -Statement Executed: Rows Affected = 2 -Server Killed -count=5 -Durablity = TRUE -Checking Durability -Server Started -Durability Works Fine -DROPPING TABLE -echo DROP TABLE T1; -Statement Executed -echo DROP TABLE T2; -Statement Executed -echo DROP TABLE T3; -Statement Executed -echo DROP TABLE T4; -Statement Executed -echo DROP TABLE T5; -Statement Executed -echo DROP TABLE T6; -Statement Executed -echo DROP TABLE T7; -Statement Executed -echo DROP TABLE T8; -Statement Executed -echo DROP TABLE T9; -Statement Executed -echo DROP TABLE T10; -Statement Executed diff --git a/test/tools/Durability/exp.test012.ksh b/test/tools/Durability/exp.test012.ksh deleted file mode 100644 index 5985b2d6..00000000 --- a/test/tools/Durability/exp.test012.ksh +++ /dev/null @@ -1,596 +0,0 @@ -Durablity = TRUE -Server Started -CREATING TABLE -echo CREATE TABLE T1(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -Statement Executed -echo CREATE TABLE T2(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -Statement Executed -echo CREATE TABLE T3(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -Statement Executed -echo CREATE TABLE T4(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -Statement Executed -echo CREATE TABLE T5(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -Statement Executed -echo CREATE TABLE T6(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -Statement Executed -echo CREATE TABLE T7(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -Statement Executed -echo CREATE TABLE T8(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -Statement Executed -echo CREATE TABLE T9(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -Statement Executed -echo CREATE TABLE T10(f1 INT,f2 BIGINT,f3 SMALLINT, f4 FLOAT, f5 CHAR(10), PRIMARY KEY(f2, f3, f1)); -Statement Executed -echo show tables; -=============TableNames=================== - T1 - T2 - T3 - T4 - T5 - T6 - T7 - T8 - T9 - T10 -========================================== -Server Killed -Durablity = TRUE -Checking Durability -Server Started -INSERTING INTO TABLE -echo INSERT INTO T1 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T1 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T1 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T2 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T2 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T3 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T3 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T4 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T4 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T5 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T5 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T6 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T6 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T7 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T7 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T8 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T8 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T9 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T9 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(1, 10, 101, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo INSERT INTO T10 VALUES(2, 20, 201, 101.101, 'Lakshya'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -Statement Executed: Rows Affected = 1 -echo INSERT INTO T10 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -Statement execute failed with error -21 -echo SELECT * FROM T1; ---------------------------------------------------------- - T1.f1 T1.f2 T1.f3 T1.f4 T1.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 101.100998 Lakshya - 2 21 201 101.100998 LAKSHYA - 2 21 211 101.100998 LAKSHYA - -echo SELECT * FROM T2; ---------------------------------------------------------- - T2.f1 T2.f2 T2.f3 T2.f4 T2.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 101.100998 Lakshya - 2 21 201 101.100998 LAKSHYA - 2 21 211 101.100998 LAKSHYA - -echo SELECT * FROM T3; ---------------------------------------------------------- - T3.f1 T3.f2 T3.f3 T3.f4 T3.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 101.100998 Lakshya - 2 21 201 101.100998 LAKSHYA - 2 21 211 101.100998 LAKSHYA - -echo SELECT * FROM T4; ---------------------------------------------------------- - T4.f1 T4.f2 T4.f3 T4.f4 T4.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 101.100998 Lakshya - 2 21 201 101.100998 LAKSHYA - 2 21 211 101.100998 LAKSHYA - -echo SELECT * FROM T5; ---------------------------------------------------------- - T5.f1 T5.f2 T5.f3 T5.f4 T5.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 101.100998 Lakshya - 2 21 201 101.100998 LAKSHYA - 2 21 211 101.100998 LAKSHYA - -echo SELECT * FROM T6; ---------------------------------------------------------- - T6.f1 T6.f2 T6.f3 T6.f4 T6.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 101.100998 Lakshya - 2 21 201 101.100998 LAKSHYA - 2 21 211 101.100998 LAKSHYA - -echo SELECT * FROM T7; ---------------------------------------------------------- - T7.f1 T7.f2 T7.f3 T7.f4 T7.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 101.100998 Lakshya - 2 21 201 101.100998 LAKSHYA - 2 21 211 101.100998 LAKSHYA - -echo SELECT * FROM T8; ---------------------------------------------------------- - T8.f1 T8.f2 T8.f3 T8.f4 T8.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 101.100998 Lakshya - 2 21 201 101.100998 LAKSHYA - 2 21 211 101.100998 LAKSHYA - -echo SELECT * FROM T9; ---------------------------------------------------------- - T9.f1 T9.f2 T9.f3 T9.f4 T9.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 101.100998 Lakshya - 2 21 201 101.100998 LAKSHYA - 2 21 211 101.100998 LAKSHYA - -echo SELECT * FROM T10; ---------------------------------------------------------- - T10.f1 T10.f2 T10.f3 T10.f4 T10.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 101.100998 Lakshya - 2 21 201 101.100998 LAKSHYA - 2 21 211 101.100998 LAKSHYA - -Server Killed -Durablity = TRUE -Checking Durability -Server Started -UPDATING RECORDS IN TABLE -echo UPDATE T1 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 3 -echo UPDATE T1 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T2 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 3 -echo UPDATE T2 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T3 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 3 -echo UPDATE T3 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T4 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 3 -echo UPDATE T4 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T5 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 3 -echo UPDATE T5 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T6 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 3 -echo UPDATE T6 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T7 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 3 -echo UPDATE T7 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T8 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 3 -echo UPDATE T8 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T9 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 3 -echo UPDATE T9 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo UPDATE T10 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -Statement Executed: Rows Affected = 3 -echo UPDATE T10 SET f1=3 WHERE f1=2; -Statement prepare failed with error -21 -echo SELECT * FROM T1; ---------------------------------------------------------- - T1.f1 T1.f2 T1.f3 T1.f4 T1.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T2; ---------------------------------------------------------- - T2.f1 T2.f2 T2.f3 T2.f4 T2.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T3; ---------------------------------------------------------- - T3.f1 T3.f2 T3.f3 T3.f4 T3.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T4; ---------------------------------------------------------- - T4.f1 T4.f2 T4.f3 T4.f4 T4.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T5; ---------------------------------------------------------- - T5.f1 T5.f2 T5.f3 T5.f4 T5.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T6; ---------------------------------------------------------- - T6.f1 T6.f2 T6.f3 T6.f4 T6.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T7; ---------------------------------------------------------- - T7.f1 T7.f2 T7.f3 T7.f4 T7.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T8; ---------------------------------------------------------- - T8.f1 T8.f2 T8.f3 T8.f4 T8.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T9; ---------------------------------------------------------- - T9.f1 T9.f2 T9.f3 T9.f4 T9.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T10; ---------------------------------------------------------- - T10.f1 T10.f2 T10.f3 T10.f4 T10.f5 ---------------------------------------------------------- - 1 10 101 101.100998 Lakshya - 1 11 101 101.100998 LAKSHYA - 1 11 111 101.100998 LAKSHYA - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -Server Killed -Durablity = TRUE -Checking Durability -Server Started -DELETING RECORDS FROM TABLE -echo DELETE FROM T1 WHERE f1 = 1; -Statement Executed: Rows Affected = 3 -echo DELETE FROM T2 WHERE f1 = 1; -Statement Executed: Rows Affected = 3 -echo DELETE FROM T3 WHERE f1 = 1; -Statement Executed: Rows Affected = 3 -echo DELETE FROM T4 WHERE f1 = 1; -Statement Executed: Rows Affected = 3 -echo DELETE FROM T5 WHERE f1 = 1; -Statement Executed: Rows Affected = 3 -echo DELETE FROM T6 WHERE f1 = 1; -Statement Executed: Rows Affected = 3 -echo DELETE FROM T7 WHERE f1 = 1; -Statement Executed: Rows Affected = 3 -echo DELETE FROM T8 WHERE f1 = 1; -Statement Executed: Rows Affected = 3 -echo DELETE FROM T9 WHERE f1 = 1; -Statement Executed: Rows Affected = 3 -echo DELETE FROM T10 WHERE f1 = 1; -Statement Executed: Rows Affected = 3 -echo SELECT * FROM T1; ---------------------------------------------------------- - T1.f1 T1.f2 T1.f3 T1.f4 T1.f5 ---------------------------------------------------------- - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T2; ---------------------------------------------------------- - T2.f1 T2.f2 T2.f3 T2.f4 T2.f5 ---------------------------------------------------------- - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T3; ---------------------------------------------------------- - T3.f1 T3.f2 T3.f3 T3.f4 T3.f5 ---------------------------------------------------------- - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T4; ---------------------------------------------------------- - T4.f1 T4.f2 T4.f3 T4.f4 T4.f5 ---------------------------------------------------------- - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T5; ---------------------------------------------------------- - T5.f1 T5.f2 T5.f3 T5.f4 T5.f5 ---------------------------------------------------------- - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T6; ---------------------------------------------------------- - T6.f1 T6.f2 T6.f3 T6.f4 T6.f5 ---------------------------------------------------------- - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T7; ---------------------------------------------------------- - T7.f1 T7.f2 T7.f3 T7.f4 T7.f5 ---------------------------------------------------------- - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T8; ---------------------------------------------------------- - T8.f1 T8.f2 T8.f3 T8.f4 T8.f5 ---------------------------------------------------------- - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T9; ---------------------------------------------------------- - T9.f1 T9.f2 T9.f3 T9.f4 T9.f5 ---------------------------------------------------------- - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -echo SELECT * FROM T10; ---------------------------------------------------------- - T10.f1 T10.f2 T10.f3 T10.f4 T10.f5 ---------------------------------------------------------- - 2 20 201 20.020000 Jagannath - 2 21 201 20.020000 Jagannath - 2 21 211 20.020000 Jagannath - -Server Killed -Durablity = TRUE -Checking Durability -Server Started -DROPPING TABLE -echo DROP TABLE T1; -Statement Executed -echo DROP TABLE T2; -Statement Executed -echo DROP TABLE T3; -Statement Executed -echo DROP TABLE T4; -Statement Executed -echo DROP TABLE T5; -Statement Executed -echo DROP TABLE T6; -Statement Executed -echo DROP TABLE T7; -Statement Executed -echo DROP TABLE T8; -Statement Executed -echo DROP TABLE T9; -Statement Executed -echo DROP TABLE T10; -Statement Executed diff --git a/test/tools/Durability/index_10.sql b/test/tools/Durability/index_10.sql deleted file mode 100644 index faaae80d..00000000 --- a/test/tools/Durability/index_10.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo CREATE INDEX idx1 ON T1(f1) UNIQUE; -CREATE INDEX idx1 ON T1(f1) UNIQUE; -echo CREATE INDEX idx2 ON T2(f1) UNIQUE; -CREATE INDEX idx2 ON T2(f1) UNIQUE; -echo CREATE INDEX idx3 ON T3(f1) UNIQUE; -CREATE INDEX idx3 ON T3(f1) UNIQUE; -echo CREATE INDEX idx4 ON T4(f1) UNIQUE; -CREATE INDEX idx4 ON T4(f1) UNIQUE; -echo CREATE INDEX idx5 ON T5(f1) UNIQUE; -CREATE INDEX idx5 ON T5(f1) UNIQUE; -echo CREATE INDEX idx6 ON T6(f1) UNIQUE; -CREATE INDEX idx6 ON T6(f1) UNIQUE; -echo CREATE INDEX idx7 ON T7(f1) UNIQUE; -CREATE INDEX idx7 ON T7(f1) UNIQUE; -echo CREATE INDEX idx8 ON T8(f1) UNIQUE; -CREATE INDEX idx8 ON T8(f1) UNIQUE; -echo CREATE INDEX idx9 ON T9(f1) UNIQUE; -CREATE INDEX idx9 ON T9(f1) UNIQUE; -echo CREATE INDEX idx10 ON T10(f1) UNIQUE; -CREATE INDEX idx10 ON T10(f1) UNIQUE; diff --git a/test/tools/Durability/ins_commit.sql b/test/tools/Durability/ins_commit.sql deleted file mode 100644 index fe7bc283..00000000 --- a/test/tools/Durability/ins_commit.sql +++ /dev/null @@ -1,26 +0,0 @@ -echo insert into t2 values(10,100.001,'2001-1-1'); -insert into t2 values(10,100.001,'2001-1-1'); -echo insert into t2 values(50,500.005,'2005-5-5'); -insert into t2 values(50,500.005,'2005-5-5'); -echo insert into t2 values(10,100.001,'2001-1-1'); -insert into t2 values(10,100.001,'2001-1-1'); -echo insert into t2 values(20,200.002,'2002-2-2'); -insert into t2 values(20,200.002,'2002-2-2'); -echo insert into t2 values(30,300.003,'2003-3-3'); -insert into t2 values(30,300.003,'2003-3-3'); -echo SET AUTOCOMMIT OFF; -SET AUTOCOMMIT OFF; -echo insert into t2 values(100,1000.0001,'2001-1-1'); -insert into t2 values(100,1000.0001,'2001-1-1'); -echo insert into t2 values(500,5000.0005,'2005-5-5'); -insert into t2 values(500,5000.0005,'2005-5-5'); -echo insert into t2 values(100,1000.0001,'2001-1-1'); -insert into t2 values(100,1000.0001,'2001-1-1'); -echo insert into t2 values(200,2000.0002,'2002-2-2'); -insert into t2 values(200,2000.0002,'2002-2-2'); -echo insert into t2 values(300,3000.0003,'2003-3-3'); -insert into t2 values(300,3000.0003,'2003-3-3'); -echo select * from t2; -select * from t2; -echo COMMIT; -COMMIT; diff --git a/test/tools/Durability/ins_rollback.sql b/test/tools/Durability/ins_rollback.sql deleted file mode 100644 index e2820a91..00000000 --- a/test/tools/Durability/ins_rollback.sql +++ /dev/null @@ -1,26 +0,0 @@ -echo insert into t2 values(10,100.001,'2001-1-1'); -insert into t2 values(10,100.001,'2001-1-1'); -echo insert into t2 values(50,500.005,'2005-5-5'); -insert into t2 values(50,500.005,'2005-5-5'); -echo insert into t2 values(10,100.001,'2001-1-1'); -insert into t2 values(10,100.001,'2001-1-1'); -echo insert into t2 values(20,200.002,'2002-2-2'); -insert into t2 values(20,200.002,'2002-2-2'); -echo insert into t2 values(30,300.003,'2003-3-3'); -insert into t2 values(30,300.003,'2003-3-3'); -echo SET AUTOCOMMIT OFF; -SET AUTOCOMMIT OFF; -echo insert into t2 values(100,1000.0001,'2001-1-1'); -insert into t2 values(100,1000.0001,'2001-1-1'); -echo insert into t2 values(500,5000.0005,'2005-5-5'); -insert into t2 values(500,5000.0005,'2005-5-5'); -echo insert into t2 values(100,1000.0001,'2001-1-1'); -insert into t2 values(100,1000.0001,'2001-1-1'); -echo insert into t2 values(200,2000.0002,'2002-2-2'); -insert into t2 values(200,2000.0002,'2002-2-2'); -echo insert into t2 values(300,3000.0003,'2003-3-3'); -insert into t2 values(300,3000.0003,'2003-3-3'); -echo select * from t2; -select * from t2; -echo ROLLBACK; -ROLLBACK; diff --git a/test/tools/Durability/insert_10.sql b/test/tools/Durability/insert_10.sql deleted file mode 100644 index 9cc342dd..00000000 --- a/test/tools/Durability/insert_10.sql +++ /dev/null @@ -1,169 +0,0 @@ -echo INSERT INTO T1 VALUES(1, 10, 101, 101.101, 'Lakshya'); -INSERT INTO T1 VALUES(1, 10, 101, 101.101, 'Lakshya'); -echo INSERT INTO T1 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T1 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T1 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -INSERT INTO T1 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -echo INSERT INTO T1 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T1 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T1 VALUES(2, 20, 201, 101.101, 'Lakshya'); -INSERT INTO T1 VALUES(2, 20, 201, 101.101, 'Lakshya'); -echo INSERT INTO T1 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T1 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -echo INSERT INTO T1 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -INSERT INTO T1 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -echo INSERT INTO T1 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T1 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); - -echo INSERT INTO T2 VALUES(1, 10, 101, 101.101, 'Lakshya'); -INSERT INTO T2 VALUES(1, 10, 101, 101.101, 'Lakshya'); -echo INSERT INTO T2 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T2 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T2 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -INSERT INTO T2 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -echo INSERT INTO T2 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T2 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T2 VALUES(2, 20, 201, 101.101, 'Lakshya'); -INSERT INTO T2 VALUES(2, 20, 201, 101.101, 'Lakshya'); -echo INSERT INTO T2 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T2 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -echo INSERT INTO T2 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -INSERT INTO T2 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -echo INSERT INTO T2 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T2 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); - -echo INSERT INTO T3 VALUES(1, 10, 101, 101.101, 'Lakshya'); -INSERT INTO T3 VALUES(1, 10, 101, 101.101, 'Lakshya'); -echo INSERT INTO T3 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T3 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T3 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -INSERT INTO T3 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -echo INSERT INTO T3 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T3 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T3 VALUES(2, 20, 201, 101.101, 'Lakshya'); -INSERT INTO T3 VALUES(2, 20, 201, 101.101, 'Lakshya'); -echo INSERT INTO T3 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T3 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -echo INSERT INTO T3 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -INSERT INTO T3 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -echo INSERT INTO T3 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T3 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); - -echo INSERT INTO T4 VALUES(1, 10, 101, 101.101, 'Lakshya'); -INSERT INTO T4 VALUES(1, 10, 101, 101.101, 'Lakshya'); -echo INSERT INTO T4 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T4 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T4 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -INSERT INTO T4 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -echo INSERT INTO T4 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T4 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T4 VALUES(2, 20, 201, 101.101, 'Lakshya'); -INSERT INTO T4 VALUES(2, 20, 201, 101.101, 'Lakshya'); -echo INSERT INTO T4 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T4 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -echo INSERT INTO T4 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -INSERT INTO T4 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -echo INSERT INTO T4 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T4 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); - -echo INSERT INTO T5 VALUES(1, 10, 101, 101.101, 'Lakshya'); -INSERT INTO T5 VALUES(1, 10, 101, 101.101, 'Lakshya'); -echo INSERT INTO T5 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T5 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T5 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -INSERT INTO T5 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -echo INSERT INTO T5 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T5 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T5 VALUES(2, 20, 201, 101.101, 'Lakshya'); -INSERT INTO T5 VALUES(2, 20, 201, 101.101, 'Lakshya'); -echo INSERT INTO T5 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T5 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -echo INSERT INTO T5 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -INSERT INTO T5 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -echo INSERT INTO T5 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T5 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); - -echo INSERT INTO T6 VALUES(1, 10, 101, 101.101, 'Lakshya'); -INSERT INTO T6 VALUES(1, 10, 101, 101.101, 'Lakshya'); -echo INSERT INTO T6 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T6 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T6 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -INSERT INTO T6 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -echo INSERT INTO T6 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T6 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T6 VALUES(2, 20, 201, 101.101, 'Lakshya'); -INSERT INTO T6 VALUES(2, 20, 201, 101.101, 'Lakshya'); -echo INSERT INTO T6 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T6 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -echo INSERT INTO T6 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -INSERT INTO T6 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -echo INSERT INTO T6 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T6 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); - -echo INSERT INTO T7 VALUES(1, 10, 101, 101.101, 'Lakshya'); -INSERT INTO T7 VALUES(1, 10, 101, 101.101, 'Lakshya'); -echo INSERT INTO T7 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T7 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T7 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -INSERT INTO T7 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -echo INSERT INTO T7 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T7 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T7 VALUES(2, 20, 201, 101.101, 'Lakshya'); -INSERT INTO T7 VALUES(2, 20, 201, 101.101, 'Lakshya'); -echo INSERT INTO T7 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T7 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -echo INSERT INTO T7 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -INSERT INTO T7 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -echo INSERT INTO T7 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T7 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); - -echo INSERT INTO T8 VALUES(1, 10, 101, 101.101, 'Lakshya'); -INSERT INTO T8 VALUES(1, 10, 101, 101.101, 'Lakshya'); -echo INSERT INTO T8 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T8 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T8 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -INSERT INTO T8 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -echo INSERT INTO T8 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T8 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T8 VALUES(2, 20, 201, 101.101, 'Lakshya'); -INSERT INTO T8 VALUES(2, 20, 201, 101.101, 'Lakshya'); -echo INSERT INTO T8 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T8 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -echo INSERT INTO T8 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -INSERT INTO T8 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -echo INSERT INTO T8 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T8 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); - -echo INSERT INTO T9 VALUES(1, 10, 101, 101.101, 'Lakshya'); -INSERT INTO T9 VALUES(1, 10, 101, 101.101, 'Lakshya'); -echo INSERT INTO T9 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T9 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T9 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -INSERT INTO T9 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -echo INSERT INTO T9 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T9 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T9 VALUES(2, 20, 201, 101.101, 'Lakshya'); -INSERT INTO T9 VALUES(2, 20, 201, 101.101, 'Lakshya'); -echo INSERT INTO T9 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T9 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -echo INSERT INTO T9 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -INSERT INTO T9 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -echo INSERT INTO T9 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T9 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); - -echo INSERT INTO T10 VALUES(1, 10, 101, 101.101, 'Lakshya'); -INSERT INTO T10 VALUES(1, 10, 101, 101.101, 'Lakshya'); -echo INSERT INTO T10 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T10 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T10 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -INSERT INTO T10 VALUES(1, 11, 111, 101.101, 'LAKSHYA'); -echo INSERT INTO T10 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -INSERT INTO T10 VALUES(1, 11, 101, 101.101, 'LAKSHYA'); -echo INSERT INTO T10 VALUES(2, 20, 201, 101.101, 'Lakshya'); -INSERT INTO T10 VALUES(2, 20, 201, 101.101, 'Lakshya'); -echo INSERT INTO T10 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T10 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -echo INSERT INTO T10 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -INSERT INTO T10 VALUES(2, 21, 211, 101.101, 'LAKSHYA'); -echo INSERT INTO T10 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); -INSERT INTO T10 VALUES(2, 21, 201, 101.101, 'LAKSHYA'); diff --git a/test/tools/Durability/insert_a.sql b/test/tools/Durability/insert_a.sql deleted file mode 100644 index 44c6f80a..00000000 --- a/test/tools/Durability/insert_a.sql +++ /dev/null @@ -1,4 +0,0 @@ -echo insert into t2 values(10,100.001,'2001-1-1'); -insert into t2 values(10,100.001,'2001-1-1'); -echo insert into t2 values(50,500.005,'2005-5-5'); -insert into t2 values(50,500.005,'2005-5-5'); diff --git a/test/tools/Durability/insert_b.sql b/test/tools/Durability/insert_b.sql deleted file mode 100644 index 0580438e..00000000 --- a/test/tools/Durability/insert_b.sql +++ /dev/null @@ -1,8 +0,0 @@ -echo SET AUTOCOMMIT OFF; -SET AUTOCOMMIT OFF; -echo insert into t2 values(100,1000.0001,'2001-1-1'); -insert into t2 values(100,1000.0001,'2001-1-1'); -echo insert into t2 values(500,5000.0005,'2005-5-5'); -insert into t2 values(500,5000.0005,'2005-5-5'); -echo ROLLBACK; -ROLLBACK; diff --git a/test/tools/Durability/insert_t1.sql b/test/tools/Durability/insert_t1.sql deleted file mode 100644 index 540cc7c9..00000000 --- a/test/tools/Durability/insert_t1.sql +++ /dev/null @@ -1,4 +0,0 @@ -echo insert into t1 values('NIHAR', 1,1,-2147483648,9223372036854775807, 2147483648,1.1, 1000000000.000000,10000001.10000001,99999,'ABCDEF0123456789','2001-1-1', '01:01:01', '2001-11-30 01:01:01'); -insert into t1 values('NIHAR', 1,1,-2147483648,9223372036854775807, 2147483648,1.1, 1000000000.000000,10000001.10000001,99999,'ABCDEF0123456789','2001-1-1', '01:01:01', '2001-11-30 01:01:01'); -echo insert into t1 values(NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL); -insert into t1 values(NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL); diff --git a/test/tools/Durability/rollback.sql b/test/tools/Durability/rollback.sql deleted file mode 100644 index f654063e..00000000 --- a/test/tools/Durability/rollback.sql +++ /dev/null @@ -1 +0,0 @@ -rollback; diff --git a/test/tools/Durability/select_10.sql b/test/tools/Durability/select_10.sql deleted file mode 100644 index 0c46893c..00000000 --- a/test/tools/Durability/select_10.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo SELECT * FROM T1; -SELECT * FROM T1; -echo SELECT * FROM T2; -SELECT * FROM T2; -echo SELECT * FROM T3; -SELECT * FROM T3; -echo SELECT * FROM T4; -SELECT * FROM T4; -echo SELECT * FROM T5; -SELECT * FROM T5; -echo SELECT * FROM T6; -SELECT * FROM T6; -echo SELECT * FROM T7; -SELECT * FROM T7; -echo SELECT * FROM T8; -SELECT * FROM T8; -echo SELECT * FROM T9; -SELECT * FROM T9; -echo SELECT * FROM T10; -SELECT * FROM T10; diff --git a/test/tools/Durability/select_t1.sql b/test/tools/Durability/select_t1.sql deleted file mode 100644 index 14313518..00000000 --- a/test/tools/Durability/select_t1.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo SELECT * FROM t1; -SELECT * FROM t1; diff --git a/test/tools/Durability/show_t1.sql b/test/tools/Durability/show_t1.sql deleted file mode 100644 index 9c019146..00000000 --- a/test/tools/Durability/show_t1.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo show tables; -show tables; diff --git a/test/tools/Durability/test001.ksh b/test/tools/Durability/test001.ksh deleted file mode 100755 index 7dbf204e..00000000 --- a/test/tools/Durability/test001.ksh +++ /dev/null @@ -1,68 +0,0 @@ -#!/bin/sh -# Run this test only under csql/test or on this directory. -# Otherwise, it may fail -# set DURABILITY to false in csql.conf (Default) -# Start csqlserver. Then create a table using CSQL Client. -# kill the currently running Server. -# Restart the Server in DURABILITY=false.Open CSQL Client. -# SHOW TABLES; Statement should not display any table. -# - -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf - -export CSQL_CONFIG_FILE=/tmp/csql.conf - -echo "Durablity = FALSE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 - -echo "CREATE TABLE laks(f1 int);" >${REL_PATH}/create.sql -echo "DROP TABLE laks;" >${REL_PATH}/drop.sql - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - rm -f ${REL_PATH}/create.sql - rm -f ${REL_PATH}/drop.sql - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql - -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" -echo "" -echo "Durablity = FALSE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 - -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -echo "" -diff before.sql after.sql - -rm -f ${REL_PATH}/create.sql -rm -f ${REL_PATH}/drop.sql -rm -f before.sql after.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -exit 0; diff --git a/test/tools/Durability/test002.ksh b/test/tools/Durability/test002.ksh deleted file mode 100755 index a2dac39f..00000000 --- a/test/tools/Durability/test002.ksh +++ /dev/null @@ -1,67 +0,0 @@ -#!/bin/sh -# Run this test only under csql/test or on this directory. -# Otherwise, it may fail -# set DURABILITY to true in csql.conf -# Start csqlserver. Then create a table using CSQL Client. -# kill the currently running Server. -# Again Restart the Server by setting DURABILITY=true and Open CSQL Client. -# SHOW TABLES; Statement should display the table. -# -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf -echo DURABILITY=true >>/tmp/csql.conf -export CSQL_CONFIG_FILE=/tmp/csql.conf - -echo "Durablity = TRUE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 - -echo "CREATE TABLE laks(f1 int);" >${REL_PATH}/create.sql -echo "DROP TABLE laks;" >${REL_PATH}/drop.sql - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - rm -f ${REL_PATH}/create.sql - rm -f ${REL_PATH}/drop.sql - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql - -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" -echo "" -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 - -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -echo "" -diff before.sql after.sql - -rm -f ${REL_PATH}/create.sql -rm -f ${REL_PATH}/drop.sql -rm -f before.sql after.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -exit 0; diff --git a/test/tools/Durability/test003.ksh b/test/tools/Durability/test003.ksh deleted file mode 100755 index c681f7ab..00000000 --- a/test/tools/Durability/test003.ksh +++ /dev/null @@ -1,68 +0,0 @@ -#!/bin/sh -# Run this test only under csql/test or on this directory. -# Otherwise, it may fail -# set DURABILITY = true in csql.conf -# Start csqlserver. Then create a table in CSQL Client. -# kill the currently running Server. -# Restart the server by setting DURABILITY = false. and Open CSQL Client. -# SHOW TABLES; Statement should not display any table. -# -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf -echo DURABILITY=true >>/tmp/csql.conf -export CSQL_CONFIG_FILE=/tmp/csql.conf - -echo "Durablity = TRUE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 - -echo "CREATE TABLE laks(f1 int);" >${REL_PATH}/create.sql -echo "DROP TABLE laks;" >${REL_PATH}/drop.sql - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - rm -f ${REL_PATH}/create.sql - rm -f ${REL_PATH}/drop.sql - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql - -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" -echo "" -echo DURABILITY=false >>/tmp/csql.conf -echo "Durablity = FALSE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 - -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -echo "" -diff before.sql after.sql - -rm -f ${REL_PATH}/create.sql -rm -f ${REL_PATH}/drop.sql -rm -f before.sql after.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -exit 0; diff --git a/test/tools/Durability/test004.ksh b/test/tools/Durability/test004.ksh deleted file mode 100755 index 5a711466..00000000 --- a/test/tools/Durability/test004.ksh +++ /dev/null @@ -1,68 +0,0 @@ -#!/bin/sh -# Run this test only under csql/test or on this directory. -# Otherwise, it may fail -# set DURABILITY to false in csql.conf (Default) -# Start csqlserver. Then create a table in CSQL Client. -# kill the currently running Server. -# Again Restart the Server by setting DURABILITY = true. and Open CSQL Client. -# SHOW TABLES; Statement should not display any table. -# -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf -echo DURABILITY=false >>/tmp/csql.conf -export CSQL_CONFIG_FILE=/tmp/csql.conf - -echo "Durablity = FALSE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 - -echo "CREATE TABLE laks(f1 int);" >${REL_PATH}/create.sql -echo "DROP TABLE laks;" >${REL_PATH}/drop.sql - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - rm -f ${REL_PATH}/create.sql - rm -f ${REL_PATH}/drop.sql - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql - -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" -echo "" -echo DURABILITY=true >>/tmp/csql.conf -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 - -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -echo "" -diff before.sql after.sql - -rm -f ${REL_PATH}/create.sql -rm -f ${REL_PATH}/drop.sql -rm -f before.sql after.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -exit 0; diff --git a/test/tools/Durability/test005.ksh b/test/tools/Durability/test005.ksh deleted file mode 100755 index b39d6c4e..00000000 --- a/test/tools/Durability/test005.ksh +++ /dev/null @@ -1,151 +0,0 @@ -#!/bin/sh -# Testing All the operation in CSQl ((After Each Operation Kill the server and Restart the server again for Another Operation) -# Run this test only under csql/test or on this directory. -# Otherwise, it may fail -# set DURABILITY to true in csql.conf -# Start csqlserver. Then create a table in CSQL Client.Insert 5 Records. -# kill the currently running Server. -# Again Restart the Server by setting DURABILITY=true and Open CSQL Client. -# Continue The same For All Operations in CSQL. -# All should work Fine -# - -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf -echo "DURABILITY=true" >>/tmp/csql.conf -export CSQL_CONFIG_FILE=/tmp/csql.conf - -echo "Durablity = TRUE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 -echo "CREATING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create_t1.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql - -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo "" -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql - -echo "INSERTING INTO TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/insert_t1.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t1.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo "" -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 - -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql - -echo "UPDATING RECORDS IN TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/update_t1.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t1.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 5; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql - -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo "" -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 - -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql - -echo "DELETING RECORDS FROM TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/delete_t1.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t1.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 7; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo "" -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 - -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql - -echo "DROPPING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t1.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 9; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -rm -f before.sql after.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -exit 0; diff --git a/test/tools/Durability/test006.ksh b/test/tools/Durability/test006.ksh deleted file mode 100755 index 25306ea6..00000000 --- a/test/tools/Durability/test006.ksh +++ /dev/null @@ -1,83 +0,0 @@ -#!/bin/sh -# Autocommit Checking -# Run this test only under csql/test or on this directory. -# Otherwise, it may fail -# set DURABILITY to true in csql.conf -# Start csqlserver. Then create a table in CSQL Client.Insert 5 Records. -# make Set autocommit off. insert another 5 records and Rollback. -# Kill the Server. -# Again Restart the Server by setting DURABILITY=true . -# select should Display 1st 5 records. -# - -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf -echo "DURABILITY=true" >>/tmp/csql.conf -export CSQL_CONFIG_FILE=/tmp/csql.conf - - -echo "SELECT * FROM t2;" >${REL_PATH}/select_t2.sql -echo "drop table t2;" >${REL_PATH}/drop_t2.sql - -echo "Durablity = TRUE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 -echo "CREATING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create_t2.sql -if [ $? -ne 0 ] - then - rm -f ${REL_PATH}/select_t2.sql - rm -f ${REL_PATH}/drop_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 1; -fi - -echo "INSERTING INTO TABLE" -echo "DEFAULT AUTOCOMMIT MODE ON" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/ins_rollback.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql - rm -f ${REL_PATH}/select_t2.sql - rm -f ${REL_PATH}/drop_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo "" -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql -rm -f ${REL_PATH}/select_t2.sql -rm -f ${REL_PATH}/drop_t2.sql -rm -f before.sql after.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -exit 0; diff --git a/test/tools/Durability/test007.ksh b/test/tools/Durability/test007.ksh deleted file mode 100755 index 12389487..00000000 --- a/test/tools/Durability/test007.ksh +++ /dev/null @@ -1,88 +0,0 @@ -#!/bin/sh -# Run this test only under csql/test or on this directory. -# Otherwise, it may fail -# set DURABILITY to true in csql.conf -# Start csqlserver. Then create a table in CSQL Client.Insert 5 Records. -# make Set autocommit off. insert another 5 records and Commit. -# Kill the Server. -# Again Restart the Server by setting DURABILITY=true . -# select should Display all 10 records. -# - -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf -echo "DURABILITY=true" >>/tmp/csql.conf -export CSQL_CONFIG_FILE=/tmp/csql.conf - - -echo "SELECT * FROM t2;" >${REL_PATH}/select_t2.sql -echo "drop table t2;" >${REL_PATH}/drop_t2.sql - -echo "Durablity = TRUE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 -echo "CREATING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create_t2.sql -if [ $? -ne 0 ] - then - rm -f ${REL_PATH}/select_t2.sql - rm -f ${REL_PATH}/drop_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 1; -fi - -echo "INSERTING INTO TABLE" -echo "DEFAULT AUTOCOMMIT MODE ON" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/ins_commit.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql - rm -f ${REL_PATH}/select_t2.sql - rm -f ${REL_PATH}/drop_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 2; -fi - -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/select_t2.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql - rm -f ${REL_PATH}/select_t2.sql - rm -f ${REL_PATH}/drop_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql -rm -f ${REL_PATH}/select_t2.sql -rm -f ${REL_PATH}/drop_t2.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -exit 0; diff --git a/test/tools/Durability/test008.ksh b/test/tools/Durability/test008.ksh deleted file mode 100755 index ae881ab0..00000000 --- a/test/tools/Durability/test008.ksh +++ /dev/null @@ -1,115 +0,0 @@ -#!/bin/sh -# Set DURABILITY to true in csql.conf -# Start csqlserver. in CSQl client create a table and insert 5 recored -# Kill the server -# Restart csqlserver again. set Autocommit Off mode.insert another 5 record.and Rollback the transaction. -# Kill the server -# Again Restart The server -# Select Should fetch only 1st 5 records -# - -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf -echo "DURABILITY=true" >>/tmp/csql.conf -export CSQL_CONFIG_FILE=/tmp/csql.conf - - -echo "SELECT * FROM t2;" >${REL_PATH}/select_t2.sql -echo "drop table t2;" >${REL_PATH}/drop_t2.sql - -echo "Durablity = TRUE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 -echo "CREATING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create_t2.sql -if [ $? -ne 0 ] - then - rm -f ${REL_PATH}/select_t2.sql - rm -f ${REL_PATH}/drop_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 1; -fi - -echo "INSERTING INTO TABLE" -echo "DEFAULT AUTOCOMMIT MODE ON" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/insert_a.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql - rm -f ${REL_PATH}/select_t2.sql - rm -f ${REL_PATH}/drop_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo "" -echo "Durablity = TRUE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/insert_b.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql - rm -f ${REL_PATH}/select_t2.sql - rm -f ${REL_PATH}/drop_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo "" -echo "Durablity = TRUE" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql -rm -f ${REL_PATH}/select_t2.sql -rm -f ${REL_PATH}/drop_t2.sql -rm -f before.sql after.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -exit 0; diff --git a/test/tools/Durability/test009.ksh b/test/tools/Durability/test009.ksh deleted file mode 100755 index bf72de3a..00000000 --- a/test/tools/Durability/test009.ksh +++ /dev/null @@ -1,123 +0,0 @@ -#!/bin/sh -# Set DURABILITY to true in csql.conf -# Start csqlserver. in CSQl client create a table and insert 5 recored -# 50 times kill and start the server -# Restart csqlserver again. -# Select Should fetch those inserted 5 records -# - -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf -echo "DURABILITY=true" >>/tmp/csql.conf -export CSQL_CONFIG_FILE=/tmp/csql.conf - - -echo "drop table t2;" >${REL_PATH}/drop_t2.sql - -echo "Durablity = TRUE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 1 -echo "CREATING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create_t2.sql -if [ $? -ne 0 ] - then - rm -f ${REL_PATH}/drop_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 1; -fi - -echo "INSERTING INTO TABLE" -echo "DEFAULT AUTOCOMMIT MODE ON" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/insert_a.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql - rm -f ${REL_PATH}/drop_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -for((i=1;i<=50;i++)) -do - echo count=$i - $CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & - pid=$! - echo "Server Started" - sleep 2 - echo "Checking Durability" - $CSQL_INSTALL_ROOT/bin/csqldump >after.sql - diff before.sql after.sql - if [ $? -eq 0 ] - then - echo Durability Works Fine - fi - - echo "INSERTING INTO TABLE" - echo "DEFAULT AUTOCOMMIT MODE ON" - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/insert_a.sql - if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql - rm -f ${REL_PATH}/drop_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 2; - fi - - $CSQL_INSTALL_ROOT/bin/csqldump >before.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - echo "Server Killed" -done - -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 1 -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi -echo "SELECT * FROM t2;" >${REL_PATH}/select_t2.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/select_t2.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql - rm -f ${REL_PATH}/drop_t2.sql - rm -f ${REL_PATH}/select_t2.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 2; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_t2.sql -rm -f ${REL_PATH}/drop_t2.sql -rm -f ${REL_PATH}/select_t2.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" -exit 0; diff --git a/test/tools/Durability/test010.ksh b/test/tools/Durability/test010.ksh deleted file mode 100755 index f7303c0d..00000000 --- a/test/tools/Durability/test010.ksh +++ /dev/null @@ -1,191 +0,0 @@ -#!/bin/sh -# Unique Index test -# Testing All the operation in CSQl ((After Each Operation Kill the server and Restart the server again for Another Operation) -# Run this test only under csql/test or on this directory. -# Otherwise, it may fail -# set DURABILITY to true in csql.conf -# Start csqlserver. Then create a table in CSQL Client.Insert 5 Records. -# kill the currently running Server. -# Again Restart the Server by setting DURABILITY=true and Open CSQL Client. -# Continue The same For All Operations in CSQL. -# All should work Fine -# - -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf -echo "DURABILITY=true" >>/tmp/csql.conf -export CSQL_CONFIG_FILE=/tmp/csql.conf - -echo "Durablity = TRUE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 -echo "CREATING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create_10.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo count=1 -echo "Durablity = TRUE" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Checking Durability" -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -echo "INSERTING INTO TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/index_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo count=2 -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -echo "INSERTING INTO TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/insert_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo count=3 -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -echo "UPDATING RECORDS IN TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/update_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 5; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo count=4 -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -echo "DELETING RECORDS FROM TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/delete_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 7; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo count=5 -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -echo "DROPPING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 9; -fi - -rm -f before.sql after.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -exit 0; diff --git a/test/tools/Durability/test011.ksh b/test/tools/Durability/test011.ksh deleted file mode 100755 index 580195c7..00000000 --- a/test/tools/Durability/test011.ksh +++ /dev/null @@ -1,192 +0,0 @@ -#!/bin/sh -# Composite index test -# Testing All the operation in CSQl ((After Each Operation Kill the server and Restart the server again for Another Operation) -# Run this test only under csql/test or on this directory. -# Otherwise, it may fail -# set DURABILITY to true in csql.conf -# Start csqlserver. Then create a table in CSQL Client.Insert 5 Records. -# kill the currently running Server. -# Start csqlserver. Then create Composite Unique Index on two fieldse in CSQL Client.Insert 5 Records. -# kill the currently running Server. -# Again Restart the Server by setting DURABILITY=true and Open CSQL Client. -# Continue The same For All Operations in CSQL. -# All should work Fine -# -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf -echo "DURABILITY=true" >>/tmp/csql.conf -export CSQL_CONFIG_FILE=/tmp/csql.conf - -echo "Durablity = TRUE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 -echo "CREATING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create_10.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo count=1 -echo "Durablity = TRUE" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Checking Durability" -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -echo "INSERTING INTO TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/compo_index2_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo count=2 -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -echo "INSERTING INTO TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/insert_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo count=3 -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -echo "UPDATING RECORDS IN TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/update_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 5; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo count=4 -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -echo "DELETING RECORDS FROM TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/delete_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 7; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >before.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo count=5 -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -$CSQL_INSTALL_ROOT/bin/csqldump >after.sql -diff before.sql after.sql -if [ $? -eq 0 ] - then - echo Durability Works Fine -fi - -echo "DROPPING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 9; -fi - -rm -f before.sql after.sql -kill -9 $pid -ipcrm -M 4444 -M 6666 -exit 0; diff --git a/test/tools/Durability/test012.ksh b/test/tools/Durability/test012.ksh deleted file mode 100755 index c5c8debf..00000000 --- a/test/tools/Durability/test012.ksh +++ /dev/null @@ -1,160 +0,0 @@ -#!/bin/sh -# Composite Primary Key test -# Testing All the operation in CSQl ((After Each Operation Kill the server and Restart the server again for Another Operation) -# Run this test only under csql/test or on this directory. -# Otherwise, it may fail -# set DURABILITY to true in csql.conf -# Start csqlserver. Then create a table (Composite Primary Key on 3 fields) in CSQL Client.Insert 5 Records. -# kill the currently running Server. -# Again Restart the Server by setting DURABILITY=true and Open CSQL Client. -# Continue The same For All Operations in CSQL. -# All should work Fine -# - -CSQL_CONF=${PWD}/tools/Durability/csql.conf -REL_PATH=. -if [ -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/Durability -fi - -rm -f /tmp/csql.conf -rm -rf /tmp/csql/db -mkdir -p /tmp/csql/db -cp -f $REL_PATH/csql.conf /tmp -echo SYS_DB_KEY=4444 >>/tmp/csql.conf -echo USER_DB_KEY=6666 >>/tmp/csql.conf -echo "DURABILITY=true" >>/tmp/csql.conf -export CSQL_CONFIG_FILE=/tmp/csql.conf - -echo "Durablity = TRUE" -echo "Server Started" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 2 -echo "CREATING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/create_pri_10.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/show_t1.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 2; -fi - -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -echo "INSERTING INTO TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/insert_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/select_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 4; -fi - -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -echo "UPDATING RECORDS IN TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/update_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 5; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/select_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 6; -fi - -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -echo "DELETING RECORDS FROM TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/delete_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 7; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/select_10.sql -if [ $? -ne 0 ] - then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 8; -fi - -kill -9 $pid -ipcrm -M 4444 -M 6666 -echo "Server Killed" - -echo "Durablity = TRUE" -echo "Checking Durability" -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -echo "Server Started" -sleep 2 -echo "DROPPING TABLE" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop_10.sql -if [ $? -ne 0 ] - then - kill -9 $pid - ipcrm -M 4444 -M 6666 - exit 9; -fi - -kill -9 $pid -ipcrm -M 4444 -M 6666 -exit 0; diff --git a/test/tools/Durability/update_10.sql b/test/tools/Durability/update_10.sql deleted file mode 100644 index 4e4c4a0f..00000000 --- a/test/tools/Durability/update_10.sql +++ /dev/null @@ -1,40 +0,0 @@ -echo UPDATE T1 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -UPDATE T1 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -echo UPDATE T1 SET f1=3 WHERE f1=2; -UPDATE T1 SET f1=3 WHERE f1=2; -echo UPDATE T2 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -UPDATE T2 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -echo UPDATE T2 SET f1=3 WHERE f1=2; -UPDATE T2 SET f1=3 WHERE f1=2; -echo UPDATE T3 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -UPDATE T3 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -echo UPDATE T3 SET f1=3 WHERE f1=2; -UPDATE T3 SET f1=3 WHERE f1=2; -echo UPDATE T4 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -UPDATE T4 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -echo UPDATE T4 SET f1=3 WHERE f1=2; -UPDATE T5 SET f1=3 WHERE f1=2; -echo UPDATE T5 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -UPDATE T5 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -echo UPDATE T5 SET f1=3 WHERE f1=2; -UPDATE T5 SET f1=3 WHERE f1=2; -echo UPDATE T6 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -UPDATE T6 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -echo UPDATE T6 SET f1=3 WHERE f1=2; -UPDATE T6 SET f1=3 WHERE f1=2; -echo UPDATE T7 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -UPDATE T7 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -echo UPDATE T7 SET f1=3 WHERE f1=2; -UPDATE T7 SET f1=3 WHERE f1=2; -echo UPDATE T8 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -UPDATE T8 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -echo UPDATE T8 SET f1=3 WHERE f1=2; -UPDATE T8 SET f1=3 WHERE f1=2; -echo UPDATE T9 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -UPDATE T9 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -echo UPDATE T9 SET f1=3 WHERE f1=2; -UPDATE T9 SET f1=3 WHERE f1=2; -echo UPDATE T10 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -UPDATE T10 SET f4 = 20.02,f5 = 'Jagannath' WHERE f1=2; -echo UPDATE T10 SET f1=3 WHERE f1=2; -UPDATE T10 SET f1=3 WHERE f1=2; diff --git a/test/tools/Durability/update_t1.sql b/test/tools/Durability/update_t1.sql deleted file mode 100644 index bee9cb14..00000000 --- a/test/tools/Durability/update_t1.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo UPDATE t1 set f1='PAPU', f2=10, f3=2, f4=2147483647, f5=-9223372036854775808, f6=-2147483647, f7=10.01, f8=2000000002.000002, f9=20000002.200002, f10=2147483647, f11='9876543210DcAbEf', f12='2003-3-3', f13='03:03:03', f14='2003-3-3 03:03:03'; -UPDATE t1 set f1='PAPU', f2=10, f3=2, f4=2147483647, f5=-9223372036854775808, f6=-2147483647, f7=10.01, f8=2000000002.000002, f9=20000002.200002, f10=2147483647, f11='9876543210DcAbEf', f12='2003-3-3', f13='03:03:03', f14='2003-3-3 03:03:03'; diff --git a/test/tools/Makefile b/test/tools/Makefile deleted file mode 100644 index 88876187..00000000 --- a/test/tools/Makefile +++ /dev/null @@ -1,35 +0,0 @@ -OSNAME = $(shell uname -s) -MAKE=make - -ifeq ($(OSNAME), SunOS) -PlatForm=supported -else -ifeq ($(OSNAME), Linux) -PlatForm=supported -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - - -ifeq ($(PlatForm), supported) -all: buildall -endif - -buildall: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE); cd ..;\ - fi;\ - done - -clean: - @for i in *; \ - do \ - if [ -d $$i ];\ - then cd $$i; $(MAKE) clean; cd ..;\ - fi;\ - done diff --git a/test/tools/catalog/Makefile b/test/tools/catalog/Makefile deleted file mode 100644 index 3764f3a2..00000000 --- a/test/tools/catalog/Makefile +++ /dev/null @@ -1,40 +0,0 @@ - -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -g -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsql - -TARGETS = \ - create drop insert - - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -create: create.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -drop: drop.c - $(CPlus) $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -insert: insert.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -clean: - rm -f $(TARGETS) - diff --git a/test/tools/catalog/common.h b/test/tools/catalog/common.h deleted file mode 100644 index f7165e5d..00000000 --- a/test/tools/catalog/common.h +++ /dev/null @@ -1,135 +0,0 @@ -#include -DbRetVal createIndex(DatabaseManager *dbMgr, char *tblname, char *fldname, char *indname) -{ - HashIndexInitInfo *idxInfo = new HashIndexInitInfo(); - strcpy(idxInfo->tableName, tblname); - idxInfo->list.append(fldname); - idxInfo->indType = hashIndex; - idxInfo->isPrimary = true; - idxInfo->isUnique = true; - DbRetVal rv = dbMgr->createIndex(indname, idxInfo); - if (rv != OK) { printf("Index creation failed\n"); return rv; } - delete idxInfo; - printf("Index created for %s\n", fldname); - return OK; -} -DbRetVal createTable(DatabaseManager *dbMgr, char *tblname) -{ - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - tabDef.addField("f2", typeInt, 0, NULL, true); - DbRetVal rv = dbMgr->createTable(tblname, tabDef); - if (rv != OK) { printf("Table creation failed\n"); return rv; } - printf("Table created\n"); - return OK; -} -DbRetVal dropTable(DatabaseManager *dbMgr, char *tblname) -{ - DbRetVal rv = dbMgr->dropTable(tblname); - if (rv != OK) { printf("Table drop failed\n"); return rv; } - printf("Table Dropped\n"); - return OK; -} -int insertTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - int id1 = 0; - table->bindFld("f1", &id1); - table->bindFld("f2", &id1); - int icount =0; - DbRetVal rv = OK; - rv = conn.startTransaction(); - if (rv != OK) { dbMgr->closeTable(table); return 1; } - for (int i = 0 ; i < count ; i++) - { - id1= i; - rv = table->insertTuple(); - if (rv != OK) break; - icount++; - - } - conn.commit(); - printf("Total Tuples inserted is %d\n", icount); - dbMgr->closeTable(table); - return icount; -} -int deleteTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname, int count) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - DbRetVal rv = OK; - - Condition p1; - int val1 = 0; - p1.setTerm("f1", OpEquals, &val1); - table->setCondition(&p1); - - rv = conn.startTransaction(); - if (rv != OK) { dbMgr->closeTable(table); return 1; } - int i =0; - void *tuple; - for (i = 0 ; i < count ; i++) - { - val1 = i; - table->execute(); - if (rv != OK) break; - tuple = (char*)table->fetch() ; - if (tuple == NULL) break; - rv = table->deleteTuple(); - if (rv != OK) break; - } - conn.commit(); - printf("Total Tuples deleted is %d\n", i); - dbMgr->closeTable(table); - return i; -} -int deleteAllTuple(DatabaseManager *dbMgr, Connection &conn, char *tblname) -{ - Table *table = dbMgr->openTable(tblname); - if (table == NULL) - { - printf("Unable to open table\n"); - return 1; - } - DbRetVal rv = OK; - - table->setCondition(NULL); - - rv = conn.startTransaction(); - if (rv != OK) { dbMgr->closeTable(table); return 1; } - int count =0; - table->execute(); - void *tuple; - while ((tuple = (char*) table->fetch())) { - rv = table->deleteTuple(); - if (rv != OK) break; - count++; - } - table->closeScan(); - - conn.commit(); - printf("Total Tuples deleted is %d\n", count); - dbMgr->closeTable(table); - return count; -} -DbRetVal execAndPrint(Table *table) -{ - table->execute(); - void *tuple; - while ((tuple = (char*) table->fetch())) { - char *t = (char*) tuple; - printf("tuple value is %d %d %d %d %d\n", *(int*)t, *(int*)(t+4), - *(int*)(t+8),*(int*)(t+12),*(int*)(t+16)); - } - table->closeScan(); - return OK; -} diff --git a/test/tools/catalog/create.c b/test/tools/catalog/create.c deleted file mode 100644 index 27c59d97..00000000 --- a/test/tools/catalog/create.c +++ /dev/null @@ -1,20 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - if ( createTable(dbMgr, "t1") != 0 ) { ret = 3; } - if ( createTable(dbMgr, "t2") != 0 ) { ret = 3; } - if ( createIndex(dbMgr, "t1", "f1", "t1idx1") != 0 ) { ret= 3; } - if ( createIndex(dbMgr, "t1", "f2", "t1idx2") != 0 ) { ret = 3; } - if ( createIndex(dbMgr, "t2", "f1", "t2idx1") != 0 ) { ret = 3; } - - conn.close(); - return ret; - -} diff --git a/test/tools/catalog/create.sql b/test/tools/catalog/create.sql deleted file mode 100644 index 133d1d0c..00000000 --- a/test/tools/catalog/create.sql +++ /dev/null @@ -1,14 +0,0 @@ -echo create table and constraints with integer fields; -create table t1 (f1 int, f2 int); -insert into t1 values (23,45); -insert into t1 values (23,45); -insert into t1 values (23,45); -insert into t1 values (23,45); -insert into t1 values (23,45); -insert into t1 values (23,45); -insert into t1 values (23,45); -insert into t1 values (23,45); -insert into t1 values (23,45); -insert into t1 values (23,45); -commit; - diff --git a/test/tools/catalog/create1.sql b/test/tools/catalog/create1.sql deleted file mode 100644 index 5033c0ce..00000000 --- a/test/tools/catalog/create1.sql +++ /dev/null @@ -1,3 +0,0 @@ -echo create table t2 and constraints with three integer fields and primary key f1; -create table t2 (f1 int,f2 int,f3 int,primary key(f1)); -create index t2Uniqueidx on t2(f3) unique; diff --git a/test/tools/catalog/createPriFlagTest.sql b/test/tools/catalog/createPriFlagTest.sql deleted file mode 100644 index 9a4f48cd..00000000 --- a/test/tools/catalog/createPriFlagTest.sql +++ /dev/null @@ -1,5 +0,0 @@ -echo create table t4 (f1 int,f2 int,primary key(f1)); -create table t4 (f1 int,f2 int,primary key(f1)); -echo create table t5 (f1 int,f2 int,primary key(f1, f2)); -create table t5 (f1 int,f2 int,primary key(f1, f2)); - diff --git a/test/tools/catalog/csql.conf b/test/tools/catalog/csql.conf deleted file mode 100644 index e33cef74..00000000 --- a/test/tools/catalog/csql.conf +++ /dev/null @@ -1,70 +0,0 @@ -# CSQL System Configuration File - -#####################################Server Section######################## -#Important: For Server section parameters, make sure that the value is same for the -# server process and all the csql client process which connects to it. otherwise, -# behavior is undefined - -# Page size. Each database is logically divided into pages and allocation happens -# in this unit of pages. Increasing this value will reduce frequent allocation of pages. -PAGE_SIZE= 8192 - -#Total number of client process which can connect and work with the -# database concurrently -MAX_PROCS = 100 - -# Maximum size of the system database. -MAX_SYS_DB_SIZE=1048576 - -#Maximum size of the user database file. -MAX_DB_SIZE=10485760 - -#Shared memory key to be used by the system to create and locate system database. -SYS_DB_KEY=1199 - -#Shared memory key to be used by the system to create and locate user database. -USER_DB_KEY=2277 - -#Give full path for the log file where important system actions are stored. -LOG_FILE=/tmp/log/csql/log.out - -#The virtual memory start address at which the shared memory segment -# will be created and attached. -MAP_ADDRESS=400000000 - -#Give full path for the database file where table and record information will -#be stored for durability -DATABASE_FILE=/tmp/csql/csql.db - -#Important: For Server section parameters, make sure that the value is same for the -# server process and all the csql client process which connects to it. otherwise, -# behavior is undefined -#####################################Client Section######################## - -#Mutex timeout interval seconds -MUTEX_TIMEOUT_SECS=0 -MUTEX_TIMEOUT_USECS=5000 -MUTEX_TIMEOUT_RETRIES=10 - -#Lock timeout interval seconds -LOCK_TIMEOUT_SECS=0 -LOCK_TIMEOUT_USECS=5000 -LOCK_TIMEOUT_RETRIES=10 - -#####################################Cache Section######################## - -#Whether to enable caching of tables from target database -CACHE_TABLE=false - -#DSN Name to connect to the target database. -#This should be present in ~/odbc.ini file -DSN=myodbc3 - -ENABLE_BIDIRECTIONAL_CACHE=false - -CACHE_RECEIVER_WAIT_SECS=10 - -#Give full path for the file where all the cached table information is stored -TABLE_CONFIG_FILE=/tmp/csql/csqltable.conf - -#####################################End Section######################## diff --git a/test/tools/catalog/delete.sql b/test/tools/catalog/delete.sql deleted file mode 100644 index 6618c94b..00000000 --- a/test/tools/catalog/delete.sql +++ /dev/null @@ -1,3 +0,0 @@ -echo delete 10 tuples; - -delete from t2 where f1<20; diff --git a/test/tools/catalog/drop.c b/test/tools/catalog/drop.c deleted file mode 100644 index 48c87cdb..00000000 --- a/test/tools/catalog/drop.c +++ /dev/null @@ -1,17 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - if ( dropTable(dbMgr, "t1") != 0 ) { ret = 3; } - if ( dropTable(dbMgr, "t2") != 0 ) { ret = 3; } - - conn.close(); - return ret; - -} diff --git a/test/tools/catalog/dropIndex.sql b/test/tools/catalog/dropIndex.sql deleted file mode 100644 index 4ca32d2d..00000000 --- a/test/tools/catalog/dropIndex.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo drop index t2Uniqueidx; -drop index t2Uniqueidx; diff --git a/test/tools/catalog/dropt1.sql b/test/tools/catalog/dropt1.sql deleted file mode 100644 index ba52c2f4..00000000 --- a/test/tools/catalog/dropt1.sql +++ /dev/null @@ -1,3 +0,0 @@ -echo drop table t1; - -drop table t1; diff --git a/test/tools/catalog/dropt2.sql b/test/tools/catalog/dropt2.sql deleted file mode 100644 index 99a31968..00000000 --- a/test/tools/catalog/dropt2.sql +++ /dev/null @@ -1,3 +0,0 @@ -echo drop table t2; - -drop table t2; diff --git a/test/tools/catalog/dropt4t5.sql b/test/tools/catalog/dropt4t5.sql deleted file mode 100644 index ad4db187..00000000 --- a/test/tools/catalog/dropt4t5.sql +++ /dev/null @@ -1,2 +0,0 @@ -drop table t4; -drop table t5; diff --git a/test/tools/catalog/exp.test001.ksh b/test/tools/catalog/exp.test001.ksh deleted file mode 100644 index 745a2f8f..00000000 --- a/test/tools/catalog/exp.test001.ksh +++ /dev/null @@ -1,20 +0,0 @@ -Case 1: With no option: - - - -Case 2: With ? option: -Usage: catalog [-u username] [-p passwd] [-l] [-i] [-d] [-T table] [-I index] [-D ] - l -> list all table with field information - list all Index information - i -> reinitialize catalog tables. Drops all tables. - d -> print db usage statistics - T -> list table information - I -> list index information - D -> print debug information for system tables -Note: If multiple options are specified, last one will be considered. -Case 3: With wrong username : -Case 4: With wrong password : -Case 5: With correct user name and password : - - - diff --git a/test/tools/catalog/exp.test005.ksh b/test/tools/catalog/exp.test005.ksh deleted file mode 100644 index 01f89942..00000000 --- a/test/tools/catalog/exp.test005.ksh +++ /dev/null @@ -1,276 +0,0 @@ -Case 1: With -D chunk option with empty database - - - 0 - 1 - UserChunkTableId - 0 - 112 - FixedSizeAllocator - 1 - 1 - LockTableHashBucketId - 1 - 57348 - FixedSizeAllocator - 2 - 1 - LockTableMutexId - 0 - 49156 - FixedSizeAllocator - 3 - 1 - LockTableId - 0 - 20 - FixedSizeAllocator - 4 - 1 - TransHasTableId - 0 - 12 - FixedSizeAllocator - 5 - 1 - UndoLogTableId - 0 - 0 - VariableSizeAllocator - 10 - 1 - DatabaseTableId - 0 - 84 - FixedSizeAllocator - 11 - 1 - UserTableId - 1 - 132 - FixedSizeAllocator - 12 - 1 - TableTableId - 0 - 88 - FixedSizeAllocator - 13 - 1 - FieldTableId - 0 - 144 - FixedSizeAllocator - 14 - 1 - AccessTableId - 0 - 132 - FixedSizeAllocator - 15 - 1 - IndexTableId - 0 - 104 - FixedSizeAllocator - 16 - 1 - IndexFieldTableId - 0 - 20 - FixedSizeAllocator - - - - -echo create table and constraints with integer fields; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Case 2: With -D chunk option after table creation: - - - 0 - 1 - UserChunkTableId - 1 - 112 - FixedSizeAllocator - 1 - 1 - LockTableHashBucketId - 1 - 57348 - FixedSizeAllocator - 2 - 1 - LockTableMutexId - 0 - 49156 - FixedSizeAllocator - 3 - 1 - LockTableId - 0 - 20 - FixedSizeAllocator - 4 - 1 - TransHasTableId - 0 - 12 - FixedSizeAllocator - 5 - 1 - UndoLogTableId - 0 - 0 - VariableSizeAllocator - 10 - 1 - DatabaseTableId - 0 - 84 - FixedSizeAllocator - 11 - 1 - UserTableId - 1 - 132 - FixedSizeAllocator - 12 - 1 - TableTableId - 1 - 88 - FixedSizeAllocator - 13 - 1 - FieldTableId - 2 - 144 - FixedSizeAllocator - 14 - 1 - AccessTableId - 0 - 132 - FixedSizeAllocator - 15 - 1 - IndexTableId - 0 - 104 - FixedSizeAllocator - 16 - 1 - IndexFieldTableId - 0 - 20 - FixedSizeAllocator - - - 101 - 1 - t1 - 10 - 16 - FixedSizeAllocator - - -echo drop table t1; -Statement Executed -t1 table droped -Case 3: With -D chunk option after drop t1 : - - - 0 - 1 - UserChunkTableId - 0 - 112 - FixedSizeAllocator - 1 - 1 - LockTableHashBucketId - 1 - 57348 - FixedSizeAllocator - 2 - 1 - LockTableMutexId - 0 - 49156 - FixedSizeAllocator - 3 - 1 - LockTableId - 0 - 20 - FixedSizeAllocator - 4 - 1 - TransHasTableId - 0 - 12 - FixedSizeAllocator - 5 - 1 - UndoLogTableId - 0 - 0 - VariableSizeAllocator - 10 - 1 - DatabaseTableId - 0 - 84 - FixedSizeAllocator - 11 - 1 - UserTableId - 1 - 132 - FixedSizeAllocator - 12 - 1 - TableTableId - 0 - 88 - FixedSizeAllocator - 13 - 1 - FieldTableId - 0 - 144 - FixedSizeAllocator - 14 - 1 - AccessTableId - 0 - 132 - FixedSizeAllocator - 15 - 1 - IndexTableId - 0 - 104 - FixedSizeAllocator - 16 - 1 - IndexFieldTableId - 0 - 20 - FixedSizeAllocator - - - - diff --git a/test/tools/catalog/exp.test006.ksh b/test/tools/catalog/exp.test006.ksh deleted file mode 100644 index e69de29b..00000000 diff --git a/test/tools/catalog/exp.test007.ksh b/test/tools/catalog/exp.test007.ksh deleted file mode 100644 index bcb8a143..00000000 --- a/test/tools/catalog/exp.test007.ksh +++ /dev/null @@ -1,65 +0,0 @@ -Case 1: create two table t4,t5 -echo create table t4 (f1 int,f2 int,primary key(f1)); -Statement Executed -echo create table t5 (f1 int,f2 int,primary key(f1, f2)); -Statement Executed -Case 2: With -l option after for primary flag checking: - - - t4 - - f1 - 0 - 4 - 1 - 1 - 0 - - - - f2 - 0 - 4 - 0 - 0 - 0 - - - - - t5 - - f1 - 0 - 4 - 1 - 1 - 0 - - - - f2 - 0 - 4 - 1 - 1 - 0 - - - -
- - t4_idx1_Primary - Hash Index - t4
- f1 - t5_idx1_Primary - Hash Index - t5
- f1 - f2 -
-case 3 : drop two table -Statement Executed -Statement Executed -t4 ,t5 table droped diff --git a/test/tools/catalog/insert.c b/test/tools/catalog/insert.c deleted file mode 100644 index 5192dd7a..00000000 --- a/test/tools/catalog/insert.c +++ /dev/null @@ -1,16 +0,0 @@ - -#include "common.h" -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - int ret =0; - ret = insertTuple(dbMgr, conn, "t1", 10); - ret = insertTuple(dbMgr, conn, "t2", 10); - conn.close(); - return ret; - -} diff --git a/test/tools/catalog/insert.sql b/test/tools/catalog/insert.sql deleted file mode 100644 index 5d0f6830..00000000 --- a/test/tools/catalog/insert.sql +++ /dev/null @@ -1,22 +0,0 @@ -echo insert into t2 20 tuples; -insert into t2 values(10,20,30); -insert into t2 values(11,20,31); -insert into t2 values(12,20,32); -insert into t2 values(13,20,33); -insert into t2 values(14,20,34); -insert into t2 values(15,20,35); -insert into t2 values(16,20,36); -insert into t2 values(17,20,37); -insert into t2 values(18,20,38); -insert into t2 values(19,20,39); -insert into t2 values(20,20,40); -insert into t2 values(21,20,41); -insert into t2 values(22,20,42); -insert into t2 values(23,20,43); -insert into t2 values(24,20,44); -insert into t2 values(25,20,45); -insert into t2 values(26,20,46); -insert into t2 values(27,20,47); -insert into t2 values(28,20,48); -insert into t2 values(29,20,49); -commit; diff --git a/test/tools/catalog/test001.ksh b/test/tools/catalog/test001.ksh deleted file mode 100755 index b9003aaa..00000000 --- a/test/tools/catalog/test001.ksh +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/sh -# Test Case -# check no option, ? -# check whether authentication is working -# -echo "Case 1: With no option:" -$CSQL_INSTALL_ROOT/bin/catalog -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 2: With ? option:" -$CSQL_INSTALL_ROOT/bin/catalog -? -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 3: With wrong username :" -$CSQL_INSTALL_ROOT/bin/catalog -u wronguser -p password >/dev/null 2>&1 -if [ $? -eq 0 ] -then - exit 1; -fi - -echo "Case 4: With wrong password :" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p password >/dev/null 2>&1 -if [ $? -eq 0 ] -then - exit 1; -fi - -echo "Case 5: With correct user name and password :" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -if [ $? -ne 0 ] -then - exit 1; -fi diff --git a/test/tools/catalog/test002.ksh b/test/tools/catalog/test002.ksh deleted file mode 100755 index a57f1fab..00000000 --- a/test/tools/catalog/test002.ksh +++ /dev/null @@ -1,66 +0,0 @@ -#!/bin/sh -# Test Case -# check options l, i, d, T, I with empty database -# check options D with trans, lock and non existing structure name -# check behaviour when multiple options are given together - -echo "Case 1: With l option:" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -l -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 2: With i option:" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -i -if [ $? -ne 0 ] -then - exit 2; -fi - -echo "Case 3: With d option:" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d -if [ $? -ne 0 ] -then - exit 3; -fi - -echo "Case 4: With nonexisting tablename on -T option :" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t1 2>/tmp/tmptstlog -if [ $? -eq 0 ] -then - exit 4; -fi - -echo "Case 5: With nonexisting indexname on -I option :" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -I idx1 2>/tmp/tmptstlog -if [ $? -eq 0 ] -then - exit 5; -fi - -echo "Case 6: With trans on D option:" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D trans -if [ $? -ne 0 ] -then - exit 6; -fi -echo "Case 7: With lock on D option:" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D lock -if [ $? -ne 0 ] -then - exit 7; -fi -echo "Case 8: With nonexisting structure on D option:" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D notexist -if [ $? -eq 0 ] -then - exit 8; -fi -echo "Case 9: With two options:" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -d -l -if [ $? -ne 0 ] -then - exit 9; -fi -exit 0 diff --git a/test/tools/catalog/test003.ksh b/test/tools/catalog/test003.ksh deleted file mode 100755 index dbe85c4d..00000000 --- a/test/tools/catalog/test003.ksh +++ /dev/null @@ -1,53 +0,0 @@ -#!/bin/sh -# Test Case -# create table t1 (f1, f2) , index t1idx1 on t1(f1), index t1idx2 on t1(f2) -# create table t2 (f1, f2) , index t2idx1 on t2(f1) -# Check -T option with table having 1 index -# Check -T option with table having 2 index -# Check -I option on index t1idx2 -# drop tables t1 and t2 - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -EXECUTABLE=${PWD}/tools/catalog/create -REL_PATH=. -if [ -s "$EXECUTABLE" ] -then - REL_PATH=${PWD}/tools/catalog -fi - -${REL_PATH}/create -if [ $? -ne 0 ] -then - exit 1; -fi -echo "Tables and Indexes are created" -echo "Case 1: -T option for t1: with two index" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t1 -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 2: -T option for t2: with one index" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t2 -if [ $? -ne 0 ] -then - exit 2; -fi - -echo "Case 3: -I option for idx2 of t1" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -I t1idx2 -if [ $? -ne 0 ] -then - exit 3; -fi - -${REL_PATH}/drop -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are dropped" - -exit 0 diff --git a/test/tools/catalog/test004.ksh b/test/tools/catalog/test004.ksh deleted file mode 100755 index a55bcf33..00000000 --- a/test/tools/catalog/test004.ksh +++ /dev/null @@ -1,60 +0,0 @@ -#!/bin/sh -# Test Case -# create table t1 (f1, f2) , index t1idx1 on t1(f1), index t1idx2 on t1(f2) -# create table t2 (f1, f2) , index t2idx1 on t2(f1) -# insert 10 tuples in both t1 and t2 -# Check -T option with table having 1 index -# Check -T option with table having 2 index -# Check -I option on index t1idx2 -# drop tables - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -EXECUTABLE=${PWD}/tools/catalog/create -REL_PATH=. -if [ -s "$EXECUTABLE" ] -then - REL_PATH=${PWD}/tools/catalog -fi - -${REL_PATH}/create -if [ $? -ne 0 ] -then - exit 1; -fi -echo "Tables and Indexes are created" -${REL_PATH}/insert -if [ $? -eq 0 ] -then - exit 1; -fi -echo "Tuples inserted into table" -echo "Case 1: -T option for t1: with two index, with tuples" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t1 -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 2: -T option for t2: with one index, with tuples" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -T t2 -if [ $? -ne 0 ] -then - exit 2; -fi - -echo "Case 3: -I option for idx2 of t1, with tuples" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -I t1idx2 -if [ $? -ne 0 ] -then - exit 3; -fi - -${REL_PATH}/drop -if [ $? -ne 0 ] -then - exit 100; -fi -echo "Tables and Indexes are dropped" - -exit 0 diff --git a/test/tools/catalog/test005.ksh b/test/tools/catalog/test005.ksh deleted file mode 100755 index 3b58cf10..00000000 --- a/test/tools/catalog/test005.ksh +++ /dev/null @@ -1,57 +0,0 @@ -#!/bin/sh -# Test Case -# check options -D chunk with empty database -#create table t1 (f1,f2) check with -D chunk -#drop t1 check with -D chunk - -CSQL_CONF=${PWD}/tools/catalog/csql.conf -input=${PWD}/tools/catalog/create.sql -REL_PATH=. -if [ -s "$input" -a -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/catalog -fi -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf - -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 5 -echo "Case 1: With -D chunk option with empty database" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D chunk -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/create.sql -if [ $? -ne 0 ] -then - exit 2; -fi - -echo "Case 2: With -D chunk option after table creation:" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D chunk -if [ $? -ne 0 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/dropt1.sql - -if [ $? -ne 0 ] -then - exit 4; -fi -echo "t1 table droped " - -echo "Case 3: With -D chunk option after drop t1 :" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D chunk -if [ $? -ne 0 ] -then - exit 5; -fi - -kill -9 $pid -ipcrm -M 1199 -M 2277 -exit 0; - diff --git a/test/tools/catalog/test006.ksh b/test/tools/catalog/test006.ksh deleted file mode 100755 index b9e2441b..00000000 --- a/test/tools/catalog/test006.ksh +++ /dev/null @@ -1,91 +0,0 @@ -#!/bin/sh -# Test Case -#create table t2 (f1,f2,f3) ,with primary key(f1) and index on f3 .check with -D chunk -#insert 20 tuples and check with -D chunk -#delete 10 tuples and check with -D chunk -#drop t2 check with -D chunk - -CSQL_CONF=${PWD}/tools/catalog/csql.conf -input=${PWD}/tools/catalog/create.sql -REL_PATH=. -if [ -s "$input" -a -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/catalog -fi -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf - -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 5 - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/create1.sql -if [ $? -ne 0 ] -then - exit 1; -fi -echo "Table created" - -echo "Case 1: With -D chunk option after table creation:" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D chunk -if [ $? -ne 0 ] -then - exit 2; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/insert.sql -if [ $? -ne 0 ] -then - exit 3; -fi -echo "Tuples insered" -echo "Case 2: With -D chunk option after insert 20 tuples:" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D chunk -if [ $? -ne 0 ] -then - exit 4; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/delete.sql -if [ $? -ne 0 ] -then - exit 5; -fi - -echo "10 tuples deleted" - -echo "Case 3: With -D chunk option after deleting 10 tuples :" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D chunk -if [ $? -ne 0 ] -then - exit 6; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/dropIndex.sql -if [ $? -ne 0 ] -then - exit 7; -fi -echo "Index droped" - -echo "Case 4: With -D chunk option after Index droped :" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D chunk -if [ $? -ne 0 ] -then - exit 8; -fi; - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/dropt2.sql - -if [ $? -ne 0 ] -then - exit 9; -fi -echo "t2 table droped with index" - -echo "Case 5: With -D chunk option after drop t2 :" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -D chunk -if [ $? -ne 0 ] -then - exit 10; -fi - -kill -9 $pid -ipcrm -M 1199 -M 2277 -exit 0; diff --git a/test/tools/catalog/test007.ksh b/test/tools/catalog/test007.ksh deleted file mode 100755 index 6f046fdd..00000000 --- a/test/tools/catalog/test007.ksh +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/sh -# Test Case -# create table t4(f1, f2) primary key on f1 -# create table t5 (f1, f2) , primary key on (f1,f2) -# Check -l option on primary flag of the key -# drop tables - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -REL_PATH=. - -CSQL_CONF=${PWD}/tools/catalog/csql.conf -input=${PWD}/tools/catalog/create.sql -REL_PATH=. -if [ -s "$input" -a -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/catalog -fi -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf - -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 5 -echo "Case 1: create two table t4,t5 " -$CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/createPriFlagTest.sql -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 2: With -l option after for primary flag checking:" -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -l -if [ $? -ne 0 ] -then - exit 2; -fi -echo "case 3 : drop two table " -$CSQL_INSTALL_ROOT/bin/csql -s ${REL_PATH}/dropt4t5.sql - -if [ $? -ne 0 ] -then - exit 4; -fi -echo "t4 ,t5 table droped " -kill -9 $pid -ipcrm -M 1199 -M 2277 - -exit 0 diff --git a/test/tools/csql/TODO b/test/tools/csql/TODO deleted file mode 100644 index a1d742c9..00000000 --- a/test/tools/csql/TODO +++ /dev/null @@ -1,17 +0,0 @@ -update t1 set f1 = f2 where f1 =100; -update t1 set f1 = 10, f2 = 20 where f1 =100; -update t1 set f1 = 10+ 20 where f1 =100; -update t1 set f1 = 200; -delete from t1; -AND with two different data types (int and char) -OR with two different data types (int and char) -BETWEEN with all data types -IN with all data types -Test -ve values for integer and with between operator -comparison (f1>f2) with two different data types (int and short, int and float, int and char) - - - -Later -1.Total columns in unique, primary key constraint - diff --git a/test/tools/csql/agg1.sql b/test/tools/csql/agg1.sql deleted file mode 100644 index 5ece9b69..00000000 --- a/test/tools/csql/agg1.sql +++ /dev/null @@ -1,42 +0,0 @@ -CREATE TABLE t1 (f1 INT , f2 INT , f3 INT); -INSERT INTO t1 VALUES(1,1,1); -INSERT INTO t1 VALUES(2,1,2); -INSERT INTO t1 VALUES(3,1,3); -INSERT INTO t1 VALUES(5,2,5); -INSERT INTO t1 VALUES(10,2,10); -INSERT INTO t1 VALUES(100,3,100); -INSERT INTO t1 VALUES(200,3,200); -INSERT INTO t1 VALUES(1000,4,1000); -echo select count(f1) from t1; -select count(f1) from t1; -echo select min(f1) from t1; -select min(f1) from t1; -echo select max(f3) from t1; -select max(f3) from t1; -echo select avg(f1) from t1; -select avg(f1) from t1; -echo select sum(f1) from t1; -select sum(f1) from t1; -echo select count(f1) from t1 group by f2; -select count(f1) from t1 group by f2; -echo select min(f1) from t1 group by f2; -select min(f1) from t1 group by f2; -echo select max(f1) from t1 group by f2; -select max(f1) from t1 group by f2; -echo select avg(f1) from t1 group by f2; -select avg(f1) from t1 group by f2; -echo select sum(f1) from t1 group by f2; -select sum(f1) from t1 group by f2; -echo select min(f1), max(f3), sum(f1) from t1; -select min(f1), max(f3), sum(f1) from t1; -echo select min(f1), f2, max(f3) from t1; -select min(f1), f2, max(f3) from t1; -echo select min(f1), f2, max(f3) from t1 group by f2; -select min(f1), f2, max(f3) from t1 group by f2; -echo select min(f2) from t1 group by f2; -select min(f2) from t1 group by f2; -echo select count(*) from t1; -select count(*) from t1; -echo select count(*) from t1 group by f2; -select count(*) from t1 group by f2; -echo test over diff --git a/test/tools/csql/autocommit1.sql b/test/tools/csql/autocommit1.sql deleted file mode 100644 index 81f1eb88..00000000 --- a/test/tools/csql/autocommit1.sql +++ /dev/null @@ -1,9 +0,0 @@ -echo create table t1(f1 int,f2 char(10)); -create table t1(f1 int,f2 char(10)); -echo insert into t1 values(1,'x'); -insert into t1 values(1,'x'); -echo insert into t1 values(2,'y'); -insert into t1 values(2,'y'); - - - diff --git a/test/tools/csql/autocommit10.sql b/test/tools/csql/autocommit10.sql deleted file mode 100644 index b5cf6c76..00000000 --- a/test/tools/csql/autocommit10.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo update t1 set f2=0,f3=f1*0 where f1<=100 and f1 >1; -update t1 set f2=0,f3=f1*0 where f1<=100 and f1 >1; -echo select * from t1; -select * from t1; diff --git a/test/tools/csql/autocommit11.sql b/test/tools/csql/autocommit11.sql deleted file mode 100644 index 0f922efa..00000000 --- a/test/tools/csql/autocommit11.sql +++ /dev/null @@ -1,22 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo update t1 set f2=0,f3=f1*0 where f1<=100 and f1 >1; -update t1 set f2=0,f3=f1*0 where f1<=100 and f1 >1; -echo select * from t1; -select * from t1; -echo rollback; -rollback; diff --git a/test/tools/csql/autocommit12.sql b/test/tools/csql/autocommit12.sql deleted file mode 100644 index c6724537..00000000 --- a/test/tools/csql/autocommit12.sql +++ /dev/null @@ -1,18 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo select * from t1; -select * from t1; -echo update t1 set f2=0,f3=f1*0 where f1<=100 and f1 >1; -update t1 set f2=0,f3=f1*0 where f1<=100 and f1 >1; -echo select * from t1; -select * from t1; diff --git a/test/tools/csql/autocommit13.sql b/test/tools/csql/autocommit13.sql deleted file mode 100644 index 273bb0f7..00000000 --- a/test/tools/csql/autocommit13.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; diff --git a/test/tools/csql/autocommit14.sql b/test/tools/csql/autocommit14.sql deleted file mode 100644 index 7bacd46a..00000000 --- a/test/tools/csql/autocommit14.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo commit; -commit; diff --git a/test/tools/csql/autocommit15.sql b/test/tools/csql/autocommit15.sql deleted file mode 100644 index c3218660..00000000 --- a/test/tools/csql/autocommit15.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo delete from t1 where f1<=100 and f1>1; -delete from t1 where f1<=100 and f1>1; -echo commit; -commit; diff --git a/test/tools/csql/autocommit16.sql b/test/tools/csql/autocommit16.sql deleted file mode 100644 index c5ecdb64..00000000 --- a/test/tools/csql/autocommit16.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo delete from t1 where f1<=100 and f1>1; -delete from t1 where f1<=100 and f1>1; -echo select * from t1; -select * from t1; diff --git a/test/tools/csql/autocommit17.sql b/test/tools/csql/autocommit17.sql deleted file mode 100644 index c251d90e..00000000 --- a/test/tools/csql/autocommit17.sql +++ /dev/null @@ -1,22 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo delete from t1 where f1<=100 and f1>1; -delete from t1 where f1<=100 and f1>1; -echo select * from t1; -select * from t1; -echo rollback; -rollback; diff --git a/test/tools/csql/autocommit18.sql b/test/tools/csql/autocommit18.sql deleted file mode 100644 index 886c3d60..00000000 --- a/test/tools/csql/autocommit18.sql +++ /dev/null @@ -1,18 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo select * from t1; -select * from t1; -echo delete from t1 where f1<=100 and f1>1; -delete from t1 where f1<=100 and f1>1; -echo select * from t1; -select * from t1; diff --git a/test/tools/csql/autocommit2.sql b/test/tools/csql/autocommit2.sql deleted file mode 100644 index 63d57d58..00000000 --- a/test/tools/csql/autocommit2.sql +++ /dev/null @@ -1,21 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo update t1 set f2='k' where f1=2; -update t1 set f2='k' where f1=2; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo insert into t1 values(3,'k'); -insert into t1 values(3,'k'); -echo insert into t1 values(4,'p'); -insert into t1 values(4,'p'); -echo commit; -commit; -echo insert into t1 values(5,'t'); -insert into t1 values(5,'t'); -echo rollback; -rollback; - diff --git a/test/tools/csql/autocommit3.sql b/test/tools/csql/autocommit3.sql deleted file mode 100644 index acc5aac2..00000000 --- a/test/tools/csql/autocommit3.sql +++ /dev/null @@ -1,24 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo delete from t1 where f1=1; -delete from t1 where f1=1; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo insert into t1 values(3,'k'); -insert into t1 values(3,'k'); -echo insert into t1 values(4,'p'); -insert into t1 values(4,'p'); -echo create table t2(f1 int,f2 char(10)); -create table t2(f1 int,f2 char(10)); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=1; -delete from t1 where f1=1; diff --git a/test/tools/csql/autocommit4.sql b/test/tools/csql/autocommit4.sql deleted file mode 100644 index 933b2c3a..00000000 --- a/test/tools/csql/autocommit4.sql +++ /dev/null @@ -1,25 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo delete from t1 where f1=1; -delete from t1 where f1=1; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo insert into t1 values(3,'k'); -insert into t1 values(3,'k'); -echo insert into t1 values(4,'p'); -insert into t1 values(4,'p'); -echo create table t2(f1 int,f2 char(10)); -create table t2(f1 int,f2 char(10)); -echo delete from t1 where f1=1; -delete from t1 where f1=1; -echo select * from t1; -select * from t1; -echo rollback; -rollback; - diff --git a/test/tools/csql/autocommit5.sql b/test/tools/csql/autocommit5.sql deleted file mode 100644 index 2a38d6ee..00000000 --- a/test/tools/csql/autocommit5.sql +++ /dev/null @@ -1,28 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo delete from t1 where f1=1; -delete from t1 where f1=1; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo update t1 set f2='X'; -update t1 set f2='X'; -echo insert into t1 values(3,'k'); -insert into t1 values(3,'k'); -echo insert into t1 values(4,'p'); -insert into t1 values(4,'p'); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo update t1 set f2='Z'; -update t1 set f2='Z'; -echo create table t2(f1 int,f2 char(10)); -create table t2(f1 int,f2 char(10)); -echo delete from t1 where f1=1; -delete from t1 where f1=1; diff --git a/test/tools/csql/autocommit6.sql b/test/tools/csql/autocommit6.sql deleted file mode 100644 index 5c2ba9ef..00000000 --- a/test/tools/csql/autocommit6.sql +++ /dev/null @@ -1,14 +0,0 @@ -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo select * from t1; -select * from t1; -echo update t1 set f2=3333, f3=4444 where f1>=100; -update t1 set f2=3333,f3=4444 where f1>=100; diff --git a/test/tools/csql/autocommit7.sql b/test/tools/csql/autocommit7.sql deleted file mode 100644 index dd19d20d..00000000 --- a/test/tools/csql/autocommit7.sql +++ /dev/null @@ -1,20 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo commit; -commit; -echo insert into t1 values(10000,20000,30000); -insert into t1 values(10000,20000,30000); -echo insert into t1 values(100000,200000,300000); -insert into t1 values(100000,200000,300000); -echo commit; -commit; diff --git a/test/tools/csql/autocommit8.sql b/test/tools/csql/autocommit8.sql deleted file mode 100644 index aed5b50a..00000000 --- a/test/tools/csql/autocommit8.sql +++ /dev/null @@ -1,22 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo commit; -commit; -echo insert into t1 values(10000,20000,30000); -insert into t1 values(10000,20000,30000); -echo insert into t1 values(100000,200000,300000); -insert into t1 values(100000,200000,300000); -echo select * from t1; -select * from t1; -echo rollback; -rollback; diff --git a/test/tools/csql/autocommit9.sql b/test/tools/csql/autocommit9.sql deleted file mode 100644 index 800666cf..00000000 --- a/test/tools/csql/autocommit9.sql +++ /dev/null @@ -1,22 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo insert into t1 values(1000,2000,3000); -insert into t1 values(1000,2000,3000); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo update t1 set f2=0,f3=f1+f2+f3 where f1<=100 and f1 >1; -update t1 set f2=0,f3=f1+f2+f3 where f1<=100 and f1 >1; -echo commit; -commit; - - diff --git a/test/tools/csql/bit_test024.ksh b/test/tools/csql/bit_test024.ksh deleted file mode 100755 index b4e221fa..00000000 --- a/test/tools/csql/bit_test024.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check bit data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype4.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/comp1.sql b/test/tools/csql/comp1.sql deleted file mode 100644 index 502c6e15..00000000 --- a/test/tools/csql/comp1.sql +++ /dev/null @@ -1,23 +0,0 @@ -CREATE TABLE t1 (f1 INT ,f2 INT ,f3 INT, primary key(f1,f2)); -INSERT INTO t1 VALUES(1,1,1); -INSERT INTO t1 VALUES(2,1,2); -INSERT INTO t1 VALUES(3,1,3); -INSERT INTO t1 VALUES(1,1,3); -INSERT INTO t1 VALUES(5,2,5); -INSERT INTO t1 VALUES(10,2,10); -INSERT INTO t1 VALUES(100,3,100); -echo select count(f1) from t1; -select count(f1) from t1; -echo select * from t1 where f1=1 and f2=1; -select * from t1 where f1=1 and f2=1; -echo select * from t1 where f1=5 and f2=1; -select * from t1 where f1=5 and f2=1; -echo select * from t1 where f1=5; -select * from t1 where f1=5; -echo select * from t1 where f1=7; -select * from t1 where f1=7; -echo select * from t1 where f1=10 and f2=2 and f3=10; -select * from t1 where f1=10 and f2=2 and f3=10; -echo select * from t1 where f1=10 and f2=6 and f3=10; -select * from t1 where f1=10 and f2=6 and f3=10; -echo test over diff --git a/test/tools/csql/comp2.sql b/test/tools/csql/comp2.sql deleted file mode 100644 index 3982d0c2..00000000 --- a/test/tools/csql/comp2.sql +++ /dev/null @@ -1,24 +0,0 @@ -CREATE TABLE t1 (f1 INT NOT NULL,f2 INT NOT NULL,f3 INT); -CREATE INDEX idx on t1 (f1,f2); -INSERT INTO t1 VALUES(1,1,1); -INSERT INTO t1 VALUES(2,1,2); -INSERT INTO t1 VALUES(3,1,3); -INSERT INTO t1 VALUES(1,1,3); -INSERT INTO t1 VALUES(5,2,5); -INSERT INTO t1 VALUES(10,2,10); -INSERT INTO t1 VALUES(100,3,100); -echo select count(f1) from t1; -select count(f1) from t1; -echo select * from t1 where f1=1 and f2=1; -select * from t1 where f1=1 and f2=1; -echo select * from t1 where f1=5 and f2=1; -select * from t1 where f1=5 and f2=1; -echo select * from t1 where f1=5; -select * from t1 where f1=5; -echo select * from t1 where f1=7; -select * from t1 where f1=7; -echo select * from t1 where f1=10 and f2=2 and f3=10; -select * from t1 where f1=10 and f2=2 and f3=10; -echo select * from t1 where f1=10 and f2=6 and f3=10; -select * from t1 where f1=10 and f2=6 and f3=10; -echo test over diff --git a/test/tools/csql/comp3.sql b/test/tools/csql/comp3.sql deleted file mode 100644 index e50a798a..00000000 --- a/test/tools/csql/comp3.sql +++ /dev/null @@ -1,24 +0,0 @@ -CREATE TABLE t1 (f1 INT NOT NULL,f2 char(10) NOT NULL,f3 INT); -CREATE INDEX idx on t1 (f1,f2) HASH UNIQUE; -INSERT INTO t1 VALUES(1,'1',1); -INSERT INTO t1 VALUES(2,'1',2); -INSERT INTO t1 VALUES(3,'1',3); -INSERT INTO t1 VALUES(1,'1',3); -INSERT INTO t1 VALUES(5,'2',5); -INSERT INTO t1 VALUES(10,'2',10); -INSERT INTO t1 VALUES(100,'3',100); -echo select count(f1) from t1; -select count(f1) from t1; -echo select * from t1 where f1=1 and f2=1; -select * from t1 where f1=1 and f2='1'; -echo select * from t1 where f1=5 and f2=1; -select * from t1 where f1=5 and f2='1'; -echo select * from t1 where f1=5; -select * from t1 where f1=5; -echo select * from t1 where f1=7; -select * from t1 where f1=7; -echo select * from t1 where f1=10 and f2=2 and f3=10; -select * from t1 where f1=10 and f2='2' and f3=10; -echo select * from t1 where f1=10 and f2=6 and f3=10; -select * from t1 where f1=10 and f2='6' and f3=10; -echo test over diff --git a/test/tools/csql/comp4.sql b/test/tools/csql/comp4.sql deleted file mode 100644 index 447104ae..00000000 --- a/test/tools/csql/comp4.sql +++ /dev/null @@ -1,7 +0,0 @@ -CREATE TABLE t1 (f1 INT NOT NULL,f2 char(10) NOT NULL,f3 INT); -CREATE INDEX idx on t1 (f1,f2) TREE UNIQUE; -INSERT INTO t1 VALUES(1,'1',1); -INSERT INTO t1 VALUES(3,'1',3); -echo select count(f1) from t1; -select count(f1) from t1; -echo test over diff --git a/test/tools/csql/composite1.sql b/test/tools/csql/composite1.sql deleted file mode 100644 index bd4280b9..00000000 --- a/test/tools/csql/composite1.sql +++ /dev/null @@ -1,62 +0,0 @@ -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx1 on t1(f1,f2) hash unique; -create index idx1 on t1(f1,f2) hash unique; -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(1,2,4); -insert into t1 values(1,2,4); -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx2 on t1(f1,f2) tree unique; -create index idx2 on t1(f1,f2) tree unique; -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(1,2,4); -insert into t1 values(1,2,4); -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo create table t1(f1 int not null,f2 int not null,f3 int); -create table t1(f1 int not null,f2 int not null,f3 int); -echo create index idx2 on t1(f1,f2) hash primary; -create index idx2 on t1(f1,f2) hash primary; -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(1,2,4); -insert into t1 values(1,2,4); -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo create table t1(f1 int not null,f2 int not null,f3 int); -create table t1(f1 int not null,f2 int not null,f3 int); -echo create index idx2 on t1(f1,f2) tree primary; -create index idx2 on t1(f1,f2) tree primary; -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(1,2,4); -insert into t1 values(1,2,4); -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo create table t1(f1 int not null,f2 int,f3 int,primary key(f1,f2)); -create table t1(f1 int not null,f2 int,f3 int,primary key(f1,f2)); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(1,2,4); -insert into t1 values(1,2,4); -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; diff --git a/test/tools/csql/composite2.sql b/test/tools/csql/composite2.sql deleted file mode 100644 index edd56e7a..00000000 --- a/test/tools/csql/composite2.sql +++ /dev/null @@ -1,62 +0,0 @@ -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx1 on t1(f1,f3) hash unique; -create index idx1 on t1(f1,f3) hash unique; -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(1,4,3); -insert into t1 values(1,4,3); -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx2 on t1(f1,f3) tree unique; -create index idx2 on t1(f1,f3) tree unique; -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(1,4,3); -insert into t1 values(1,4,3); -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo create table t1(f1 int not null,f2 int,f3 int not null); -create table t1(f1 int not null,f2 int,f3 int not null); -echo create index idx2 on t1(f1,f3) hash primary; -create index idx2 on t1(f1,f3) hash primary; -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(1,4,3); -insert into t1 values(1,4,3); -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo create table t1(f1 int not null,f2 int,f3 int not null); -create table t1(f1 int not null,f2 int,f3 int not null); -echo create index idx2 on t1(f1,f3) tree primary; -create index idx2 on t1(f1,f3) tree primary; -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(1,4,3); -insert into t1 values(1,4,3); -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo create table t1(f1 int not null,f2 int,f3 int,primary key(f1,f3)); -create table t1(f1 int not null,f2 int,f3 int,primary key(f1,f3)); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(1,4,3); -insert into t1 values(1,4,3); -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; diff --git a/test/tools/csql/composite3.sql b/test/tools/csql/composite3.sql deleted file mode 100644 index edd3fba8..00000000 --- a/test/tools/csql/composite3.sql +++ /dev/null @@ -1,10 +0,0 @@ -echo create table t1(f1 int,f2 int,f3 int,f4 int,primary key(f2,f4)); -create table t1(f1 int,f2 int,f3 int,f4 int,primary key(f2,f4)); -echo insert into t1 values(1,2,3,4); -insert into t1 values(1,2,3,4); -echo insert into t1 values(1,2,5,4); -insert into t1 values(1,2,5,4); -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; diff --git a/test/tools/csql/csql1.sql b/test/tools/csql/csql1.sql deleted file mode 100644 index e96ad6cf..00000000 --- a/test/tools/csql/csql1.sql +++ /dev/null @@ -1,28 +0,0 @@ -echo create table and constraints with integer fields; -create table t1 (f1 int, f2 int); -insert into t1 values (10, 20); -insert into t1 (f1, f2) values (11, 21); -insert into t1 (f2, f1) values (22, 12); -insert into t1 (f1) values (13); -insert into t1 (f2) values (24); -select * from t1; -create table t2 (f1 int not null, f2 int); -insert into t2 values (10, 20); -insert into t2 (f1, f2) values (11, 21); -insert into t2 (f2, f1) values (22, 12); -insert into t2 (f1) values (13); -insert into t2 (f2) values (24); -select * from t2; -create table t3 (f1 int, f2 int, primary key(f1)); -insert into t3 values (10, 20); -insert into t3 (f1, f2) values (11, 21); -insert into t3 (f2, f1) values (22, 12); -insert into t3 (f1) values (13); -insert into t3 (f2) values (24); -insert into t3 values (100, NULL); -update t3 set f2=NULL where f1=10; -delete from t3 where f2=NULL; -select * from t3; -drop table t1; -drop table t2; -drop table t3; diff --git a/test/tools/csql/csql10.sql b/test/tools/csql/csql10.sql deleted file mode 100644 index 57a473d0..00000000 --- a/test/tools/csql/csql10.sql +++ /dev/null @@ -1,26 +0,0 @@ -echo Description: SET TRANSACTION type test - -create table t1 (f1 int, f2 char(10), f3 int, primary key (f1)); -echo check default transaction type -insert into t1 values (10, '20', 10); -insert into t1 values (11, '21', 11); - -echo check read only type -set transaction read only; -insert into t1 values (11, '21', 11); -update set t2='a' where f1 = 10; -delete from t1 where f1 = 11; -select * from t1; - -echo check read write type -insert into t1 values (50, '50', 50); -update set t2='a' where f1 = 10; -delete from t1 where f1 = 11; -select * from t1; - -echo check read only type -set transaction read only; -insert into t1 values (11, '21', 11); -update set t2='a' where f1 = 10; -delete from t1 where f1 = 11; -select * from t1; diff --git a/test/tools/csql/csql11.sql b/test/tools/csql/csql11.sql deleted file mode 100644 index 97e78929..00000000 --- a/test/tools/csql/csql11.sql +++ /dev/null @@ -1,6 +0,0 @@ -echo all data type create, insert, select test; -create table t1 (f1 int not null, f2 smallint not null, f3 char(10) not null,f4 float not null, f5 double not null,f6 date not null, f7 time not null, f8 timestamp not null,f9 tinyint not null,f10 bigint not null,f11 binary(10) not null); -insert into t1 values(1, 1,'NIHAR', 1.1,10000001.10000001, '2001-1-1', '01:01:01', '2001-11-30 01:01:01',1,10000000,'ABCD56789'); -insert into t1 values(null,null,null,null,null,null,null,null,null,null,null); -select * from t1; -drop table t1; diff --git a/test/tools/csql/csql12.sql b/test/tools/csql/csql12.sql deleted file mode 100644 index 5976a533..00000000 --- a/test/tools/csql/csql12.sql +++ /dev/null @@ -1,24 +0,0 @@ -echo create table t1 (f1 int,f2 date); -create table t1 (f1 int,f2 date); -echo insert into t1 values(1,'2008-10-29'); -insert into t1 values(1,'2008-10-29'); -echo insert into t1 values(2,'28-12-2008'); -insert into t1 values(2,'28-12-2008'); -echo insert into t1 values(3,'2008-2-30'); -insert into t1 values(3,'2008-2-30'); -echo insert into t1 values(4,'2008-3- -20'); -insert into t1 values(4,'2008-3- -20'); -echo insert into t1 values(5,NULL); -insert into t1 values(5,NULL); -echo insert into t1 values(6,'2007-05-05'); -insert into t1 values(6,'2007-05-05'); -echo select * from t1; -select * from t1; -echo select * from t1 where f2<='2007-05-05'; -select * from t1 where f2<='2007-05-05'; -echo select * from t1 where f2>='2007-05-05'; -select * from t1 where f2>='2007-05-05'; -echo select * from t1 where f2='2007-05-05'; -select * from t1 where f2='2007-05-05'; -echo drop table t1; -drop table t1; diff --git a/test/tools/csql/csql2.sql b/test/tools/csql/csql2.sql deleted file mode 100644 index 5b8d28b9..00000000 --- a/test/tools/csql/csql2.sql +++ /dev/null @@ -1,34 +0,0 @@ -echo UPDATE and DELETE testing; - -create table t1 (f1 int, f2 int, primary key (f1)); -insert into t1 values (10, 20); -insert into t1 values (11, 21); -insert into t1 values (12, 22); -insert into t1 values (13, 23); -insert into t1 values (14, 24); -insert into t1 values (50, 50); -echo select * from t1; -select * from t1; -echo select * from t1 where f1 = 100; -select * from t1 where f1 = 50; - -echo update t1 set f2 = 100; -update t1 set f2 = 100; -echo select * from t1; -select * from t1; - -echo update t1 set f2 = 200 where f1 =50; -update t1 set f2 =200 where f1 =50; -echo select * from t1; -select * from t1; - -echo delete from t1 where f1 = 50; -delete from t1 where f1 = 50; -echo select * from t1; -select * from t1; - -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -drop table t1; diff --git a/test/tools/csql/csql3.sql b/test/tools/csql/csql3.sql deleted file mode 100644 index 28b5e4cd..00000000 --- a/test/tools/csql/csql3.sql +++ /dev/null @@ -1,52 +0,0 @@ -echo Same as csql2 but with primary key; - -create table t1 (f1 int, f2 int, primary key (f1)); -insert into t1 values (10, 20); -insert into t1 values (11, 21); -insert into t1 values (12, 22); -insert into t1 values (13, 23); -insert into t1 values (14, 24); -insert into t1 values (50, 50); -echo select * from t1; -select * from t1; -echo select * from t1 where f1 = 100; -select * from t1 where f1 = 100; -echo select * from t1 where f1 = 10; -select * from t1 where f1 = 10; -echo select f1 from t1 where f1 = 11; -select f1 from t1 where f1 = 11; -echo select f2 from t1 where f1 = 11; -select f2 from t1 where f1 = 11; -echo select f1, f2 from t1 where f1 = 12; -select f1, f2 from t1 where f1 = 12; -echo select * from t1 where f1 != 12 AND f2 <= 13; -select * from t1 where f1 != 12 AND f2 <= 13; -echo select * from t1 where f1 = 12 AND f2 >= 22; -select * from t1 where f1 = 12 AND f2 >= 22; -echo select * from t1 where f1 = 12 OR f1 > 13; -select * from t1 where f1 = 12 OR f1 > 13; -echo select * from t1 where f1 = 12 OR f2 < 13; -select * from t1 where f1 = 12 OR f2 < 13; -echo select * from t1 where f1 = 12 OR f2 <> 22; -select * from t1 where f1 = 12 OR f2 <> 22; -echo select * from t1 where NOT f1 = 12; -select * from t1 where NOT f1 = 12; -echo select * from t1 where f1 != 12; -select * from t1 where f1 != 12; -echo select * from t1 where NOT f1 != 12; -select * from t1 where NOT f1 != 12; -echo select * from t1 where NOT (f1 = 12 AND f2 =22); -select * from t1 where NOT (f1 = 12 AND f2 =22); -echo select * from t1 where NOT (f1 = 12 OR f2 = 23); -select * from t1 where NOT (f1 = 12 OR f2 = 23); -echo select * from t1 where f1 = 12 OR f2 = 23 OR f2 = 22; -select * from t1 where f1 = 12 OR f2 = 23 OR f2 = 22; -echo select * from t1 where f1+12 = 20; -select * from t1 where f1+12 = 20; -echo select * from t1 where f1 = 12 + f2; -select * from t1 where f1 = 12 + f2; -echo select * from t1 where f1 = f2; -select * from t1 where f1 = f2; -echo select * from t1 where f1=12 and f1<=13 or f1>=11; -select * from t1 where f1=12 and f1<=13 or f1>=11; -drop table t1; diff --git a/test/tools/csql/csql4.sql b/test/tools/csql/csql4.sql deleted file mode 100644 index b408b5ba..00000000 --- a/test/tools/csql/csql4.sql +++ /dev/null @@ -1,7 +0,0 @@ -echo all data type create, insert, select test; -echo create table t1 (f1 char(10), f2 tinyint, f3 smallint,f4 int, f5 bigint,f6 integer, f7 float, f8 real,f9 double,f10 long,f11 binary(128),f12 date,f13 time,f14 timestamp); -create table t1 (f1 char(10), f2 tinyint, f3 smallint,f4 int, f5 bigint,f6 integer, f7 float, f8 real,f9 double,f10 long,f11 binary(128),f12 date,f13 time,f14 timestamp); -echo insert into t1 values('NIHAR', 1,1,-2147483648,9223372036854775807, 2147483648,1.1, 1000000000.000000,10000001.10000001,99999,'ABCDEF0123456789','2001-1-1', '01:01:01', '2001-11-30 01:01:01'); -insert into t1 values('NIHAR', 1,1,-2147483648,9223372036854775807, 2147483648,1.1, 1000000000.000000,10000001.10000001,99999,'ABCDEF0123456789','2001-1-1', '01:01:01', '2001-11-30 01:01:01'); -select * from t1; -drop table t1; diff --git a/test/tools/csql/csql5.sql b/test/tools/csql/csql5.sql deleted file mode 100644 index 9b9d9898..00000000 --- a/test/tools/csql/csql5.sql +++ /dev/null @@ -1,5 +0,0 @@ -echo drop table test; -create table t1 (f1 integer); -drop table t1; -create table t1 (f1 integer); -drop table t1; diff --git a/test/tools/csql/csql6.sql b/test/tools/csql/csql6.sql deleted file mode 100644 index 1cd99d02..00000000 --- a/test/tools/csql/csql6.sql +++ /dev/null @@ -1,11 +0,0 @@ -echo create index test; -create table t1 (f1 integer not null, f2 integer not null, - f3 int not null, f4 int not null, - f5 int not null, f6 int not null); -create index idx1 on t1 (f1); -create index idx2 on t1 (f2) UNIQUE; -create index idx3 on t1 (f3) PRIMARY; -create index idx4 on t1 (f4) HASH PRIMARY; -create index idx5 on t1 (f5) TREE; -create index idx6 on t1 (f6) TREE PRIMARY; -drop table t1; diff --git a/test/tools/csql/csql7.sql b/test/tools/csql/csql7.sql deleted file mode 100644 index a7a8d7f4..00000000 --- a/test/tools/csql/csql7.sql +++ /dev/null @@ -1,8 +0,0 @@ -echo Descr:drop index test; -create table t1 (f1 integer not null, f2 integer not null, - f3 int not null, f4 int not null); -create index idx1 on t1 (f1); -create index idx2 on t1 (f2) UNIQUE; -create index idx3 on t1 (f3) PRIMARY; -drop index idx2; -drop table t1; diff --git a/test/tools/csql/csql8.sql b/test/tools/csql/csql8.sql deleted file mode 100644 index 46c41a57..00000000 --- a/test/tools/csql/csql8.sql +++ /dev/null @@ -1,14 +0,0 @@ -echo Description:count(*) test; - -create table t1 (f1 int, f2 int, primary key (f1)); -insert into t1 values (10, 20); -insert into t1 values (11, 21); -insert into t1 values (12, 22); -insert into t1 values (13, 23); -insert into t1 values (14, 24); -insert into t1 values (50, 50); -echo select * from t1; -select count(*) from t1; -echo select * from t1 where f1 =11; -select count(*) from t1 where f1 = 11; -drop table t1; diff --git a/test/tools/csql/csql9.sql b/test/tools/csql/csql9.sql deleted file mode 100644 index 02e9b963..00000000 --- a/test/tools/csql/csql9.sql +++ /dev/null @@ -1,33 +0,0 @@ -echo Description:BETWEEN and IN test; - -create table t1 (f1 int, f2 char(10), f3 int, primary key (f1)); -insert into t1 values (10, '20', 10); -insert into t1 values (11, '21', 11); -insert into t1 values (12, '22', 12); -insert into t1 values (13, '23', 13); -insert into t1 values (14, '24', 14); -insert into t1 values (50, '50', 50); -echo select * from t1 where f1 between 12 and 14; -select * from t1 where f1 between 12 and 14; - -echo select * from t1 where f1 not between 12 and 14; -select * from t1 where f1 not between 12 and 14; - -echo select * from t1 where f3 between 12 and 14; -select * from t1 where f3 between 12 and 14; - -echo select * from t1 where f1 IN (12, 14, 50); -select * from t1 where f1 IN (12, 14, 50); - -echo select * from t1 where f1 IN (12, 14, 50) AND f3 IN (50); -select * from t1 where f1 IN (12, 14, 50) AND f3 IN (50); - -echo select * from t1 where f1 IN (12, 14, 50) OR f3 IN (50); -select * from t1 where f1 IN (12, 14, 50) OR f3 IN (50); - -echo select * from t1 where f1 IN (12, 14, 50) AND f3 between 12 and 14; -select * from t1 where f1 IN (12, 14, 50) AND f3 between 12 and 14; - -echo select * from t1 where f1 NOT IN (12, 14, 50); -select * from t1 where f1 NOT IN (12, 14, 50); -drop table t1; diff --git a/test/tools/csql/datatype1.sql b/test/tools/csql/datatype1.sql deleted file mode 100644 index 99a6f7ee..00000000 --- a/test/tools/csql/datatype1.sql +++ /dev/null @@ -1,48 +0,0 @@ -echo int data type testing; - -create table t1 (f1 int, f2 int, primary key (f1)); -insert into t1 values (10, 1); -insert into t1 values (11, 1); -insert into t1 values (12, 1); -insert into t1 values (13, 1); -insert into t1 values (-2147483648, 1); -insert into t1 values (2147483647, 1); -echo select * from t1; -select * from t1; -echo select * from t1 where f1 = 10; -select * from t1 where f1 = 10; -echo select * from t1 where f1 != 12 AND f2 <= 13; -select * from t1 where f1 != 12 AND f2 <= 13; -echo select * from t1 where f1 = 12 AND f2 >= 22; -select * from t1 where f1 = 12 AND f2 >= 22; -echo select * from t1 where f1 = 12 OR f1 > 13; -select * from t1 where f1 = 12 OR f1 > 13; -echo select * from t1 where f1 = 12 OR f2 < 13; -select * from t1 where f1 = 12 OR f2 < 13; -echo select * from t1 where f1 = 12 OR f2 <> 22; -select * from t1 where f1 = 12 OR f2 <> 22; -echo select * from t1 where NOT f1 = 12; -select * from t1 where NOT f1 = 12; -echo select * from t1 where f1 != 12; -select * from t1 where f1 != 12; -echo select * from t1 where NOT f1 != 12; -select * from t1 where NOT f1 != 12; -echo select * from t1 where f1 = f2; -select * from t1 where f1 = f2; - -echo select * from t1 where f1 between 2147483646 and 2147483647; -select * from t1 where f1 between 2147483646 and 2147483647; -echo select * from t1 where f1 between -2147483647 and -2147483648; -select * from t1 where f1 between -2147483647 and -2147483648; - -echo update t1 set f2 = 2 where f1 != f2; -update t1 set f2 = 2 where f1 != f2; -select * from t1; - -echo update t1 set f2 = 3 where f1 = 12; -update t1 set f2 = 3 where f1 = 12; -select * from t1; - -delete from t1 where f1 = 12; -select * from t1; -drop table t1; diff --git a/test/tools/csql/datatype10.sql b/test/tools/csql/datatype10.sql deleted file mode 100644 index 67e0d7fc..00000000 --- a/test/tools/csql/datatype10.sql +++ /dev/null @@ -1,50 +0,0 @@ -echo binary data type testing; - -create table t1 (f1 int, f2 binary(4) ); -insert into t1 values (10, '12fe'); -insert into t1 values (11, '245af'); -insert into t1 values (12, '245af'); -insert into t1 values (13, '12fe'); -insert into t1 values (-2147483648,'dc23' ); -insert into t1 values (2147483647, '323a34'); -echo select * from t1; -select * from t1; -echo select * from t1 where f2 = '12fe'; -select * from t1 where f2 = '12fe'; -echo select * from t1 where f2 != '323a34' AND f1 = 13; -select * from t1 where f2 != '323a34' AND f1 = 13; -echo select * from t1 where f1 = 12 AND f2 >= '245af'; -select * from t1 where f1 = 12 AND f2 >= '245af'; -echo select * from t1 where f1 = 12 OR f2 > 'dc23'; -select * from t1 where f1 = 12 OR f2 > 'dc23'; -echo select * from t1 where f1 = 12 OR f2 < 'dc23'; -select * from t1 where f1 = 12 OR f2 < 'dc23'; -echo select * from t1 where f1 = 12 OR f2 <> '245af'; -select * from t1 where f1 = 12 OR f2 <> '245af'; -echo select * from t1 where NOT f2 ='12fe'; -select * from t1 where NOT f2 ='12fe'; -echo select * from t1 where f2 != '12fe'; -select * from t1 where f2 != '12fe'; -echo select * from t1 where NOT f2 != '12fe'; -select * from t1 where NOT f2 != '12fe'; -echo select * from t1 where f1 = f2; -select * from t1 where f1 = f2; -echo select * from t1 where f2 in ('245af','12fe'); -select * from t1 where f2 in ('245af','12fe'); -echo select * from t1 where f2 between '00000000' and 'ffffffff'; -select * from t1 where f2 between '00000000' and 'ffffffff'; -echo select * from t1 where f2 between '122' and '12a2'; -select * from t1 where f2 between '122' and '12a2'; - -echo update t1 set f2 = '435f3' where f1 != 13 and f2='323a34' ; -update t1 set f2 ='435f3' where f1 != 13 and f2='323a34'; -select * from t1; - -echo update t1 set f2 = '23abc' where f2 = '245af'; -update t1 set f2 = '23abc' where f2 = '245af'; -select * from t1; - -echo delete from t1 where f2 = '12fe'; -delete from t1 where f2 = '12fe'; -select * from t1; -drop table t1; diff --git a/test/tools/csql/datatype11.sql b/test/tools/csql/datatype11.sql deleted file mode 100644 index bf40a71b..00000000 --- a/test/tools/csql/datatype11.sql +++ /dev/null @@ -1,46 +0,0 @@ -echo binary data type testing with primary key; - -create table t1 (f1 int, f2 binary(4) ,primary key(f2)); -insert into t1 values (10, '12fe'); -insert into t1 values (11, '245af'); -insert into t1 values (12, '2423fe'); -insert into t1 values (13, '12fe'); -insert into t1 values (-2147483648,'dc23' ); -insert into t1 values (2147483647, '323a34'); -echo select * from t1; -select * from t1; -echo select * from t1 where f2 = '12fe'; -select * from t1 where f2 = '12fe'; -echo select * from t1 where f2 != '323a34' AND f1 = 13; -select * from t1 where f2 != '323a34' AND f1 = 13; -echo select * from t1 where f1 = 12 AND f2 >= '245af'; -select * from t1 where f1 = 12 AND f2 >= '245af'; -echo select * from t1 where f1 = 12 OR f2 > 'dc23'; -select * from t1 where f1 = 12 OR f2 > 'dc23'; -echo select * from t1 where f1 = 12 OR f2 < 'dc23'; -select * from t1 where f1 = 12 OR f2 < 'dc23'; -echo select * from t1 where f1 = 12 OR f2 <> '245af'; -select * from t1 where f1 = 12 OR f2 <> '245af'; -echo select * from t1 where NOT f2 ='12fe'; -select * from t1 where NOT f2 ='12fe'; -echo select * from t1 where f2 != '12fe'; -select * from t1 where f2 != '12fe'; -echo select * from t1 where NOT f2 != '12fe'; -select * from t1 where NOT f2 != '12fe'; -echo select * from t1 where f1 = f2; -select * from t1 where f1 = f2; -echo select * from t1 where f2 in ('245af','12fe'); -select * from t1 where f2 in ('245af','12fe'); -echo select * from t1 where f2 between '00000000' and 'ffffffff'; -select * from t1 where f2 between '00000000' and 'ffffffff'; -echo select * from t1 where f2 between '122' and '12a2'; -select * from t1 where f2 between '122' and '12a2'; - -echo update t1 set f2 = '435f3' where f1 != 13 and f2='323a34' ; -update t1 set f2 ='435f3' where f1 != 13 and f2='323a34'; -select * from t1; - -echo delete from t1 where f2 = '23abc'; -delete from t1 where f2 = '23abc'; -select * from t1; -drop table t1; diff --git a/test/tools/csql/datatype12.sql b/test/tools/csql/datatype12.sql deleted file mode 100644 index 27571c89..00000000 --- a/test/tools/csql/datatype12.sql +++ /dev/null @@ -1,48 +0,0 @@ -echo binary data type testing with primary key; - -echo create table t1 (f1 int, f2 binary(4) DEFAULT 'abcd12' ,primary key(f2)); -create table t1 (f1 int, f2 binary(4) DEFAULT 'abcd12' ,primary key(f2)); -insert into t1 values (10, '12fe'); -insert into t1 (f1) values (10); -insert into t1 values (11, '245af'); -insert into t1 values (12, '2423fe'); -insert into t1 values (13, '12fe'); -insert into t1 values (-2147483648,'dc23' ); -insert into t1 values (2147483647, '323a34'); -echo select * from t1; -select * from t1; -echo select * from t1 where f2 = '12fe'; -select * from t1 where f2 = '12fe'; -echo select * from t1 where f2 != '323a34' AND f1 = 13; -select * from t1 where f2 != '323a34' AND f1 = 13; -echo select * from t1 where f1 = 12 AND f2 >= '245af'; -select * from t1 where f1 = 12 AND f2 >= '245af'; -echo select * from t1 where f1 = 12 OR f2 > 'dc23'; -select * from t1 where f1 = 12 OR f2 > 'dc23'; -echo select * from t1 where f1 = 12 OR f2 < 'dc23'; -select * from t1 where f1 = 12 OR f2 < 'dc23'; -echo select * from t1 where f1 = 12 OR f2 <> '245af'; -select * from t1 where f1 = 12 OR f2 <> '245af'; -echo select * from t1 where NOT f2 ='12fe'; -select * from t1 where NOT f2 ='12fe'; -echo select * from t1 where f2 != '12fe'; -select * from t1 where f2 != '12fe'; -echo select * from t1 where NOT f2 != '12fe'; -select * from t1 where NOT f2 != '12fe'; -echo select * from t1 where f1 = f2; -select * from t1 where f1 = f2; -echo select * from t1 where f2 in ('245af','12fe'); -select * from t1 where f2 in ('245af','12fe'); -echo select * from t1 where f2 between '00000000' and 'ffffffff'; -select * from t1 where f2 between '00000000' and 'ffffffff'; -echo select * from t1 where f2 between '122' and '12a2'; -select * from t1 where f2 between '122' and '12a2'; - -echo update t1 set f2 = '435f3' where f1 != 13 and f2='323a34' ; -update t1 set f2 ='435f3' where f1 != 13 and f2='323a34'; -select * from t1; - -echo delete from t1 where f2 = '12fe'; -delete from t1 where f2 = '12fe'; -select * from t1; -drop table t1; diff --git a/test/tools/csql/datatype2.sql b/test/tools/csql/datatype2.sql deleted file mode 100644 index 26909daa..00000000 --- a/test/tools/csql/datatype2.sql +++ /dev/null @@ -1,51 +0,0 @@ -echo char datatype testing; - -create table t1 (f1 char(20), f2 char(20), primary key (f1)); -insert into t1 values ('10', 'A'); -insert into t1 values ('11', 'B'); -insert into t1 values ('12', 'C'); -insert into t1 values ('13', 'D'); -insert into t1 values ('14', '14'); -insert into t1 values ('50', 'E'); -insert into t1 values ('This is really a very big string. should get cut when it is stored', 'E'); -insert into t1 values ('UPPERCASE', 'UPPER'); -insert into t1 values ('uppercase', 'LOWER'); -insert into t1 values ('upperletter', 'LOWER'); -insert into t1 values ('uppercaseletter', 'LOWER'); -echo select * from t1; -select * from t1; -echo select * from t1 where f1 = '10'; -select * from t1 where f1 = '10'; -echo select * from t1 where f1 != '12' AND f2 <= '13'; -select * from t1 where f1 != '12' AND f2 <= '13'; -echo select * from t1 where f1 = '12' AND f2 >= '22'; -select * from t1 where f1 = '12' AND f2 >= '22'; -echo select * from t1 where f1 = '12' OR f1 > '13'; -select * from t1 where f1 = '12' OR f1 > '13'; -echo select * from t1 where f1 = '12' OR f2 = '13'; -select * from t1 where f1 = '12' OR f2 < '13'; -echo select * from t1 where f1 = '12' OR f2 < '22'; -select * from t1 where f1 = '12' OR f2 <> '22'; -echo select * from t1 where NOT f1 = '12'; -select * from t1 where NOT f1 = '12'; -echo select * from t1 where f1 != '12'; -select * from t1 where f1 != '12'; -echo select * from t1 where NOT f1 != '12'; -select * from t1 where NOT f1 != '12'; -echo select * from t1 where f1 = f2; -select * from t1 where f1 = f2; - -echo select * from t1 where f2 between 'A' AND 'C'; -select * from t1 where f2 between 'A' AND 'C'; - -echo update t1 set f2 = '2' where f1 != f2; -update t1 set f2 = '2' where f1 != f2; -select * from t1; - -echo update t1 set f2 = '3' where f1 = '50'; -update t1 set f2 = '3' where f1 = '50'; -select * from t1; - -delete from t1 where f1 = '50'; -select * from t1; -drop table t1; diff --git a/test/tools/csql/datatype3.sql b/test/tools/csql/datatype3.sql deleted file mode 100644 index ff8f11eb..00000000 --- a/test/tools/csql/datatype3.sql +++ /dev/null @@ -1,48 +0,0 @@ -echo smallint data type testing; - -create table t1 (f1 smallint, f2 smallint, primary key (f1)); -insert into t1 values (10, 1); -insert into t1 values (11, 1); -insert into t1 values (12, 1); -insert into t1 values (13, 1); -insert into t1 values (-9998, 1); -insert into t1 values (9998, 1); -insert into t1 values (50, 23); -echo select * from t1; -select * from t1; -echo select * from t1 where f1 = 10; -select * from t1 where f1 = 10; -echo select * from t1 where f1 != 12 AND f2 <= 13; -select * from t1 where f1 != 12 AND f2 <= 13; -echo select * from t1 where f1 = 12 AND f2 >= 22; -select * from t1 where f1 = 12 AND f2 >= 22; -echo select * from t1 where f1 = 12 OR f2 < 13; -select * from t1 where f1 = 12 OR f2 < 13; -echo select * from t1 where f1 = 12 OR f2 <> 22; -select * from t1 where f1 = 12 OR f2 <> 22; -echo select * from t1 where NOT f1 = 12; -select * from t1 where NOT f1 = 12; -echo select * from t1 where f1 != 12; -select * from t1 where f1 != 12; -echo select * from t1 where NOT f1 != 12; -select * from t1 where NOT f1 != 12; -echo select * from t1 where f1 = f2; -select * from t1 where f1 = f2; - -echo select * from t1 where f1 between 9997 and 9999; -select * from t1 where f1 between 9997 and 9999; - -echo select * from t1 where f1 between -9999 and -9997; -select * from t1 where f1 between -9999 and -9997; - -echo update t1 set f2 = 2 where f1 != f2; -update t1 set f2 = 2 where f1 != f2; -select * from t1; - -echo update t1 set f2 = 3 where f1 = 50; -update t1 set f2 = 3 where f1 = 50; -select * from t1; - -delete from t1 where f1 = 50; -select * from t1; -drop table t1; diff --git a/test/tools/csql/datatype4.sql b/test/tools/csql/datatype4.sql deleted file mode 100644 index aafb4001..00000000 --- a/test/tools/csql/datatype4.sql +++ /dev/null @@ -1,39 +0,0 @@ -echo bit data type testing; - -create table t1 (f1 bit, f2 bit)); -insert into t1 values (0, 0); -insert into t1 values (1, 1); -insert into t1 values (0, 1); -insert into t1 values (1, 0); -echo select * from t1; -select * from t1; -echo select * from t1 where f1 = 1; -select * from t1 where f1 = 1; -echo select * from t1 where f1 = 1 AND f1 = 1; -select * from t1 where f1 = 1 AND f1 = 1; -echo select * from t1 where f1 != 0 AND f2 != 0 ; -select * from t1 where f1 != 0 AND f2 !=0 -echo select * from t1 where f1 = 12 AND f2 >= 22; -select * from t1 where f1 = 12 AND f2 >= 22; - -echo select * from t1 where NOT f1 = 1; -select * from t1 where NOT f1 = 1; -echo select * from t1 where f1 != 1; -select * from t1 where f1 != 1; -echo select * from t1 where NOT f1 != 1; -select * from t1 where NOT f1 != 1; - -echo select * from t1 where f1 = f2; -select * from t1 where f1 = f2; - -echo update t1 set f2 = 1 where f1 != f2; -update t1 set f2 = 1 where f1 != f2; -select * from t1; - -echo update t1 set f2 = 0 where f1 = 1; -update t1 set f2 = 0 where f1 = 1; -select * from t1; - -delete from t1 where f1 = 1; -select * from t1; -drop table t1; diff --git a/test/tools/csql/datatype5.sql b/test/tools/csql/datatype5.sql deleted file mode 100644 index 448d4200..00000000 --- a/test/tools/csql/datatype5.sql +++ /dev/null @@ -1,36 +0,0 @@ -echo float data type testing; -create table t1 (f1 float, f2 float); -insert into t1 values (0.1048575, 10.234); -insert into t1 values (-0.1048575, 11.234); -insert into t1 values (12.234, 11.456); -insert into t1 values (13.123, 11.987); -insert into t1 values (14.467, 12.123); -insert into t1 values (50.345, 10.234); -insert into t1 values (123.456E3, 10.234); -insert into t1 values (123456E-3, 10.234); -echo select * from t1; -select * from t1; - -echo select * from t1 where f1 BETWEEN 0.104856 AND 0.104858 -select * from t1 where f1 BETWEEN 0.104856 AND 0.104858; - -echo select * from t1 where f1 >122 AND f1 <124; -select * from t1 where f1 >122 AND f1 <124; - -echo select * from t1 where f1 BETWEEN -0.104859 AND -0.104856 -select * from t1 where f1 BETWEEN -0.104859 AND -0.104856; - -echo select * from t1 where f1 BETWEEN -124 AND -122 -select * from t1 where f1 BETWEEN -124 AND -122; - -echo select * from t1 where f2 < f1; -select * from t1 where f2 < f1; - -echo update t1 set f2 = 3.4345 where f2 >11; -update t1 set f2 = 3.4335 where f2>11; -select * from t1; - -echo delete from t1 where f1 > 14.234; -delete from t1 where f1 > 14.234; -select * from t1; -drop table t1; diff --git a/test/tools/csql/datatype6.sql b/test/tools/csql/datatype6.sql deleted file mode 100644 index 6b220a15..00000000 --- a/test/tools/csql/datatype6.sql +++ /dev/null @@ -1,29 +0,0 @@ -echo double data type testing; - -create table t1 (f1 double, f2 double); -insert into t1 values (0.1073741823, 10.234); -insert into t1 values (-0.1073741823, 11.234); -insert into t1 values (12.234, 11.456); -insert into t1 values (13.123, 11.987); -insert into t1 values (14.467, 12.123); -insert into t1 values (50.345, 10.234); -echo select * from t1; -select * from t1; - -echo select * from t1 where f1 BETWEEN 0.1073741822 AND 0.1073741824 -select * from t1 where f1 BETWEEN 0.1073741822 AND 0.1073741824; - -echo select * from t1 where f1 BETWEEN -0.1073741824 AND -0.1073741822 -select * from t1 where f1 BETWEEN -0.1073741824 AND -0.1073741822; - -echo select * from t1 where f2 < f1; -select * from t1 where f2 < f1; - -echo update t1 set f2 = 3.4345 where f2 >11; -update t1 set f2 = 3.4335 where f2>11; -select * from t1; - -echo delete from t1 where f1 > 14.234; -delete from t1 where f1 > 14.234; -select * from t1; -drop table t1; diff --git a/test/tools/csql/datatype7.sql b/test/tools/csql/datatype7.sql deleted file mode 100644 index e907d6f4..00000000 --- a/test/tools/csql/datatype7.sql +++ /dev/null @@ -1,49 +0,0 @@ -echo bigint data type testing; - -create table t1 (f1 bigint, f2 bigint, primary key (f1)); -insert into t1 values (10, 1); -insert into t1 values (11, 1); -insert into t1 values (12, 1); -insert into t1 values (13, 1); -insert into t1 values (-9223372036854775808, 1); -insert into t1 values (9223372036854775807, 1); -echo select * from t1; -select * from t1; -echo select * from t1 where f1 = 10; -select * from t1 where f1 = 10; -echo select * from t1 where f1 != 12 AND f2 <= 13; -select * from t1 where f1 != 12 AND f2 <= 13; -echo select * from t1 where f1 = 12 AND f2 >= 22; -select * from t1 where f1 = 12 AND f2 >= 22; -echo select * from t1 where f1 = 12 OR f1 > 13; -select * from t1 where f1 = 12 OR f1 > 13; -echo select * from t1 where f1 = 12 OR f2 < 13; -select * from t1 where f1 = 12 OR f2 < 13; -echo select * from t1 where f1 = 12 OR f2 <> 22; -select * from t1 where f1 = 12 OR f2 <> 22; -echo select * from t1 where NOT f1 = 12; -select * from t1 where NOT f1 = 12; -echo select * from t1 where f1 != 12; -select * from t1 where f1 != 12; -echo select * from t1 where NOT f1 != 12; -select * from t1 where NOT f1 != 12; -echo select * from t1 where f1 = f2; -select * from t1 where f1 = f2; - -echo select * from t1 where f1 between 999999999997 and 999999999999; -select * from t1 where f1 between 999999999997 and 999999999999; - -echo select * from t1 where f1 between -999999999999 and -999999999997; -select * from t1 where f1 between -999999999999 and -999999999997; - -echo update t1 set f2 = 2 where f1 != f2; -update t1 set f2 = 2 where f1 != f2; -select * from t1; - -echo update t1 set f2 = 3 where f1 = 50; -update t1 set f2 = 3 where f1 = 50; -select * from t1; - -delete from t1 where f1 = 50; -select * from t1; -drop table t1; diff --git a/test/tools/csql/datatype8.sql b/test/tools/csql/datatype8.sql deleted file mode 100644 index 0b85703f..00000000 --- a/test/tools/csql/datatype8.sql +++ /dev/null @@ -1,38 +0,0 @@ -echo LIKE operator char datatype testing; - -create table t1 (f1 char(20), f2 char(20), primary key (f1)); -insert into t1 values ('10', 'A'); -insert into t1 values ('11', 'B'); -insert into t1 values ('12', 'C'); -insert into t1 values ('13', 'D'); -insert into t1 values ('14', '14'); -insert into t1 values ('50', 'E'); -insert into t1 values ('This is really a very big string. should get cut when it is stored', 'E'); -insert into t1 values ('UPPERCASE', 'UPPER'); -insert into t1 values ('uppercase', 'LOWER'); -insert into t1 values ('upperletter', 'LOWER'); -insert into t1 values ('uppercaseletter', 'LOWER'); -echo select * from t1; -select * from t1; - -echo select * from t1 where f1 LIKE 'UPP%'; -select * from t1 where f1 LIKE 'UPP%'; - -echo select * from t1 where f1 LIKE 'upp%'; -select * from t1 where f1 LIKE 'upp%'; - -echo select * from t1 where f1 LIKE 'upper%letter'; -select * from t1 where f1 LIKE 'upp%letter'; - -echo select * from t1 where f1 LIKE 'upper____letter'; -select * from t1 where f1 LIKE 'upper____letter'; - -echo select * from t1 where f1 like 'UP__R%SE'; -select * from t1 where f1 like 'UP__R%SE'; -echo select * from t1 where f1 like 'UP__R%SE' and f2 = 'B'; -select * from t1 where f1 like 'UP__R%SE' and f2 = 'B'; -echo select * from t1 where f1 like 'UP__R%SE' and f2 = 'UPPER'; -select * from t1 where f1 like 'UP__R%SE' and f2 = 'UPPER'; -echo select * from t1 where f1 like 'UP__R%SE' and f2 like 'UPPER'; -select * from t1 where f1 like 'UP__R%SE' and f2 like 'UP%ER'; -drop table t1; diff --git a/test/tools/csql/datatype9.sql b/test/tools/csql/datatype9.sql deleted file mode 100644 index 0ce8f0da..00000000 --- a/test/tools/csql/datatype9.sql +++ /dev/null @@ -1,48 +0,0 @@ -echo tinyint data type testing; - -create table t1 (f1 tinyint, f2 tinyint, primary key (f1)); -insert into t1 values (10, 1); -insert into t1 values (11, 1); -insert into t1 values (12, 1); -insert into t1 values (13, 1); -insert into t1 values (-128, 1); -insert into t1 values (127, 1); -echo select * from t1; -select * from t1; -echo select * from t1 where f1 = 10; -select * from t1 where f1 = 10; -echo select * from t1 where f1 != 12 AND f2 <= 13; -select * from t1 where f1 != 12 AND f2 <= 13; -echo select * from t1 where f1 = 12 AND f2 >= 22; -select * from t1 where f1 = 12 AND f2 >= 22; -echo select * from t1 where f1 = 12 OR f1 > 13; -select * from t1 where f1 = 12 OR f1 > 13; -echo select * from t1 where f1 = 12 OR f2 < 13; -select * from t1 where f1 = 12 OR f2 < 13; -echo select * from t1 where f1 = 12 OR f2 <> 22; -select * from t1 where f1 = 12 OR f2 <> 22; -echo select * from t1 where NOT f1 = 12; -select * from t1 where NOT f1 = 12; -echo select * from t1 where f1 != 12; -select * from t1 where f1 != 12; -echo select * from t1 where NOT f1 != 12; -select * from t1 where NOT f1 != 12; -echo select * from t1 where f1 = f2; -select * from t1 where f1 = f2; - -echo select * from t1 where f1 between 126 and 127; -select * from t1 where f1 between 126 and 127; -echo select * from t1 where f1 between -127 and -128; -select * from t1 where f1 between -127 and -128; - -echo update t1 set f2 = 2 where f1 != f2; -update t1 set f2 = 2 where f1 != f2; -select * from t1; - -echo update t1 set f2 = 3 where f1 = 12; -update t1 set f2 = 3 where f1 = 12; -select * from t1; - -delete from t1 where f1 = 12; -select * from t1; -drop table t1; diff --git a/test/tools/csql/dbobjname.sql b/test/tools/csql/dbobjname.sql deleted file mode 100644 index 0a062197..00000000 --- a/test/tools/csql/dbobjname.sql +++ /dev/null @@ -1,39 +0,0 @@ -echo create table t-1(f1 int,f2 int); -create table t-1(f1 int,f2 int); -echo create table t!1(f1 int,f2 int); -create table t!1(f1 int,f2 int); -echo create table t@1(f1 int,f2 int); -create table t@1(f1 int,f2 int); -echo create table t#1(f1 int,f2 int); -create table t#1(f1 int,f2 int); -echo create table t$1(f1 int,f2 int); -create table t$1(f1 int,f2 int); -echo create table t%1(f1 int,f2 int); -create table t%1(f1 int,f2 int); -echo create table t^1(f1 int,f2 int); -create table t^1(f1 int,f2 int); -echo create table t*1(f1 int,f2 int); -create table t*1(f1 int,f2 int); -echo create table t+1(f1 int,f2 int); -create table t+1(f1 int,f2 int); -echo create table t/1(f1 int,f2 int); -create table t/1(f1 int,f2 int); -echo create table t~1(f1 int,f2 int); -create table t~1(f1 int,f2 int); -echo create table t`1(f1 int,f2 int); -create table t`1(f1 int,f2 int); -echo create table t[]1(f1 int,f2 int); -create table t[]1(f1 int,f2 int); -echo create table _t1(f1 int,f2 int); -create table _t1(f1 int,f2 int); -echo create table t1(f-1 int); -create table t1(f-1 int,f2 int); -echo create table t1(f-1 int,f2 int); -create table t1(f-1 int,f2 int); -echo create table t1(f1 int,f-2 int); -create table t1(f1 int,f-2 int); -echo create table t_0_(f1_ int,f_2 int,f0_ int); -create table t_0_(f1_ int,f_2 int,f0_ int); - - - diff --git a/test/tools/csql/ddl.sql b/test/tools/csql/ddl.sql deleted file mode 100644 index dda5723f..00000000 --- a/test/tools/csql/ddl.sql +++ /dev/null @@ -1,8 +0,0 @@ - -create table t1 (f1 int, f2 int); -insert into t1 values (10, 20); -insert into t1 (f1, f2) values (11, 21); -insert into t1 (f2, f1) values (22, 12); -insert into t1 (f1) values (13); -insert into t1 (f2) values (24); -select * from t1; diff --git a/test/tools/csql/diffintindex.sql b/test/tools/csql/diffintindex.sql deleted file mode 100644 index 638e4497..00000000 --- a/test/tools/csql/diffintindex.sql +++ /dev/null @@ -1,409 +0,0 @@ -echo "-----Table having two fields f1 bigint,f2 integer and index on t1(f1)-----"; -echo create table t1(f1 bigint,f2 integer); -create table t1(f1 bigint,f2 integer); -echo create index idx1 on t1(f1); -create index idx1 on t1(f1); -echo insert into t1 values(10,2147483647); -insert into t1 values(10,2147483647); -echo insert into t1 values(21,-2147483648); -insert into t1 values(21,-2147483648); -echo insert into t1 values(32,1000000000); -insert into t1 values(32,1000000000); -echo insert into t1 values(123,999999999); -insert into t1 values(123,999999999); -echo insert into t1 values(-2147483648,0); -insert into t1 values(-2147483648,0); -echo insert into t1 values(2147483647,-2147483648); -insert into t1 values(2147483647,-2147483648); -echo insert into t1 values(123,9); -insert into t1 values(123,9); -echo select * from t1; -select * from t1; -echo select * from t1 where f1>-5; -select * from t1 where f1>-5; -echo select * from t1 where f1<-10; -select * from t1 where f1<-10; -echo select f1 from t1 where f1 in (10,30,123); -select f1 from t1 where f1 in (10,30,123); -echo select * from t1; -select * from t1; -echo select * from t1 where f1 between 25 and 6000000; -select * from t1 where f1 between 25 and 6000000; -echo select * from t1 where f1 between 6000000 and 25; -select * from t1 where f1 between 6000000 and 25; -echo update t1 set f1=25 where f1=21; -update t1 set f1=25 where f1=21; -echo select * from t1; -select * from t1; -echo update t1 set f1=21 where f1=25 and f2=-2147483648; -update t1 set f1=21 where f1=25 and f2=-2147483648; -echo select * from t1; -select * from t1; -echo update t1 set f1=1010101 where f1 in(32,10,40); -update t1 set f1=1010101 where f1 in(32,10,40); -echo select * from t1; -select * from t1; -echo update t1 set f1=7777 where f1=1010101 and f2 in(1000000000,999999999); -update t1 set f1=7777 where f1=1010101 and f2 in(1000000000,999999999); -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f2 in(1000000000,999999999) and f1>=7777; -update t1 set f1=2020202 where f2 in(1000000000,999999999) and f1>=7777; -echo select * from t1; -select * from t1; -echo update t1 set f1=987654 where f1 between 25 and 200; -update t1 set f1=987654 where f1 between 25 and 200; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=2020202; -delete from t1 where f1=2020202; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 between 25 and 6000000; -delete from t1 where f1 between 25 and 6000000; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo "--Table having 5 fields f1,f2,f3,f4,f5(Different int) index on t1(f1,f2)--"; -echo create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -echo create index idx1 on t1(f1,f2); -create index idx1 on t1(f1,f2); -echo insert into t1 values(11,222,3333,44444,555555); -insert into t1 values(11,222,3333,44444,555555); -echo insert into t1 values(12,123,1234,12345,123456); -insert into t1 values(12,123,1234,12345,123456); -echo insert into t1 values(234,4567,56789,1234,4321); -insert into t1 values(234,4567,56789,1234,4321); -echo insert into t1 values(-2147483648,1,101,212,2147483647); -insert into t1 values(-2147483648,1,101,212,2147483647); -echo insert into t1 values(101,12121,0,32123,78987); -insert into t1 values(101,12121,0,32123,78987); -echo insert into t1 values(12,123,1000,1111,1); -insert into t1 values(12,123,1000,1111,1); -echo select * from t1; -select * from t1; -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -echo select * from t1 where f1<-1 and f2>=1 or f3=101; -select * from t1 where f1<-1 and f2>=1 or f3=101; -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; -select * from t1 where f1<-1 and f2>=1 or f3=1234; -echo select * from t1; -select * from t1; -echo select * from t1 where f1 between 25 and 6000000; -select * from t1 where f1 between 25 and 6000000; -echo select * from t1 where f1 between 6000000 and 25; -select * from t1 where f1 between 6000000 and 25; -echo update t1 set f1=22 where f1=11; -update t1 set f1=22 where f1=11; -echo select * from t1; -select * from t1; -echo update t1 set f1=11 where f1=22 and f2=222; -update t1 set f1=11 where f1=22 and f2=222; -echo select * from t1; -select * from t1; -echo update t1 set f1=10 where f1 in(234,10); -update t1 set f1=10 where f1 in(234,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=100 where f1 in(12,10); -update t1 set f2=100 where f1 in(12,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=101,f2=12121 where f3=0; -update t1 set f2=101,f2=12121 where f3=0; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -echo select * from t1; -select * from t1; -echo update t1 set f1=987654 where f1 between 25 and 200; -update t1 set f1=987654 where f1 between 25 and 200; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=2020202 and f5=2147483647; -delete from t1 where f1=2020202 and f5=2147483647; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 between 25 and 6000000; -delete from t1 where f1 between 25 and 6000000; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo "--Table having 5 fields f1,f2,f3,f4,f5(Different int) index on t1(f1,f3)--"; -echo create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -echo create index idx1 on t1(f1,f3); -create index idx1 on t1(f1,f3); -echo insert into t1 values(11,222,3333,44444,555555); -insert into t1 values(11,222,3333,44444,555555); -echo insert into t1 values(12,123,1234,12345,123456); -insert into t1 values(12,123,1234,12345,123456); -echo insert into t1 values(234,4567,56789,1234,4321); -insert into t1 values(234,4567,56789,1234,4321); -echo insert into t1 values(-2147483648,1,101,212,2147483647); -insert into t1 values(-2147483648,1,101,212,2147483647); -echo insert into t1 values(101,12121,0,32123,78987); -insert into t1 values(101,12121,0,32123,78987); -echo insert into t1 values(12,100,1234,1111,1); -insert into t1 values(12,100,1234,1111,1); -echo select * from t1; -select * from t1; -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -echo select * from t1 where f1<-1 and f2>=1 or f3=101; -select * from t1 where f1<-1 and f2>=1 or f3=101; -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; -select * from t1 where f1<-1 and f2>=1 or f3=1234; -echo select * from t1; -select * from t1; -echo select * from t1 where f1 between 25 and 6000000; -select * from t1 where f1 between 25 and 6000000; -echo select * from t1 where f1 between 6000000 and 25; -select * from t1 where f1 between 6000000 and 25; -echo update t1 set f1=22 where f1=11; -update t1 set f1=22 where f1=11; -echo select * from t1; -select * from t1; -echo update t1 set f1=11 where f1=22 and f2=222; -update t1 set f1=11 where f1=22 and f2=222; -echo select * from t1; -select * from t1; -echo update t1 set f1=10 where f1 in(234,10); -update t1 set f1=10 where f1 in(234,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=100 where f1 in(12,10); -update t1 set f2=100 where f1 in(12,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=101,f2=12121 where f3=0; -update t1 set f2=101,f2=12121 where f3=0; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -echo select * from t1; -select * from t1; -echo update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=-2147483648 or f3=1234; -delete from t1 where f1=-2147483648 or f3=1234; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 between 25 and 6000000; -delete from t1 where f1 between 25 and 6000000; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - - -echo "--Table having 5 fields f1,f2,f3,f4,f5(Different int) index on t1(f1,f3,f2)--"; -echo create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -echo create index idx1 on t1(f1,f3,f2); -create index idx1 on t1(f1,f3,f2); -echo insert into t1 values(11,222,3333,44444,555555); -insert into t1 values(11,222,3333,44444,555555); -echo insert into t1 values(12,123,1234,12345,123456); -insert into t1 values(12,123,1234,12345,123456); -echo insert into t1 values(234,4567,56789,1234,4321); -insert into t1 values(234,4567,56789,1234,4321); -echo insert into t1 values(-2147483648,1,101,212,2147483647); -insert into t1 values(-2147483648,1,101,212,2147483647); -echo insert into t1 values(101,12121,0,32123,78987); -insert into t1 values(101,12121,0,32123,78987); -echo insert into t1 values(12,123,1234,1111,1); -insert into t1 values(12,123,1234,1111,1); -echo select * from t1; -select * from t1; -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -echo select * from t1 where f1<-1 and f2>=1 or f3=101; -select * from t1 where f1<-1 and f2>=1 or f3=101; -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; -select * from t1 where f1<-1 and f2>=1 or f3=1234; -echo select * from t1; -select * from t1; -echo select * from t1 where f1 between 25 and 6000000; -select * from t1 where f1 between 25 and 6000000; -echo select * from t1 where f1 between 6000000 and 25; -select * from t1 where f1 between 6000000 and 25; -echo update t1 set f1=22 where f1=11; -update t1 set f1=22 where f1=11; -echo select * from t1; -select * from t1; -echo update t1 set f1=11 where f1=22 and f2=222; -update t1 set f1=11 where f1=22 and f2=222; -echo select * from t1; -select * from t1; -echo update t1 set f1=10 where f1 in(234,10); -update t1 set f1=10 where f1 in(234,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=100 where f1 in(12,10); -update t1 set f2=100 where f1 in(12,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=101,f2=12121 where f3=0; -update t1 set f2=101,f2=12121 where f3=0; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=5 and f3=101; -update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=5 and f3=101; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -echo select * from t1; -select * from t1; -echo update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=-2147483648 or f3=1234; -delete from t1 where f1=-2147483648 or f3=1234; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 between 25 and 6000000; -delete from t1 where f1 between 25 and 6000000; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo "--Table having 5 fields f1,f2,f3,f4,f5(Different int) index on t1(f5,f1,f3,f2)--"; -echo create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -echo create index idx1 on t1(f5,f1,f3,f2); -create index idx1 on t1(f5,f1,f3,f2); -echo insert into t1 values(11,222,3333,44444,555555); -insert into t1 values(11,222,3333,44444,555555); -echo insert into t1 values(12,123,1234,12345,123456); -insert into t1 values(12,123,1234,12345,123456); -echo insert into t1 values(234,4567,56789,1234,4321); -insert into t1 values(234,4567,56789,1234,4321); -echo insert into t1 values(-2147483648,1,101,212,2147483647); -insert into t1 values(-2147483648,1,101,212,2147483647); -echo insert into t1 values(101,12121,0,32123,78987); -insert into t1 values(101,12121,0,32123,78987); -echo insert into t1 values(12,123,1234,1111,1); -insert into t1 values(12,123,1234,1111,1); -echo select * from t1; -select * from t1; -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -echo select * from t1 where f1<-1 and f2>=1 or f3=101; -select * from t1 where f1<-1 and f2>=1 or f3=101; -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; -select * from t1 where f1<-1 and f2>=1 or f3=1234; -echo select * from t1; -select * from t1; -echo select * from t1 where f1 between 25 and 6000000; -select * from t1 where f1 between 25 and 6000000; -echo select * from t1 where f1 between 6000000 and 25; -select * from t1 where f1 between 6000000 and 25; -echo update t1 set f1=22 where f1=11; -update t1 set f1=22 where f1=11; -echo select * from t1; -select * from t1; -echo update t1 set f1=11 where f1=22 and f2=222; -update t1 set f1=11 where f1=22 and f2=222; -echo select * from t1; -select * from t1; -echo update t1 set f1=10 where f1 in(234,10); -update t1 set f1=10 where f1 in(234,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=100 where f1 in(12,10); -update t1 set f2=100 where f1 in(12,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=5 and f3=101; -update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=5 and f3=101; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=-2147483648 or f3=1234; -delete from t1 where f1=-2147483648 or f3=1234; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 between 25 and 6000000; -delete from t1 where f1 between 25 and 6000000; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - diff --git a/test/tools/csql/drop.sql b/test/tools/csql/drop.sql deleted file mode 100644 index 853c1ad6..00000000 --- a/test/tools/csql/drop.sql +++ /dev/null @@ -1 +0,0 @@ -drop table t1; diff --git a/test/tools/csql/drop1.sql b/test/tools/csql/drop1.sql deleted file mode 100644 index 523719f4..00000000 --- a/test/tools/csql/drop1.sql +++ /dev/null @@ -1,9 +0,0 @@ -echo drop table t1; -echo drop table t2; -echo drop table t3; -drop table t1; -drop table t2; -drop table t3; -echo drop table t4; -drop table t4; - diff --git a/test/tools/csql/drop2.sql b/test/tools/csql/drop2.sql deleted file mode 100644 index f28777b3..00000000 --- a/test/tools/csql/drop2.sql +++ /dev/null @@ -1,2 +0,0 @@ -echo drop table t2; -drop table t2; diff --git a/test/tools/csql/exp.test001.ksh b/test/tools/csql/exp.test001.ksh deleted file mode 100644 index c9828a4c..00000000 --- a/test/tools/csql/exp.test001.ksh +++ /dev/null @@ -1,17 +0,0 @@ -Case 1: With no option: -CSQL>Case 2: With ? option: -Usage: csql [ [-u username] [-p passwd] ] [ [-H hostname] [-P port] ] - [-s sqlfile] - username -> username to connect to database - password -> password to connect to database - hostname -> hostname to connect to database through network - port -> port no - sqlfile -> filename containing sql statements -Case 3: With wrong username and wrong password : -failed -Case 4: With wrong username : -Failed -Case 5: With wrong password : -failed -Case 6: With correct user name and password : -CSQL>passed diff --git a/test/tools/csql/exp.test002.ksh b/test/tools/csql/exp.test002.ksh deleted file mode 100644 index fa54d8f0..00000000 --- a/test/tools/csql/exp.test002.ksh +++ /dev/null @@ -1,51 +0,0 @@ -echo create table and constraints with integer fields; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 11 21 - 12 22 - 13 NULL - NULL 24 - -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement execute failed with error -22 ---------------------------------------------------------- - t2.f1 t2.f2 ---------------------------------------------------------- - 10 20 - 11 21 - 12 22 - 13 NULL - -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement execute failed with error -22 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement prepare failed with error -19 ---------------------------------------------------------- - t3.f1 t3.f2 ---------------------------------------------------------- - 10 NULL - 11 21 - 12 22 - 13 NULL - 100 NULL - -Statement Executed -Statement Executed -Statement Executed diff --git a/test/tools/csql/exp.test003.ksh b/test/tools/csql/exp.test003.ksh deleted file mode 100644 index f208609e..00000000 --- a/test/tools/csql/exp.test003.ksh +++ /dev/null @@ -1,71 +0,0 @@ -echo UPDATE and DELETE testing; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 11 21 - 12 22 - 13 23 - 14 24 - 50 50 - -echo select * from t1 where f1 = 100; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 50 50 - -echo update t1 set f2 = 100; -Statement Executed: Rows Affected = 6 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 100 - 11 100 - 12 100 - 13 100 - 14 100 - 50 100 - -echo update t1 set f2 = 200 where f1 =50; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 100 - 11 100 - 12 100 - 13 100 - 14 100 - 50 200 - -echo delete from t1 where f1 = 50; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 100 - 11 100 - 12 100 - 13 100 - 14 100 - -echo delete from t1; -Statement Executed: Rows Affected = 5 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -Statement Executed diff --git a/test/tools/csql/exp.test004.ksh b/test/tools/csql/exp.test004.ksh deleted file mode 100644 index d3bbafa5..00000000 --- a/test/tools/csql/exp.test004.ksh +++ /dev/null @@ -1,157 +0,0 @@ -echo Same as csql2 but with primary key; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 11 21 - 12 22 - 13 23 - 14 24 - 50 50 - -echo select * from t1 where f1 = 100; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 = 10; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - -echo select f1 from t1 where f1 = 11; ---------------------------------------------------------- - f1 ---------------------------------------------------------- - 11 - -echo select f2 from t1 where f1 = 11; ---------------------------------------------------------- - f2 ---------------------------------------------------------- - 21 - -echo select f1, f2 from t1 where f1 = 12; ---------------------------------------------------------- - f1 f2 ---------------------------------------------------------- - 12 22 - -echo select * from t1 where f1 != 12 AND f2 <= 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 = 12 AND f2 >= 22; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 22 - -echo select * from t1 where f1 = 12 OR f1 > 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 22 - 14 24 - 50 50 - -echo select * from t1 where f1 = 12 OR f2 < 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 22 - -echo select * from t1 where f1 = 12 OR f2 <> 22; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 11 21 - 12 22 - 13 23 - 14 24 - 50 50 - -echo select * from t1 where NOT f1 = 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 11 21 - 13 23 - 14 24 - 50 50 - -echo select * from t1 where f1 != 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 11 21 - 13 23 - 14 24 - 50 50 - -echo select * from t1 where NOT f1 != 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 22 - -echo select * from t1 where NOT (f1 = 12 AND f2 =22); ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 11 21 - 13 23 - 14 24 - 50 50 - -echo select * from t1 where NOT (f1 = 12 OR f2 = 23); ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 20 - 11 21 - 14 24 - 50 50 - -echo select * from t1 where f1 = 12 OR f2 = 23 OR f2 = 22; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 22 - 13 23 - -echo select * from t1 where f1+12 = 20; -Statement prepare failed with error -19 -echo select * from t1 where f1 = 12 + f2; -Statement prepare failed with error -19 -echo select * from t1 where f1 = f2; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 50 50 - -echo select * from t1 where f1=12 and f1<=13 or f1>=11; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 11 21 - 12 22 - 13 23 - 14 24 - 50 50 - -Statement Executed diff --git a/test/tools/csql/exp.test005.ksh b/test/tools/csql/exp.test005.ksh deleted file mode 100644 index 59dc5e4f..00000000 --- a/test/tools/csql/exp.test005.ksh +++ /dev/null @@ -1,11 +0,0 @@ -echo all data type create, insert, select test; -echo create table t1 (f1 char(10), f2 tinyint, f3 smallint,f4 int, f5 bigint,f6 integer, f7 float, f8 real,f9 double,f10 long,f11 binary(128),f12 date,f13 time,f14 timestamp); -Statement Executed -echo insert into t1 values('NIHAR', 1,1,-2147483648,9223372036854775807, 2147483648,1.1, 1000000000.000000,10000001.10000001,99999,'ABCDEF0123456789','2001-1-1', '01:01:01', '2001-11-30 01:01:01'); -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 t1.f6 t1.f7 t1.f8 t1.f9 t1.f10 t1.f11 t1.f12 t1.f13 t1.f14 ---------------------------------------------------------- - NIHAR 1 1 -2147483648 9223372036854775807 2147483647 1.100000 1000000000.000000 10000001.100000 99999 ABCDEF0123456789 2001/1/1 1:1:1.0 2001/11/30 1:1:1.0 - -Statement Executed diff --git a/test/tools/csql/exp.test006.ksh b/test/tools/csql/exp.test006.ksh deleted file mode 100644 index 67690874..00000000 --- a/test/tools/csql/exp.test006.ksh +++ /dev/null @@ -1,5 +0,0 @@ -echo drop table test; -Statement Executed -Statement Executed -Statement Executed -Statement Executed diff --git a/test/tools/csql/exp.test007.ksh b/test/tools/csql/exp.test007.ksh deleted file mode 100644 index c48898b7..00000000 --- a/test/tools/csql/exp.test007.ksh +++ /dev/null @@ -1,9 +0,0 @@ -echo create index test; -Statement Executed -Statement Executed -Statement Executed -Statement Executed -Statement Executed -Statement Executed -Statement Executed -Statement Executed diff --git a/test/tools/csql/exp.test008.ksh b/test/tools/csql/exp.test008.ksh deleted file mode 100644 index 3cf2bc91..00000000 --- a/test/tools/csql/exp.test008.ksh +++ /dev/null @@ -1,7 +0,0 @@ -echo Descr:drop index test; -Statement Executed -Statement Executed -Statement Executed -Statement Executed -Statement Executed -Statement Executed diff --git a/test/tools/csql/exp.test009.ksh b/test/tools/csql/exp.test009.ksh deleted file mode 100644 index 04eeda77..00000000 --- a/test/tools/csql/exp.test009.ksh +++ /dev/null @@ -1,21 +0,0 @@ -echo Description:count(*) test; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - COUNT(*) ---------------------------------------------------------- - 6 - -echo select * from t1 where f1 =11; ---------------------------------------------------------- - COUNT(*) ---------------------------------------------------------- - 1 - -Statement Executed diff --git a/test/tools/csql/exp.test010.ksh b/test/tools/csql/exp.test010.ksh deleted file mode 100644 index 1d16ed7e..00000000 --- a/test/tools/csql/exp.test010.ksh +++ /dev/null @@ -1,72 +0,0 @@ -echo Description:BETWEEN and IN test; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1 where f1 between 12 and 14; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 12 22 12 - 13 23 13 - 14 24 14 - -echo select * from t1 where f1 not between 12 and 14; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 20 10 - 11 21 11 - 50 50 50 - -echo select * from t1 where f3 between 12 and 14; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 12 22 12 - 13 23 13 - 14 24 14 - -echo select * from t1 where f1 IN (12, 14, 50); ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 12 22 12 - 14 24 14 - 50 50 50 - -echo select * from t1 where f1 IN (12, 14, 50) AND f3 IN (50); ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 12 22 12 - 14 24 14 - 50 50 50 - -echo select * from t1 where f1 IN (12, 14, 50) OR f3 IN (50); ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 12 22 12 - 14 24 14 - 50 50 50 - -echo select * from t1 where f1 IN (12, 14, 50) AND f3 between 12 and 14; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 12 22 12 - 14 24 14 - -echo select * from t1 where f1 NOT IN (12, 14, 50); ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 20 10 - 11 21 11 - 13 23 13 - -Statement Executed diff --git a/test/tools/csql/exp.test011.ksh b/test/tools/csql/exp.test011.ksh deleted file mode 100644 index 45c9ee09..00000000 --- a/test/tools/csql/exp.test011.ksh +++ /dev/null @@ -1,10 +0,0 @@ -echo all data type create, insert, select test; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement execute failed with error -22 ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 t1.f6 t1.f7 t1.f8 t1.f9 t1.f10 t1.f11 ---------------------------------------------------------- - 1 1 NIHAR 1.100000 10000001.100000 2001/1/1 1:1:1.0 2001/11/30 1:1:1.0 1 10000000 ABCD56789 - -Statement Executed diff --git a/test/tools/csql/exp.test012.ksh b/test/tools/csql/exp.test012.ksh deleted file mode 100644 index 63a8846f..00000000 --- a/test/tools/csql/exp.test012.ksh +++ /dev/null @@ -1,49 +0,0 @@ -echo create table t1 (f1 int,f2 date); -Statement Executed -echo insert into t1 values(1,'2008-10-29'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,'28-12-2008'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,'2008-2-30'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(4,'2008-3- -20'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(5,NULL); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(6,'2007-05-05'); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 2008/10/29 - 2 0/0/0 - 3 0/0/0 - 4 0/0/0 - 5 NULL - 6 2007/5/5 - -echo select * from t1 where f2<='2007-05-05'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 2 0/0/0 - 3 0/0/0 - 4 0/0/0 - 6 2007/5/5 - -echo select * from t1 where f2>='2007-05-05'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 2008/10/29 - 6 2007/5/5 - -echo select * from t1 where f2='2007-05-05'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 6 2007/5/5 - -echo drop table t1; -Statement Executed diff --git a/test/tools/csql/exp.test021.ksh b/test/tools/csql/exp.test021.ksh deleted file mode 100644 index e8a98c47..00000000 --- a/test/tools/csql/exp.test021.ksh +++ /dev/null @@ -1,146 +0,0 @@ -echo int data type testing; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -2147483648 1 - 2147483647 1 - -echo select * from t1 where f1 = 10; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - -echo select * from t1 where f1 != 12 AND f2 <= 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -2147483648 1 - 2147483647 1 - -echo select * from t1 where f1 = 12 AND f2 >= 22; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 = 12 OR f1 > 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 1 - 2147483647 1 - -echo select * from t1 where f1 = 12 OR f2 < 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -2147483648 1 - 2147483647 1 - -echo select * from t1 where f1 = 12 OR f2 <> 22; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -2147483648 1 - 2147483647 1 - -echo select * from t1 where NOT f1 = 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -2147483648 1 - 2147483647 1 - -echo select * from t1 where f1 != 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -2147483648 1 - 2147483647 1 - -echo select * from t1 where NOT f1 != 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 1 - -echo select * from t1 where f1 = f2; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 between 2147483646 and 2147483647; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 2147483647 1 - -echo select * from t1 where f1 between -2147483647 and -2147483648; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo update t1 set f2 = 2 where f1 != f2; -Statement Executed: Rows Affected = 6 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 2 - 13 2 - -2147483648 2 - 2147483647 2 - -echo update t1 set f2 = 3 where f1 = 12; -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 3 - 13 2 - -2147483648 2 - 2147483647 2 - -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 13 2 - -2147483648 2 - 2147483647 2 - -Statement Executed diff --git a/test/tools/csql/exp.test022.ksh b/test/tools/csql/exp.test022.ksh deleted file mode 100644 index 611a5aa7..00000000 --- a/test/tools/csql/exp.test022.ksh +++ /dev/null @@ -1,181 +0,0 @@ -echo char datatype testing; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 A - 11 B - 12 C - 13 D - 14 14 - 50 E - This is really a very b E - UPPERCASE UPPER - uppercase LOWER - upperletter LOWER - uppercaseletter LOWER - -echo select * from t1 where f1 = '10'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 A - -echo select * from t1 where f1 != '12' AND f2 <= '13'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 = '12' AND f2 >= '22'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 C - -echo select * from t1 where f1 = '12' OR f1 > '13'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 C - 14 14 - 50 E - This is really a very b E - UPPERCASE UPPER - uppercase LOWER - upperletter LOWER - uppercaseletter LOWER - -echo select * from t1 where f1 = '12' OR f2 = '13'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 C - -echo select * from t1 where f1 = '12' OR f2 < '22'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 A - 11 B - 12 C - 13 D - 14 14 - 50 E - This is really a very b E - UPPERCASE UPPER - uppercase LOWER - upperletter LOWER - uppercaseletter LOWER - -echo select * from t1 where NOT f1 = '12'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 A - 11 B - 13 D - 14 14 - 50 E - This is really a very b E - UPPERCASE UPPER - uppercase LOWER - upperletter LOWER - uppercaseletter LOWER - -echo select * from t1 where f1 != '12'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 A - 11 B - 13 D - 14 14 - 50 E - This is really a very b E - UPPERCASE UPPER - uppercase LOWER - upperletter LOWER - uppercaseletter LOWER - -echo select * from t1 where NOT f1 != '12'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 C - -echo select * from t1 where f1 = f2; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 14 14 - -echo select * from t1 where f2 between 'A' AND 'C'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 A - 11 B - 12 C - -echo update t1 set f2 = '2' where f1 != f2; -Statement Executed: Rows Affected = 10 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 2 - 13 2 - 14 14 - 50 2 - This is really a very b 2 - UPPERCASE 2 - uppercase 2 - upperletter 2 - uppercaseletter 2 - -echo update t1 set f2 = '3' where f1 = '50'; -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 2 - 13 2 - 14 14 - 50 3 - This is really a very b 2 - UPPERCASE 2 - uppercase 2 - upperletter 2 - uppercaseletter 2 - -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 2 - 13 2 - 14 14 - This is really a very b 2 - UPPERCASE 2 - uppercase 2 - upperletter 2 - uppercaseletter 2 - -Statement Executed diff --git a/test/tools/csql/exp.test023.ksh b/test/tools/csql/exp.test023.ksh deleted file mode 100644 index 1aba3f7d..00000000 --- a/test/tools/csql/exp.test023.ksh +++ /dev/null @@ -1,148 +0,0 @@ -echo smallint data type testing; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -9998 1 - 9998 1 - 50 23 - -echo select * from t1 where f1 = 10; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - -echo select * from t1 where f1 != 12 AND f2 <= 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -9998 1 - 9998 1 - -echo select * from t1 where f1 = 12 AND f2 >= 22; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 = 12 OR f2 < 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -9998 1 - 9998 1 - -echo select * from t1 where f1 = 12 OR f2 <> 22; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -9998 1 - 9998 1 - 50 23 - -echo select * from t1 where NOT f1 = 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -9998 1 - 9998 1 - 50 23 - -echo select * from t1 where f1 != 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -9998 1 - 9998 1 - 50 23 - -echo select * from t1 where NOT f1 != 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 1 - -echo select * from t1 where f1 = f2; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 between 9997 and 9999; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 9998 1 - -echo select * from t1 where f1 between -9999 and -9997; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -9998 1 - -echo update t1 set f2 = 2 where f1 != f2; -Statement Executed: Rows Affected = 7 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 2 - 13 2 - -9998 2 - 9998 2 - 50 2 - -echo update t1 set f2 = 3 where f1 = 50; -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 2 - 13 2 - -9998 2 - 9998 2 - 50 3 - -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 2 - 13 2 - -9998 2 - 9998 2 - -Statement Executed diff --git a/test/tools/csql/exp.test024.ksh b/test/tools/csql/exp.test024.ksh deleted file mode 100644 index be8247eb..00000000 --- a/test/tools/csql/exp.test024.ksh +++ /dev/null @@ -1,2 +0,0 @@ -echo bit data type testing; -test failing diff --git a/test/tools/csql/exp.test025.ksh b/test/tools/csql/exp.test025.ksh deleted file mode 100644 index 52b4c1c8..00000000 --- a/test/tools/csql/exp.test025.ksh +++ /dev/null @@ -1,71 +0,0 @@ -echo float data type testing; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 0.104857 10.234000 - -0.104857 11.234000 - 12.234000 11.456000 - 13.123000 11.987000 - 14.467000 12.123000 - 50.345001 10.234000 - 123456.000000 10.234000 - 123.456001 10.234000 - -echo select * from t1 where f1 BETWEEN 0.104856 AND 0.104858 -select * from t1 where f1 BETWEEN 0.104856 AND 0.104858; -echo select * from t1 where f1 >122 AND f1 <124; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 123.456001 10.234000 - -echo select * from t1 where f1 BETWEEN -0.104859 AND -0.104856 -select * from t1 where f1 BETWEEN -0.104859 AND -0.104856; -echo select * from t1 where f1 BETWEEN -124 AND -122 -select * from t1 where f1 BETWEEN -124 AND -122; -echo select * from t1 where f2 < f1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12.234000 11.456000 - 13.123000 11.987000 - 14.467000 12.123000 - 50.345001 10.234000 - 123456.000000 10.234000 - 123.456001 10.234000 - -echo update t1 set f2 = 3.4345 where f2 >11; -Statement Executed: Rows Affected = 4 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 0.104857 10.234000 - -0.104857 3.433500 - 12.234000 3.433500 - 13.123000 3.433500 - 14.467000 3.433500 - 50.345001 10.234000 - 123456.000000 10.234000 - 123.456001 10.234000 - -echo delete from t1 where f1 > 14.234; -Statement Executed: Rows Affected = 4 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 0.104857 10.234000 - -0.104857 3.433500 - 12.234000 3.433500 - 13.123000 3.433500 - -Statement Executed diff --git a/test/tools/csql/exp.test026.ksh b/test/tools/csql/exp.test026.ksh deleted file mode 100644 index be073817..00000000 --- a/test/tools/csql/exp.test026.ksh +++ /dev/null @@ -1,55 +0,0 @@ -echo double data type testing; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 0.107374 10.234000 - -0.107374 11.234000 - 12.234000 11.456000 - 13.123000 11.987000 - 14.467000 12.123000 - 50.345000 10.234000 - -echo select * from t1 where f1 BETWEEN 0.1073741822 AND 0.1073741824 -select * from t1 where f1 BETWEEN 0.1073741822 AND 0.1073741824; -echo select * from t1 where f1 BETWEEN -0.1073741824 AND -0.1073741822 -select * from t1 where f1 BETWEEN -0.1073741824 AND -0.1073741822; -echo select * from t1 where f2 < f1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12.234000 11.456000 - 13.123000 11.987000 - 14.467000 12.123000 - 50.345000 10.234000 - -echo update t1 set f2 = 3.4345 where f2 >11; -Statement Executed: Rows Affected = 4 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 0.107374 10.234000 - -0.107374 3.433500 - 12.234000 3.433500 - 13.123000 3.433500 - 14.467000 3.433500 - 50.345000 10.234000 - -echo delete from t1 where f1 > 14.234; -Statement Executed: Rows Affected = 2 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 0.107374 10.234000 - -0.107374 3.433500 - 12.234000 3.433500 - 13.123000 3.433500 - -Statement Executed diff --git a/test/tools/csql/exp.test027.ksh b/test/tools/csql/exp.test027.ksh deleted file mode 100644 index fb119ad1..00000000 --- a/test/tools/csql/exp.test027.ksh +++ /dev/null @@ -1,146 +0,0 @@ -echo bigint data type testing; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -9223372036854775808 1 - 9223372036854775807 1 - -echo select * from t1 where f1 = 10; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - -echo select * from t1 where f1 != 12 AND f2 <= 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -9223372036854775808 1 - 9223372036854775807 1 - -echo select * from t1 where f1 = 12 AND f2 >= 22; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 = 12 OR f1 > 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 1 - 9223372036854775807 1 - -echo select * from t1 where f1 = 12 OR f2 < 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -9223372036854775808 1 - 9223372036854775807 1 - -echo select * from t1 where f1 = 12 OR f2 <> 22; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -9223372036854775808 1 - 9223372036854775807 1 - -echo select * from t1 where NOT f1 = 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -9223372036854775808 1 - 9223372036854775807 1 - -echo select * from t1 where f1 != 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -9223372036854775808 1 - 9223372036854775807 1 - -echo select * from t1 where NOT f1 != 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 1 - -echo select * from t1 where f1 = f2; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 between 999999999997 and 999999999999; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 between -999999999999 and -999999999997; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo update t1 set f2 = 2 where f1 != f2; -Statement Executed: Rows Affected = 6 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 2 - 13 2 - -9223372036854775808 2 - 9223372036854775807 2 - -echo update t1 set f2 = 3 where f1 = 50; -Statement Executed: Rows Affected = 0 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 2 - 13 2 - -9223372036854775808 2 - 9223372036854775807 2 - -Statement Executed: Rows Affected = 0 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 2 - 13 2 - -9223372036854775808 2 - 9223372036854775807 2 - -Statement Executed diff --git a/test/tools/csql/exp.test028.ksh b/test/tools/csql/exp.test028.ksh deleted file mode 100644 index 4e016814..00000000 --- a/test/tools/csql/exp.test028.ksh +++ /dev/null @@ -1,80 +0,0 @@ -echo LIKE operator char datatype testing; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 A - 11 B - 12 C - 13 D - 14 14 - 50 E - This is really a very b E - UPPERCASE UPPER - uppercase LOWER - upperletter LOWER - uppercaseletter LOWER - -echo select * from t1 where f1 LIKE 'UPP%'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - UPPERCASE UPPER - -echo select * from t1 where f1 LIKE 'upp%'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - uppercase LOWER - upperletter LOWER - uppercaseletter LOWER - -echo select * from t1 where f1 LIKE 'upper%letter'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - upperletter LOWER - uppercaseletter LOWER - -echo select * from t1 where f1 LIKE 'upper____letter'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - uppercaseletter LOWER - -echo select * from t1 where f1 like 'UP__R%SE'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - UPPERCASE UPPER - -echo select * from t1 where f1 like 'UP__R%SE' and f2 = 'B'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 like 'UP__R%SE' and f2 = 'UPPER'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - UPPERCASE UPPER - -echo select * from t1 where f1 like 'UP__R%SE' and f2 like 'UPPER'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - UPPERCASE UPPER - -Statement Executed diff --git a/test/tools/csql/exp.test029.ksh b/test/tools/csql/exp.test029.ksh deleted file mode 100644 index 89b36405..00000000 --- a/test/tools/csql/exp.test029.ksh +++ /dev/null @@ -1,130 +0,0 @@ -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select count(f1) from t1; ---------------------------------------------------------- - COUNT(f1) ---------------------------------------------------------- - 8 - -echo select min(f1) from t1; ---------------------------------------------------------- - MIN(f1) ---------------------------------------------------------- - 1 - -echo select max(f3) from t1; ---------------------------------------------------------- - MAX(f3) ---------------------------------------------------------- - 1000 - -echo select avg(f1) from t1; ---------------------------------------------------------- - AVG(f1) ---------------------------------------------------------- - 165 - -echo select sum(f1) from t1; ---------------------------------------------------------- - SUM(f1) ---------------------------------------------------------- - 1321 - -echo select count(f1) from t1 group by f2; ---------------------------------------------------------- - COUNT(f1) ---------------------------------------------------------- - 3 - 2 - 2 - 1 - -echo select min(f1) from t1 group by f2; ---------------------------------------------------------- - MIN(f1) ---------------------------------------------------------- - 1 - 5 - 100 - 1000 - -echo select max(f1) from t1 group by f2; ---------------------------------------------------------- - MAX(f1) ---------------------------------------------------------- - 3 - 10 - 200 - 1000 - -echo select avg(f1) from t1 group by f2; ---------------------------------------------------------- - AVG(f1) ---------------------------------------------------------- - 2 - 7 - 150 - 1000 - -echo select sum(f1) from t1 group by f2; ---------------------------------------------------------- - SUM(f1) ---------------------------------------------------------- - 6 - 15 - 300 - 1000 - -echo select min(f1), max(f3), sum(f1) from t1; ---------------------------------------------------------- - MIN(f1) MAX(f3) SUM(f1) ---------------------------------------------------------- - 1 1000 1321 - -echo select min(f1), f2, max(f3) from t1; ---------------------------------------------------------- - MIN(f1) f2 MAX(f3) ---------------------------------------------------------- - 1 1 1000 - -echo select min(f1), f2, max(f3) from t1 group by f2; ---------------------------------------------------------- - MIN(f1) f2 MAX(f3) ---------------------------------------------------------- - 1 1 3 - 5 2 10 - 100 3 200 - 1000 4 1000 - -echo select min(f2) from t1 group by f2; ---------------------------------------------------------- - MIN(f2) ---------------------------------------------------------- - 1 - 2 - 3 - 4 - -echo select count(*) from t1; ---------------------------------------------------------- - COUNT(*) ---------------------------------------------------------- - 8 - -echo select count(*) from t1 group by f2; ---------------------------------------------------------- - COUNT(*) ---------------------------------------------------------- - 3 - 2 - 2 - 1 - -Statement Executed diff --git a/test/tools/csql/exp.test030.ksh b/test/tools/csql/exp.test030.ksh deleted file mode 100644 index 6df3b784..00000000 --- a/test/tools/csql/exp.test030.ksh +++ /dev/null @@ -1,58 +0,0 @@ -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement execute failed with error -21 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select count(f1) from t1; ---------------------------------------------------------- - COUNT(f1) ---------------------------------------------------------- - 6 - -echo select * from t1 where f1=1 and f2=1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 1 1 - -echo select * from t1 where f1=5 and f2=1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=5; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 5 2 5 - -echo select * from t1 where f1=7; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=10 and f2=2 and f3=10; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 2 10 - -echo select * from t1 where f1=10 and f2=6 and f3=10; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT NOT NULL , f3 INT ); -CREATE INDEX t1_idx1_Primary on t1 ( f1 ,f2 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(1,1,1); -INSERT INTO t1 VALUES(2,1,2); -INSERT INTO t1 VALUES(3,1,3); -INSERT INTO t1 VALUES(5,2,5); -INSERT INTO t1 VALUES(10,2,10); -INSERT INTO t1 VALUES(100,3,100); -COMMIT; -Statement Executed diff --git a/test/tools/csql/exp.test031.ksh b/test/tools/csql/exp.test031.ksh deleted file mode 100644 index 616d1890..00000000 --- a/test/tools/csql/exp.test031.ksh +++ /dev/null @@ -1,61 +0,0 @@ -Statement Executed -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select count(f1) from t1; ---------------------------------------------------------- - COUNT(f1) ---------------------------------------------------------- - 7 - -echo select * from t1 where f1=1 and f2=1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 1 1 - 1 1 3 - -echo select * from t1 where f1=5 and f2=1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=5; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 5 2 5 - -echo select * from t1 where f1=7; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=10 and f2=2 and f3=10; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 2 10 - -echo select * from t1 where f1=10 and f2=6 and f3=10; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT NOT NULL , f3 INT ); -CREATE INDEX idx on t1 ( f1 ,f2 ) HASH ; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(1,1,1); -INSERT INTO t1 VALUES(2,1,2); -INSERT INTO t1 VALUES(3,1,3); -INSERT INTO t1 VALUES(1,1,3); -INSERT INTO t1 VALUES(5,2,5); -INSERT INTO t1 VALUES(10,2,10); -INSERT INTO t1 VALUES(100,3,100); -COMMIT; -Statement Executed diff --git a/test/tools/csql/exp.test032.ksh b/test/tools/csql/exp.test032.ksh deleted file mode 100644 index c20067b3..00000000 --- a/test/tools/csql/exp.test032.ksh +++ /dev/null @@ -1,59 +0,0 @@ -Statement Executed -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement execute failed with error -21 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select count(f1) from t1; ---------------------------------------------------------- - COUNT(f1) ---------------------------------------------------------- - 6 - -echo select * from t1 where f1=1 and f2=1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 1 1 - -echo select * from t1 where f1=5 and f2=1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=5; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 5 2 5 - -echo select * from t1 where f1=7; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=10 and f2=2 and f3=10; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 2 10 - -echo select * from t1 where f1=10 and f2=6 and f3=10; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -CREATE TABLE t1 (f1 INT NOT NULL , f2 CHAR (12) NOT NULL , f3 INT ); -CREATE INDEX idx on t1 ( f1 ,f2 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(1, '1',1); -INSERT INTO t1 VALUES(2, '1',2); -INSERT INTO t1 VALUES(3, '1',3); -INSERT INTO t1 VALUES(5, '2',5); -INSERT INTO t1 VALUES(10, '2',10); -INSERT INTO t1 VALUES(100, '3',100); -COMMIT; -Statement Executed diff --git a/test/tools/csql/exp.test033.ksh b/test/tools/csql/exp.test033.ksh deleted file mode 100644 index 46b04e9a..00000000 --- a/test/tools/csql/exp.test033.ksh +++ /dev/null @@ -1,17 +0,0 @@ -Statement Executed -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select count(f1) from t1; ---------------------------------------------------------- - COUNT(f1) ---------------------------------------------------------- - 2 - -CREATE TABLE t1 (f1 INT NOT NULL , f2 CHAR (12) NOT NULL , f3 INT ); -CREATE INDEX idx on t1 ( f1 ,f2 ) TREE UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(1, '1',1); -INSERT INTO t1 VALUES(3, '1',3); -COMMIT; -Statement Executed diff --git a/test/tools/csql/exp.test034.ksh b/test/tools/csql/exp.test034.ksh deleted file mode 100644 index 6e0175c0..00000000 --- a/test/tools/csql/exp.test034.ksh +++ /dev/null @@ -1,1162 +0,0 @@ -echo "----------Table having single field f1 and index on t1(f1)--------------"; -echo create table t1(f1 int); -Statement Executed -echo create index idx1 on t1(f1); -Statement Executed -echo insert into t1 values(10); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(21); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(32); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(123); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(-2147483648); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2147483647); -Statement Executed: Rows Affected = 1 -echo select * from t1 where f1>-5; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 10 - 21 - 32 - 123 - 2147483647 - -echo select * from t1 where f1<-10; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - -2147483648 - -echo select f1 from t1 where f1 in (10,30,123); ---------------------------------------------------------- - f1 ---------------------------------------------------------- - 10 - 123 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 10 - 21 - 32 - 123 - -2147483648 - 2147483647 - -echo update t1 set f1=25 where f1=21; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 10 - 25 - 32 - 123 - -2147483648 - 2147483647 - -echo update t1 set f1=1010101 where f1 in(32,10,40); -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1010101 - 25 - 1010101 - 123 - -2147483648 - 2147483647 - -echo update t1 set f1=987654 where f1 between 25 and 200; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1010101 - 987654 - 1010101 - 987654 - -2147483648 - 2147483647 - -echo delete from t1 where f1=2147483647; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1010101 - 987654 - 1010101 - 987654 - -2147483648 - -echo delete from t1 where f1 between 25 and 6000000; -Statement Executed: Rows Affected = 4 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - -2147483648 - -echo delete from t1; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo "-----Table having two fields f1 int,f2 int and index on t1(f1)-----"; -echo create table t1(f1 int,f2 int); -Statement Executed -echo create index idx1 on t1(f1); -Statement Executed -echo insert into t1 values(10,2147483647); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(21,-2147483648); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(32,1000000000); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(123,999999999); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(-2147483648,0); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2147483647,-2147483648); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(123,9); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2147483647 - 21 -2147483648 - 32 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo select * from t1 where f1>-5; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2147483647 - 21 -2147483648 - 32 1000000000 - 123 999999999 - 2147483647 -2147483648 - 123 9 - -echo select * from t1 where f1<-10; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -2147483648 0 - -echo select f1 from t1 where f1 in (10,30,123); ---------------------------------------------------------- - f1 ---------------------------------------------------------- - 10 - 123 - 123 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2147483647 - 21 -2147483648 - 32 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo update t1 set f1=25 where f1=21; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2147483647 - 25 -2147483648 - 32 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo update t1 set f1=21 where f1=25 and f2=-2147483648; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2147483647 - 21 -2147483648 - 32 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo update t1 set f1=1010101 where f1 in(32,10,40); -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1010101 2147483647 - 21 -2147483648 - 1010101 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo update t1 set f1=7777 where f1=1010101 and f2 in(1000000000,999999999); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1010101 2147483647 - 21 -2147483648 - 7777 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo update t1 set f1=2020202 where f2 in(1000000000,999999999) and f1>=7777; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1010101 2147483647 - 21 -2147483648 - 2020202 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo update t1 set f1=987654 where f1 between 25 and 200; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1010101 2147483647 - 21 -2147483648 - 2020202 1000000000 - 987654 999999999 - -2147483648 0 - 2147483647 -2147483648 - 987654 9 - -echo delete from t1 where f1=2147483647; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1010101 2147483647 - 21 -2147483648 - 2020202 1000000000 - 987654 999999999 - -2147483648 0 - 987654 9 - -echo delete from t1 where f1 between 25 and 6000000; -Statement Executed: Rows Affected = 4 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 21 -2147483648 - -2147483648 0 - -echo delete from t1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo "--Table having 5 fields f1,f2,f3,f4,f5(all int) index on t1(f1,f2)--"; -echo create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -Statement Executed -echo create index idx1 on t1(f1,f2); -Statement Executed -echo insert into t1 values(11,222,3333,44444,555555); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,12345,123456); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(234,4567,56789,1234,4321); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(-2147483647,1,101,212,2147483647); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(101,12121,0,32123,78987); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1000,1111,1); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483647 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1000 1111 1 - -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; ---------------------------------------------------------- - f1 f3 f5 ---------------------------------------------------------- - 11 3333 555555 - 12 1234 123456 - 234 56789 4321 - -2147483647 101 2147483647 - 101 0 78987 - -echo select * from t1 where f1<-1 and f2>=1 or f3=101; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -2147483647 1 101 212 2147483647 - -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 12 123 1234 12345 123456 - -2147483647 1 101 212 2147483647 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483647 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1000 1111 1 - -echo update t1 set f1=22 where f1=11; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 22 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483647 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1000 1111 1 - -echo update t1 set f1=11 where f1=22 and f2=222; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483647 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1000 1111 1 - -echo update t1 set f1=10 where f1 in(234,10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 10 4567 56789 1234 4321 - -2147483647 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1000 1111 1 - -echo update t1 set f2=100 where f1 in(12,10); -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 100 56789 1234 4321 - -2147483647 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1000 1111 1 - -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 222 56789 1234 4321 - -2147483647 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1000 1111 1 - -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -Statement Executed: Rows Affected = 5 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483647 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1000 1111 1 - -echo update t1 set f2=101,f2=12121 where f3=0; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483647 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1000 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1000 1111 1 - -echo update t1 set f1=987654 where f1 between 25 and 200; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 987654 12121 0 32123 78987 - 12 5 1000 1111 1 - -echo delete from t1 where f1=2147483647; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 987654 12121 0 32123 78987 - 12 5 1000 1111 1 - -echo delete from t1 where f1 between 25 and 6000000; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 12 5 1000 1111 1 - -echo delete from t1; -Statement Executed: Rows Affected = 4 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo "--Table having 5 fields f1,f2,f3,f4,f5(all int) index on t1(f1,f3)--"; -echo create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -Statement Executed -echo create index idx1 on t1(f1,f3); -Statement Executed -echo insert into t1 values(11,222,3333,44444,555555); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,12345,123456); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(234,4567,56789,1234,4321); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(-2147483648,1,101,212,2147483647); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(101,12121,0,32123,78987); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,100,1234,1111,1); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; ---------------------------------------------------------- - f1 f3 f5 ---------------------------------------------------------- - 11 3333 555555 - 12 1234 123456 - 234 56789 4321 - -2147483648 101 2147483647 - 101 0 78987 - -echo select * from t1 where f1<-1 and f2>=1 or f3=101; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -2147483648 1 101 212 2147483647 - -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 12 123 1234 12345 123456 - -2147483648 1 101 212 2147483647 - 12 100 1234 1111 1 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f1=22 where f1=11; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 22 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f1=11 where f1=22 and f2=222; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f1=10 where f1 in(234,10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 10 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=100 where f1 in(12,10); -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 100 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 222 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -Statement Executed: Rows Affected = 5 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f2=101,f2=12121 where f3=0; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo delete from t1 where f1=-2147483648 or f3=1234; -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - 101 12121 0 32123 78987 - -echo delete from t1 where f1 between 25 and 6000000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - -echo delete from t1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo "--Table having 5 fields f1,f2,f3,f4,f5(all int) index on t1(f1,f3,f2)--"; -echo create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -Statement Executed -echo create index idx1 on t1(f1,f3,f2); -Statement Executed -echo insert into t1 values(11,222,3333,44444,555555); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,12345,123456); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(234,4567,56789,1234,4321); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(-2147483648,1,101,212,2147483647); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(101,12121,0,32123,78987); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,1111,1); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; ---------------------------------------------------------- - f1 f3 f5 ---------------------------------------------------------- - 11 3333 555555 - 12 1234 123456 - 234 56789 4321 - -2147483648 101 2147483647 - 101 0 78987 - -echo select * from t1 where f1<-1 and f2>=1 or f3=101; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -2147483648 1 101 212 2147483647 - -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 12 123 1234 12345 123456 - -2147483648 1 101 212 2147483647 - 12 123 1234 1111 1 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f1=22 where f1=11; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 22 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f1=11 where f1=22 and f2=222; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f1=10 where f1 in(234,10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 10 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f2=100 where f1 in(12,10); -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 100 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 222 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -Statement Executed: Rows Affected = 5 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f2=101,f2=12121 where f3=0; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=1 and f3=101; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo delete from t1 where f1=-2147483648 or f3=1234; -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - 101 12121 0 32123 78987 - -echo delete from t1 where f1 between 25 and 6000000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - -echo delete from t1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo "--Table having 5 fields f1,f2,f3,f4,f5(all int) index on t1(f5,f1,f3,f2)--"; -echo create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -Statement Executed -echo create index idx1 on t1(f5,f1,f3,f2); -Statement Executed -echo insert into t1 values(11,222,3333,44444,555555); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,12345,123456); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(234,4567,56789,1234,4321); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(-2147483648,1,101,212,2147483647); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(101,12121,0,32123,78987); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,1111,1); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; ---------------------------------------------------------- - f1 f3 f5 ---------------------------------------------------------- - 11 3333 555555 - 12 1234 123456 - 234 56789 4321 - -2147483648 101 2147483647 - 101 0 78987 - -echo select * from t1 where f1<-1 and f2>=1 or f3=101; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -2147483648 1 101 212 2147483647 - -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 12 123 1234 12345 123456 - -2147483648 1 101 212 2147483647 - 12 123 1234 1111 1 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f1=22 where f1=11; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 22 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f1=11 where f1=22 and f2=222; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f1=10 where f1 in(234,10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 10 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f2=100 where f1 in(12,10); -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 100 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 222 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -Statement Executed: Rows Affected = 5 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=1 and f3=101; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo delete from t1 where f1=-2147483648 or f3=1234; -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - 101 12121 0 32123 78987 - -echo delete from t1 where f1 between 25 and 6000000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - -echo delete from t1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed diff --git a/test/tools/csql/exp.test034a.ksh b/test/tools/csql/exp.test034a.ksh deleted file mode 100644 index 5e21a2d6..00000000 --- a/test/tools/csql/exp.test034a.ksh +++ /dev/null @@ -1,1107 +0,0 @@ -echo "-----Table having two fields f1 bigint,f2 integer and index on t1(f1)-----"; -echo create table t1(f1 bigint,f2 integer); -Statement Executed -echo create index idx1 on t1(f1); -Statement Executed -echo insert into t1 values(10,2147483647); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(21,-2147483648); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(32,1000000000); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(123,999999999); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(-2147483648,0); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2147483647,-2147483648); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(123,9); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2147483647 - 21 -2147483648 - 32 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo select * from t1 where f1>-5; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2147483647 - 21 -2147483648 - 32 1000000000 - 123 999999999 - 2147483647 -2147483648 - 123 9 - -echo select * from t1 where f1<-10; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -2147483648 0 - -echo select f1 from t1 where f1 in (10,30,123); ---------------------------------------------------------- - f1 ---------------------------------------------------------- - 10 - 123 - 123 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2147483647 - 21 -2147483648 - 32 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo select * from t1 where f1 between 25 and 6000000; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 32 1000000000 - 123 999999999 - 123 9 - -echo select * from t1 where f1 between 6000000 and 25; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo update t1 set f1=25 where f1=21; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2147483647 - 25 -2147483648 - 32 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo update t1 set f1=21 where f1=25 and f2=-2147483648; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2147483647 - 21 -2147483648 - 32 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo update t1 set f1=1010101 where f1 in(32,10,40); -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1010101 2147483647 - 21 -2147483648 - 1010101 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo update t1 set f1=7777 where f1=1010101 and f2 in(1000000000,999999999); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1010101 2147483647 - 21 -2147483648 - 7777 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo update t1 set f1=2020202 where f2 in(1000000000,999999999) and f1>=7777; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1010101 2147483647 - 21 -2147483648 - 2020202 1000000000 - 123 999999999 - -2147483648 0 - 2147483647 -2147483648 - 123 9 - -echo update t1 set f1=987654 where f1 between 25 and 200; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1010101 2147483647 - 21 -2147483648 - 2020202 1000000000 - 987654 999999999 - -2147483648 0 - 2147483647 -2147483648 - 987654 9 - -echo delete from t1 where f1=2020202; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1010101 2147483647 - 21 -2147483648 - 987654 999999999 - -2147483648 0 - 2147483647 -2147483648 - 987654 9 - -echo delete from t1 where f1 between 25 and 6000000; -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 21 -2147483648 - -2147483648 0 - 2147483647 -2147483648 - -echo delete from t1; -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo "--Table having 5 fields f1,f2,f3,f4,f5(Different int) index on t1(f1,f2)--"; -echo create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -Statement Executed -echo create index idx1 on t1(f1,f2); -Statement Executed -echo insert into t1 values(11,222,3333,44444,555555); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,12345,123456); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(234,4567,56789,1234,4321); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(-2147483648,1,101,212,2147483647); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(101,12121,0,32123,78987); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1000,1111,1); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1000 1111 1 - -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; ---------------------------------------------------------- - f1 f3 f5 ---------------------------------------------------------- - 11 3333 555555 - 12 1234 123456 - 234 56789 4321 - -2147483648 101 2147483647 - 101 0 78987 - -echo select * from t1 where f1<-1 and f2>=1 or f3=101; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -2147483648 1 101 212 2147483647 - -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 12 123 1234 12345 123456 - -2147483648 1 101 212 2147483647 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1000 1111 1 - -echo select * from t1 where f1 between 25 and 6000000; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 234 4567 56789 1234 4321 - 101 12121 0 32123 78987 - -echo select * from t1 where f1 between 6000000 and 25; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo update t1 set f1=22 where f1=11; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 22 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1000 1111 1 - -echo update t1 set f1=11 where f1=22 and f2=222; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1000 1111 1 - -echo update t1 set f1=10 where f1 in(234,10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 10 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1000 1111 1 - -echo update t1 set f2=100 where f1 in(12,10); -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 100 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1000 1111 1 - -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 222 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1000 1111 1 - -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -Statement Executed: Rows Affected = 5 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1000 1111 1 - -echo update t1 set f2=101,f2=12121 where f3=0; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1000 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1000 1111 1 - -echo update t1 set f1=987654 where f1 between 25 and 200; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 987654 12121 0 32123 78987 - 12 5 1000 1111 1 - -echo delete from t1 where f1=2020202 and f5=2147483647; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 987654 12121 0 32123 78987 - 12 5 1000 1111 1 - -echo delete from t1 where f1 between 25 and 6000000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 12 5 1000 1111 1 - -echo delete from t1; -Statement Executed: Rows Affected = 4 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo "--Table having 5 fields f1,f2,f3,f4,f5(Different int) index on t1(f1,f3)--"; -echo create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -Statement Executed -echo create index idx1 on t1(f1,f3); -Statement Executed -echo insert into t1 values(11,222,3333,44444,555555); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,12345,123456); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(234,4567,56789,1234,4321); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(-2147483648,1,101,212,2147483647); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(101,12121,0,32123,78987); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,100,1234,1111,1); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; ---------------------------------------------------------- - f1 f3 f5 ---------------------------------------------------------- - 11 3333 555555 - 12 1234 123456 - 234 56789 4321 - -2147483648 101 2147483647 - 101 0 78987 - -echo select * from t1 where f1<-1 and f2>=1 or f3=101; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -2147483648 1 101 212 2147483647 - -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 12 123 1234 12345 123456 - -2147483648 1 101 212 2147483647 - 12 100 1234 1111 1 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo select * from t1 where f1 between 25 and 6000000; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 234 4567 56789 1234 4321 - 101 12121 0 32123 78987 - -echo select * from t1 where f1 between 6000000 and 25; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo update t1 set f1=22 where f1=11; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 22 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f1=11 where f1=22 and f2=222; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f1=10 where f1 in(234,10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 10 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=100 where f1 in(12,10); -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 100 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 222 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -Statement Executed: Rows Affected = 5 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f2=101,f2=12121 where f3=0; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo delete from t1 where f1=-2147483648 or f3=1234; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 101 12121 0 32123 78987 - -echo delete from t1 where f1 between 25 and 6000000; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - -echo delete from t1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo "--Table having 5 fields f1,f2,f3,f4,f5(Different int) index on t1(f1,f3,f2)--"; -echo create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -Statement Executed -echo create index idx1 on t1(f1,f3,f2); -Statement Executed -echo insert into t1 values(11,222,3333,44444,555555); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,12345,123456); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(234,4567,56789,1234,4321); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(-2147483648,1,101,212,2147483647); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(101,12121,0,32123,78987); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,1111,1); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; ---------------------------------------------------------- - f1 f3 f5 ---------------------------------------------------------- - 11 3333 555555 - 12 1234 123456 - 234 56789 4321 - -2147483648 101 2147483647 - 101 0 78987 - -echo select * from t1 where f1<-1 and f2>=1 or f3=101; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -2147483648 1 101 212 2147483647 - -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 12 123 1234 12345 123456 - -2147483648 1 101 212 2147483647 - 12 123 1234 1111 1 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo select * from t1 where f1 between 25 and 6000000; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 234 4567 56789 1234 4321 - 101 12121 0 32123 78987 - -echo select * from t1 where f1 between 6000000 and 25; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo update t1 set f1=22 where f1=11; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 22 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f1=11 where f1=22 and f2=222; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f1=10 where f1 in(234,10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 10 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f2=100 where f1 in(12,10); -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 100 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 222 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -Statement Executed: Rows Affected = 5 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f2=101,f2=12121 where f3=0; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=5 and f3=101; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo delete from t1 where f1=-2147483648 or f3=1234; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 101 12121 0 32123 78987 - -echo delete from t1 where f1 between 25 and 6000000; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - -echo delete from t1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo "--Table having 5 fields f1,f2,f3,f4,f5(Different int) index on t1(f5,f1,f3,f2)--"; -echo create table t1(f1 bigint,f2 integer,f3 int,f4 integer,f5 bigint); -Statement Executed -echo create index idx1 on t1(f5,f1,f3,f2); -Statement Executed -echo insert into t1 values(11,222,3333,44444,555555); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,12345,123456); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(234,4567,56789,1234,4321); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(-2147483648,1,101,212,2147483647); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(101,12121,0,32123,78987); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(12,123,1234,1111,1); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; ---------------------------------------------------------- - f1 f3 f5 ---------------------------------------------------------- - 11 3333 555555 - 12 1234 123456 - 234 56789 4321 - -2147483648 101 2147483647 - 101 0 78987 - -echo select * from t1 where f1<-1 and f2>=1 or f3=101; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -2147483648 1 101 212 2147483647 - -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 12 123 1234 12345 123456 - -2147483648 1 101 212 2147483647 - 12 123 1234 1111 1 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo select * from t1 where f1 between 25 and 6000000; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 234 4567 56789 1234 4321 - 101 12121 0 32123 78987 - -echo select * from t1 where f1 between 6000000 and 25; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo update t1 set f1=22 where f1=11; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 22 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f1=11 where f1=22 and f2=222; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 234 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f1=10 where f1 in(234,10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 123 1234 12345 123456 - 10 4567 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 123 1234 1111 1 - -echo update t1 set f2=100 where f1 in(12,10); -Statement Executed: Rows Affected = 3 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 100 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 222 3333 44444 555555 - 12 100 1234 12345 123456 - 10 222 56789 1234 4321 - -2147483648 1 101 212 2147483647 - 101 12121 0 32123 78987 - 12 100 1234 1111 1 - -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -Statement Executed: Rows Affected = 5 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=5 and f3=101; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - -2147483648 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo update t1 set f1=2020202 where f1 in(-2147483648,2147483647) or f1>=7777; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 12 5 1234 12345 123456 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 101 12121 0 32123 78987 - 12 5 1234 1111 1 - -echo delete from t1 where f1=-2147483648 or f3=1234; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - 2020202 5 101 212 2147483647 - 101 12121 0 32123 78987 - -echo delete from t1 where f1 between 25 and 6000000; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - 11 5 3333 44444 555555 - 10 5 56789 1234 4321 - -echo delete from t1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 t1.f5 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed diff --git a/test/tools/csql/exp.test035.ksh b/test/tools/csql/exp.test035.ksh deleted file mode 100644 index 24753bf6..00000000 --- a/test/tools/csql/exp.test035.ksh +++ /dev/null @@ -1,17 +0,0 @@ -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo create index ind on t1(f1)unique; -Statement execute failed with error -21 -CREATE TABLE t1 (f1 INT , f2 INT ); -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(1,1); -INSERT INTO t1 VALUES(1,2); -INSERT INTO t1 VALUES(5,5); -INSERT INTO t1 VALUES(2,1); -INSERT INTO t1 VALUES(2,2); -COMMIT; -Statement Executed diff --git a/test/tools/csql/exp.test036.ksh b/test/tools/csql/exp.test036.ksh deleted file mode 100644 index 7d2e7c68..00000000 --- a/test/tools/csql/exp.test036.ksh +++ /dev/null @@ -1,256 +0,0 @@ -echo create table t2 ( f1 int, f2 int, primary key(f1, f2)); -Statement Executed -echo create index ind on t2(f1); -Statement Executed -echo create table t1 (f1 int,f2 char(10),f3 smallint,f4 tinyint,primary key(f1,f2)); -Statement Executed -echo create index indx1 on t1 (f1,f3); -Statement Executed -echo create index indx2 on t1 (f3); -Statement Executed -echo create index indx3 on t1 (f2,f4); -Statement Executed -echo create index indx4 on t1 (f2,f3); -Statement Executed -echo create index indx5 on t1 (f1,f3,f4); -Statement Executed -echo create index indx6 on t1 (f1,f3,f2); -Statement Executed -echo create index indx7 on t1 (f1,f3,f2); -Statement Executed -echo create table t3 (f1 int,f2 char(10),f3 smallint,f4 tinyint,primary key(f1,f2)); -Statement Executed -echo create index indx11 on t3 (f1,f3); -Statement Executed -echo create index indx12 on t3 (f3); -Statement Executed -echo create index indx13 on t3 (f2,f4); -Statement Executed -echo create index indx14 on t3 (f2,f3); -Statement Executed -echo create index indx15 on t1 (f1,f3,f4); -Statement Executed -echo create index indx16 on t1 (f1,f3,f2); -Statement Executed -echo create index indx17 on t1 (f1,f3,f2); -Statement Executed -echo create table t4 (f1 int); -Statement Executed -echo create index indx18 on t4(f1,f1); -Statement execute failed with error -4 - - - t2 - - f1 - 0 - 4 - 1 - 1 - 0 - - - - f2 - 0 - 4 - 1 - 1 - 0 - - - - - t1 - - f1 - 0 - 4 - 1 - 1 - 0 - - - - f2 - 30 - 12 - 1 - 1 - 0 - - - - f3 - 3 - 4 - 0 - 0 - 0 - - - - f4 - 4 - 4 - 0 - 0 - 0 - - - - - t3 - - f1 - 0 - 4 - 1 - 1 - 0 - - - - f2 - 30 - 12 - 1 - 1 - 0 - - - - f3 - 3 - 4 - 0 - 0 - 0 - - - - f4 - 4 - 4 - 0 - 0 - 0 - - - - - t4 - - f1 - 0 - 4 - 0 - 0 - 0 - - - -
- - t2_idx1_Primary - Hash Index - t2
- f1 - f2 - ind - Hash Index - t2
- f1 - t1_idx1_Primary - Hash Index - t1
- f1 - f2 - indx1 - Hash Index - t1
- f1 - f3 - indx2 - Hash Index - t1
- f3 - indx3 - Hash Index - t1
- f2 - f4 - indx4 - Hash Index - t1
- f2 - f3 - indx5 - Hash Index - t1
- f1 - f3 - f4 - indx6 - Hash Index - t1
- f1 - f3 - f2 - indx7 - Hash Index - t1
- f1 - f4 - f2 - t3_idx1_Primary - Hash Index - t3
- f1 - f2 - indx11 - Hash Index - t3
- f1 - f3 - indx12 - Hash Index - t3
- f3 - indx13 - Hash Index - t3
- f2 - f4 - indx14 - Hash Index - t3
- f2 - f3 - indx15 - Hash Index - t3
- f1 - f3 - f4 - indx16 - Hash Index - t3
- f1 - f3 - f2 - indx17 - Hash Index - t3
- f1 - f4 - f2 -
-echo drop table t1; -echo drop table t2; -echo drop table t3; -Statement Executed -Statement Executed -Statement Executed -echo drop table t4; -Statement Executed diff --git a/test/tools/csql/exp.test037.ksh b/test/tools/csql/exp.test037.ksh deleted file mode 100644 index f649161a..00000000 --- a/test/tools/csql/exp.test037.ksh +++ /dev/null @@ -1,146 +0,0 @@ -echo tinyint data type testing; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -128 1 - 127 1 - -echo select * from t1 where f1 = 10; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - -echo select * from t1 where f1 != 12 AND f2 <= 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -128 1 - 127 1 - -echo select * from t1 where f1 = 12 AND f2 >= 22; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 = 12 OR f1 > 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 1 - 127 1 - -echo select * from t1 where f1 = 12 OR f2 < 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -128 1 - 127 1 - -echo select * from t1 where f1 = 12 OR f2 <> 22; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 12 1 - 13 1 - -128 1 - 127 1 - -echo select * from t1 where NOT f1 = 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -128 1 - 127 1 - -echo select * from t1 where f1 != 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 1 - 11 1 - 13 1 - -128 1 - 127 1 - -echo select * from t1 where NOT f1 != 12; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 12 1 - -echo select * from t1 where f1 = f2; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 between 126 and 127; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 127 1 - -echo select * from t1 where f1 between -127 and -128; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo update t1 set f2 = 2 where f1 != f2; -Statement Executed: Rows Affected = 6 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 2 - 13 2 - -128 2 - 127 2 - -echo update t1 set f2 = 3 where f1 = 12; -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 12 3 - 13 2 - -128 2 - 127 2 - -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 2 - 11 2 - 13 2 - -128 2 - 127 2 - -Statement Executed diff --git a/test/tools/csql/exp.test038.ksh b/test/tools/csql/exp.test038.ksh deleted file mode 100644 index 88fad6ba..00000000 --- a/test/tools/csql/exp.test038.ksh +++ /dev/null @@ -1,84 +0,0 @@ -echo create table t1 (f1 int, f2 char(10), f3 bigint); -Statement Executed -echo insert into t1 values(10,'india',1234321); -Statement Executed: Rows Affected = 1 -echo insert into t1 (f1, f2 ) values(20,'INDIA'); -Statement Executed: Rows Affected = 1 -echo insert into t1 (f2, f3 ) values('orissa',123432); -Statement Executed: Rows Affected = 1 -echo insert into t1 (f1, f3 ) values(30,123432); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 india 1234321 - 20 INDIA NULL - NULL orissa 123432 - 30 NULL 123432 - -echo update t1 set f1=10; -Statement Executed: Rows Affected = 4 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 india 1234321 - 10 INDIA NULL - 10 orissa 123432 - 10 NULL 123432 - -echo update t1 set f2='hello'; -Statement Executed: Rows Affected = 4 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 hello 1234321 - 10 hello NULL - 10 hello 123432 - 10 hello 123432 - -echo update t1 set f3=10000; -Statement Executed: Rows Affected = 4 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 hello 10000 - 10 hello 10000 - 10 hello 10000 - 10 hello 10000 - -echo create table t2 (f1 tinyint, f2 float); -Statement Executed -echo insert into t2 values (112, 235.50); -Statement Executed: Rows Affected = 1 -echo insert into t2 (f1) values (220); -Statement Executed: Rows Affected = 1 -echo insert into t2 (f2) values (100.50); -Statement Executed: Rows Affected = 1 -echo select * from t2; ---------------------------------------------------------- - t2.f1 t2.f2 ---------------------------------------------------------- - 112 235.500000 - -36 NULL - NULL 100.500000 - -echo update t2 set f2=250.50; -Statement Executed: Rows Affected = 3 -echo update t2 set f1=125; -Statement Executed: Rows Affected = 3 -echo select * from t2; ---------------------------------------------------------- - t2.f1 t2.f2 ---------------------------------------------------------- - 125 250.500000 - 125 250.500000 - 125 250.500000 - -echo drop table t1; -Statement Executed -echo drop table t2; -Statement Executed diff --git a/test/tools/csql/exp.test039.ksh b/test/tools/csql/exp.test039.ksh deleted file mode 100644 index cb4de221..00000000 --- a/test/tools/csql/exp.test039.ksh +++ /dev/null @@ -1,84 +0,0 @@ -echo create table t1 (f1 int, f2 char(10), f3 bigint); -Statement Executed -echo insert into t1 values(10,'india',1234321); -Statement Executed: Rows Affected = 1 -echo insert into t1 (f1, f2 ) values(20,'INDIA'); -Statement Executed: Rows Affected = 1 -echo insert into t1 (f2, f3 ) values('orissa',123432); -Statement Executed: Rows Affected = 1 -echo insert into t1 (f1, f3 ) values(30,123432); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 india 1234321 - 20 INDIA NULL - NULL orissa 123432 - 30 NULL 123432 - -echo select f1,f2,f3 from t1; ---------------------------------------------------------- - f1 f2 f3 ---------------------------------------------------------- - 10 india 1234321 - 20 INDIA NULL - NULL orissa 123432 - 30 NULL 123432 - -echo select f2,f1,f3 from t1; ---------------------------------------------------------- - f2 f1 f3 ---------------------------------------------------------- - india 10 1234321 - INDIA 20 NULL - orissa NULL 123432 - NULL 30 123432 - -echo select f1,f1,f1,f1,f1 from t1; ---------------------------------------------------------- - f1 f1 f1 f1 f1 ---------------------------------------------------------- - 10 10 10 10 10 - 20 20 20 20 20 - NULL NULL NULL NULL NULL - 30 30 30 30 30 - -echo select f2,f2,f2,f2,f2 from t1; ---------------------------------------------------------- - f2 f2 f2 f2 f2 ---------------------------------------------------------- - india india india india india - INDIA INDIA INDIA INDIA INDIA - orissa orissa orissa orissa orissa - NULL NULL NULL NULL NULL - -echo select f3,f3,f3,f3,f3 from t1; ---------------------------------------------------------- - f3 f3 f3 f3 f3 ---------------------------------------------------------- - 1234321 1234321 1234321 1234321 1234321 - NULL NULL NULL NULL NULL - 123432 123432 123432 123432 123432 - 123432 123432 123432 123432 123432 - -echo select f1,f1,f2,f2,f3,f3 from t1; ---------------------------------------------------------- - f1 f1 f2 f2 f3 f3 ---------------------------------------------------------- - 10 10 india india 1234321 1234321 - 20 20 INDIA INDIA NULL NULL - NULL NULL orissa orissa 123432 123432 - 30 30 NULL NULL 123432 123432 - -echo select f1,f2,f1,f3,f3,f2,f1,f3 from t1; ---------------------------------------------------------- - f1 f2 f1 f3 f3 f2 f1 f3 ---------------------------------------------------------- - 10 india 10 1234321 1234321 india 10 1234321 - 20 INDIA 20 NULL NULL INDIA 20 NULL - NULL orissa NULL 123432 123432 orissa NULL 123432 - 30 NULL 30 123432 123432 NULL 30 123432 - -echo drop table t1; -Statement Executed diff --git a/test/tools/csql/exp.test040.ksh b/test/tools/csql/exp.test040.ksh deleted file mode 100644 index 8d017475..00000000 --- a/test/tools/csql/exp.test040.ksh +++ /dev/null @@ -1,165 +0,0 @@ -echo binary data type testing; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 11 245AF - 12 245AF - 13 12FE - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where f2 = '12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 13 12FE - -echo select * from t1 where f2 != '323a34' AND f1 = 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 13 12FE - -echo select * from t1 where f1 = 12 AND f2 >= '245af'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary - -echo select * from t1 where f1 = 12 OR f2 > 'dc23'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 11 245AF - 12 245AF - 2147483647 323A34 - -echo select * from t1 where f1 = 12 OR f2 < 'dc23'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 12 245AF - 13 12FE - -echo select * from t1 where f1 = 12 OR f2 <> '245af'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 12 245AF - 13 12FE - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where NOT f2 ='12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 11 245AF - 12 245AF - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where f2 != '12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 11 245AF - 12 245AF - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where NOT f2 != '12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 13 12FE - -echo select * from t1 where f1 = f2; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f2 in ('245af','12fe'); ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 11 245AF - 12 245AF - 13 12FE - -echo select * from t1 where f2 between '00000000' and 'ffffffff'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary - -echo select * from t1 where f2 between '122' and '12a2'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary - -echo update t1 set f2 = '435f3' where f1 != 13 and f2='323a34' ; -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 11 245AF - 12 245AF - 13 12FE - -2147483648 DC23 - 2147483647 435F3 - -echo update t1 set f2 = '23abc' where f2 = '245af'; -Statement Executed: Rows Affected = 2 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 11 23ABC - 12 23ABC - 13 12FE - -2147483648 DC23 - 2147483647 435F3 - -echo delete from t1 where f2 = '12fe'; -Statement Executed: Rows Affected = 2 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 11 23ABC - 12 23ABC - -2147483648 DC23 - 2147483647 435F3 - -Statement Executed diff --git a/test/tools/csql/exp.test041.ksh b/test/tools/csql/exp.test041.ksh deleted file mode 100644 index 48be6a7c..00000000 --- a/test/tools/csql/exp.test041.ksh +++ /dev/null @@ -1,142 +0,0 @@ -echo binary data type testing with primary key; -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement execute failed with error -21 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 11 245AF - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where f2 = '12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - -echo select * from t1 where f2 != '323a34' AND f1 = 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 = 12 AND f2 >= '245af'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary - -echo select * from t1 where f1 = 12 OR f2 > 'dc23'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 11 245AF - 12 2423FE - 2147483647 323A34 - -echo select * from t1 where f1 = 12 OR f2 < 'dc23'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 12 2423FE - -echo select * from t1 where f1 = 12 OR f2 <> '245af'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where NOT f2 ='12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 11 245AF - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where f2 != '12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 11 245AF - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where NOT f2 != '12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - -echo select * from t1 where f1 = f2; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f2 in ('245af','12fe'); ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 11 245AF - -echo select * from t1 where f2 between '00000000' and 'ffffffff'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary - -echo select * from t1 where f2 between '122' and '12a2'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary - -echo update t1 set f2 = '435f3' where f1 != 13 and f2='323a34' ; -Statement prepare failed with error -21 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 11 245AF - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -echo delete from t1 where f2 = '23abc'; -Statement Executed: Rows Affected = 0 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 11 245AF - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -Statement Executed diff --git a/test/tools/csql/exp.test042.ksh b/test/tools/csql/exp.test042.ksh deleted file mode 100644 index 209d904c..00000000 --- a/test/tools/csql/exp.test042.ksh +++ /dev/null @@ -1,153 +0,0 @@ -echo binary data type testing with primary key; -echo create table t1 (f1 int, f2 binary(4) DEFAULT 'abcd12' ,primary key(f2)); -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement execute failed with error -21 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 10 ABCD12 - 11 245AF - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where f2 = '12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - -echo select * from t1 where f2 != '323a34' AND f1 = 13; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1 = 12 AND f2 >= '245af'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary - -echo select * from t1 where f1 = 12 OR f2 > 'dc23'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 ABCD12 - 11 245AF - 12 2423FE - 2147483647 323A34 - -echo select * from t1 where f1 = 12 OR f2 < 'dc23'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 12 2423FE - -echo select * from t1 where f1 = 12 OR f2 <> '245af'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 10 ABCD12 - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where NOT f2 ='12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 ABCD12 - 11 245AF - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where f2 != '12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 ABCD12 - 11 245AF - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -echo select * from t1 where NOT f2 != '12fe'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - -echo select * from t1 where f1 = f2; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f2 in ('245af','12fe'); ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 11 245AF - -echo select * from t1 where f2 between '00000000' and 'ffffffff'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary - -echo select * from t1 where f2 between '122' and '12a2'; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary -Illegal Operator:Not Supported for Binary - -echo update t1 set f2 = '435f3' where f1 != 13 and f2='323a34' ; -Statement prepare failed with error -21 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 12FE - 10 ABCD12 - 11 245AF - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -echo delete from t1 where f2 = '12fe'; -Statement Executed: Rows Affected = 1 ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 ABCD12 - 11 245AF - 12 2423FE - -2147483648 DC23 - 2147483647 323A34 - -Statement Executed diff --git a/test/tools/csql/exp.test043.ksh b/test/tools/csql/exp.test043.ksh deleted file mode 100644 index abba57d7..00000000 --- a/test/tools/csql/exp.test043.ksh +++ /dev/null @@ -1,6 +0,0 @@ -echo create tree index test; -Statement Executed -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed diff --git a/test/tools/csql/exp.test044.ksh b/test/tools/csql/exp.test044.ksh deleted file mode 100644 index f86d00b8..00000000 --- a/test/tools/csql/exp.test044.ksh +++ /dev/null @@ -1,6 +0,0 @@ -echo create tree index test; -Statement Executed -Statement Executed -Statement Executed: Rows Affected = 1 -Statement execute failed with error -21 -Statement Executed diff --git a/test/tools/csql/exp.test045.ksh b/test/tools/csql/exp.test045.ksh deleted file mode 100644 index 35df4534..00000000 --- a/test/tools/csql/exp.test045.ksh +++ /dev/null @@ -1,288 +0,0 @@ -Statement Executed -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - 11 11 - 12 12 - 13 13 - 14 14 - 15 15 - 16 16 - 17 17 - 18 18 - 19 19 - 20 20 - 21 21 - 22 22 - 23 23 - 24 24 - 25 25 - 26 26 - 27 27 - 28 28 - 29 29 - 30 30 - 31 31 - 32 32 - 33 33 - 34 34 - 35 35 - 36 36 - 37 37 - 38 38 - 39 39 - 40 40 - 41 41 - 42 42 - 43 43 - 44 44 - 45 45 - 46 46 - 47 47 - 48 48 - 49 49 - 50 50 - -50 rows selected -echo select * from t1 where f1=10; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 10 - -echo select * from t1 where f1=99; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1>27; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 28 28 - 29 29 - 30 30 - 31 31 - 32 32 - 33 33 - 34 34 - 35 35 - 36 36 - 37 37 - 38 38 - 39 39 - 40 40 - 41 41 - 42 42 - 43 43 - 44 44 - 45 45 - 46 46 - 47 47 - 48 48 - 49 49 - 50 50 - -echo select * from t1 where f1>=27; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 27 27 - 28 28 - 29 29 - 30 30 - 31 31 - 32 32 - 33 33 - 34 34 - 35 35 - 36 36 - 37 37 - 38 38 - 39 39 - 40 40 - 41 41 - 42 42 - 43 43 - 44 44 - 45 45 - 46 46 - 47 47 - 48 48 - 49 49 - 50 50 - -echo select * from t1 where f1<=27; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - 11 11 - 12 12 - 13 13 - 14 14 - 15 15 - 16 16 - 17 17 - 18 18 - 19 19 - 20 20 - 21 21 - 22 22 - 23 23 - 24 24 - 25 25 - 26 26 - 27 27 - -echo select * from t1 where f1<27; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - 11 11 - 12 12 - 13 13 - 14 14 - 15 15 - 16 16 - 17 17 - 18 18 - 19 19 - 20 20 - 21 21 - 22 22 - 23 23 - 24 24 - 25 25 - 26 26 - -echo select * from t1 where f1>99; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1<-1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1=40 and f1> 27; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 40 40 - -echo select * from t1 where f1> 27 and f1=40; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 40 40 - -echo select * from t1 where f1> 27 and f2=40; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 40 40 - -echo select * from t1 where f1 >10 and f1 <20; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 11 11 - 12 12 - 13 13 - 14 14 - 15 15 - 16 16 - 17 17 - 18 18 - 19 19 - -echo select * from t1 where f1 >10 and f1 <20 and f2=15; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 15 15 - -Statement Executed diff --git a/test/tools/csql/exp.test046.ksh b/test/tools/csql/exp.test046.ksh deleted file mode 100644 index 35df4534..00000000 --- a/test/tools/csql/exp.test046.ksh +++ /dev/null @@ -1,288 +0,0 @@ -Statement Executed -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - 11 11 - 12 12 - 13 13 - 14 14 - 15 15 - 16 16 - 17 17 - 18 18 - 19 19 - 20 20 - 21 21 - 22 22 - 23 23 - 24 24 - 25 25 - 26 26 - 27 27 - 28 28 - 29 29 - 30 30 - 31 31 - 32 32 - 33 33 - 34 34 - 35 35 - 36 36 - 37 37 - 38 38 - 39 39 - 40 40 - 41 41 - 42 42 - 43 43 - 44 44 - 45 45 - 46 46 - 47 47 - 48 48 - 49 49 - 50 50 - -50 rows selected -echo select * from t1 where f1=10; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 10 10 - -echo select * from t1 where f1=99; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1>27; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 28 28 - 29 29 - 30 30 - 31 31 - 32 32 - 33 33 - 34 34 - 35 35 - 36 36 - 37 37 - 38 38 - 39 39 - 40 40 - 41 41 - 42 42 - 43 43 - 44 44 - 45 45 - 46 46 - 47 47 - 48 48 - 49 49 - 50 50 - -echo select * from t1 where f1>=27; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 27 27 - 28 28 - 29 29 - 30 30 - 31 31 - 32 32 - 33 33 - 34 34 - 35 35 - 36 36 - 37 37 - 38 38 - 39 39 - 40 40 - 41 41 - 42 42 - 43 43 - 44 44 - 45 45 - 46 46 - 47 47 - 48 48 - 49 49 - 50 50 - -echo select * from t1 where f1<=27; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - 11 11 - 12 12 - 13 13 - 14 14 - 15 15 - 16 16 - 17 17 - 18 18 - 19 19 - 20 20 - 21 21 - 22 22 - 23 23 - 24 24 - 25 25 - 26 26 - 27 27 - -echo select * from t1 where f1<27; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - 11 11 - 12 12 - 13 13 - 14 14 - 15 15 - 16 16 - 17 17 - 18 18 - 19 19 - 20 20 - 21 21 - 22 22 - 23 23 - 24 24 - 25 25 - 26 26 - -echo select * from t1 where f1>99; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1<-1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - -echo select * from t1 where f1=40 and f1> 27; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 40 40 - -echo select * from t1 where f1> 27 and f1=40; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 40 40 - -echo select * from t1 where f1> 27 and f2=40; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 40 40 - -echo select * from t1 where f1 >10 and f1 <20; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 11 11 - 12 12 - 13 13 - 14 14 - 15 15 - 16 16 - 17 17 - 18 18 - 19 19 - -echo select * from t1 where f1 >10 and f1 <20 and f2=15; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 15 15 - -Statement Executed diff --git a/test/tools/csql/exp.test047.ksh b/test/tools/csql/exp.test047.ksh deleted file mode 100644 index ac335ccb..00000000 --- a/test/tools/csql/exp.test047.ksh +++ /dev/null @@ -1,109 +0,0 @@ -Statement Executed -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1 where f1>5 and f1<15; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 6 6 - 7 7 - 8 8 - 9 9 - 11 11 - 12 12 - 13 13 - 14 14 - -echo delete from t1 where f1>40; -Statement Executed: Rows Affected = 10 -echo commit; -echo select * from t1 where f1>35 and f1<55; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 36 36 - 37 37 - 38 38 - 39 39 - 40 40 - -echo delete from t1 where f1<8; -Statement Executed: Rows Affected = 7 -echo commit; -echo select * from t1 where f1>=-5 and f1<15; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 8 8 - 9 9 - 11 11 - 12 12 - 13 13 - 14 14 - -echo insert into t1 values(10,10); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1 where f1 >5 and f1 <15; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 8 8 - 9 9 - 10 10 - 11 11 - 12 12 - 13 13 - 14 14 - -Statement Executed diff --git a/test/tools/csql/exp.test048.ksh b/test/tools/csql/exp.test048.ksh deleted file mode 100644 index 737b50d8..00000000 --- a/test/tools/csql/exp.test048.ksh +++ /dev/null @@ -1,148 +0,0 @@ -Statement Executed -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - -echo select * from t1 where f1>-1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - -echo select * from t1 where f1>-2; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - -echo select * from t1 where f1>-3; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - -echo select * from t1 where f1>-4; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - -echo select * from t1 where f1>-5; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - -echo select * from t1 where f1>-10; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - -echo select * from t1 where f1>-100; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - -echo select * from t1 where f1>-1000; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 1 - 2 2 - 3 3 - 4 4 - 5 5 - 6 6 - 7 7 - 8 8 - 9 9 - 10 10 - -Statement Executed diff --git a/test/tools/csql/exp.test049.ksh b/test/tools/csql/exp.test049.ksh deleted file mode 100644 index 5b8d623e..00000000 --- a/test/tools/csql/exp.test049.ksh +++ /dev/null @@ -1,101 +0,0 @@ -echo create table t1 (f1 int, f2 int,f3 int); -Statement Executed -echo insert into t1 values(10,10,10); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(20,10,10); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(30,10,10); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(40,10,10); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(50,10,10); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(60,10,10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 10 10 - 20 10 10 - 30 10 10 - 40 10 10 - 50 10 10 - 60 10 10 - -echo update t1 set f1=f1+f2+f3+7,f2=f3+23+f1,f3=12; -Statement Executed: Rows Affected = 6 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 37 43 12 - 47 53 12 - 57 63 12 - 67 73 12 - 77 83 12 - 87 93 12 - -echo update t1 set f1=f2/f3+7,f2=f3+23+f1,f3=f2 where f3=12; -Statement Executed: Rows Affected = 6 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 10 72 43 - 11 82 53 - 12 92 63 - 13 102 73 - 13 112 83 - 14 122 93 - -echo create table t2 (f1 tinyint, f2 bigint,f3 int); -Statement Executed -echo insert into t2 values(60,1110,5110); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(70,1115,1510); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(80,1150,1150); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(90,1510,1115); -Statement Executed: Rows Affected = 1 -echo insert into t2 values(50,5110,1110); -Statement Executed: Rows Affected = 1 -echo select * from t2; ---------------------------------------------------------- - t2.f1 t2.f2 t2.f3 ---------------------------------------------------------- - 60 1110 5110 - 70 1115 1510 - 80 1150 1150 - 90 1510 1115 - 50 5110 1110 - -echo update t2 set f1=NULL,f2=f1+f2+f3+10 where f2>1122; -Statement Executed: Rows Affected = 3 -echo select * from t2; ---------------------------------------------------------- - t2.f1 t2.f2 t2.f3 ---------------------------------------------------------- - 60 1110 5110 - 70 1115 1510 - NULL 2390 1150 - NULL 2725 1115 - NULL 6280 1110 - -echo update t2 set f2=f2+123 ,f3=23+f2; -Statement Executed: Rows Affected = 5 -echo select * from t2; ---------------------------------------------------------- - t2.f1 t2.f2 t2.f3 ---------------------------------------------------------- - 60 1233 1133 - 70 1238 1138 - NULL 2513 2413 - NULL 2848 2748 - NULL 6403 6303 - -echo drop table t1; -Statement Executed -echo drop table t2; -Statement Executed diff --git a/test/tools/csql/exp.test050.ksh b/test/tools/csql/exp.test050.ksh deleted file mode 100644 index 26cd1d9f..00000000 --- a/test/tools/csql/exp.test050.ksh +++ /dev/null @@ -1,42 +0,0 @@ -Statement Executed -Statement Executed - - - t1 - - f1 - 0 - 4 - 0 - 1 - 0 - - - - f2 - 0 - 4 - 0 - 0 - 0 - - - - f3 - 0 - 4 - 0 - 0 - 0 - - - -
- - idx1 - Tree Index - t1
- f1 - f2 -
-Statement Executed diff --git a/test/tools/csql/exp.test051.ksh b/test/tools/csql/exp.test051.ksh deleted file mode 100644 index 292d7f0d..00000000 --- a/test/tools/csql/exp.test051.ksh +++ /dev/null @@ -1,76 +0,0 @@ -Statement Executed -Statement Executed -Statement Executed -Statement Executed -Statement Executed -Statement Executed -Statement Executed -Statement Executed - - - t1 - - f1 - 0 - 4 - 0 - 1 - 0 - - - - f2 - 0 - 4 - 0 - 0 - 0 - - - - f3 - 0 - 4 - 0 - 0 - 0 - - - -
- - idx1 - Tree Index - t1
- f1 - idx2 - Tree Index - t1
- f2 - idx3 - Tree Index - t1
- f3 - idx4 - Tree Index - t1
- f1 - f2 - idx5 - Tree Index - t1
- f2 - f3 - idx6 - Tree Index - t1
- f3 - f1 - idx7 - Tree Index - t1
- f1 - f2 - f3 -
-Statement Executed diff --git a/test/tools/csql/exp.test052.ksh b/test/tools/csql/exp.test052.ksh deleted file mode 100644 index cd35807c..00000000 --- a/test/tools/csql/exp.test052.ksh +++ /dev/null @@ -1,13 +0,0 @@ -Statement Executed -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -Statement Executed: Rows Affected = 1 -echo create index idx1 on t1(f1) tree unique; -Statement execute failed with error -21 -CREATE TABLE t1 (f1 INT , f2 INT , f3 INT ); -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(1,1,1); -INSERT INTO t1 VALUES(2,2,2); -INSERT INTO t1 VALUES(1,2,3); -COMMIT; -Statement Executed diff --git a/test/tools/csql/exp.test053.ksh b/test/tools/csql/exp.test053.ksh deleted file mode 100644 index 35e91573..00000000 --- a/test/tools/csql/exp.test053.ksh +++ /dev/null @@ -1,9 +0,0 @@ -Statement Executed -echo create index idx1 on t1(f1)unique; -Statement Executed -echo create index idx2 on t1(f1)primary; -Statement execute failed with error -4 -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT , f3 INT ); -CREATE INDEX idx1 on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -Statement Executed diff --git a/test/tools/csql/exp.test054.ksh b/test/tools/csql/exp.test054.ksh deleted file mode 100644 index 84095053..00000000 --- a/test/tools/csql/exp.test054.ksh +++ /dev/null @@ -1,9 +0,0 @@ -Statement Executed -echo create index idx1 on t1(f1) primary; -Statement Executed -echo create index idx2 on t1(f1) hash primary; -Statement execute failed with error -4 -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT , f3 INT ); -CREATE INDEX idx1 on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -Statement Executed diff --git a/test/tools/csql/exp.test055.ksh b/test/tools/csql/exp.test055.ksh deleted file mode 100644 index ec1e4e53..00000000 --- a/test/tools/csql/exp.test055.ksh +++ /dev/null @@ -1,9 +0,0 @@ -Statement Executed -echo create index idx1 on t1(f1) unique; -Statement Executed -echo create index idx2 on t1(f1) hash unique; -Statement execute failed with error -4 -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT , f3 INT ); -CREATE INDEX idx1 on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -Statement Executed diff --git a/test/tools/csql/exp.test056.ksh b/test/tools/csql/exp.test056.ksh deleted file mode 100644 index 814bed00..00000000 --- a/test/tools/csql/exp.test056.ksh +++ /dev/null @@ -1,11 +0,0 @@ -Statement Executed -echo create index idx1 on t1(f1) unique; -Statement Executed -echo create index idx2 on t1(f1) primary; -Statement execute failed with error -4 -echo create index idx3 on t1(f1) hash primary; -Statement execute failed with error -4 -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT , f3 INT ); -CREATE INDEX idx1 on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -Statement Executed diff --git a/test/tools/csql/exp.test057.ksh b/test/tools/csql/exp.test057.ksh deleted file mode 100644 index 9c13c6f9..00000000 --- a/test/tools/csql/exp.test057.ksh +++ /dev/null @@ -1,11 +0,0 @@ -Statement Executed -echo create index idx1 on t1(f1) hash unique; -Statement Executed -echo drop index idx1; -Statement Executed -echo create index idx2 on t1(f1) hash primary; -Statement Executed -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT , f3 INT ); -CREATE INDEX idx2 on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -Statement Executed diff --git a/test/tools/csql/exp.test058.ksh b/test/tools/csql/exp.test058.ksh deleted file mode 100644 index 42297e26..00000000 --- a/test/tools/csql/exp.test058.ksh +++ /dev/null @@ -1,10 +0,0 @@ -Statement Executed -echo create index idx1 on t1(f1) hash unique; -Statement Executed -echo create index idx2 on t1(f1) tree unique; -Statement Executed -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT , f3 INT ); -CREATE INDEX idx1 on t1 ( f1 ) HASH UNIQUE; -CREATE INDEX idx2 on t1 ( f1 ) TREE UNIQUE; -SET AUTOCOMMIT OFF; -Statement Executed diff --git a/test/tools/csql/exp.test059.ksh b/test/tools/csql/exp.test059.ksh deleted file mode 100644 index 96a2f1b1..00000000 --- a/test/tools/csql/exp.test059.ksh +++ /dev/null @@ -1,10 +0,0 @@ -Statement Executed -echo create index idx1 on t1(f1) hash primary; -Statement Executed -echo create index idx2 on t1(f1) tree primary; -Statement Executed -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT , f3 INT ); -CREATE INDEX idx1 on t1 ( f1 ) HASH UNIQUE; -CREATE INDEX idx2 on t1 ( f1 ) TREE UNIQUE; -SET AUTOCOMMIT OFF; -Statement Executed diff --git a/test/tools/csql/exp.test060.ksh b/test/tools/csql/exp.test060.ksh deleted file mode 100644 index fb33cfa5..00000000 --- a/test/tools/csql/exp.test060.ksh +++ /dev/null @@ -1,7 +0,0 @@ -Statement Executed -echo create index idx1 on t1(f1) unique; -Statement execute failed with error -4 -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT , f3 INT ); -CREATE INDEX t1_idx1_Primary on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -Statement Executed diff --git a/test/tools/csql/exp.test061.ksh b/test/tools/csql/exp.test061.ksh deleted file mode 100644 index 702f1dd8..00000000 --- a/test/tools/csql/exp.test061.ksh +++ /dev/null @@ -1,8 +0,0 @@ -Statement Executed -echo create index idx1 on t1(f1) tree unique; -Statement Executed -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT , f3 INT ); -CREATE INDEX t1_idx1_Primary on t1 ( f1 ) HASH UNIQUE; -CREATE INDEX idx1 on t1 ( f1 ) TREE UNIQUE; -SET AUTOCOMMIT OFF; -Statement Executed diff --git a/test/tools/csql/exp.test062.ksh b/test/tools/csql/exp.test062.ksh deleted file mode 100644 index fb812078..00000000 --- a/test/tools/csql/exp.test062.ksh +++ /dev/null @@ -1,9 +0,0 @@ -Statement Executed -echo create index idx1 on t1(f1) tree unique; -Statement Executed -echo create index idx2 on t1(f1) tree primary; -Statement execute failed with error -4 -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT , f3 INT ); -CREATE INDEX idx1 on t1 ( f1 ) TREE UNIQUE; -SET AUTOCOMMIT OFF; -Statement Executed diff --git a/test/tools/csql/exp.test063.ksh b/test/tools/csql/exp.test063.ksh deleted file mode 100644 index 79da150d..00000000 --- a/test/tools/csql/exp.test063.ksh +++ /dev/null @@ -1,11 +0,0 @@ -Statement Executed -echo create index idx1 on t1(f1) tree unique; -Statement Executed -echo drop index idx1; -Statement Executed -echo create index idx2 on t1(f1) tree primary; -Statement Executed -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT , f3 INT ); -CREATE INDEX idx2 on t1 ( f1 ) TREE UNIQUE; -SET AUTOCOMMIT OFF; -Statement Executed diff --git a/test/tools/csql/exp.test064.ksh b/test/tools/csql/exp.test064.ksh deleted file mode 100644 index 4d8fb1c3..00000000 --- a/test/tools/csql/exp.test064.ksh +++ /dev/null @@ -1,26 +0,0 @@ -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - -Statement Executed diff --git a/test/tools/csql/exp.test065.ksh b/test/tools/csql/exp.test065.ksh deleted file mode 100644 index bd2a902c..00000000 --- a/test/tools/csql/exp.test065.ksh +++ /dev/null @@ -1,25 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - -echo quit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -Statement Executed diff --git a/test/tools/csql/exp.test066.ksh b/test/tools/csql/exp.test066.ksh deleted file mode 100644 index 71d50924..00000000 --- a/test/tools/csql/exp.test066.ksh +++ /dev/null @@ -1,28 +0,0 @@ -echo set autocommit on; -AUTOCOMMIT Mode is set to ON -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - -echo quit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - -Statement Executed diff --git a/test/tools/csql/exp.test067.ksh b/test/tools/csql/exp.test067.ksh deleted file mode 100644 index bea62fed..00000000 --- a/test/tools/csql/exp.test067.ksh +++ /dev/null @@ -1,25 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -Statement Executed diff --git a/test/tools/csql/exp.test068.ksh b/test/tools/csql/exp.test068.ksh deleted file mode 100644 index b0d702e6..00000000 --- a/test/tools/csql/exp.test068.ksh +++ /dev/null @@ -1,28 +0,0 @@ -echo set autocommit on; -AUTOCOMMIT Mode is set to ON -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - -Statement Executed diff --git a/test/tools/csql/exp.test069.ksh b/test/tools/csql/exp.test069.ksh deleted file mode 100644 index 5a479b29..00000000 --- a/test/tools/csql/exp.test069.ksh +++ /dev/null @@ -1,28 +0,0 @@ -echo set autocommit on; -AUTOCOMMIT Mode is set to ON -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - -Statement Executed diff --git a/test/tools/csql/exp.test070.ksh b/test/tools/csql/exp.test070.ksh deleted file mode 100644 index 5c0709b4..00000000 --- a/test/tools/csql/exp.test070.ksh +++ /dev/null @@ -1,31 +0,0 @@ -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -echo update t1 set f2=3333, f3=4444 where f1>=100; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 3333 4444 - 1000 3333 4444 - -Statement Executed diff --git a/test/tools/csql/exp.test071.ksh b/test/tools/csql/exp.test071.ksh deleted file mode 100644 index 4a47d092..00000000 --- a/test/tools/csql/exp.test071.ksh +++ /dev/null @@ -1,30 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo commit; -echo insert into t1 values(10000,20000,30000); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100000,200000,300000); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - 10000 20000 30000 - 100000 200000 300000 - -Statement Executed diff --git a/test/tools/csql/exp.test072.ksh b/test/tools/csql/exp.test072.ksh deleted file mode 100644 index b65f4ce9..00000000 --- a/test/tools/csql/exp.test072.ksh +++ /dev/null @@ -1,39 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo commit; -echo insert into t1 values(10000,20000,30000); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100000,200000,300000); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - 10000 20000 30000 - 100000 200000 300000 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -Statement Executed diff --git a/test/tools/csql/exp.test073.ksh b/test/tools/csql/exp.test073.ksh deleted file mode 100644 index 9474dbd7..00000000 --- a/test/tools/csql/exp.test073.ksh +++ /dev/null @@ -1,35 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -echo update t1 set f2=0,f3=f1+f2+f3 where f1<=100 and f1 >1; -Statement Executed: Rows Affected = 2 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 0 60 - 100 0 600 - 1000 2000 3000 - -Statement Executed diff --git a/test/tools/csql/exp.test074.ksh b/test/tools/csql/exp.test074.ksh deleted file mode 100644 index fe99c082..00000000 --- a/test/tools/csql/exp.test074.ksh +++ /dev/null @@ -1,43 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -echo update t1 set f2=0,f3=f1*0 where f1<=100 and f1 >1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 0 0 - 100 0 0 - 1000 2000 3000 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -Statement Executed diff --git a/test/tools/csql/exp.test075.ksh b/test/tools/csql/exp.test075.ksh deleted file mode 100644 index d7dcac19..00000000 --- a/test/tools/csql/exp.test075.ksh +++ /dev/null @@ -1,44 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -echo update t1 set f2=0,f3=f1*0 where f1<=100 and f1 >1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 0 0 - 100 0 0 - 1000 2000 3000 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -Statement Executed diff --git a/test/tools/csql/exp.test076.ksh b/test/tools/csql/exp.test076.ksh deleted file mode 100644 index 4c551fad..00000000 --- a/test/tools/csql/exp.test076.ksh +++ /dev/null @@ -1,38 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -echo update t1 set f2=0,f3=f1*0 where f1<=100 and f1 >1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 0 0 - 100 0 0 - 1000 2000 3000 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -Statement Executed diff --git a/test/tools/csql/exp.test077.ksh b/test/tools/csql/exp.test077.ksh deleted file mode 100644 index 8a0105db..00000000 --- a/test/tools/csql/exp.test077.ksh +++ /dev/null @@ -1,39 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -echo delete from t1; -Statement Executed: Rows Affected = 4 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -Statement Executed diff --git a/test/tools/csql/exp.test078.ksh b/test/tools/csql/exp.test078.ksh deleted file mode 100644 index f96bf874..00000000 --- a/test/tools/csql/exp.test078.ksh +++ /dev/null @@ -1,31 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -echo delete from t1; -Statement Executed: Rows Affected = 4 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -Statement Executed diff --git a/test/tools/csql/exp.test079.ksh b/test/tools/csql/exp.test079.ksh deleted file mode 100644 index 3901a51f..00000000 --- a/test/tools/csql/exp.test079.ksh +++ /dev/null @@ -1,33 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -echo delete from t1 where f1<=100 and f1>1; -Statement Executed: Rows Affected = 2 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 1000 2000 3000 - -Statement Executed diff --git a/test/tools/csql/exp.test080.ksh b/test/tools/csql/exp.test080.ksh deleted file mode 100644 index 255471b5..00000000 --- a/test/tools/csql/exp.test080.ksh +++ /dev/null @@ -1,41 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -echo delete from t1 where f1<=100 and f1>1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 1000 2000 3000 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -Statement Executed diff --git a/test/tools/csql/exp.test081.ksh b/test/tools/csql/exp.test081.ksh deleted file mode 100644 index 54bb1cd6..00000000 --- a/test/tools/csql/exp.test081.ksh +++ /dev/null @@ -1,42 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -echo delete from t1 where f1<=100 and f1>1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 1000 2000 3000 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -Statement Executed diff --git a/test/tools/csql/exp.test082.ksh b/test/tools/csql/exp.test082.ksh deleted file mode 100644 index 652ec099..00000000 --- a/test/tools/csql/exp.test082.ksh +++ /dev/null @@ -1,36 +0,0 @@ -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(100,200,300); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1000,2000,3000); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 10 20 30 - 100 200 300 - 1000 2000 3000 - -echo delete from t1 where f1<=100 and f1>1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 1000 2000 3000 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -Statement Executed diff --git a/test/tools/csql/exp.test083.ksh b/test/tools/csql/exp.test083.ksh deleted file mode 100644 index 6afafe42..00000000 --- a/test/tools/csql/exp.test083.ksh +++ /dev/null @@ -1,43 +0,0 @@ -echo create table t1(f1 int,f2 char(10)); -Statement Executed -echo insert into t1 values(1,'x'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,'y'); -Statement Executed: Rows Affected = 1 -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo update t1 set f2='k' where f1=2; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 x - 2 k - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 x - 2 y - -echo insert into t1 values(3,'k'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(4,'p'); -Statement Executed: Rows Affected = 1 -echo commit; -echo insert into t1 values(5,'t'); -Statement Executed: Rows Affected = 1 -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 x - 2 y - 3 k - 4 p - -Statement Executed diff --git a/test/tools/csql/exp.test084.ksh b/test/tools/csql/exp.test084.ksh deleted file mode 100644 index dab6bcbd..00000000 --- a/test/tools/csql/exp.test084.ksh +++ /dev/null @@ -1,55 +0,0 @@ -echo create table t1(f1 int,f2 char(10)); -Statement Executed -echo insert into t1 values(1,'x'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,'y'); -Statement Executed: Rows Affected = 1 -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo delete from t1 where f1=1; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 2 y - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 x - 2 y - -echo commit; -echo insert into t1 values(3,'k'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(4,'p'); -Statement Executed: Rows Affected = 1 -echo create table t2(f1 int,f2 char(10)); -Statement Executed -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 x - 2 y - 3 k - 4 p - -echo delete from t1 where f1=1; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 x - 2 y - 3 k - 4 p - -Statement Executed -echo drop table t2; -Statement Executed diff --git a/test/tools/csql/exp.test085.ksh b/test/tools/csql/exp.test085.ksh deleted file mode 100644 index af3c72b8..00000000 --- a/test/tools/csql/exp.test085.ksh +++ /dev/null @@ -1,52 +0,0 @@ -echo create table t1(f1 int,f2 char(10)); -Statement Executed -echo insert into t1 values(1,'x'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,'y'); -Statement Executed: Rows Affected = 1 -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo delete from t1 where f1=1; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 2 y - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 x - 2 y - -echo commit; -echo insert into t1 values(3,'k'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(4,'p'); -Statement Executed: Rows Affected = 1 -echo create table t2(f1 int,f2 char(10)); -Statement Executed -echo delete from t1 where f1=1; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 2 y - 3 k - 4 p - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 x - 2 y - -Statement Executed -echo drop table t2; -Statement Executed diff --git a/test/tools/csql/exp.test086.ksh b/test/tools/csql/exp.test086.ksh deleted file mode 100644 index c885b672..00000000 --- a/test/tools/csql/exp.test086.ksh +++ /dev/null @@ -1,59 +0,0 @@ -echo create table t1(f1 int,f2 char(10)); -Statement Executed -echo insert into t1 values(1,'x'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,'y'); -Statement Executed: Rows Affected = 1 -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo delete from t1 where f1=1; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 2 y - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 x - 2 y - -echo commit; -echo update t1 set f2='X'; -Statement Executed: Rows Affected = 2 -echo insert into t1 values(3,'k'); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(4,'p'); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 X - 2 X - 3 k - 4 p - -echo update t1 set f2='Z'; -Statement Executed: Rows Affected = 4 -echo create table t2(f1 int,f2 char(10)); -Statement Executed -echo delete from t1 where f1=1; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 ---------------------------------------------------------- - 1 X - 2 X - 3 k - 4 p - -Statement Executed -echo drop table t2; -Statement Executed diff --git a/test/tools/csql/exp.test087.ksh b/test/tools/csql/exp.test087.ksh deleted file mode 100644 index 58e22499..00000000 --- a/test/tools/csql/exp.test087.ksh +++ /dev/null @@ -1,40 +0,0 @@ -echo create table t-1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t!1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t@1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t#1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t$1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t%1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t^1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t*1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t+1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t/1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t~1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t`1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table t[]1(f1 int,f2 int); -Statement prepare failed with error -19 -echo create table _t1(f1 int,f2 int); -Statement Executed -echo create table t1(f-1 int); -Statement prepare failed with error -19 -echo create table t1(f-1 int,f2 int); -Statement prepare failed with error -19 -echo create table t1(f1 int,f-2 int); -Statement prepare failed with error -19 -echo create table t_0_(f1_ int,f_2 int,f0_ int); -Statement Executed - - _t1 - t_0_ - diff --git a/test/tools/csql/exp.test088.ksh b/test/tools/csql/exp.test088.ksh deleted file mode 100644 index 4232cd1c..00000000 --- a/test/tools/csql/exp.test088.ksh +++ /dev/null @@ -1,193 +0,0 @@ -echo "<<<<<<<<<<<<<<<<<<<<<<<< UPDATE t1 SET f2=NULL >>>>>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,NULL,4); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,4,NULL); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(11,NULL,NULL); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 2 NULL 4 - 3 4 NULL - 10 20 30 - 11 NULL NULL - -echo update t1 set f2=NULL; -Statement Executed: Rows Affected = 5 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 NULL 3 - 2 NULL 4 - 3 NULL NULL - 10 NULL 30 - 11 NULL NULL - -echo drop table t1; -Statement Executed -echo "<<<<<<<<<<<<<<<<<<<<<<<< UPDATE t1 SET f1=NULL >>>>>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,NULL,4); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,4,NULL); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(11,NULL,NULL); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 2 NULL 4 - 3 4 NULL - 10 20 30 - 11 NULL NULL - -echo update t1 set f1=NULL; -Statement prepare failed with error -22 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 2 NULL 4 - 3 4 NULL - 10 20 30 - 11 NULL NULL - -echo drop table t1; -Statement Executed -echo "<<<<<<<<<<<<<<<<<<<<<< UPDATE t1 SET f1=f1+f2+f3 >>>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,NULL,4); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,4,NULL); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(11,NULL,NULL); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 2 NULL 4 - 3 4 NULL - 10 20 30 - 11 NULL NULL - -echo update t1 set f1=f1+f2+f3; -Statement execute failed with error -22 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 6 2 3 - 2 NULL 4 - 3 4 NULL - 10 20 30 - 11 NULL NULL - -echo drop table t1; -Statement Executed -echo "<<<<<<<<<<<<<<<<<< UPDATE t1 SET f2=0 WHERE f3>=1 >>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,NULL,4); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,4,NULL); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(11,NULL,NULL); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 2 NULL 4 - 3 4 NULL - 10 20 30 - 11 NULL NULL - -echo UPDATE t1 SET f2=0 where f3>=1; -Statement Executed: Rows Affected = 3 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 0 3 - 2 0 4 - 3 4 NULL - 10 0 30 - 11 NULL NULL - -echo drop table t1; -Statement Executed -echo "<<<<<<<<<<<<<<<<<<< DELETE FROM t1 WHERE f3>=4 >>>>>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,NULL,4); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,4,NULL); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(11,NULL,NULL); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 2 NULL 4 - 3 4 NULL - 10 20 30 - 11 NULL NULL - -echo DELETE FROM t1 WHERE f3>=4; -Statement Executed: Rows Affected = 2 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 3 4 NULL - 11 NULL NULL - -echo drop table t1; -Statement Executed diff --git a/test/tools/csql/exp.test089.ksh b/test/tools/csql/exp.test089.ksh deleted file mode 100644 index db3e3189..00000000 --- a/test/tools/csql/exp.test089.ksh +++ /dev/null @@ -1,39 +0,0 @@ -echo "<<<<<<<<<<<<<<<<<<<<<<<< UPDATE t1 SET f1=f1+NULL >>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,NULL,4); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,4,NULL); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10,20,30); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(11,NULL,NULL); -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 2 NULL 4 - 3 4 NULL - 10 20 30 - 11 NULL NULL - -echo update t1 set f1=f1+NULL; -Statement execute failed with error -22 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - 2 NULL 4 - 3 4 NULL - 10 20 30 - 11 NULL NULL - -echo drop table t1; -Statement Executed diff --git a/test/tools/csql/exp.test090.ksh b/test/tools/csql/exp.test090.ksh deleted file mode 100644 index 01928582..00000000 --- a/test/tools/csql/exp.test090.ksh +++ /dev/null @@ -1,170 +0,0 @@ -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo create index idx1 on t1(f1,f2) hash unique; -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1,2,4); -Statement execute failed with error -21 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - -echo drop table t1; -Statement Executed -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo create index idx2 on t1(f1,f2) tree unique; -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1,2,4); -Statement execute failed with error -21 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - -echo drop table t1; -Statement Executed -echo create table t1(f1 int not null,f2 int not null,f3 int); -Statement Executed -echo create index idx2 on t1(f1,f2) hash primary; -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1,2,4); -Statement execute failed with error -21 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - -echo drop table t1; -Statement Executed -echo create table t1(f1 int not null,f2 int not null,f3 int); -Statement Executed -echo create index idx2 on t1(f1,f2) tree primary; -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1,2,4); -Statement execute failed with error -21 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - -echo drop table t1; -Statement Executed -echo create table t1(f1 int not null,f2 int,f3 int,primary key(f1,f2)); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1,2,4); -Statement execute failed with error -21 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - -echo drop table t1; -Statement Executed -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo create index idx1 on t1(f1,f3) hash unique; -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1,4,3); -Statement execute failed with error -21 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - -echo drop table t1; -Statement Executed -echo create table t1(f1 int not null,f2 int,f3 int); -Statement Executed -echo create index idx2 on t1(f1,f3) tree unique; -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1,4,3); -Statement execute failed with error -21 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - -echo drop table t1; -Statement Executed -echo create table t1(f1 int not null,f2 int,f3 int not null); -Statement Executed -echo create index idx2 on t1(f1,f3) hash primary; -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1,4,3); -Statement execute failed with error -21 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - -echo drop table t1; -Statement Executed -echo create table t1(f1 int not null,f2 int,f3 int not null); -Statement Executed -echo create index idx2 on t1(f1,f3) tree primary; -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1,4,3); -Statement execute failed with error -21 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - -echo drop table t1; -Statement Executed -echo create table t1(f1 int not null,f2 int,f3 int,primary key(f1,f3)); -Statement Executed -echo insert into t1 values(1,2,3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1,4,3); -Statement execute failed with error -21 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 2 3 - -echo drop table t1; -Statement Executed -echo create table t1(f1 int,f2 int,f3 int,f4 int,primary key(f2,f4)); -Statement Executed -echo insert into t1 values(1,2,3,4); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(1,2,5,4); -Statement execute failed with error -21 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 t1.f4 ---------------------------------------------------------- - 1 2 3 4 - -echo drop table t1; -Statement Executed diff --git a/test/tools/csql/exp.test091.ksh b/test/tools/csql/exp.test091.ksh deleted file mode 100644 index 3f890b34..00000000 --- a/test/tools/csql/exp.test091.ksh +++ /dev/null @@ -1,1198 +0,0 @@ -echo create table t1(f1 int); -Statement Executed -echo create index idx1 on t1(f1); -Statement Executed -echo insert into t1 values(1); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(11); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 3 - 2 - 11 - 10 - -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo insert into t1 values(8); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 3 - 2 - 11 - 10 - 8 - 10 - -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 3 - 2 - 11 - 10 - 8 - 10 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 3 - 2 - 11 - 10 - 8 - 10 - -echo insert into t1 values(12); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(11); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 3 - 2 - 11 - 10 - 8 - 10 - 12 - 11 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 3 - 2 - 11 - 10 - 8 - 10 - -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 3 - 2 - 11 - 10 - 8 - 10 - -echo update t1 set f1=15 where f1=3; -Statement Executed: Rows Affected = 1 -echo update t1 set f1=11 where f1=2; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 15 - 11 - 11 - 10 - 8 - 10 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 3 - 2 - 11 - 10 - 8 - 10 - -echo select * from t1 where f1=3; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 3 - -echo update t1 set f1=30 where f1=3; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 30 - 2 - 11 - 10 - 8 - 10 - -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 30 - 2 - 11 - 10 - 8 - 10 - -echo delete from t1 where f1=30; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 2 - 11 - 10 - 8 - 10 - -echo delete from t1 where f1=3; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 2 - 11 - 10 - 8 - 10 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 30 - 2 - 11 - 10 - 8 - 10 - -echo delete from t1 where f1=30; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 2 - 11 - 10 - 8 - 10 - -echo delete from t1 where f1=3; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 2 - 11 - 10 - 8 - 10 - -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 1 - 2 - 11 - 10 - 8 - 10 - -echo delete from t1 where f1<=10; -Statement Executed: Rows Affected = 5 -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - 11 - -echo delete from t1; -Statement Executed: Rows Affected = 1 -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo quit; -echo create table t1(f1 int,f2 int,f3 int); -Statement Executed -echo create index idx1 on t1(f1,f2); -Statement Executed -echo insert into t1 values(1,10,100); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,33,333); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,33,444); -Statement Executed: Rows Affected = 1 -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo insert into t1 values(4,40,400); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,33,333); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - -echo insert into t1 values(4,40,400); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,33,333); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo update t1 set f1=20 where f1=2; -Statement Executed: Rows Affected = 1 -echo select * from t1 where f1=20; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 33 444 - -echo update t1 set f2=333 where f3=444; -Statement Executed: Rows Affected = 1 -echo select * from t1 where f3=444; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 333 444 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 20 333 444 - 4 40 400 - 3 33 333 - -echo update t1 set f1=1,f2=10 where f1=20; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - f1 f2 f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo rollback; -echo select * from t1 where f1=33; ---------------------------------------------------------- - t1f1 t1f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=2; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 2 33 444 - -echo select * from t1 where f1=2 and f2=33; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 2 33 444 - -echo update t1 set f1=20 where f1=2; -Statement Executed: Rows Affected = 1 -echo select * from t1 where f1=20; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 33 444 - -echo update t1 set f2=333 where f3=444; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 20 333 444 - 4 40 400 - 3 33 333 - -echo select * from t1 where f3=444; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 333 444 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 20 333 444 - 4 40 400 - 3 33 333 - -echo update t1 set f1=1,f2=10 where f1=20; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo commit; -echo select *from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo select * from t1 where f1=1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - -echo select * from t1 where f1=2; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=2 and f2=33; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo delete from t1 where f1=3 and f2=33; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - 4 40 400 - -echo delete from t1 where f1 in(1,5) and f2 in(50,10); -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 4 40 400 - -echo delete from t1 where f2 between 33 and 45; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo delete from t1; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo delete from t1 where f1=3 and f2=33; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - 4 40 400 - -echo delete from t1 where f1 in(1,5) and f2 in(50,10); -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 4 40 400 - -echo commit; -echo delete from t1 where f2 between 33 and 45; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo delete from t1; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo quit; -echo create table t1(f1 int,f2 int,f3 int); -Statement Executed -echo create index idx1 on t1(f1,f3); -Statement Executed -echo insert into t1 values(1,10,100); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,33,333); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,33,444); -Statement Executed: Rows Affected = 1 -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo insert into t1 values(4,40,400); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,33,333); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - -echo insert into t1 values(4,40,400); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,33,333); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo update t1 set f1=20 where f1=2; -Statement Executed: Rows Affected = 1 -echo select * from t1 where f1=20; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 33 444 - -echo update t1 set f2=333 where f3=444; -Statement Executed: Rows Affected = 1 -echo select * from t1 where f3=444; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 333 444 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 20 333 444 - 4 40 400 - 3 33 333 - -echo update t1 set f1=1,f2=10 where f1=20; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo rollback; -echo select * from t1 where f1=33; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=2; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 2 33 444 - -echo select * from t1 where f1=2 and f3=444; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 2 33 444 - -echo update t1 set f1=20 where f1=2; -Statement Executed: Rows Affected = 1 -echo select * from t1 where f1=20; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 33 444 - -echo update t1 set f2=333 where f3=444; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 20 333 444 - 4 40 400 - 3 33 333 - -echo select * from t1 where f3=444; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 333 444 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 20 333 444 - 4 40 400 - 3 33 333 - -echo update t1 set f1=1,f2=10 where f1=20; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo commit; -echo select *from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo select * from t1 where f1=1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - -echo select * from t1 where f1=2; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=2 and f3=444; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo delete from t1 where f1=3 and f3=333; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - 4 40 400 - -echo delete from t1 where f1 in(1,5) and f3 in(50,100); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 444 - 4 40 400 - -echo delete from t1 where f2 between 33 and 45; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 444 - -echo delete from t1; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo delete from t1 where f1=3 and f3=333; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - 4 40 400 - -echo delete from t1 where f1 in(1,5) and f3 in(50,100); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 444 - 4 40 400 - -echo commit; -echo delete from t1 where f2 between 33 and 45; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 444 - -echo delete from t1; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo quit; -echo create table t1(f1 int,f2 int,f3 int); -Statement Executed -echo create index idx1 on t1(f3,f2); -Statement Executed -echo insert into t1 values(1,10,100); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,33,333); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(2,33,444); -Statement Executed: Rows Affected = 1 -echo set autocommit off; -AUTOCOMMIT Mode is set to OFF -echo insert into t1 values(4,40,400); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,33,333); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - -echo insert into t1 values(4,40,400); -Statement Executed: Rows Affected = 1 -echo insert into t1 values(3,33,333); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo commit; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 2 33 444 - 4 40 400 - 3 33 333 - -echo update t1 set f1=20 where f1=2; -Statement Executed: Rows Affected = 1 -echo select * from t1 where f1=20; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 33 444 - -echo update t1 set f2=333 where f3=444; -Statement Executed: Rows Affected = 1 -echo select * from t1 where f3=444; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 333 444 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 20 333 444 - 4 40 400 - 3 33 333 - -echo update t1 set f1=1,f2=10 where f1=20; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo rollback; -echo select * from t1 where f1=33; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=2; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 2 33 444 - -echo select * from t1 where f1=2 and f2=33; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 2 33 444 - -echo update t1 set f1=20 where f1=2; -Statement Executed: Rows Affected = 1 -echo select * from t1 where f1=20; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 33 444 - -echo update t1 set f2=333 where f3=444; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 20 333 444 - 4 40 400 - 3 33 333 - -echo select * from t1 where f3=444; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 20 333 444 - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 20 333 444 - 4 40 400 - 3 33 333 - -echo update t1 set f1=1,f2=10 where f1=20; -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo commit; -echo select *from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo select * from t1 where f1=1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - -echo select * from t1 where f1=2; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1 where f1=2 and f2=33; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo delete from t1 where f3=333 and f2=33; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - 4 40 400 - -echo delete from t1 where f2 in(10,40) and f3 in(400,10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - -echo delete from t1 where f2 between 33 and 45; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - -echo delete from t1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo rollback; -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 3 33 333 - 1 10 444 - 4 40 400 - 3 33 333 - -echo delete from t1 where f3=333 and f2=33; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - 4 40 400 - -echo delete from t1 where f2 in(10,40) and f3 in(400,10); -Statement Executed: Rows Affected = 1 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - -echo commit; -echo delete from t1 where f2 between 33 and 45; -Statement Executed: Rows Affected = 0 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - 1 10 100 - 1 10 444 - -echo delete from t1; -Statement Executed: Rows Affected = 2 -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo select * from t1; ---------------------------------------------------------- - t1.f1 t1.f2 t1.f3 ---------------------------------------------------------- - -echo drop table t1; -Statement Executed -echo quit; diff --git a/test/tools/csql/expresion.sql b/test/tools/csql/expresion.sql deleted file mode 100644 index 1a938288..00000000 --- a/test/tools/csql/expresion.sql +++ /dev/null @@ -1,51 +0,0 @@ -echo create table t1 (f1 int, f2 int,f3 int); -create table t1 (f1 int, f2 int,f3 int); -echo insert into t1 values(10,10,10); -insert into t1 values(10,10,10); -echo insert into t1 values(20,10,10); -insert into t1 values(20,10,10); -echo insert into t1 values(30,10,10); -insert into t1 values(30,10,10); -echo insert into t1 values(40,10,10); -insert into t1 values(40,10,10); -echo insert into t1 values(50,10,10); -insert into t1 values(50,10,10); -echo insert into t1 values(60,10,10); -insert into t1 values(60,10,10); -echo select * from t1; -select * from t1; -echo update t1 set f1=f1+f2+f3+7,f2=f3+23+f1,f3=12; -update t1 set f1=f1+f2+f3+7,f2=f3+23+f1,f3=12; -echo select * from t1; -select * from t1; -echo update t1 set f1=f2/f3+7,f2=f3+23+f1,f3=f2 where f3=12; -update t1 set f1=f2/f3+7,f2=f3+23+f1,f3=f2 where f3=12; -echo select * from t1; -select * from t1; -echo create table t2 (f1 tinyint, f2 bigint,f3 int); -create table t2 (f1 tinyint, f2 bigint,f3 int); -echo insert into t2 values(60,1110,5110); -insert into t2 values(60,1110,5110); -echo insert into t2 values(70,1115,1510); -insert into t2 values(70,1115,1510); -echo insert into t2 values(80,1150,1150); -insert into t2 values(80,1150,1150); -echo insert into t2 values(90,1510,1115); -insert into t2 values(90,1510,1115); -echo insert into t2 values(50,5110,1110); -insert into t2 values(50,5110,1110); -echo select * from t2; -select * from t2; -echo update t2 set f1=NULL,f2=f1+f2+f3+10 where f2>1122; -update t2 set f1=NULL,f2=f1+f2+f3+10 where f2>1122; -echo select * from t2; -select * from t2; -echo update t2 set f2=f2+123 ,f3=23+f2; -update t2 set f2=f2+123 ,f3=23+f2; -echo select * from t2; -select * from t2; -echo drop table t1; -drop table t1; -echo drop table t2; -drop table t2; - diff --git a/test/tools/csql/fieldlimit.sql b/test/tools/csql/fieldlimit.sql deleted file mode 100644 index 5c4d50b9..00000000 --- a/test/tools/csql/fieldlimit.sql +++ /dev/null @@ -1,221 +0,0 @@ -CREATE TABLE t1 ( -C1 INT, C2 INT, C3 INT, C4 INT, C5 INT, C6 INT, -C7 INT, C8 INT, C9 INT, C10 INT, C11 INT, C12 INT, -C13 INT, C14 INT, C15 INT, C16 INT, C17 INT, C18 INT, -C19 INT, C20 INT, C21 INT, C22 INT, C23 INT, C24 INT, -C25 INT, C26 INT, C27 INT, C28 INT, C29 INT, C30 INT, -C31 INT, C32 INT, C33 INT, C34 INT, C35 INT, C36 INT, -C37 INT, C38 INT, C39 INT, C40 INT, C41 INT, C42 INT, -C43 INT, C44 INT, C45 INT, C46 INT, C47 INT, C48 INT, -C49 INT, C50 INT, C51 INT, C52 INT, C53 INT, C54 INT, -C55 INT, C56 INT, C57 INT, C58 INT, C59 INT, C60 INT, -C61 INT, C62 INT, C63 INT, C64 INT, C65 INT, C66 INT, -C67 INT, C68 INT, C69 INT, C70 INT, C71 INT, C72 INT, -C73 INT, C74 INT, C75 INT, C76 INT, C77 INT, C78 INT, -C79 INT, C80 INT, C81 INT, C82 INT, C83 INT, C84 INT, -C85 INT, C86 INT, C87 INT, C88 INT, C89 INT, C90 INT, -C91 INT, C92 INT, C93 INT, C94 INT, C95 INT, C96 INT, -C97 INT, C98 INT, C99 INT, C100 INT, C101 INT, C102 INT, -C103 INT, C104 INT, C105 INT, C106 INT, C107 INT, C108 INT, -C109 INT, C110 INT, C111 INT, C112 INT, C113 INT, C114 INT, -C115 INT, C116 INT, C117 INT, C118 INT, C119 INT, C120 INT, -C121 INT, C122 INT, C123 INT, C124 INT, C125 INT, C126 INT, -C127 INT, C128 INT, C129 INT, C130 INT, C131 INT, C132 INT, -C133 INT, C134 INT, C135 INT, C136 INT, C137 INT, C138 INT, -C139 INT, C140 INT, C141 INT, C142 INT, C143 INT, C144 INT, -C145 INT, C146 INT, C147 INT, C148 INT, C149 INT, C150 INT, -C151 INT, C152 INT, C153 INT, C154 INT, C155 INT, C156 INT, -C157 INT, C158 INT, C159 INT, C160 INT, C161 INT, C162 INT, -C163 INT, C164 INT, C165 INT, C166 INT, C167 INT, C168 INT, -C169 INT, C170 INT, C171 INT, C172 INT, C173 INT, C174 INT, -C175 INT, C176 INT, C177 INT, C178 INT, C179 INT, C180 INT, -C181 INT, C182 INT, C183 INT, C184 INT, C185 INT, C186 INT, -C187 INT, C188 INT, C189 INT, C190 INT, C191 INT, C192 INT, -C193 INT, C194 INT, C195 INT, C196 INT, C197 INT, C198 INT, -C199 INT, C200 INT, C201 INT, C202 INT, C203 INT, C204 INT, -C205 INT, C206 INT, C207 INT, C208 INT, C209 INT, C210 INT, -C211 INT, C212 INT, C213 INT, C214 INT, C215 INT, C216 INT, -C217 INT, C218 INT, C219 INT, C220 INT, C221 INT, C222 INT, -C223 INT, C224 INT, C225 INT, C226 INT, C227 INT, C228 INT, -C229 INT, C230 INT, C231 INT, C232 INT, C233 INT, C234 INT, -C235 INT, C236 INT, C237 INT, C238 INT, C239 INT, C240 INT, -C241 INT, C242 INT, C243 INT, C244 INT, C245 INT, C246 INT, -C247 INT, C248 INT, C249 INT, C250 INT); - -INSERT INTO t1 VALUES ( -1, 2, 3, 4, 5, 6, -7, 8, 9, 10, 11, 12, -13, 14, 15, 16, 17, 18, -19, 20, 21, 22, 23, 24, -25, 26, 27, 28, 29, 30, -31, 32, 33, 34, 35, 36, -37, 38, 39, 40, 41, 42, -43, 44, 45, 46, 47, 48, -49, 50, 51, 52, 53, 54, -55, 56, 57, 58, 59, 60, -61, 62, 63, 64, 65, 66, -67, 68, 69, 70, 71, 72, -73, 74, 75, 76, 77, 78, -79, 80, 81, 82, 83, 84, -85, 86, 87, 88, 89, 90, -91, 92, 93, 94, 95, 96, -97, 98, 99, 100, 101, 102, -103, 104, 105, 106, 107, 108, -109, 110, 111, 112, 113, 114, -115, 116, 117, 118, 119, 120, -121, 122, 123, 124, 125, 126, -127, 128, 129, 130, 131, 132, -133, 134, 135, 136, 137, 138, -139, 140, 141, 142, 143, 144, -145, 146, 147, 148, 149, 150, -151, 152, 153, 154, 155, 156, -157, 158, 159, 160, 161, 162, -163, 164, 165, 166, 167, 168, -169, 170, 171, 172, 173, 174, -175, 176, 177, 178, 179, 180, -181, 182, 183, 184, 185, 186, -187, 188, 189, 190, 191, 192, -193, 194, 195, 196, 197, 198, -199, 200, 201, 202, 203, 204, -205, 206, 207, 208, 209, 210, -211, 212, 213, 214, 215, 216, -217, 218, 219, 220, 221, 222, -223, 224, 225, 226, 227, 228, -229, 230, 231, 232, 233, 234, -235, 236, 237, 238, 239, 240, -241, 242, 243, 244, 245, 246, -247, 248, 249, 250); - -UPDATE t1 SET -C1 = C1 + 1, C2 = C2 + 1, C3 = C3 + 1, -C4 = C4 + 1, C5 = C5 + 1, C6 = C6 + 1, -C7 = C7 + 1, C8 = C8 + 1, C9 = C9 + 1, -C10 = C10 + 1, C11 = C11 + 1, C12 = C12 + 1, -C13 = C13 + 1, C14 = C14 + 1, C15 = C15 + 1, -C16 = C16 + 1, C17 = C17 + 1, C18 = C18 + 1, -C19 = C19 + 1, C20 = C20 + 1, C21 = C21 + 1, -C22 = C22 + 1, C23 = C23 + 1, C24 = C24 + 1, -C25 = C25 + 1, C26 = C26 + 1, C27 = C27 + 1, -C28 = C28 + 1, C29 = C29 + 1, C30 = C30 + 1, -C31 = C31 + 1, C32 = C32 + 1, C33 = C33 + 1, -C34 = C34 + 1, C35 = C35 + 1, C36 = C36 + 1, -C37 = C37 + 1, C38 = C38 + 1, C39 = C39 + 1, -C40 = C40 + 1, C41 = C41 + 1, C42 = C42 + 1, -C43 = C43 + 1, C44 = C44 + 1, C45 = C45 + 1, -C46 = C46 + 1, C47 = C47 + 1, C48 = C48 + 1, -C49 = C49 + 1, C50 = C50 + 1, C51 = C51 + 1, -C52 = C52 + 1, C53 = C53 + 1, C54 = C54 + 1, -C55 = C55 + 1, C56 = C56 + 1, C57 = C57 + 1, -C58 = C58 + 1, C59 = C59 + 1, C60 = C60 + 1, -C61 = C61 + 1, C62 = C62 + 1, C63 = C63 + 1, -C64 = C64 + 1, C65 = C65 + 1, C66 = C66 + 1, -C67 = C67 + 1, C68 = C68 + 1, C69 = C69 + 1, -C70 = C70 + 1, C71 = C71 + 1, C72 = C72 + 1, -C73 = C73 + 1, C74 = C74 + 1, C75 = C75 + 1, -C76 = C76 + 1, C77 = C77 + 1, C78 = C78 + 1, -C79 = C79 + 1, C80 = C80 + 1, C81 = C81 + 1, -C82 = C82 + 1, C83 = C83 + 1, C84 = C84 + 1, -C85 = C85 + 1, C86 = C86 + 1, C87 = C87 + 1, -C88 = C88 + 1, C89 = C89 + 1, C90 = C90 + 1, -C91 = C91 + 1, C92 = C92 + 1, C93 = C93 + 1, -C94 = C94 + 1, C95 = C95 + 1, C96 = C96 + 1, -C97 = C97 + 1, C98 = C98 + 1, C99 = C99 + 1, -C100 = C100 + 1, C101 = C101 + 1, C102 = C102 + 1, -C103 = C103 + 1, C104 = C104 + 1, C105 = C105 + 1, -C106 = C106 + 1, C107 = C107 + 1, C108 = C108 + 1, -C109 = C109 + 1, C110 = C110 + 1, C111 = C111 +1, -C112 = C112 +1, C113 = C113 +1, C114 = C114 +1, -C115 = C115 +1, C116 = C116 +1, C117 = C117 +1, -C118 = C118 +1, C119 = C119 +1, C120 = C120 +1, -C121 = C121 +1, C122 = C122 +1, C123 = C123 +1, -C124 = C124 +1, C125 = C125 +1, C126 = C126 +1, -C127 = C127 +1, C128 = C128 +1, C129 = C129 +1, -C130 = C130 +1, C131 = C131 +1, C132 = C132 +1, -C133 = C133 +1, C134 = C134 +1, C135 = C135 +1, -C136 = C136 +1, C137 = C137 +1, C138 = C138 +1, -C139 = C139 +1, C140 = C140 +1, C141 = C141 +1, -C142 = C142 +1, C143 = C143 +1, C144 = C144 +1, -C145 = C145 +1, C146 = C146 +1, C147 = C147 +1, -C148 = C148 +1, C149 = C149 +1, C150 = C150 +1, -C151 = C151 +1, C152 = C152 +1, C153 = C153 +1, -C154 = C154 +1, C155 = C155 +1, C156 = C156 +1, -C157 = C157 +1, C158 = C158 +1, C159 = C159 +1, -C160 = C160 +1, C161 = C161 +1, C162 = C162 +1, -C163 = C163 +1, C164 = C164 +1, C165 = C165 +1, -C166 = C166 +1, C167 = C167 +1, C168 = C168 +1, -C169 = C169 +1, C170 = C170 +1, C171 = C171 +1, -C172 = C172 +1, C173 = C173 +1, C174 = C174 +1, -C175 = C175 +1, C176 = C176 +1, C177 = C177 +1, -C178 = C178 +1, C179 = C179 +1, C180 = C180 +1, -C181 = C181 +1, C182 = C182 +1, C183 = C183 +1, -C184 = C184 +1, C185 = C185 +1, C186 = C186 +1, -C187 = C187 +1, C188 = C188 +1, C189 = C189 +1, -C190 = C190 +1, C191 = C191 +1, C192 = C192 +1, -C193 = C193 +1, C194 = C194 +1, C195 = C195 +1, -C196 = C196 +1, C197 = C197 +1, C198 = C198 +1, -C199 = C199 +1, C200 = C200 +1, C201 = C201 +1, -C202 = C202 +1, C203 = C203 +1, C204 = C204 +1, -C205 = C205 +1, C206 = C206 +1, C207 = C207 +1, -C208 = C208 +1, C209 = C209 +1, C210 = C210 +1, -C211 = C211 +1, C212 = C212 +1, C213 = C213 +1, -C214 = C214 +1, C215 = C215 +1, C216 = C216 +1, -C217 = C217 +1, C218 = C218 +1, C219 = C219 +1, -C220 = C220 +1, C221 = C221 +1, C222 = C222 +1, -C223 = C223 +1, C224 = C224 +1, C225 = C225 +1, -C226 = C226 +1, C227 = C227 +1, C228 = C228 +1, -C229 = C229 +1, C230 = C230 +1, C231 = C231 +1, -C232 = C232 +1, C233 = C233 +1, C234 = C234 +1, -C235 = C235 +1, C236 = C236 +1, C237 = C237 +1, -C238 = C238 +1, C239 = C239 +1, C240 = C240 +1, -C241 = C241 +1, C242 = C242 +1, C243 = C243 +1, -C244 = C244 +1, C245 = C245 +1, C246 = C246 +1, -C247 = C247 +1, C248 = C248 +1, C249 = C249 +1, -C250 = C250 +1; - - -SELECT -C1, C2, C3, C4, C5, C6, -C7, C8, C9, C10, C11, C12, -C13, C14, C15, C16, C17, C18, -C19, C20, C21, C22, C23, C24, -C25, C26, C27, C28, C29, C30, -C31, C32, C33, C34, C35, C36, -C37, C38, C39, C40, C41, C42, -C43, C44, C45, C46, C47, C48, -C49, C50, C51, C52, C53, C54, -C55, C56, C57, C58, C59, C60, -C61, C62, C63, C64, C65, C66, -C67, C68, C69, C70, C71, C72, -C73, C74, C75, C76, C77, C78, -C79, C80, C81, C82, C83, C84, -C85, C86, C87, C88, C89, C90, -C91, C92, C93, C94, C95, C96, -C97, C98, C99, C100, C101, C102, -C103, C104, C105, C106, C107, C108, -C109, C110, C111, C112, C113, C114, -C115, C116, C117, C118, C119, C120, -C121, C122, C123, C124, C125, C126, -C127, C128, C129, C130, C131, C132, -C133, C134, C135, C136, C137, C138, -C139, C140, C141, C142, C143, C144, -C145, C146, C147, C148, C149, C150, -C151, C152, C153, C154, C155, C156, -C157, C158, C159, C160, C161, C162, -C163, C164, C165, C166, C167, C168, -C169, C170, C171, C172, C173, C174, -C175, C176, C177, C178, C179, C180, -C181, C182, C183, C184, C185, C186, -C187, C188, C189, C190, C191, C192, -C193, C194, C195, C196, C197, C198, -C199, C200, C201, C202, C203, C204, -C205, C206, C207, C208, C209, C210, -C211, C212, C213, C214, C215, C216, -C217, C218, C219, C220, C221, C222, -C223, C224, C225, C226, C227, C228, -C229, C230, C231, C232, C233, C234, -C235, C236, C237, C238, C239, C240, -C241, C242, C243, C244, C245, C246, -C247, C248, C249, C250 -FROM t1; - -echo TODO for select with 100 predicates with 100 projection field names specified diff --git a/test/tools/csql/indexontuples.sql b/test/tools/csql/indexontuples.sql deleted file mode 100644 index 70421533..00000000 --- a/test/tools/csql/indexontuples.sql +++ /dev/null @@ -1,441 +0,0 @@ -echo "----------Table having single field f1 and index on t1(f1)--------------"; -echo create table t1(f1 int); -create table t1(f1 int); -echo create index idx1 on t1(f1); -create index idx1 on t1(f1); -echo insert into t1 values(10); -insert into t1 values(10); -echo insert into t1 values(21); -insert into t1 values(21); -echo insert into t1 values(32); -insert into t1 values(32); -echo insert into t1 values(123); -insert into t1 values(123); -echo insert into t1 values(-2147483648); -insert into t1 values(-2147483648); -echo insert into t1 values(2147483647); -insert into t1 values(2147483647); -echo select * from t1 where f1>-5; -select * from t1 where f1>-5; -echo select * from t1 where f1<-10; -select * from t1 where f1<-10; -echo select f1 from t1 where f1 in (10,30,123); -select f1 from t1 where f1 in (10,30,123); -echo select * from t1; -select * from t1; -echo update t1 set f1=25 where f1=21; -update t1 set f1=25 where f1=21; -echo select * from t1; -select * from t1; -echo update t1 set f1=1010101 where f1 in(32,10,40); -update t1 set f1=1010101 where f1 in(32,10,40); -echo select * from t1; -select * from t1; -echo update t1 set f1=987654 where f1 between 25 and 200; -update t1 set f1=987654 where f1 between 25 and 200; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=2147483647; -delete from t1 where f1=2147483647; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 between 25 and 6000000; -delete from t1 where f1 between 25 and 6000000; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo "-----Table having two fields f1 int,f2 int and index on t1(f1)-----"; -echo create table t1(f1 int,f2 int); -create table t1(f1 int,f2 int); -echo create index idx1 on t1(f1); -create index idx1 on t1(f1); -echo insert into t1 values(10,2147483647); -insert into t1 values(10,2147483647); -echo insert into t1 values(21,-2147483648); -insert into t1 values(21,-2147483648); -echo insert into t1 values(32,1000000000); -insert into t1 values(32,1000000000); -echo insert into t1 values(123,999999999); -insert into t1 values(123,999999999); -echo insert into t1 values(-2147483648,0); -insert into t1 values(-2147483648,0); -echo insert into t1 values(2147483647,-2147483648); -insert into t1 values(2147483647,-2147483648); -echo insert into t1 values(123,9); -insert into t1 values(123,9); -echo select * from t1; -select * from t1; -echo select * from t1 where f1>-5; -select * from t1 where f1>-5; -echo select * from t1 where f1<-10; -select * from t1 where f1<-10; -echo select f1 from t1 where f1 in (10,30,123); -select f1 from t1 where f1 in (10,30,123); -echo select * from t1; -select * from t1; -echo update t1 set f1=25 where f1=21; -update t1 set f1=25 where f1=21; -echo select * from t1; -select * from t1; -echo update t1 set f1=21 where f1=25 and f2=-2147483648; -update t1 set f1=21 where f1=25 and f2=-2147483648; -echo select * from t1; -select * from t1; -echo update t1 set f1=1010101 where f1 in(32,10,40); -update t1 set f1=1010101 where f1 in(32,10,40); -echo select * from t1; -select * from t1; -echo update t1 set f1=7777 where f1=1010101 and f2 in(1000000000,999999999); -update t1 set f1=7777 where f1=1010101 and f2 in(1000000000,999999999); -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f2 in(1000000000,999999999) and f1>=7777; -update t1 set f1=2020202 where f2 in(1000000000,999999999) and f1>=7777; -echo select * from t1; -select * from t1; -echo update t1 set f1=987654 where f1 between 25 and 200; -update t1 set f1=987654 where f1 between 25 and 200; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=2147483647; -delete from t1 where f1=2147483647; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 between 25 and 6000000; -delete from t1 where f1 between 25 and 6000000; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo "--Table having 5 fields f1,f2,f3,f4,f5(all int) index on t1(f1,f2)--"; -echo create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -echo create index idx1 on t1(f1,f2); -create index idx1 on t1(f1,f2); -echo insert into t1 values(11,222,3333,44444,555555); -insert into t1 values(11,222,3333,44444,555555); -echo insert into t1 values(12,123,1234,12345,123456); -insert into t1 values(12,123,1234,12345,123456); -echo insert into t1 values(234,4567,56789,1234,4321); -insert into t1 values(234,4567,56789,1234,4321); -echo insert into t1 values(-2147483647,1,101,212,2147483647); -insert into t1 values(-2147483647,1,101,212,2147483647); -echo insert into t1 values(101,12121,0,32123,78987); -insert into t1 values(101,12121,0,32123,78987); -echo insert into t1 values(12,123,1000,1111,1); -insert into t1 values(12,123,1000,1111,1); -echo select * from t1; -select * from t1; -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -echo select * from t1 where f1<-1 and f2>=1 or f3=101; -select * from t1 where f1<-1 and f2>=1 or f3=101; -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; -select * from t1 where f1<-1 and f2>=1 or f3=1234; -echo select * from t1; -select * from t1; -echo update t1 set f1=22 where f1=11; -update t1 set f1=22 where f1=11; -echo select * from t1; -select * from t1; -echo update t1 set f1=11 where f1=22 and f2=222; -update t1 set f1=11 where f1=22 and f2=222; -echo select * from t1; -select * from t1; -echo update t1 set f1=10 where f1 in(234,10); -update t1 set f1=10 where f1 in(234,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=100 where f1 in(12,10); -update t1 set f2=100 where f1 in(12,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=101,f2=12121 where f3=0; -update t1 set f2=101,f2=12121 where f3=0; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -echo select * from t1; -select * from t1; -echo update t1 set f1=987654 where f1 between 25 and 200; -update t1 set f1=987654 where f1 between 25 and 200; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=2147483647; -delete from t1 where f1=2147483647; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 between 25 and 6000000; -delete from t1 where f1 between 25 and 6000000; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo "--Table having 5 fields f1,f2,f3,f4,f5(all int) index on t1(f1,f3)--"; -echo create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -echo create index idx1 on t1(f1,f3); -create index idx1 on t1(f1,f3); -echo insert into t1 values(11,222,3333,44444,555555); -insert into t1 values(11,222,3333,44444,555555); -echo insert into t1 values(12,123,1234,12345,123456); -insert into t1 values(12,123,1234,12345,123456); -echo insert into t1 values(234,4567,56789,1234,4321); -insert into t1 values(234,4567,56789,1234,4321); -echo insert into t1 values(-2147483648,1,101,212,2147483647); -insert into t1 values(-2147483648,1,101,212,2147483647); -echo insert into t1 values(101,12121,0,32123,78987); -insert into t1 values(101,12121,0,32123,78987); -echo insert into t1 values(12,100,1234,1111,1); -insert into t1 values(12,100,1234,1111,1); -echo select * from t1; -select * from t1; -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -echo select * from t1 where f1<-1 and f2>=1 or f3=101; -select * from t1 where f1<-1 and f2>=1 or f3=101; -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; -select * from t1 where f1<-1 and f2>=1 or f3=1234; -echo select * from t1; -select * from t1; -echo update t1 set f1=22 where f1=11; -update t1 set f1=22 where f1=11; -echo select * from t1; -select * from t1; -echo update t1 set f1=11 where f1=22 and f2=222; -update t1 set f1=11 where f1=22 and f2=222; -echo select * from t1; -select * from t1; -echo update t1 set f1=10 where f1 in(234,10); -update t1 set f1=10 where f1 in(234,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=100 where f1 in(12,10); -update t1 set f2=100 where f1 in(12,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=101,f2=12121 where f3=0; -update t1 set f2=101,f2=12121 where f3=0; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -echo select * from t1; -select * from t1; -echo update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=-2147483648 or f3=1234; -delete from t1 where f1=-2147483648 or f3=1234; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 between 25 and 6000000; -delete from t1 where f1 between 25 and 6000000; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - - -echo "--Table having 5 fields f1,f2,f3,f4,f5(all int) index on t1(f1,f3,f2)--"; -echo create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -echo create index idx1 on t1(f1,f3,f2); -create index idx1 on t1(f1,f3,f2); -echo insert into t1 values(11,222,3333,44444,555555); -insert into t1 values(11,222,3333,44444,555555); -echo insert into t1 values(12,123,1234,12345,123456); -insert into t1 values(12,123,1234,12345,123456); -echo insert into t1 values(234,4567,56789,1234,4321); -insert into t1 values(234,4567,56789,1234,4321); -echo insert into t1 values(-2147483648,1,101,212,2147483647); -insert into t1 values(-2147483648,1,101,212,2147483647); -echo insert into t1 values(101,12121,0,32123,78987); -insert into t1 values(101,12121,0,32123,78987); -echo insert into t1 values(12,123,1234,1111,1); -insert into t1 values(12,123,1234,1111,1); -echo select * from t1; -select * from t1; -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -echo select * from t1 where f1<-1 and f2>=1 or f3=101; -select * from t1 where f1<-1 and f2>=1 or f3=101; -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; -select * from t1 where f1<-1 and f2>=1 or f3=1234; -echo select * from t1; -select * from t1; -echo update t1 set f1=22 where f1=11; -update t1 set f1=22 where f1=11; -echo select * from t1; -select * from t1; -echo update t1 set f1=11 where f1=22 and f2=222; -update t1 set f1=11 where f1=22 and f2=222; -echo select * from t1; -select * from t1; -echo update t1 set f1=10 where f1 in(234,10); -update t1 set f1=10 where f1 in(234,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=100 where f1 in(12,10); -update t1 set f2=100 where f1 in(12,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=101,f2=12121 where f3=0; -update t1 set f2=101,f2=12121 where f3=0; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=1 and f3=101; -update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=1 and f3=101; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -echo select * from t1; -select * from t1; -echo update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -update t1 set f1=987654 where f1 between 25 and 200 and f3>=4000; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=-2147483648 or f3=1234; -delete from t1 where f1=-2147483648 or f3=1234; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 between 25 and 6000000; -delete from t1 where f1 between 25 and 6000000; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - -echo "--Table having 5 fields f1,f2,f3,f4,f5(all int) index on t1(f5,f1,f3,f2)--"; -echo create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -create table t1(f1 int,f2 int,f3 int,f4 int,f5 int); -echo create index idx1 on t1(f5,f1,f3,f2); -create index idx1 on t1(f5,f1,f3,f2); -echo insert into t1 values(11,222,3333,44444,555555); -insert into t1 values(11,222,3333,44444,555555); -echo insert into t1 values(12,123,1234,12345,123456); -insert into t1 values(12,123,1234,12345,123456); -echo insert into t1 values(234,4567,56789,1234,4321); -insert into t1 values(234,4567,56789,1234,4321); -echo insert into t1 values(-2147483648,1,101,212,2147483647); -insert into t1 values(-2147483648,1,101,212,2147483647); -echo insert into t1 values(101,12121,0,32123,78987); -insert into t1 values(101,12121,0,32123,78987); -echo insert into t1 values(12,123,1234,1111,1); -insert into t1 values(12,123,1234,1111,1); -echo select * from t1; -select * from t1; -echo select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -select * from t1 where f1>0 and f2<=222 and f3=3333 and f4>44443 and f5!=555550; -echo select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -select f1,f3,f5 from t1 where f1=234 or f5>4000 or f3>=50000; -echo select * from t1 where f1<-1 and f2>=1 or f3=101; -select * from t1 where f1<-1 and f2>=1 or f3=101; -echo select * from t1 where f1<-1 and f2>=1 or f3=1234; -select * from t1 where f1<-1 and f2>=1 or f3=1234; -echo select * from t1; -select * from t1; -echo update t1 set f1=22 where f1=11; -update t1 set f1=22 where f1=11; -echo select * from t1; -select * from t1; -echo update t1 set f1=11 where f1=22 and f2=222; -update t1 set f1=11 where f1=22 and f2=222; -echo select * from t1; -select * from t1; -echo update t1 set f1=10 where f1 in(234,10); -update t1 set f1=10 where f1 in(234,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=100 where f1 in(12,10); -update t1 set f2=100 where f1 in(12,10); -echo select * from t1; -select * from t1; -echo update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -update t1 set f2=222 where f3=56789 and f2 in(100,4567) and f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -update t1 set f2=5 where f3=56789 or f2 in(123,222) or f4 between 100 and 20000; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=1 and f3=101; -update t1 set f1=2020202 where f1 in(-2147483647,2147483647) and f2=1 and f3=101; -echo select * from t1; -select * from t1; -echo update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -update t1 set f1=2020202 where f1 in(-2147483647,2147483647) or f1>=7777; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=-2147483648 or f3=1234; -delete from t1 where f1=-2147483648 or f3=1234; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 between 25 and 6000000; -delete from t1 where f1 between 25 and 6000000; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - diff --git a/test/tools/csql/indextran1.sql b/test/tools/csql/indextran1.sql deleted file mode 100644 index e8781256..00000000 --- a/test/tools/csql/indextran1.sql +++ /dev/null @@ -1,104 +0,0 @@ -echo create table t1(f1 int); -create table t1(f1 int); -echo create index idx1 on t1(f1); -create index idx1 on t1(f1); -echo insert into t1 values(1); -insert into t1 values(1); -echo insert into t1 values(3); -insert into t1 values(3); -echo insert into t1 values(2); -insert into t1 values(2); -echo insert into t1 values(11); -insert into t1 values(11); -echo insert into t1 values(10); -insert into t1 values(10); -echo select * from t1; -select * from t1; -echo set autocommit off; -set autocommit off; -echo insert into t1 values(8); -insert into t1 values(8); -echo insert into t1 values(10); -insert into t1 values(10); -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo insert into t1 values(12); -insert into t1 values(12); -echo insert into t1 values(11); -insert into t1 values(11); -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo update t1 set f1=15 where f1=3; -update t1 set f1=15 where f1=3; -echo update t1 set f1=11 where f1=2; -update t1 set f1=11 where f1=2; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo select * from t1 where f1=3; -select * from t1 where f1=3; -echo update t1 set f1=30 where f1=3; -update t1 set f1=30 where f1=3; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=30; -delete from t1 where f1=30; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=3; -delete from t1 where f1=3; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=30; -delete from t1 where f1=30; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=3; -delete from t1 where f1=3; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo delete from t1 where f1<=10; -delete from t1 where f1<=10; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; -echo quit; -quit; diff --git a/test/tools/csql/indextran2.sql b/test/tools/csql/indextran2.sql deleted file mode 100644 index b40c2236..00000000 --- a/test/tools/csql/indextran2.sql +++ /dev/null @@ -1,135 +0,0 @@ -echo create table t1(f1 int,f2 int,f3 int); -create table t1(f1 int,f2 int,f3 int); -echo create index idx1 on t1(f1,f2); -create index idx1 on t1(f1,f2); -echo insert into t1 values(1,10,100); -insert into t1 values(1,10,100); -echo insert into t1 values(3,33,333); -insert into t1 values(3,33,333); -echo insert into t1 values(2,33,444); -insert into t1 values(2,33,444); -echo set autocommit off; -set autocommit off; -echo insert into t1 values(4,40,400); -insert into t1 values(4,40,400); -echo insert into t1 values(3,33,333); -insert into t1 values(3,33,333); -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo insert into t1 values(4,40,400); -insert into t1 values(4,40,400); -echo insert into t1 values(3,33,333); -insert into t1 values(3,33,333); -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo update t1 set f1=20 where f1=2; -update t1 set f1=20 where f1=2; -echo select * from t1 where f1=20; -select * from t1 where f1=20; -echo update t1 set f2=333 where f3=444; -update t1 set f2=333 where f3=444; -echo select * from t1 where f3=444; -select * from t1 where f3=444; -echo select * from t1; -select * from t1; -echo update t1 set f1=1,f2=10 where f1=20; -update t1 set f1=1,f2=10 where f1=20; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1 where f1=33; -select * from t1 where f1=33; -echo select * from t1 where f1=2; -select * from t1 where f1=2; -echo select * from t1 where f1=2 and f2=33; -select * from t1 where f1=2 and f2=33; -echo update t1 set f1=20 where f1=2; -update t1 set f1=20 where f1=2; -echo select * from t1 where f1=20; -select * from t1 where f1=20; -echo update t1 set f2=333 where f3=444; -update t1 set f2=333 where f3=444; -echo select * from t1; -select * from t1; -echo select * from t1 where f3=444; -select * from t1 where f3=444; -echo select * from t1; -select * from t1; -echo update t1 set f1=1,f2=10 where f1=20; -update t1 set f1=1,f2=10 where f1=20; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select *from t1; -select *from t1; -echo select * from t1 where f1=1; -select * from t1 where f1=1; -echo select * from t1 where f1=2; -select * from t1 where f1=2; -echo select * from t1 where f1=2 and f2=33; -select * from t1 where f1=2 and f2=33; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=3 and f2=33; -delete from t1 where f1=3 and f2=33; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 in(1,5) and f2 in(50,10); -delete from t1 where f1 in(1,5) and f2 in(50,10); -echo select * from t1; -select * from t1; -echo delete from t1 where f2 between 33 and 45; -delete from t1 where f2 between 33 and 45; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=3 and f2=33; -delete from t1 where f1=3 and f2=33; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 in(1,5) and f2 in(50,10); -delete from t1 where f1 in(1,5) and f2 in(50,10); -echo select * from t1; -select * from t1; -echo commit; -commit; -echo delete from t1 where f2 between 33 and 45; -delete from t1 where f2 between 33 and 45; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo select * from t1; -select * from t1; -rollback; -echo drop table t1; -drop table t1; -echo quit; -quit; diff --git a/test/tools/csql/indextran3.sql b/test/tools/csql/indextran3.sql deleted file mode 100644 index 77fe75f4..00000000 --- a/test/tools/csql/indextran3.sql +++ /dev/null @@ -1,135 +0,0 @@ -echo create table t1(f1 int,f2 int,f3 int); -create table t1(f1 int,f2 int,f3 int); -echo create index idx1 on t1(f1,f3); -create index idx1 on t1(f1,f3); -echo insert into t1 values(1,10,100); -insert into t1 values(1,10,100); -echo insert into t1 values(3,33,333); -insert into t1 values(3,33,333); -echo insert into t1 values(2,33,444); -insert into t1 values(2,33,444); -echo set autocommit off; -set autocommit off; -echo insert into t1 values(4,40,400); -insert into t1 values(4,40,400); -echo insert into t1 values(3,33,333); -insert into t1 values(3,33,333); -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo insert into t1 values(4,40,400); -insert into t1 values(4,40,400); -echo insert into t1 values(3,33,333); -insert into t1 values(3,33,333); -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo update t1 set f1=20 where f1=2; -update t1 set f1=20 where f1=2; -echo select * from t1 where f1=20; -select * from t1 where f1=20; -echo update t1 set f2=333 where f3=444; -update t1 set f2=333 where f3=444; -echo select * from t1 where f3=444; -select * from t1 where f3=444; -echo select * from t1; -select * from t1; -echo update t1 set f1=1,f2=10 where f1=20; -update t1 set f1=1,f2=10 where f1=20; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1 where f1=33; -select * from t1 where f1=33; -echo select * from t1 where f1=2; -select * from t1 where f1=2; -echo select * from t1 where f1=2 and f3=444; -select * from t1 where f1=2 and f3=444; -echo update t1 set f1=20 where f1=2; -update t1 set f1=20 where f1=2; -echo select * from t1 where f1=20; -select * from t1 where f1=20; -echo update t1 set f2=333 where f3=444; -update t1 set f2=333 where f3=444; -echo select * from t1; -select * from t1; -echo select * from t1 where f3=444; -select * from t1 where f3=444; -echo select * from t1; -select * from t1; -echo update t1 set f1=1,f2=10 where f1=20; -update t1 set f1=1,f2=10 where f1=20; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select *from t1; -select *from t1; -echo select * from t1 where f1=1; -select * from t1 where f1=1; -echo select * from t1 where f1=2; -select * from t1 where f1=2; -echo select * from t1 where f1=2 and f3=444; -select * from t1 where f1=2 and f3=444; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=3 and f3=333; -delete from t1 where f1=3 and f3=333; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 in(1,5) and f3 in(50,100); -delete from t1 where f1 in(1,5) and f3 in(50,100); -echo select * from t1; -select * from t1; -echo delete from t1 where f2 between 33 and 45; -delete from t1 where f2 between 33 and 45; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo delete from t1 where f1=3 and f3=333; -delete from t1 where f1=3 and f3=333; -echo select * from t1; -select * from t1; -echo delete from t1 where f1 in(1,5) and f3 in(50,100); -delete from t1 where f1 in(1,5) and f3 in(50,100); -echo select * from t1; -select * from t1; -echo commit; -commit; -echo delete from t1 where f2 between 33 and 45; -delete from t1 where f2 between 33 and 45; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo select * from t1; -select * from t1; -rollback; -echo drop table t1; -drop table t1; -echo quit; -quit; diff --git a/test/tools/csql/indextran4.sql b/test/tools/csql/indextran4.sql deleted file mode 100644 index 2b8d38a0..00000000 --- a/test/tools/csql/indextran4.sql +++ /dev/null @@ -1,134 +0,0 @@ -echo create table t1(f1 int,f2 int,f3 int); -create table t1(f1 int,f2 int,f3 int); -echo create index idx1 on t1(f3,f2); -create index idx1 on t1(f3,f2); -echo insert into t1 values(1,10,100); -insert into t1 values(1,10,100); -echo insert into t1 values(3,33,333); -insert into t1 values(3,33,333); -echo insert into t1 values(2,33,444); -insert into t1 values(2,33,444); -echo set autocommit off; -set autocommit off; -echo insert into t1 values(4,40,400); -insert into t1 values(4,40,400); -echo insert into t1 values(3,33,333); -insert into t1 values(3,33,333); -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo insert into t1 values(4,40,400); -insert into t1 values(4,40,400); -echo insert into t1 values(3,33,333); -insert into t1 values(3,33,333); -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo update t1 set f1=20 where f1=2; -update t1 set f1=20 where f1=2; -echo select * from t1 where f1=20; -select * from t1 where f1=20; -echo update t1 set f2=333 where f3=444; -update t1 set f2=333 where f3=444; -echo select * from t1 where f3=444; -select * from t1 where f3=444; -echo select * from t1; -select * from t1; -echo update t1 set f1=1,f2=10 where f1=20; -update t1 set f1=1,f2=10 where f1=20; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1 where f1=33; -select * from t1 where f1=33; -echo select * from t1 where f1=2; -select * from t1 where f1=2; -echo select * from t1 where f1=2 and f2=33; -select * from t1 where f1=2 and f2=33; -echo update t1 set f1=20 where f1=2; -update t1 set f1=20 where f1=2; -echo select * from t1 where f1=20; -select * from t1 where f1=20; -echo update t1 set f2=333 where f3=444; -update t1 set f2=333 where f3=444; -echo select * from t1; -select * from t1; -echo select * from t1 where f3=444; -select * from t1 where f3=444; -echo select * from t1; -select * from t1; -echo update t1 set f1=1,f2=10 where f1=20; -update t1 set f1=1,f2=10 where f1=20; -echo select * from t1; -select * from t1; -echo commit; -commit; -echo select *from t1; -select *from t1; -echo select * from t1 where f1=1; -select * from t1 where f1=1; -echo select * from t1 where f1=2; -select * from t1 where f1=2; -echo select * from t1 where f1=2 and f2=33; -select * from t1 where f1=2 and f2=33; -echo select * from t1; -select * from t1; -echo delete from t1 where f3=333 and f2=33; -delete from t1 where f3=333 and f2=33; -echo select * from t1; -select * from t1; -echo delete from t1 where f2 in(10,40) and f3 in(400,10); -delete from t1 where f2 in(10,40) and f3 in(400,10); -echo select * from t1; -select * from t1; -echo delete from t1 where f2 between 33 and 45; -delete from t1 where f2 between 33 and 45; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo rollback; -rollback; -echo select * from t1; -select * from t1; -echo delete from t1 where f3=333 and f2=33; -delete from t1 where f3=333 and f2=33; -echo select * from t1; -select * from t1; -echo delete from t1 where f2 in(10,40) and f3 in(400,10); -delete from t1 where f2 in(10,40) and f3 in(400,10); -echo select * from t1; -select * from t1; -echo commit; -commit; -echo delete from t1 where f2 between 33 and 45; -delete from t1 where f2 between 33 and 45; -echo select * from t1; -select * from t1; -echo delete from t1; -delete from t1; -echo select * from t1; -select * from t1; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; -echo quit; -quit; diff --git a/test/tools/csql/null1.sql b/test/tools/csql/null1.sql deleted file mode 100644 index ad28b68a..00000000 --- a/test/tools/csql/null1.sql +++ /dev/null @@ -1,25 +0,0 @@ -echo "<<<<<<<<<<<<<<<<<<<<<<<< UPDATE t1 SET f2=NULL >>>>>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(2,NULL,4); -insert into t1 values(2,NULL,4); -echo insert into t1 values(3,4,NULL); -insert into t1 values(3,4,NULL); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(11,NULL,NULL); -insert into t1 values(11,NULL,NULL); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo update t1 set f2=NULL; -update t1 set f2=NULL; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; diff --git a/test/tools/csql/null2.sql b/test/tools/csql/null2.sql deleted file mode 100644 index 98bc53c8..00000000 --- a/test/tools/csql/null2.sql +++ /dev/null @@ -1,26 +0,0 @@ -echo "<<<<<<<<<<<<<<<<<<<<<<<< UPDATE t1 SET f1=NULL >>>>>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(2,NULL,4); -insert into t1 values(2,NULL,4); -echo insert into t1 values(3,4,NULL); -insert into t1 values(3,4,NULL); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(11,NULL,NULL); -insert into t1 values(11,NULL,NULL); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo update t1 set f1=NULL; -update t1 set f1=NULL; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - diff --git a/test/tools/csql/null3.sql b/test/tools/csql/null3.sql deleted file mode 100644 index 3bf98afb..00000000 --- a/test/tools/csql/null3.sql +++ /dev/null @@ -1,25 +0,0 @@ -echo "<<<<<<<<<<<<<<<<<<<<<< UPDATE t1 SET f1=f1+f2+f3 >>>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(2,NULL,4); -insert into t1 values(2,NULL,4); -echo insert into t1 values(3,4,NULL); -insert into t1 values(3,4,NULL); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(11,NULL,NULL); -insert into t1 values(11,NULL,NULL); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo update t1 set f1=f1+f2+f3; -update t1 set f1=f1+f2+f3; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; diff --git a/test/tools/csql/null4.sql b/test/tools/csql/null4.sql deleted file mode 100644 index 42fd5130..00000000 --- a/test/tools/csql/null4.sql +++ /dev/null @@ -1,25 +0,0 @@ -echo "<<<<<<<<<<<<<<<<<< UPDATE t1 SET f2=0 WHERE f3>=1 >>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(2,NULL,4); -insert into t1 values(2,NULL,4); -echo insert into t1 values(3,4,NULL); -insert into t1 values(3,4,NULL); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(11,NULL,NULL); -insert into t1 values(11,NULL,NULL); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo UPDATE t1 SET f2=0 where f3>=1; -UPDATE t1 SET f2=0 where f3>=1; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; diff --git a/test/tools/csql/null5.sql b/test/tools/csql/null5.sql deleted file mode 100644 index 9b8d94bd..00000000 --- a/test/tools/csql/null5.sql +++ /dev/null @@ -1,25 +0,0 @@ -echo "<<<<<<<<<<<<<<<<<<< DELETE FROM t1 WHERE f3>=4 >>>>>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(2,NULL,4); -insert into t1 values(2,NULL,4); -echo insert into t1 values(3,4,NULL); -insert into t1 values(3,4,NULL); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(11,NULL,NULL); -insert into t1 values(11,NULL,NULL); -echo commit; -commit; -echo select * from t1; -select * from t1; -echo DELETE FROM t1 WHERE f3>=4; -DELETE FROM t1 WHERE f3>=4; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; diff --git a/test/tools/csql/null6.sql b/test/tools/csql/null6.sql deleted file mode 100644 index 6989115c..00000000 --- a/test/tools/csql/null6.sql +++ /dev/null @@ -1,17 +0,0 @@ -echo "<<<<<<<<<<<<<<<<<<<<<<<< UPDATE t1 SET f1=f1+NULL >>>>>>>>>>>>>>>>>>>>>>"; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(2,NULL,4); -insert into t1 values(2,NULL,4); -echo insert into t1 values(3,4,NULL); -insert into t1 values(3,4,NULL); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(11,NULL,NULL); -insert into t1 values(11,NULL,NULL); -echo commit; -commit; -echo select * from t1; -select * from t1; diff --git a/test/tools/csql/null7.sql b/test/tools/csql/null7.sql deleted file mode 100644 index 4b3ab601..00000000 --- a/test/tools/csql/null7.sql +++ /dev/null @@ -1,9 +0,0 @@ -echo update t1 set f1=f1+NULL; -update t1 set f1=f1+NULL; -echo commit; -commit; -echo select * from t1; -select * from t1; -echo drop table t1; -drop table t1; - diff --git a/test/tools/csql/quit.sql b/test/tools/csql/quit.sql deleted file mode 100644 index 8c0cb686..00000000 --- a/test/tools/csql/quit.sql +++ /dev/null @@ -1 +0,0 @@ -quit; diff --git a/test/tools/csql/rowsizelimit.sql b/test/tools/csql/rowsizelimit.sql deleted file mode 100644 index d4cbfc42..00000000 --- a/test/tools/csql/rowsizelimit.sql +++ /dev/null @@ -1,4 +0,0 @@ -echo Description: row size limit..checking for 8K size - -create table t1 (f1 char (1000), f2 char (1000), f3 char (1000), f4 char (1000), f5 char (1000), - f6 char (1000), f7 char (1000), f8, char (1000)); diff --git a/test/tools/csql/selcond.sql b/test/tools/csql/selcond.sql deleted file mode 100644 index 668c1ec6..00000000 --- a/test/tools/csql/selcond.sql +++ /dev/null @@ -1,26 +0,0 @@ -echo select * from t1 where f1=10; -select * from t1 where f1=10; -echo select * from t1 where f1=99; -select * from t1 where f1=99; -echo select * from t1 where f1>27; -select * from t1 where f1>27; -echo select * from t1 where f1>=27; -select * from t1 where f1>=27; -echo select * from t1 where f1<=27; -select * from t1 where f1<=27; -echo select * from t1 where f1<27; -select * from t1 where f1<27; -echo select * from t1 where f1>99; -select * from t1 where f1>99; -echo select * from t1 where f1<-1; -select * from t1 where f1<-1; -echo select * from t1 where f1=40 and f1> 27; -select * from t1 where f1=40 and f1> 27; -echo select * from t1 where f1> 27 and f1=40; -select * from t1 where f1> 27 and f1=40; -echo select * from t1 where f1> 27 and f2=40; -select * from t1 where f1> 27 and f2=40; -echo select * from t1 where f1 >10 and f1 <20; -select * from t1 where f1 >10 and f1 <20; -echo select * from t1 where f1 >10 and f1 <20 and f2=15; -select * from t1 where f1 >10 and f1 <20 and f2=15; diff --git a/test/tools/csql/selectstar.sql b/test/tools/csql/selectstar.sql deleted file mode 100644 index 6bf56360..00000000 --- a/test/tools/csql/selectstar.sql +++ /dev/null @@ -1,3 +0,0 @@ -echo select * from t1; -select * from t1; - diff --git a/test/tools/csql/selecttest.sql b/test/tools/csql/selecttest.sql deleted file mode 100644 index bb039958..00000000 --- a/test/tools/csql/selecttest.sql +++ /dev/null @@ -1,32 +0,0 @@ -echo create table t1 (f1 int, f2 char(10), f3 bigint); -create table t1 (f1 int, f2 char(10), f3 bigint); - -echo insert into t1 values(10,'india',1234321); -insert into t1 values(10,'india',1234321); -echo insert into t1 (f1, f2 ) values(20,'INDIA'); -insert into t1 (f1, f2 ) values(20,'INDIA'); -echo insert into t1 (f2, f3 ) values('orissa',123432); -insert into t1 (f2, f3 ) values('orissa',123432); -echo insert into t1 (f1, f3 ) values(30,123432); -insert into t1 (f1, f3 ) values(30,123432); - -echo select * from t1; -select * from t1; -echo select f1,f2,f3 from t1; -select f1,f2,f3 from t1; -echo select f2,f1,f3 from t1; -select f2,f1,f3 from t1; -echo select f1,f1,f1,f1,f1 from t1; -select f1,f1,f1,f1,f1 from t1; -echo select f2,f2,f2,f2,f2 from t1; -select f2,f2,f2,f2,f2 from t1; -echo select f3,f3,f3,f3,f3 from t1; -select f3,f3,f3,f3,f3 from t1; -echo select f1,f1,f2,f2,f3,f3 from t1; -select f1,f1,f2,f2,f3,f3 from t1; -echo select f1,f2,f1,f3,f3,f2,f1,f3 from t1; -select f1,f2,f1,f3,f3,f2,f1,f3 from t1; - -echo drop table t1; -drop table t1; - diff --git a/test/tools/csql/singleandcompind.sql b/test/tools/csql/singleandcompind.sql deleted file mode 100644 index ff7562aa..00000000 --- a/test/tools/csql/singleandcompind.sql +++ /dev/null @@ -1,41 +0,0 @@ -echo create table t2 ( f1 int, f2 int, primary key(f1, f2)); -create table t2( f1 int, f2 int, primary key(f1, f2)); -echo create index ind on t2(f1); -create index ind on t2(f1); -echo create table t1 (f1 int,f2 char(10),f3 smallint,f4 tinyint,primary key(f1,f2)); -create table t1 (f1 int,f2 char(10),f3 smallint,f4 tinyint,primary key(f1,f2)); -echo create index indx1 on t1 (f1,f3); -create index indx1 on t1 (f1,f3); -echo create index indx2 on t1 (f3); -create index indx2 on t1 (f3); -echo create index indx3 on t1 (f2,f4); -create index indx3 on t1 (f2,f4); -echo create index indx4 on t1 (f2,f3); -create index indx4 on t1 (f2,f3); -echo create index indx5 on t1 (f1,f3,f4); -create index indx5 on t1 (f1,f3,f4); -echo create index indx6 on t1 (f1,f3,f2); -create index indx6 on t1 (f1,f3,f2); -echo create index indx7 on t1 (f1,f3,f2); -create index indx7 on t1 (f1,f4,f2); -echo create table t3 (f1 int,f2 char(10),f3 smallint,f4 tinyint,primary key(f1,f2)); -create table t3 (f1 int,f2 char(10),f3 smallint,f4 tinyint,primary key(f1,f2)); -echo create index indx11 on t3 (f1,f3); -create index indx11 on t3 (f1,f3); -echo create index indx12 on t3 (f3); -create index indx12 on t3 (f3); -echo create index indx13 on t3 (f2,f4); -create index indx13 on t3 (f2,f4); -echo create index indx14 on t3 (f2,f3); -create index indx14 on t3 (f2,f3); -echo create index indx15 on t1 (f1,f3,f4); -create index indx15 on t3 (f1,f3,f4); -echo create index indx16 on t1 (f1,f3,f2); -create index indx16 on t3 (f1,f3,f2); -echo create index indx17 on t1 (f1,f3,f2); -create index indx17 on t3 (f1,f4,f2); -echo create table t4 (f1 int); -create table t4 (f1 int); -echo create index indx18 on t4(f1,f1); -create index indx18 on t4(f1,f1); - diff --git a/test/tools/csql/test001.ksh b/test/tools/csql/test001.ksh deleted file mode 100755 index 0d4a61c4..00000000 --- a/test/tools/csql/test001.ksh +++ /dev/null @@ -1,59 +0,0 @@ -#!/bin/sh -# Test Case -# check no option, ? -# check whether authentication is working -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi -echo "Case 1: With no option:" -$CSQL_INSTALL_ROOT/bin/csql < ${REL_PATH}/quit.sql -if [ $? -ne 0 ] -then - exit 1; -fi -echo "Case 2: With ? option:" -$CSQL_INSTALL_ROOT/bin/csql -? -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 3: With wrong username and wrong password :" -$CSQL_INSTALL_ROOT/bin/csql -u wronguser -p password < ${REL_PATH}/quit.sql >/dev/null 2>&1 -if [ $? -eq 0 ] -then - echo passed - exit 1; -fi -echo failed - -echo "Case 4: With wrong username :" -$CSQL_INSTALL_ROOT/bin/csql -u wronguser -p manager < ${REL_PATH}/quit.sql >/dev/null 2>&1 -if [ $? -eq 0 ] -then - echo Passed - exit 1; -fi -echo Failed - -echo "Case 5: With wrong password :" -$CSQL_INSTALL_ROOT/bin/csql -u root -p password < ${REL_PATH}/quit.sql >/dev/null 2>&1 -if [ $? -eq 0 ] -then - echo passed - exit 1; -fi -echo failed - -echo "Case 6: With correct user name and password :" -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager < ${REL_PATH}/quit.sql -if [ $? -ne 0 ] -then - echo failed - exit 1; -fi -echo passed diff --git a/test/tools/csql/test002.ksh b/test/tools/csql/test002.ksh deleted file mode 100755 index df2936a9..00000000 --- a/test/tools/csql/test002.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check basic INSERT, SELECT -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/csql1.sql 2>/dev/null -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test003.ksh b/test/tools/csql/test003.ksh deleted file mode 100755 index e112d154..00000000 --- a/test/tools/csql/test003.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check basic UPDATE and DELETE -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/csql2.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test004.ksh b/test/tools/csql/test004.ksh deleted file mode 100755 index 686b05fd..00000000 --- a/test/tools/csql/test004.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check basic UPDATE and DELETE -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/csql3.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test005.ksh b/test/tools/csql/test005.ksh deleted file mode 100755 index 33f3eed1..00000000 --- a/test/tools/csql/test005.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check all data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/csql4.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test006.ksh b/test/tools/csql/test006.ksh deleted file mode 100755 index d4b8967f..00000000 --- a/test/tools/csql/test006.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check DDL -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/csql5.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test007.ksh b/test/tools/csql/test007.ksh deleted file mode 100755 index ea5f7f04..00000000 --- a/test/tools/csql/test007.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check create index -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/csql6.sql 2>/dev/null -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test008.ksh b/test/tools/csql/test008.ksh deleted file mode 100755 index 34159e9c..00000000 --- a/test/tools/csql/test008.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check create index -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/csql7.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test009.ksh b/test/tools/csql/test009.ksh deleted file mode 100755 index b340f726..00000000 --- a/test/tools/csql/test009.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check count -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/csql8.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test010.ksh b/test/tools/csql/test010.ksh deleted file mode 100755 index c0eb0c6a..00000000 --- a/test/tools/csql/test010.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check between and in -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/csql9.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test011.ksh b/test/tools/csql/test011.ksh deleted file mode 100755 index 0e34651f..00000000 --- a/test/tools/csql/test011.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check all data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/csql11.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test012.ksh b/test/tools/csql/test012.ksh deleted file mode 100755 index c1440b89..00000000 --- a/test/tools/csql/test012.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check all data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/csql12.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test021.ksh b/test/tools/csql/test021.ksh deleted file mode 100755 index 3a354f9f..00000000 --- a/test/tools/csql/test021.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check int data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype1.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test022.ksh b/test/tools/csql/test022.ksh deleted file mode 100755 index ec4698cb..00000000 --- a/test/tools/csql/test022.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check char data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype2.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test023.ksh b/test/tools/csql/test023.ksh deleted file mode 100755 index 6fca03b5..00000000 --- a/test/tools/csql/test023.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check shortint data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype3.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test025.ksh b/test/tools/csql/test025.ksh deleted file mode 100755 index fc1e8382..00000000 --- a/test/tools/csql/test025.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check float data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype5.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test026.ksh b/test/tools/csql/test026.ksh deleted file mode 100755 index 605232e6..00000000 --- a/test/tools/csql/test026.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check double data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype6.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test027.ksh b/test/tools/csql/test027.ksh deleted file mode 100755 index 21baa6bd..00000000 --- a/test/tools/csql/test027.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check bigint data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype7.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test028.ksh b/test/tools/csql/test028.ksh deleted file mode 100755 index aa1e0be7..00000000 --- a/test/tools/csql/test028.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check bigint data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype8.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test029.ksh b/test/tools/csql/test029.ksh deleted file mode 100755 index b15ee3aa..00000000 --- a/test/tools/csql/test029.ksh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -# Test Case -# check aggegates and group by data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/agg1.sql -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test030.ksh b/test/tools/csql/test030.ksh deleted file mode 100755 index f7ff52f2..00000000 --- a/test/tools/csql/test030.ksh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -# Test Case -# check composite primary key -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/comp1.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test031.ksh b/test/tools/csql/test031.ksh deleted file mode 100755 index 9e61459f..00000000 --- a/test/tools/csql/test031.ksh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -# Test Case -# check non-unique index with composite keys -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/comp2.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test032.ksh b/test/tools/csql/test032.ksh deleted file mode 100755 index 3f3ef944..00000000 --- a/test/tools/csql/test032.ksh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -# Test Case -# check non-unique index with composite keys -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/comp3.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test033.ksh b/test/tools/csql/test033.ksh deleted file mode 100755 index 87de84c5..00000000 --- a/test/tools/csql/test033.ksh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -# Test Case -# check non-unique index with composite keys -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/comp4.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test034.ksh b/test/tools/csql/test034.ksh deleted file mode 100755 index 55fc80db..00000000 --- a/test/tools/csql/test034.ksh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/sh -# Test Case -#create table t2(taking different integer fields) (test034a.ksh) -#create index in various ways. -#Do all operations like select,insert,update,delete on the indexed field. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/indexontuples.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql - exit 1; -fi - diff --git a/test/tools/csql/test034a.ksh b/test/tools/csql/test034a.ksh deleted file mode 100755 index d7f6ad6b..00000000 --- a/test/tools/csql/test034a.ksh +++ /dev/null @@ -1,21 +0,0 @@ -#!/bin/sh -# Test Case -#create table t2(taking different integer fields) (test034a.ksh) -#create index in various ways. -#Do all operations like select,insert,update,delete on the indexed field. -# - -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/diffintindex.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql - exit 1; -fi - diff --git a/test/tools/csql/test035.ksh b/test/tools/csql/test035.ksh deleted file mode 100755 index be2ee047..00000000 --- a/test/tools/csql/test035.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -# Test Case -# 35. Create table (f1 int, f2 int); -# Insert 5 tuples (1, 1), (1, 2), (2, 1), (2 ,2), (5, 5). (test035.ksh) -# create index ind on t1 (f1) unique; -# Should fail with unique key violation error. - -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/uniqueindontuples.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test036.ksh b/test/tools/csql/test036.ksh deleted file mode 100755 index d5fc8b09..00000000 --- a/test/tools/csql/test036.ksh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/sh -# Test Case -# 36. Create table t1 with composite primary key. -# t1(f1 int, f2 int, primary key(f1, f2)); -# create one more index indx on t1(f1). -# the index should be created. - -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/singleandcompind.sql 2 >&1 -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -l -if [ $? -ne 0 ] -then - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop1.sql -if [ $? -ne 0 ] -then - exit 3; -fi -exit 0; diff --git a/test/tools/csql/test037.ksh b/test/tools/csql/test037.ksh deleted file mode 100755 index 8eb5843b..00000000 --- a/test/tools/csql/test037.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check tinyint data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype9.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test038.ksh b/test/tools/csql/test038.ksh deleted file mode 100755 index a4be2bf5..00000000 --- a/test/tools/csql/test038.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# Update statement check for null values -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/updatetest.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test039.ksh b/test/tools/csql/test039.ksh deleted file mode 100755 index 5f70db91..00000000 --- a/test/tools/csql/test039.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# Update statement check for null values -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selecttest.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test040.ksh b/test/tools/csql/test040.ksh deleted file mode 100755 index 3ae432a8..00000000 --- a/test/tools/csql/test040.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check binary data type table t1 field f1 int ,f2 binary(4) -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype10.sql -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/tools/csql/test041.ksh b/test/tools/csql/test041.ksh deleted file mode 100755 index 80d0c3b8..00000000 --- a/test/tools/csql/test041.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check binary data type table t1 field f1 int ,f2 binary(4),primary key(f2) -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype11.sql -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/tools/csql/test042.ksh b/test/tools/csql/test042.ksh deleted file mode 100755 index 234b7b85..00000000 --- a/test/tools/csql/test042.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# check binary data type table t1 field f1 int ,f2 binary(4),primary key(f2) -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/datatype12.sql -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/tools/csql/test043.ksh b/test/tools/csql/test043.ksh deleted file mode 100755 index b959104d..00000000 --- a/test/tools/csql/test043.ksh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -# TEST CASE -# 1. create table t1 (f1 int not null, f2 int); -# 2. create index idx on t1 (f1) tree -# 3. insert duplicate records and it should pass -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree0.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 2; -fi -exit 0; diff --git a/test/tools/csql/test044.ksh b/test/tools/csql/test044.ksh deleted file mode 100755 index ed5fd1df..00000000 --- a/test/tools/csql/test044.ksh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -# TEST CASE -# 1. create table t1 (f1 int not null, f2 int); -# 2. create index idx on t1 (f1) tree -# 3. insert duplicate records and it should pass -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree1.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 2; -fi -exit 0; diff --git a/test/tools/csql/test045.ksh b/test/tools/csql/test045.ksh deleted file mode 100755 index 6a2bd937..00000000 --- a/test/tools/csql/test045.ksh +++ /dev/null @@ -1,36 +0,0 @@ -#!/bin/sh -# TEST CASE -# 1. create table t1 (f1 int not null, f2 int); -# 2. create index idx on t1 (f1) tree unique -# 3. insert duplicate records and it should fail -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi -#table creation and insertino of 50 records -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree2.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -if [ $? -ne 0 ] -then - exit 2; -fi -echo "50 rows selected"; -#selecting rows providing condition -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selcond.sql -if [ $? -ne 0 ] -then - exit 3; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 4; -fi -exit 0; diff --git a/test/tools/csql/test046.ksh b/test/tools/csql/test046.ksh deleted file mode 100755 index 3e733b09..00000000 --- a/test/tools/csql/test046.ksh +++ /dev/null @@ -1,36 +0,0 @@ -#!/bin/sh -# TEST CASE -# 1. create table t1 (f1 int not null, f2 int); -# 2. create index idx on t1 (f1) tree unique -# 3. insert duplicate records and it should fail -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi -#table creation and insertino of 50 records -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree3.sql 2>/dev/null -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -if [ $? -ne 0 ] -then - exit 2; -fi -echo "50 rows selected"; -#selecting rows providing condition -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selcond.sql -if [ $? -ne 0 ] -then - exit 3; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 4; -fi -exit 0; diff --git a/test/tools/csql/test047.ksh b/test/tools/csql/test047.ksh deleted file mode 100755 index 63c0b5e6..00000000 --- a/test/tools/csql/test047.ksh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh -# TEST CASE -# 1. create table t1 (f1 int not null, f2 int); -# 2. create index idx on t1 (f1) tree -# 3. insert duplicate records and it should pass -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree4.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 2; -fi -exit 0; diff --git a/test/tools/csql/test048.ksh b/test/tools/csql/test048.ksh deleted file mode 100755 index 696b9cda..00000000 --- a/test/tools/csql/test048.ksh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -# TEST CASE -# 1. create table t1 (f1 int not null, f2 int); -# 2. create index idx on t1 (f1) tree -#checking Select statement with condition on 0 or less than 0 on index field -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree5.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 2; -fi -exit 0; diff --git a/test/tools/csql/test049.ksh b/test/tools/csql/test049.ksh deleted file mode 100755 index 693b18eb..00000000 --- a/test/tools/csql/test049.ksh +++ /dev/null @@ -1,17 +0,0 @@ -#!/bin/sh -# Test Case -# Expression in update statement check -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/expresion.sql -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/tools/csql/test050.ksh b/test/tools/csql/test050.ksh deleted file mode 100755 index 63412362..00000000 --- a/test/tools/csql/test050.ksh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh -# TEST CASE -#create table t1(f1 int not null,f2 int,f3 int); -#create index idx1 on t1(f1,f2) tree; -#It should be created. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree6.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -l -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 2; -fi -exit 0; diff --git a/test/tools/csql/test051.ksh b/test/tools/csql/test051.ksh deleted file mode 100755 index c79e7509..00000000 --- a/test/tools/csql/test051.ksh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/sh -# TEST CASE -#create table t1(f1 int not null,f2 int,f3 int); -#create multiple tree index on the same table by taking different combination of fields -#create index idx1 on t1(f1) tree; -#create index idx2 on t1(f2) tree; -#create index idx3 on t1(f3) tree; -#create index idx4 on t1(f1,f2) tree; -#create index idx5 on t1(f2,f3) tree; -#create index idx6 on t1(f3,f1) tree; -#create index idx7 on t1(f1,f2,f3) tree; -#all should work fine. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree7.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -l -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 2; -fi -exit 0; diff --git a/test/tools/csql/test052.ksh b/test/tools/csql/test052.ksh deleted file mode 100755 index ed49d1df..00000000 --- a/test/tools/csql/test052.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -# Test Case -# Create table (f1 int, f2 int, f3 int); -# Insert 5 tuples (1, 1, 1), (2, 2, 2), (1, 2, 3) -# create index idx1 on t1(f1) tree unique; -# Should fail with unique key violation error. - -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/uniquetreeindontuples.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test053.ksh b/test/tools/csql/test053.ksh deleted file mode 100755 index 007b70de..00000000 --- a/test/tools/csql/test053.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int); -#a) create unique index on the first field. -#b) create primary index on the same field. -#It should fail Saying "Index on this field already exists". -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree8.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test054.ksh b/test/tools/csql/test054.ksh deleted file mode 100755 index e381bf3f..00000000 --- a/test/tools/csql/test054.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int); -#a) create primary index on the first field. -#b) create hash primary index on the same field. -#It should fail Saying "Index on this field already exists". -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree9.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test055.ksh b/test/tools/csql/test055.ksh deleted file mode 100755 index 63e91a64..00000000 --- a/test/tools/csql/test055.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int); -#a) create unique index on the first field. -#b) create hash unique index on the same field. -#It should fail Saying "Index on this field already exists". -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree10.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test056.ksh b/test/tools/csql/test056.ksh deleted file mode 100755 index 1ebcbe83..00000000 --- a/test/tools/csql/test056.ksh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int); -#a) create unique index on the first field. -#b) create primary index on the same field. -#c) create hash primary index on the same field. -#b) and c) should fail Saying "Index on this field already exists". -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree11.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test057.ksh b/test/tools/csql/test057.ksh deleted file mode 100755 index 42d18560..00000000 --- a/test/tools/csql/test057.ksh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int); -#a) create hash unique index on the first field. -#b) drop the index -#c) create hash primary index on the same field. -#It should be passed -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree12.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test058.ksh b/test/tools/csql/test058.ksh deleted file mode 100755 index 03059e51..00000000 --- a/test/tools/csql/test058.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int); -#a) create hash unique index on the first field. -#b) create tree unique index on the same field. -#It should be passed -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree13.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test059.ksh b/test/tools/csql/test059.ksh deleted file mode 100755 index 19d9820c..00000000 --- a/test/tools/csql/test059.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int); -#a) create hash primary index on the first field. -#b) create tree primary index on the same field. -#It should be passed -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree14.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test060.ksh b/test/tools/csql/test060.ksh deleted file mode 100755 index 575c2be6..00000000 --- a/test/tools/csql/test060.ksh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int,primary key(f1)); -# create index idx1 on t1(f1) unique; -#It should be failed saying "Index on this field already exists". -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree15.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test061.ksh b/test/tools/csql/test061.ksh deleted file mode 100755 index 1fdb5880..00000000 --- a/test/tools/csql/test061.ksh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int,primary key(f1)); -#create index idx1 on t1(f1) tree unique; -#It should be passed. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree16.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test062.ksh b/test/tools/csql/test062.ksh deleted file mode 100755 index 5b4424aa..00000000 --- a/test/tools/csql/test062.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#create table t1( f1 int not null,f2 int, f3 int); -#a) create tree unique index on first field -#b) create tree primary index on same firld. -#It should be failed Saying "Index on this field already exists". -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree17.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test063.ksh b/test/tools/csql/test063.ksh deleted file mode 100755 index 990daea2..00000000 --- a/test/tools/csql/test063.ksh +++ /dev/null @@ -1,27 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int); -#a) create tree unique index on the first field. -#b) drop the index -#c) create tree primary index on the same field. -#It should be passed -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree18.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test064.ksh b/test/tools/csql/test064.ksh deleted file mode 100755 index ae28d266..00000000 --- a/test/tools/csql/test064.ksh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/sh -#Test case -#1.Default autocommit mode -#run insert statement and then rollback in csql tool. After that disconnect csql and reconnect it and check whether the record is inserted. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree19.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test065.ksh b/test/tools/csql/test065.ksh deleted file mode 100755 index 0c543d7d..00000000 --- a/test/tools/csql/test065.ksh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh -#Test case -#autocommit false and disconnect -#set the autocommit mode false and then call insert and disconnect from csql. then reconnect and check that the inserted record is not present. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree20.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test066.ksh b/test/tools/csql/test066.ksh deleted file mode 100755 index 9fc2a23a..00000000 --- a/test/tools/csql/test066.ksh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh -#Test case -#autocommit true and disconnect -#set the autocommit mode to true and then call insert and disconnect from csql. then reconnect and check whether the records is inserted. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree21.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test067.ksh b/test/tools/csql/test067.ksh deleted file mode 100755 index 8a3172af..00000000 --- a/test/tools/csql/test067.ksh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh -#Test case -#autocommit mode to false and rollback -#set the autocommit mode to false and then call insert and rollback from csql. then check that the inserted record is not present. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree22.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test068.ksh b/test/tools/csql/test068.ksh deleted file mode 100755 index ade778bd..00000000 --- a/test/tools/csql/test068.ksh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh -#Test case -#autocommit mode to true and rollback -#set the autocommit mode to true and then call insert and rollback from csql. then check that the inserted record is present. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree23.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test069.ksh b/test/tools/csql/test069.ksh deleted file mode 100755 index 8ae5f920..00000000 --- a/test/tools/csql/test069.ksh +++ /dev/null @@ -1,24 +0,0 @@ -#!/bin/sh -#Test case -#utocommit mode to true and commit -#set the autocommit mode to true and then call insert and commit from csql. then check that the inserted record is present and the commit should not give error message. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/tree24.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test070.ksh b/test/tools/csql/test070.ksh deleted file mode 100755 index f428eb26..00000000 --- a/test/tools/csql/test070.ksh +++ /dev/null @@ -1,25 +0,0 @@ -#!/bin/sh -#Test case -#Default autocommit mode -#Insert 4 records . Update records providing some condition,Disconnect csql and then reconnect csql. Check changes made by update should be reflected on the records. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit6.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test071.ksh b/test/tools/csql/test071.ksh deleted file mode 100755 index 70da2b9c..00000000 --- a/test/tools/csql/test071.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit off mode -#create table t1(f1 int,f2 int); -#insert 4 records into table t1 and commit. Then insert another 2 records into t1 and commit, disconnect csql and reconnect csql again. Check all 6 records are there. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit7.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test072.ksh b/test/tools/csql/test072.ksh deleted file mode 100755 index 3a51deae..00000000 --- a/test/tools/csql/test072.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit mode off -#create table t1(f1 int,f2 int); -#insert 4 records into table t1 and commit. Then insert another records into t1 and Rollback, disconnect csql and reconnect csql again. Check last 2 records are not there. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit8.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test073.ksh b/test/tools/csql/test073.ksh deleted file mode 100755 index deb73591..00000000 --- a/test/tools/csql/test073.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit mode off -#create table t1(f1 int,f2 int); -#insert 4 records into table t1 and commit. Then update the records giving a condition and commit. disconnect csql and reconnect again. Check the changes made by update are reflected on records. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit9.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test074.ksh b/test/tools/csql/test074.ksh deleted file mode 100755 index b29aa694..00000000 --- a/test/tools/csql/test074.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit mode off -#create table t1(f1 int,f2 int); -#insert 4 records into table t1 and commit. Then update the records giving a condition, disconnect csql and and reconnect again. Check the changes made by update are not reflected on record -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit10.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test075.ksh b/test/tools/csql/test075.ksh deleted file mode 100755 index 94194311..00000000 --- a/test/tools/csql/test075.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit mode off -#create table t1(f1 int,f2 int); -#insert 4 records into table t1 and commit. Then update the records giving a condition and roll back, disconnect csql and and reconnect again. Check the changes made by update are not reflected on records -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit11.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test076.ksh b/test/tools/csql/test076.ksh deleted file mode 100755 index 3bdbf49f..00000000 --- a/test/tools/csql/test076.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit mode off -#create table t1(f1 int,f2 int); -#insert 4 records into table t1 . Update the records giving a condition, disconnect csql and and reconnect again. Check No records are there -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit12.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test077.ksh b/test/tools/csql/test077.ksh deleted file mode 100755 index 41c5e884..00000000 --- a/test/tools/csql/test077.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit mode off -#create table t1(f1 int,f2 int); -#insert 4 records and Commit, delete all records, Disconnect csql . Reconnect csql again. Check all the 4 records are there. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit13.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test078.ksh b/test/tools/csql/test078.ksh deleted file mode 100755 index e17a7150..00000000 --- a/test/tools/csql/test078.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit mode off -#create table t1(f1 int,f2 int); -#insert 4 records and Commit, delete all records and commit, Disconnect csql . Reconnect csql again. Check all the 4 records are not there. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit14.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test079.ksh b/test/tools/csql/test079.ksh deleted file mode 100755 index f3c6697a..00000000 --- a/test/tools/csql/test079.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit mode off -#create table t1(f1 int,f2 int); -#insert 4 records into table t1 and commit. Then delete the records giving a condition and commit. disconnect csql and reconnect again. Check some records are deleted. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit15.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test080.ksh b/test/tools/csql/test080.ksh deleted file mode 100755 index ee0797fd..00000000 --- a/test/tools/csql/test080.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit mode off -#create table t1(f1 int,f2 int); -#insert 4 records into table t1 and commit. Then delete the records giving a condition, disconnect csql and and reconnect again. Check all the inserted records are there. No record is deleted. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit16.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test081.ksh b/test/tools/csql/test081.ksh deleted file mode 100755 index 0255231b..00000000 --- a/test/tools/csql/test081.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit mode off -#create table t1(f1 int,f2 int); -#insert 4 records into table t1 and commit. Then delete the records giving a condition and roll back, disconnect csql and and reconnect again. Check all the inserted records are there. No record is deleted -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit17.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test082.ksh b/test/tools/csql/test082.ksh deleted file mode 100755 index 81ca7182..00000000 --- a/test/tools/csql/test082.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#Autocommit mode off -#create table t1(f1 int,f2 int); -#insert 4 records into table t1 . Delete the records giving a condition, disconnect csql and and reconnect again. Check No records are there. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit18.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/quit.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test083.ksh b/test/tools/csql/test083.ksh deleted file mode 100755 index a57b451e..00000000 --- a/test/tools/csql/test083.ksh +++ /dev/null @@ -1,28 +0,0 @@ -#!/bin/sh -#Test case -#Miscelaneous testing of insert in autocommit off mode -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit1.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit2.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test084.ksh b/test/tools/csql/test084.ksh deleted file mode 100755 index 63779a4e..00000000 --- a/test/tools/csql/test084.ksh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/sh -#Test case -#Miscelaneous Testing in insert and delete in autocommit off mode -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit1.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit3.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop2.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test085.ksh b/test/tools/csql/test085.ksh deleted file mode 100755 index 1c81c170..00000000 --- a/test/tools/csql/test085.ksh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/sh -#Test case -#Miscelaneous testing in insert and delete in autocommit off mode -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit1.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit4.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop2.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test086.ksh b/test/tools/csql/test086.ksh deleted file mode 100755 index 9e924cfc..00000000 --- a/test/tools/csql/test086.ksh +++ /dev/null @@ -1,29 +0,0 @@ -#!/bin/sh -#Test case -#miscelaneous testing on insert , delete and update in autocommit off mode -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit1.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/autocommit5.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/selectstar.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop2.sql -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test087.ksh b/test/tools/csql/test087.ksh deleted file mode 100755 index c0726b81..00000000 --- a/test/tools/csql/test087.ksh +++ /dev/null @@ -1,23 +0,0 @@ -#!/bin/sh -#Test case -#Create table with table name adding special character and field name with special character. -#It should fail for name other than alphanumeric and underscore . -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/dbobjname.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/catalog -u root -p manager -i -if [ $? -ne 0 ] -then - exit 1; -fi - diff --git a/test/tools/csql/test088.ksh b/test/tools/csql/test088.ksh deleted file mode 100755 index b2b7a2ea..00000000 --- a/test/tools/csql/test088.ksh +++ /dev/null @@ -1,48 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int); -#insert 5 records into t1. Test the following cases -#a) update t1 set f2=NULL; -#b) update t1 set f1=NULL; -#c) update t1 set f1=f1+f2+f3; -#d) UPDATE t1 SET f2=0 where f3>=1; -#e) DELETE FROM t1 WHERE f3>=4; -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/null1.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/null2.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/null3.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/null4.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/null5.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql - exit 1; -fi - diff --git a/test/tools/csql/test089.ksh b/test/tools/csql/test089.ksh deleted file mode 100755 index c056faf1..00000000 --- a/test/tools/csql/test089.ksh +++ /dev/null @@ -1,26 +0,0 @@ -#!/bin/sh -#Test case -#create table t1(f1 int not null,f2 int,f3 int); -#insert 5 records into t1. Test the following case -#a) update t1 set f1=f1+NULL; -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/null6.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/null7.sql -if [ $? -ne 0 ] -then - $CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/drop.sql - exit 1; -fi - diff --git a/test/tools/csql/test090.ksh b/test/tools/csql/test090.ksh deleted file mode 100755 index a85f796c..00000000 --- a/test/tools/csql/test090.ksh +++ /dev/null @@ -1,31 +0,0 @@ -#!/bin/sh -# Test Case -# create table t1(f1 int,f2 int,f3 int,primary key(f1,f2)); -# insert duplicate values in composite key field. It should be failed. -# create table t1(f1 int,f2 int,f3 int,primary key(f1,f3)); -# insert duplicate values in composite key field. It should be failed. -# create table t1(f1 int,f2 int,f3 int,f4 int,primary key(f2,f4)); -# insert duplicate values in composite key field. It should be failed. -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/composite1.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/composite2.sql -if [ $? -ne 0 ] -then - exit 1; -fi -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/composite3.sql -if [ $? -ne 0 ] -then - exit 1; -fi diff --git a/test/tools/csql/test091.ksh b/test/tools/csql/test091.ksh deleted file mode 100755 index 7fa05442..00000000 --- a/test/tools/csql/test091.ksh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh -# Test Case -# check aggegates and group by data type -# -QUITFILE=${PWD}/tools/csql/quit.sql -REL_PATH=. -if [ -s "$QUITFILE" ] -then - REL_PATH=`pwd`/tools/csql -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/indextran1.sql -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/indextran2.sql -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/indextran3.sql -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s ${REL_PATH}/indextran4.sql -if [ $? -ne 0 ] -then - exit 1; -fi diff --git a/test/tools/csql/tree0.sql b/test/tools/csql/tree0.sql deleted file mode 100644 index cfe43db7..00000000 --- a/test/tools/csql/tree0.sql +++ /dev/null @@ -1,9 +0,0 @@ -echo create tree index test; -create table t1 ( f1 int not null, f2 int); -create index idx on t1(f1) tree; -insert into t1 values(1,2); -insert into t1 values(1,2); - - - - diff --git a/test/tools/csql/tree1.sql b/test/tools/csql/tree1.sql deleted file mode 100644 index f87fda2c..00000000 --- a/test/tools/csql/tree1.sql +++ /dev/null @@ -1,9 +0,0 @@ -echo create tree index test; -create table t1 ( f1 int not null, f2 int); -create index idx on t1(f1) tree unique; -insert into t1 values(1,2); -insert into t1 values(1,2); - - - - diff --git a/test/tools/csql/tree10.sql b/test/tools/csql/tree10.sql deleted file mode 100644 index 421cf21d..00000000 --- a/test/tools/csql/tree10.sql +++ /dev/null @@ -1,6 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx1 on t1(f1) unique; -create index idx1 on t1(f1) unique; -echo create index idx2 on t1(f1) hash unique; -create index idx2 on t1(f1) hash unique; - diff --git a/test/tools/csql/tree11.sql b/test/tools/csql/tree11.sql deleted file mode 100644 index cf3670bf..00000000 --- a/test/tools/csql/tree11.sql +++ /dev/null @@ -1,8 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx1 on t1(f1) unique; -create index idx1 on t1(f1) unique; -echo create index idx2 on t1(f1) primary; -create index idx2 on t1(f1) primary; -echo create index idx3 on t1(f1) hash primary; -create index idx3 on t1(f1) hash primary; - diff --git a/test/tools/csql/tree12.sql b/test/tools/csql/tree12.sql deleted file mode 100644 index dea8f48a..00000000 --- a/test/tools/csql/tree12.sql +++ /dev/null @@ -1,8 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx1 on t1(f1) hash unique; -create index idx1 on t1(f1) hash unique; -echo drop index idx1; -drop index idx1; -echo create index idx2 on t1(f1) hash primary; -create index idx2 on t1(f1) hash primary; - diff --git a/test/tools/csql/tree13.sql b/test/tools/csql/tree13.sql deleted file mode 100644 index 0d84d125..00000000 --- a/test/tools/csql/tree13.sql +++ /dev/null @@ -1,6 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx1 on t1(f1) hash unique; -create index idx1 on t1(f1) hash unique; -echo create index idx2 on t1(f1) tree unique; -create index idx2 on t1(f1) tree unique; - diff --git a/test/tools/csql/tree14.sql b/test/tools/csql/tree14.sql deleted file mode 100644 index df9cba02..00000000 --- a/test/tools/csql/tree14.sql +++ /dev/null @@ -1,6 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx1 on t1(f1) hash primary; -create index idx1 on t1(f1) hash primary; -echo create index idx2 on t1(f1) tree primary; -create index idx2 on t1(f1) tree primary; - diff --git a/test/tools/csql/tree15.sql b/test/tools/csql/tree15.sql deleted file mode 100644 index 1027c73c..00000000 --- a/test/tools/csql/tree15.sql +++ /dev/null @@ -1,4 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int,primary key(f1)); -echo create index idx1 on t1(f1) unique; -create index idx1 on t1(f1) unique; - diff --git a/test/tools/csql/tree16.sql b/test/tools/csql/tree16.sql deleted file mode 100644 index 1e9f707f..00000000 --- a/test/tools/csql/tree16.sql +++ /dev/null @@ -1,4 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int,primary key(f1)); -echo create index idx1 on t1(f1) tree unique; -create index idx1 on t1(f1) tree unique; - diff --git a/test/tools/csql/tree17.sql b/test/tools/csql/tree17.sql deleted file mode 100644 index b67eee8c..00000000 --- a/test/tools/csql/tree17.sql +++ /dev/null @@ -1,6 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx1 on t1(f1) tree unique; -create index idx1 on t1(f1) tree unique; -echo create index idx2 on t1(f1) tree primary; -create index idx2 on t1(f1) tree primary; - diff --git a/test/tools/csql/tree18.sql b/test/tools/csql/tree18.sql deleted file mode 100644 index 71c8159d..00000000 --- a/test/tools/csql/tree18.sql +++ /dev/null @@ -1,8 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx1 on t1(f1) tree unique; -create index idx1 on t1(f1) tree unique; -echo drop index idx1; -drop index idx1; -echo create index idx2 on t1(f1) tree primary; -create index idx2 on t1(f1) tree primary; - diff --git a/test/tools/csql/tree19.sql b/test/tools/csql/tree19.sql deleted file mode 100644 index e557b6ee..00000000 --- a/test/tools/csql/tree19.sql +++ /dev/null @@ -1,12 +0,0 @@ -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo select * from t1; -select * from t1; -echo rollback; -rollback; diff --git a/test/tools/csql/tree2.sql b/test/tools/csql/tree2.sql deleted file mode 100644 index 265912c3..00000000 --- a/test/tools/csql/tree2.sql +++ /dev/null @@ -1,53 +0,0 @@ -create table t1 (f1 int not null, f2 int); -create index idx on t1 (f1) tree unique; -insert into t1 values(1,1); -insert into t1 values(2,2); -insert into t1 values(3,3); -insert into t1 values(4,4); -insert into t1 values(5,5); -insert into t1 values(6,6); -insert into t1 values(7,7); -insert into t1 values(8,8); -insert into t1 values(9,9); -insert into t1 values(10,10); -insert into t1 values(11,11); -insert into t1 values(12,12); -insert into t1 values(13,13); -insert into t1 values(14,14); -insert into t1 values(15,15); -insert into t1 values(16,16); -insert into t1 values(17,17); -insert into t1 values(18,18); -insert into t1 values(19,19); -insert into t1 values(20,20); -insert into t1 values(21,21); -insert into t1 values(22,22); -insert into t1 values(23,23); -insert into t1 values(24,24); -insert into t1 values(25,25); -insert into t1 values(26,26); -insert into t1 values(27,27); -insert into t1 values(28,28); -insert into t1 values(29,29); -insert into t1 values(30,30); -insert into t1 values(31,31); -insert into t1 values(32,32); -insert into t1 values(33,33); -insert into t1 values(34,34); -insert into t1 values(35,35); -insert into t1 values(36,36); -insert into t1 values(37,37); -insert into t1 values(38,38); -insert into t1 values(39,39); -insert into t1 values(40,40); -insert into t1 values(41,41); -insert into t1 values(42,42); -insert into t1 values(43,43); -insert into t1 values(44,44); -insert into t1 values(45,45); -insert into t1 values(46,46); -insert into t1 values(47,47); -insert into t1 values(48,48); -insert into t1 values(49,49); -insert into t1 values(50,50); -commit; diff --git a/test/tools/csql/tree20.sql b/test/tools/csql/tree20.sql deleted file mode 100644 index 7988841f..00000000 --- a/test/tools/csql/tree20.sql +++ /dev/null @@ -1,14 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo select * from t1; -select * from t1; -echo quit; -quit; diff --git a/test/tools/csql/tree21.sql b/test/tools/csql/tree21.sql deleted file mode 100644 index e9f8992f..00000000 --- a/test/tools/csql/tree21.sql +++ /dev/null @@ -1,14 +0,0 @@ -echo set autocommit on; -set autocommit on; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo select * from t1; -select * from t1; -echo quit; -quit; diff --git a/test/tools/csql/tree22.sql b/test/tools/csql/tree22.sql deleted file mode 100644 index 224c1f5e..00000000 --- a/test/tools/csql/tree22.sql +++ /dev/null @@ -1,14 +0,0 @@ -echo set autocommit off; -set autocommit off; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo select * from t1; -select * from t1; -echo rollback; -rollback; diff --git a/test/tools/csql/tree23.sql b/test/tools/csql/tree23.sql deleted file mode 100644 index 65a93e21..00000000 --- a/test/tools/csql/tree23.sql +++ /dev/null @@ -1,14 +0,0 @@ -echo set autocommit on; -set autocommit on; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo select * from t1; -select * from t1; -echo rollback; -rollback; diff --git a/test/tools/csql/tree24.sql b/test/tools/csql/tree24.sql deleted file mode 100644 index fdbcc90a..00000000 --- a/test/tools/csql/tree24.sql +++ /dev/null @@ -1,14 +0,0 @@ -echo set autocommit on; -set autocommit on; -echo create table t1(f1 int not null,f2 int,f3 int); -create table t1(f1 int not null,f2 int,f3 int); -echo insert into t1 values(1,2,3); -insert into t1 values(1,2,3); -echo insert into t1 values(10,20,30); -insert into t1 values(10,20,30); -echo insert into t1 values(100,200,300); -insert into t1 values(100,200,300); -echo select * from t1; -select * from t1; -echo commit; -commit; diff --git a/test/tools/csql/tree3.sql b/test/tools/csql/tree3.sql deleted file mode 100644 index cdaf9ceb..00000000 --- a/test/tools/csql/tree3.sql +++ /dev/null @@ -1,53 +0,0 @@ -create table t1 (f1 int not null, f2 int, primary key(f1)); -create index idx on t1 (f1) tree unique; -insert into t1 values(1,1); -insert into t1 values(2,2); -insert into t1 values(3,3); -insert into t1 values(4,4); -insert into t1 values(5,5); -insert into t1 values(6,6); -insert into t1 values(7,7); -insert into t1 values(8,8); -insert into t1 values(9,9); -insert into t1 values(10,10); -insert into t1 values(11,11); -insert into t1 values(12,12); -insert into t1 values(13,13); -insert into t1 values(14,14); -insert into t1 values(15,15); -insert into t1 values(16,16); -insert into t1 values(17,17); -insert into t1 values(18,18); -insert into t1 values(19,19); -insert into t1 values(20,20); -insert into t1 values(21,21); -insert into t1 values(22,22); -insert into t1 values(23,23); -insert into t1 values(24,24); -insert into t1 values(25,25); -insert into t1 values(26,26); -insert into t1 values(27,27); -insert into t1 values(28,28); -insert into t1 values(29,29); -insert into t1 values(30,30); -insert into t1 values(31,31); -insert into t1 values(32,32); -insert into t1 values(33,33); -insert into t1 values(34,34); -insert into t1 values(35,35); -insert into t1 values(36,36); -insert into t1 values(37,37); -insert into t1 values(38,38); -insert into t1 values(39,39); -insert into t1 values(40,40); -insert into t1 values(41,41); -insert into t1 values(42,42); -insert into t1 values(43,43); -insert into t1 values(44,44); -insert into t1 values(45,45); -insert into t1 values(46,46); -insert into t1 values(47,47); -insert into t1 values(48,48); -insert into t1 values(49,49); -insert into t1 values(50,50); -commit; diff --git a/test/tools/csql/tree4.sql b/test/tools/csql/tree4.sql deleted file mode 100644 index ed29545b..00000000 --- a/test/tools/csql/tree4.sql +++ /dev/null @@ -1,75 +0,0 @@ -create table t1 (f1 int not null, f2 int); -create index idx on t1 (f1) tree unique; -insert into t1 values(1,1); -insert into t1 values(2,2); -insert into t1 values(3,3); -insert into t1 values(4,4); -insert into t1 values(5,5); -insert into t1 values(6,6); -insert into t1 values(7,7); -insert into t1 values(8,8); -insert into t1 values(9,9); -insert into t1 values(10,10); -insert into t1 values(11,11); -insert into t1 values(12,12); -insert into t1 values(13,13); -insert into t1 values(14,14); -insert into t1 values(15,15); -insert into t1 values(16,16); -insert into t1 values(17,17); -insert into t1 values(18,18); -insert into t1 values(19,19); -insert into t1 values(20,20); -insert into t1 values(21,21); -insert into t1 values(22,22); -insert into t1 values(23,23); -insert into t1 values(24,24); -insert into t1 values(25,25); -insert into t1 values(26,26); -insert into t1 values(27,27); -insert into t1 values(28,28); -insert into t1 values(29,29); -insert into t1 values(30,30); -insert into t1 values(31,31); -insert into t1 values(32,32); -insert into t1 values(33,33); -insert into t1 values(34,34); -insert into t1 values(35,35); -insert into t1 values(36,36); -insert into t1 values(37,37); -insert into t1 values(38,38); -insert into t1 values(39,39); -insert into t1 values(40,40); -insert into t1 values(41,41); -insert into t1 values(42,42); -insert into t1 values(43,43); -insert into t1 values(44,44); -insert into t1 values(45,45); -insert into t1 values(46,46); -insert into t1 values(47,47); -insert into t1 values(48,48); -insert into t1 values(49,49); -insert into t1 values(50,50); -commit; -delete from t1 where f1=10; -commit; -echo select * from t1 where f1>5 and f1<15; -select * from t1 where f1>5 and f1<15; -echo delete from t1 where f1>40; -delete from t1 where f1>40; -echo commit; -commit; -echo select * from t1 where f1>35 and f1<55; -select * from t1 where f1>35 and f1<55; -echo delete from t1 where f1<8; -delete from t1 where f1<8; -echo commit; -commit; -echo select * from t1 where f1>=-5 and f1<15; -select * from t1 where f1>=-5 and f1<15; -echo insert into t1 values(10,10); -insert into t1 values(10,10); -echo commit; -commit; -echo select * from t1 where f1 >5 and f1 <15; -select * from t1 where f1 >5 and f1 <15; diff --git a/test/tools/csql/tree5.sql b/test/tools/csql/tree5.sql deleted file mode 100644 index 88696420..00000000 --- a/test/tools/csql/tree5.sql +++ /dev/null @@ -1,32 +0,0 @@ -create table t1(f1 int not null,f2 int); -create index idx on t1(f1) tree unique; -insert into t1 values(1,1); -insert into t1 values(2,2); -insert into t1 values(3,3); -insert into t1 values(4,4); -insert into t1 values(5,5); -insert into t1 values(6,6); -insert into t1 values(7,7); -insert into t1 values(8,8); -insert into t1 values(9,9); -insert into t1 values(10,10); -commit; -echo select * from t1; -select * from t1; -echo select * from t1 where f1>-1; -select * from t1 where f1>-1; -echo select * from t1 where f1>-2; -select * from t1 where f1>-2; -echo select * from t1 where f1>-3; -select * from t1 where f1>-3; -echo select * from t1 where f1>-4; -select * from t1 where f1>-4; -echo select * from t1 where f1>-5; -select * from t1 where f1>-5; -echo select * from t1 where f1>-10; -select * from t1 where f1>-10; -echo select * from t1 where f1>-100; -select * from t1 where f1>-100; -echo select * from t1 where f1>-1000; -select * from t1 where f1>-1000; - diff --git a/test/tools/csql/tree6.sql b/test/tools/csql/tree6.sql deleted file mode 100644 index e33cabe8..00000000 --- a/test/tools/csql/tree6.sql +++ /dev/null @@ -1,3 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int); -create index idx1 on t1(f1,f2) tree; -commit; diff --git a/test/tools/csql/tree7.sql b/test/tools/csql/tree7.sql deleted file mode 100644 index c86d669b..00000000 --- a/test/tools/csql/tree7.sql +++ /dev/null @@ -1,9 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int); -create index idx1 on t1(f1) tree; -create index idx2 on t1(f2) tree; -create index idx3 on t1(f3) tree; -create index idx4 on t1(f1,f2) tree; -create index idx5 on t1(f2,f3) tree; -create index idx6 on t1(f3,f1) tree; -create index idx7 on t1(f1,f2,f3) tree; -commit; diff --git a/test/tools/csql/tree8.sql b/test/tools/csql/tree8.sql deleted file mode 100644 index ad56c280..00000000 --- a/test/tools/csql/tree8.sql +++ /dev/null @@ -1,6 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx1 on t1(f1)unique; -create index idx1 on t1(f1)unique; -echo create index idx2 on t1(f1)primary; -create index idx2 on t1(f1)primary; - diff --git a/test/tools/csql/tree9.sql b/test/tools/csql/tree9.sql deleted file mode 100644 index 199af6f9..00000000 --- a/test/tools/csql/tree9.sql +++ /dev/null @@ -1,6 +0,0 @@ -create table t1(f1 int not null,f2 int,f3 int); -echo create index idx1 on t1(f1) primary; -create index idx1 on t1(f1)primary; -echo create index idx2 on t1(f1) hash primary; -create index idx2 on t1(f1) hash primary; - diff --git a/test/tools/csql/uniqueindontuples.sql b/test/tools/csql/uniqueindontuples.sql deleted file mode 100644 index 66524cfc..00000000 --- a/test/tools/csql/uniqueindontuples.sql +++ /dev/null @@ -1,8 +0,0 @@ -create table t1 ( f1 int, f2 int); -insert into t1 values(1, 1); -insert into t1 values(1, 2); -insert into t1 values(5, 5); -insert into t1 values(2, 1); -insert into t1 values(2, 2); -echo create index ind on t1(f1)unique; -create index ind on t1(f1) unique; diff --git a/test/tools/csql/uniquetreeindontuples.sql b/test/tools/csql/uniquetreeindontuples.sql deleted file mode 100644 index 7b09e16b..00000000 --- a/test/tools/csql/uniquetreeindontuples.sql +++ /dev/null @@ -1,6 +0,0 @@ -create table t1 ( f1 int, f2 int,f3 int); -insert into t1 values(1,1,1); -insert into t1 values(2,2,2); -insert into t1 values(1,2,3); -echo create index idx1 on t1(f1) tree unique; -create index idx1 on t1(f1) tree unique; diff --git a/test/tools/csql/updatetest.sql b/test/tools/csql/updatetest.sql deleted file mode 100644 index a34e01d7..00000000 --- a/test/tools/csql/updatetest.sql +++ /dev/null @@ -1,53 +0,0 @@ -echo create table t1 (f1 int, f2 char(10), f3 bigint); -create table t1 (f1 int, f2 char(10), f3 bigint); - -echo insert into t1 values(10,'india',1234321); -insert into t1 values(10,'india',1234321); -echo insert into t1 (f1, f2 ) values(20,'INDIA'); -insert into t1 (f1, f2 ) values(20,'INDIA'); -echo insert into t1 (f2, f3 ) values('orissa',123432); -insert into t1 (f2, f3 ) values('orissa',123432); -echo insert into t1 (f1, f3 ) values(30,123432); -insert into t1 (f1, f3 ) values(30,123432); - -echo select * from t1; -select * from t1; - -echo update t1 set f1=10; -update t1 set f1=10; -echo select * from t1; -select * from t1; -echo update t1 set f2='hello'; -update t1 set f2='hello'; -echo select * from t1; -select * from t1; -echo update t1 set f3=10000; -update t1 set f3=10000; - -echo select * from t1; -select * from t1; - -echo create table t2 (f1 tinyint, f2 float); -create table t2 (f1 tinyint, f2 float); - -echo insert into t2 values (112, 235.50); -insert into t2 values (112, 235.50); -echo insert into t2 (f1) values (220); -insert into t2 (f1) values (220); -echo insert into t2 (f2) values (100.50); -insert into t2 (f2) values (100.50); - - -echo select * from t2; -select * from t2; -echo update t2 set f2=250.50; -update t2 set f2=250.50; -echo update t2 set f1=125; -update t2 set f1=125; - -echo select * from t2; -select * from t2; -echo drop table t1; -drop table t1; -echo drop table t2; -drop table t2; diff --git a/test/tools/csqldump/Makefile b/test/tools/csqldump/Makefile deleted file mode 100644 index 496ed8fc..00000000 --- a/test/tools/csqldump/Makefile +++ /dev/null @@ -1,36 +0,0 @@ - -OSNAME = $(shell uname -s) -PlatForm=supported - -ifeq ($(OSNAME), SunOS) -CPlus = CC -CPlusFlags = -O2 -w -mt -xarch=v8 -SYSLIBS=-ldl -lnsl -lsocket -lposix4 -else -ifeq ($(OSNAME), Linux) -CPlus = g++ -CPlusFlags = -g -w -SYSLIBS= -rdynamic -lrt -lpthread -lcrypt -else -PlatForm=notsupported -all: - echo "CSQL is not supported on $(OSNAME) platform" -endif -endif - -INCL= -I$(CSQL_INSTALL_ROOT)/include -LIBS= -L$(CSQL_INSTALL_ROOT)/lib -lcsql - -TARGETS = \ - insert - - -ifeq ($(PlatForm), supported) -all: $(TARGETS) -endif - -insert: insert.c - $(CPlus) -DWITHINDEX $(CPlusFlags) -o $@ $< $(INCL) $(LIBS) $(SYSLIBS) -clean: - rm -f $(TARGETS) - diff --git a/test/tools/csqldump/csql.conf b/test/tools/csqldump/csql.conf deleted file mode 100644 index e8a30cf2..00000000 --- a/test/tools/csqldump/csql.conf +++ /dev/null @@ -1,62 +0,0 @@ -# CSQL System Configuration File - -#####################################Server Section######################## -#Important: For Server section parameters, make sure that the value is same for the -# server process and all the csql client process which connects to it. otherwise, -# behavior is undefined - -# Page size. Each database is logically divided into pages and allocation happens -# in this unit of pages. Increasing this value will reduce frequent allocation of pages. -PAGE_SIZE= 8192 - -#Total number of client process which can connect and work with the -# database concurrently -MAX_PROCS = 100 - -# Maximum size of the system database. -MAX_SYS_DB_SIZE=10485760 - -#Maximum size of the user database file. -MAX_DB_SIZE=335544320 - -#Shared memory key to be used by the system to create and locate system database. -SYS_DB_KEY=1234 - -#Shared memory key to be used by the system to create and locate user database. -USER_DB_KEY=4321 - -#Give full path for the log file where important system actions are stored. -LOG_FILE=/tmp/log/csql/log.out - -#The virtual memory start address at which the shared memory segment -# will be created and attached. -MAP_ADDRESS=400000000 - -#Important: For Server section parameters, make sure that the value is same for the -# server process and all the csql client process which connects to it. otherwise, -# behavior is undefined -#####################################Client Section######################## - -#Mutex timeout interval seconds -MUTEX_TIMEOUT_SECS=0 -MUTEX_TIMEOUT_USECS=5000 -MUTEX_TIMEOUT_RETRIES=10 - -#Lock timeout interval seconds -LOCK_TIMEOUT_SECS=0 -LOCK_TIMEOUT_USECS=5000 -LOCK_TIMEOUT_RETRIES=10 - -#####################################Cache Section######################## - -#Whether to enable caching of tables from target database -CACHE_TABLE=false - -#DSN Name to connect to the target database. -#This should be present in ~/odbc.ini file -DSN=myodbc3 - -#Give full path for the file where all the cached table information is stored -TABLE_CONFIG_FILE=/tmp/csql/csqltable.conf - -#####################################End Section######################## diff --git a/test/tools/csqldump/drop.sql b/test/tools/csqldump/drop.sql deleted file mode 100644 index 853c1ad6..00000000 --- a/test/tools/csqldump/drop.sql +++ /dev/null @@ -1 +0,0 @@ -drop table t1; diff --git a/test/tools/csqldump/dropall.sql b/test/tools/csqldump/dropall.sql deleted file mode 100644 index bf1acd9a..00000000 --- a/test/tools/csqldump/dropall.sql +++ /dev/null @@ -1,11 +0,0 @@ -drop table kishor; -drop table rahul; -drop table ramesh; -drop table vinod; -drop table vikas; -drop table vikram; -drop table ravi; -drop table kiran; -drop table jayant; -drop table anand; - diff --git a/test/tools/csqldump/exp.test002.ksh b/test/tools/csqldump/exp.test002.ksh deleted file mode 100644 index 77ff2fd7..00000000 --- a/test/tools/csqldump/exp.test002.ksh +++ /dev/null @@ -1,31 +0,0 @@ -CREATE TABLE t1 (f1 INT NOT NULL , f2 CHAR (32)); -CREATE INDEX t1_idx1_Primary on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(51, 'Praba'); -INSERT INTO t1 VALUES(2, 'Lakshya2'); -INSERT INTO t1 VALUES(3, 'Lakshya3'); -INSERT INTO t1 VALUES(4, 'Kishor'); -INSERT INTO t1 VALUES(5, 'Lakshya5'); -INSERT INTO t1 VALUES(6, 'Lakshya6'); -INSERT INTO t1 VALUES(7, 'Lakshya7'); -INSERT INTO t1 VALUES(58, 'Lakshya8'); -INSERT INTO t1 VALUES(9, 'Lakshya9'); -INSERT INTO t1 VALUES(10, 'Lakshya10'); -COMMIT; -INSERT INTO t1 VALUES(11, 'Lakshya11'); -INSERT INTO t1 VALUES(12, 'Kiran'); -INSERT INTO t1 VALUES(69, 'Lakshya13'); -INSERT INTO t1 VALUES(14, 'Lakshya14'); -INSERT INTO t1 VALUES(15, 'Lakshya15'); -INSERT INTO t1 VALUES(16, 'Lakshya16'); -INSERT INTO t1 VALUES(31, 'Lakshya17'); -INSERT INTO t1 VALUES(18, 'jitendra'); -INSERT INTO t1 VALUES(19, 'Lakshya19'); -INSERT INTO t1 VALUES(20, 'Lakshya20'); -COMMIT; -INSERT INTO t1 VALUES(21, 'Lakshya21'); -INSERT INTO t1 VALUES(72, 'suman'); -INSERT INTO t1 VALUES(23, 'Lakshya23'); -INSERT INTO t1 VALUES(24, 'Lakshya24'); -INSERT INTO t1 VALUES(25, 'Lakshya25'); -COMMIT; diff --git a/test/tools/csqldump/exp.test003.ksh b/test/tools/csqldump/exp.test003.ksh deleted file mode 100644 index 4c712bf0..00000000 --- a/test/tools/csqldump/exp.test003.ksh +++ /dev/null @@ -1,108 +0,0 @@ -CREATE TABLE t1 (f1 INT NOT NULL , f2 CHAR (32)); -CREATE INDEX t1_idx1_Primary on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(123, 'india'); -INSERT INTO t1 VALUES(72, 'Lakshya72'); -INSERT INTO t1 VALUES(73, 'Lakshya73'); -INSERT INTO t1 VALUES(74, 'Lakshya74'); -INSERT INTO t1 VALUES(456, 'Lakshya75'); -INSERT INTO t1 VALUES(76, 'Lakshya76'); -INSERT INTO t1 VALUES(77, 'Lakshya77'); -INSERT INTO t1 VALUES(78, 'Lakshya78'); -INSERT INTO t1 VALUES(79, 'Lakshya79'); -INSERT INTO t1 VALUES(80, 'Lakshya80'); -INSERT INTO t1 VALUES(81, 'Lakshya81'); -INSERT INTO t1 VALUES(82, 'Lakshya82'); -INSERT INTO t1 VALUES(40, 'Lakshya40'); -INSERT INTO t1 VALUES(41, 'Lakshya41'); -INSERT INTO t1 VALUES(42, 'Lakshya42'); -INSERT INTO t1 VALUES(43, 'Lakshya43'); -INSERT INTO t1 VALUES(44, 'Lakshya44'); -INSERT INTO t1 VALUES(45, 'Lakshya45'); -INSERT INTO t1 VALUES(46, 'Lakshya46'); -INSERT INTO t1 VALUES(47, 'Lakshya47'); -COMMIT; -INSERT INTO t1 VALUES(18, 'Lakshya18'); -INSERT INTO t1 VALUES(555, 'Malaysia63'); -INSERT INTO t1 VALUES(64, 'Lakshya64'); -INSERT INTO t1 VALUES(65, 'Lakshya65'); -INSERT INTO t1 VALUES(66, 'Lakshya66'); -INSERT INTO t1 VALUES(67, 'Lakshya67'); -INSERT INTO t1 VALUES(68, 'Lakshya68'); -INSERT INTO t1 VALUES(19, 'Lakshya19'); -INSERT INTO t1 VALUES(823, 'Lakshya83'); -INSERT INTO t1 VALUES(84, 'Lakshya84'); -INSERT INTO t1 VALUES(85, 'Lakshya85'); -INSERT INTO t1 VALUES(11, 'Lakshya11'); -INSERT INTO t1 VALUES(12, 'Lakshya12'); -INSERT INTO t1 VALUES(13, 'Lakshya13'); -INSERT INTO t1 VALUES(14, 'Lakshya14'); -INSERT INTO t1 VALUES(15, 'Lakshya15'); -INSERT INTO t1 VALUES(16, 'Lakshya16'); -INSERT INTO t1 VALUES(17, 'Lakshya17'); -INSERT INTO t1 VALUES(530, 'Lakshya30'); -INSERT INTO t1 VALUES(31, 'Lakshya31'); -COMMIT; -INSERT INTO t1 VALUES(32, 'Lakshya32'); -INSERT INTO t1 VALUES(33, 'Lakshya33'); -INSERT INTO t1 VALUES(34, 'Lakshya34'); -INSERT INTO t1 VALUES(35, 'Lakshya35'); -INSERT INTO t1 VALUES(36, 'Pakistan'); -INSERT INTO t1 VALUES(37, 'Lakshya37'); -INSERT INTO t1 VALUES(777, 'Lakshya38'); -INSERT INTO t1 VALUES(39, 'Lakshya39'); -INSERT INTO t1 VALUES(20, 'Lakshya20'); -INSERT INTO t1 VALUES(21, 'Lakshya21'); -INSERT INTO t1 VALUES(22, 'Lakshya22'); -INSERT INTO t1 VALUES(23, 'Lakshya23'); -INSERT INTO t1 VALUES(24, 'Lakshya24'); -INSERT INTO t1 VALUES(25, 'Lakshya25'); -INSERT INTO t1 VALUES(26, 'Lakshya26'); -INSERT INTO t1 VALUES(27, 'Lakshya27'); -INSERT INTO t1 VALUES(28, 'Lakshya28'); -INSERT INTO t1 VALUES(29, 'Lakshya29'); -INSERT INTO t1 VALUES(48, 'Lakshya48'); -INSERT INTO t1 VALUES(49, 'Lakshya49'); -COMMIT; -INSERT INTO t1 VALUES(50, 'Lakshya50'); -INSERT INTO t1 VALUES(51, 'Lakshya51'); -INSERT INTO t1 VALUES(142, 'Lakshya52'); -INSERT INTO t1 VALUES(53, 'Lakshya53'); -INSERT INTO t1 VALUES(54, 'Lakshya54'); -INSERT INTO t1 VALUES(55, 'Lakshya55'); -INSERT INTO t1 VALUES(56, 'Lakshya56'); -INSERT INTO t1 VALUES(90, 'Lakshya90'); -INSERT INTO t1 VALUES(91, 'Lakshya91'); -INSERT INTO t1 VALUES(92, 'Lakshya92'); -INSERT INTO t1 VALUES(93, 'Lakshya93'); -INSERT INTO t1 VALUES(94, 'Lakshya94'); -INSERT INTO t1 VALUES(95, 'Lakshya95'); -INSERT INTO t1 VALUES(96, 'Lakshya96'); -INSERT INTO t1 VALUES(97, 'Lakshya97'); -INSERT INTO t1 VALUES(98, 'Lakshya98'); -INSERT INTO t1 VALUES(99, 'Lakshya99'); -INSERT INTO t1 VALUES(100, 'Lakshya100'); -INSERT INTO t1 VALUES(1, 'Lakshya1'); -INSERT INTO t1 VALUES(2, 'Lakshya2'); -COMMIT; -INSERT INTO t1 VALUES(3, 'Lakshya3'); -INSERT INTO t1 VALUES(4, 'Lakshya4'); -INSERT INTO t1 VALUES(5, 'Lakshya5'); -INSERT INTO t1 VALUES(6, 'Lakshya6'); -INSERT INTO t1 VALUES(7, 'Lakshya7'); -INSERT INTO t1 VALUES(8, 'Lakshya8'); -INSERT INTO t1 VALUES(9, 'Lakshya9'); -INSERT INTO t1 VALUES(10, 'Lakshya10'); -INSERT INTO t1 VALUES(57, 'Lakshya57'); -INSERT INTO t1 VALUES(58, 'Lakshya58'); -INSERT INTO t1 VALUES(59, 'Lakshya59'); -INSERT INTO t1 VALUES(60, 'Lakshya60'); -INSERT INTO t1 VALUES(61, 'Lakshya61'); -INSERT INTO t1 VALUES(62, 'Lakshya62'); -INSERT INTO t1 VALUES(69, 'Lakshya69'); -INSERT INTO t1 VALUES(70, 'Lakshya70'); -INSERT INTO t1 VALUES(86, 'Lakshya86'); -INSERT INTO t1 VALUES(87, 'Lakshya87'); -INSERT INTO t1 VALUES(88, 'Lakshya88'); -INSERT INTO t1 VALUES(89, 'Lakshya89'); -COMMIT; diff --git a/test/tools/csqldump/exp.test004.ksh b/test/tools/csqldump/exp.test004.ksh deleted file mode 100644 index 444fab16..00000000 --- a/test/tools/csqldump/exp.test004.ksh +++ /dev/null @@ -1,106 +0,0 @@ -CREATE TABLE t1 (f1 INT NOT NULL , f2 CHAR (32)); -CREATE INDEX t1_idx1_Primary on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(123, 'india'); -INSERT INTO t1 VALUES(72, 'Laxman72'); -INSERT INTO t1 VALUES(73, 'Laxman73'); -INSERT INTO t1 VALUES(74, 'Laxman74'); -INSERT INTO t1 VALUES(456, 'Laxman75'); -INSERT INTO t1 VALUES(76, 'Laxman76'); -INSERT INTO t1 VALUES(77, 'Laxman77'); -INSERT INTO t1 VALUES(78, 'Laxman78'); -INSERT INTO t1 VALUES(79, 'Laxman79'); -INSERT INTO t1 VALUES(80, 'Laxman80'); -INSERT INTO t1 VALUES(81, 'Laxman81'); -INSERT INTO t1 VALUES(82, 'Laxman82'); -INSERT INTO t1 VALUES(40, 'Laxman40'); -INSERT INTO t1 VALUES(41, 'Laxman41'); -INSERT INTO t1 VALUES(42, 'Laxman42'); -INSERT INTO t1 VALUES(43, 'Laxman43'); -INSERT INTO t1 VALUES(44, 'Laxman44'); -INSERT INTO t1 VALUES(45, 'Laxman45'); -INSERT INTO t1 VALUES(46, 'Laxman46'); -INSERT INTO t1 VALUES(47, 'Laxman47'); -INSERT INTO t1 VALUES(18, 'Laxman18'); -INSERT INTO t1 VALUES(555, 'Malaysia63'); -INSERT INTO t1 VALUES(64, 'Laxman64'); -INSERT INTO t1 VALUES(65, 'Laxman65'); -INSERT INTO t1 VALUES(66, 'Laxman66'); -INSERT INTO t1 VALUES(67, 'Laxman67'); -INSERT INTO t1 VALUES(68, 'Laxman68'); -INSERT INTO t1 VALUES(19, 'Laxman19'); -INSERT INTO t1 VALUES(823, 'Laxman83'); -INSERT INTO t1 VALUES(84, 'Laxman84'); -COMMIT; -INSERT INTO t1 VALUES(85, 'Laxman85'); -INSERT INTO t1 VALUES(11, 'Laxman11'); -INSERT INTO t1 VALUES(12, 'Laxman12'); -INSERT INTO t1 VALUES(13, 'Laxman13'); -INSERT INTO t1 VALUES(14, 'Laxman14'); -INSERT INTO t1 VALUES(15, 'Laxman15'); -INSERT INTO t1 VALUES(16, 'Laxman16'); -INSERT INTO t1 VALUES(17, 'Laxman17'); -INSERT INTO t1 VALUES(530, 'Laxman30'); -INSERT INTO t1 VALUES(31, 'Laxman31'); -INSERT INTO t1 VALUES(32, 'Laxman32'); -INSERT INTO t1 VALUES(33, 'Paris3'); -INSERT INTO t1 VALUES(34, 'Laxman34'); -INSERT INTO t1 VALUES(35, 'Laxman35'); -INSERT INTO t1 VALUES(36, 'Pakistan'); -INSERT INTO t1 VALUES(37, 'Laxman37'); -INSERT INTO t1 VALUES(777, 'Laxman38'); -INSERT INTO t1 VALUES(39, 'Laxman39'); -INSERT INTO t1 VALUES(20, 'Laxman20'); -INSERT INTO t1 VALUES(21, 'Laxman21'); -INSERT INTO t1 VALUES(22, 'Laxman22'); -INSERT INTO t1 VALUES(23, 'Laxman23'); -INSERT INTO t1 VALUES(24, 'Laxman24'); -INSERT INTO t1 VALUES(25, 'Laxman25'); -INSERT INTO t1 VALUES(26, 'Laxman26'); -INSERT INTO t1 VALUES(27, 'Laxman27'); -INSERT INTO t1 VALUES(28, 'Laxman28'); -INSERT INTO t1 VALUES(29, 'Laxman29'); -INSERT INTO t1 VALUES(48, 'London'); -INSERT INTO t1 VALUES(49, 'Laxman49'); -COMMIT; -INSERT INTO t1 VALUES(50, 'Laxman50'); -INSERT INTO t1 VALUES(51, 'Laxman51'); -INSERT INTO t1 VALUES(142, 'Laxman52'); -INSERT INTO t1 VALUES(53, 'Laxman53'); -INSERT INTO t1 VALUES(54, 'Laxman54'); -INSERT INTO t1 VALUES(55, 'Laxman55'); -INSERT INTO t1 VALUES(56, 'Laxman56'); -INSERT INTO t1 VALUES(90, 'Laxman90'); -INSERT INTO t1 VALUES(91, 'Laxman91'); -INSERT INTO t1 VALUES(92, 'Laxman92'); -INSERT INTO t1 VALUES(93, 'Laxman93'); -INSERT INTO t1 VALUES(94, 'Laxman94'); -INSERT INTO t1 VALUES(95, 'Laxman95'); -INSERT INTO t1 VALUES(96, 'Laxman96'); -INSERT INTO t1 VALUES(97, 'Laxman97'); -INSERT INTO t1 VALUES(98, 'Laxman98'); -INSERT INTO t1 VALUES(99, 'Laxman99'); -INSERT INTO t1 VALUES(1, 'Laxman1'); -INSERT INTO t1 VALUES(2, 'Laxman2'); -INSERT INTO t1 VALUES(3, 'Laxman3'); -INSERT INTO t1 VALUES(4, 'Laxman4'); -INSERT INTO t1 VALUES(5, 'Laxman5'); -INSERT INTO t1 VALUES(6, 'Laxman6'); -INSERT INTO t1 VALUES(7, 'Laxman7'); -INSERT INTO t1 VALUES(8, 'Laxman8'); -INSERT INTO t1 VALUES(9, 'Laxman9'); -INSERT INTO t1 VALUES(10, 'Laxman10'); -INSERT INTO t1 VALUES(57, 'Laxman57'); -INSERT INTO t1 VALUES(58, 'Laxman58'); -INSERT INTO t1 VALUES(59, 'Laxman59'); -COMMIT; -INSERT INTO t1 VALUES(60, 'Laxman60'); -INSERT INTO t1 VALUES(61, 'Laxman61'); -INSERT INTO t1 VALUES(62, 'Laxman62'); -INSERT INTO t1 VALUES(69, 'Laxman69'); -INSERT INTO t1 VALUES(70, 'Laxman70'); -INSERT INTO t1 VALUES(86, 'Laxman86'); -INSERT INTO t1 VALUES(87, 'Laxman87'); -INSERT INTO t1 VALUES(88, 'Laxman88'); -INSERT INTO t1 VALUES(89, 'Laxman89'); -COMMIT; diff --git a/test/tools/csqldump/exp.test005.ksh b/test/tools/csqldump/exp.test005.ksh deleted file mode 100644 index bfaa4cf7..00000000 --- a/test/tools/csqldump/exp.test005.ksh +++ /dev/null @@ -1,109 +0,0 @@ -CREATE TABLE t1 (f1 INT NOT NULL , f2 CHAR (32)); -CREATE INDEX t1_idx1_Primary on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(123, 'india'); -INSERT INTO t1 VALUES(72, 'Laxwoman72'); -INSERT INTO t1 VALUES(25, 'Laxwoman25'); -INSERT INTO t1 VALUES(77, 'Laxwoman77'); -INSERT INTO t1 VALUES(78, 'Laxwoman78'); -INSERT INTO t1 VALUES(79, 'Laxwoman79'); -INSERT INTO t1 VALUES(80, 'Laxwoman80'); -INSERT INTO t1 VALUES(26, 'Laxwoman26'); -INSERT INTO t1 VALUES(27, 'Laxwoman27'); -INSERT INTO t1 VALUES(28, 'Laxwoman28'); -INSERT INTO t1 VALUES(29, 'Laxwoman29'); -INSERT INTO t1 VALUES(48, 'London'); -INSERT INTO t1 VALUES(49, 'Laxwoman49'); -INSERT INTO t1 VALUES(50, 'Laxwoman50'); -INSERT INTO t1 VALUES(51, 'Laxwoman51'); -INSERT INTO t1 VALUES(142, 'Laxwoman52'); -INSERT INTO t1 VALUES(53, 'Laxwoman53'); -INSERT INTO t1 VALUES(54, 'Laxwoman54'); -INSERT INTO t1 VALUES(55, 'Laxwoman55'); -INSERT INTO t1 VALUES(56, 'Laxwoman56'); -INSERT INTO t1 VALUES(90, 'Laxwoman90'); -INSERT INTO t1 VALUES(91, 'Laxwoman91'); -INSERT INTO t1 VALUES(92, 'Laxwoman92'); -INSERT INTO t1 VALUES(93, 'Laxwoman93'); -INSERT INTO t1 VALUES(94, 'Laxwoman94'); -COMMIT; -INSERT INTO t1 VALUES(95, 'Laxwoman95'); -INSERT INTO t1 VALUES(73, 'Laxwoman73'); -INSERT INTO t1 VALUES(74, 'Laxwoman74'); -INSERT INTO t1 VALUES(456, 'Laxwoman75'); -INSERT INTO t1 VALUES(76, 'Laxwoman76'); -INSERT INTO t1 VALUES(81, 'Laxwoman81'); -INSERT INTO t1 VALUES(82, 'Laxwoman82'); -INSERT INTO t1 VALUES(40, 'Laxwoman40'); -INSERT INTO t1 VALUES(41, 'Laxwoman41'); -INSERT INTO t1 VALUES(42, 'Laxwoman42'); -INSERT INTO t1 VALUES(43, 'Laxwoman43'); -INSERT INTO t1 VALUES(44, 'Laxwoman44'); -INSERT INTO t1 VALUES(45, 'Laxwoman45'); -INSERT INTO t1 VALUES(46, 'Laxwoman46'); -INSERT INTO t1 VALUES(47, 'Laxwoman47'); -INSERT INTO t1 VALUES(18, 'Laxwoman18'); -INSERT INTO t1 VALUES(555, 'Malaysia63'); -INSERT INTO t1 VALUES(64, 'Laxwoman64'); -INSERT INTO t1 VALUES(65, 'Laxwoman65'); -INSERT INTO t1 VALUES(66, 'Laxwoman66'); -INSERT INTO t1 VALUES(67, 'Laxwoman67'); -INSERT INTO t1 VALUES(68, 'Laxwoman68'); -INSERT INTO t1 VALUES(19, 'Laxwoman19'); -INSERT INTO t1 VALUES(823, 'Laxwoman83'); -INSERT INTO t1 VALUES(84, 'Laxwoman84'); -COMMIT; -INSERT INTO t1 VALUES(85, 'Laxwoman85'); -INSERT INTO t1 VALUES(11, 'Laxwoman11'); -INSERT INTO t1 VALUES(12, 'Laxwoman12'); -INSERT INTO t1 VALUES(13, 'Laxwoman13'); -INSERT INTO t1 VALUES(14, 'Laxwoman14'); -INSERT INTO t1 VALUES(15, 'Laxwoman15'); -INSERT INTO t1 VALUES(16, 'Laxwoman16'); -INSERT INTO t1 VALUES(17, 'Laxwoman17'); -INSERT INTO t1 VALUES(530, 'Laxwoman30'); -INSERT INTO t1 VALUES(31, 'Laxwoman31'); -INSERT INTO t1 VALUES(32, 'Laxwoman32'); -INSERT INTO t1 VALUES(33, 'Paris3'); -INSERT INTO t1 VALUES(34, 'Laxwoman34'); -INSERT INTO t1 VALUES(35, 'Laxwoman35'); -INSERT INTO t1 VALUES(36, 'Pakistan'); -INSERT INTO t1 VALUES(37, 'Laxwoman37'); -INSERT INTO t1 VALUES(777, 'Laxwoman38'); -INSERT INTO t1 VALUES(39, 'Laxwoman39'); -INSERT INTO t1 VALUES(20, 'Laxwoman20'); -INSERT INTO t1 VALUES(21, 'Laxwoman21'); -INSERT INTO t1 VALUES(22, 'Laxwoman22'); -INSERT INTO t1 VALUES(23, 'Laxwoman23'); -INSERT INTO t1 VALUES(24, 'Laxwoman24'); -INSERT INTO t1 VALUES(96, 'Laxwoman96'); -INSERT INTO t1 VALUES(97, 'Laxwoman97'); -COMMIT; -INSERT INTO t1 VALUES(98, 'Laxwoman98'); -INSERT INTO t1 VALUES(1, 'Laxwoman1'); -INSERT INTO t1 VALUES(2, 'Laxwoman2'); -INSERT INTO t1 VALUES(3, 'Laxwoman3'); -INSERT INTO t1 VALUES(4, 'Laxwoman4'); -INSERT INTO t1 VALUES(5, 'Laxwoman5'); -INSERT INTO t1 VALUES(6, 'Laxwoman6'); -INSERT INTO t1 VALUES(7, 'Laxwoman7'); -INSERT INTO t1 VALUES(8, 'Laxwoman8'); -INSERT INTO t1 VALUES(9, 'Laxwoman9'); -INSERT INTO t1 VALUES(10, 'Laxwoman10'); -INSERT INTO t1 VALUES(57, 'Laxwoman57'); -INSERT INTO t1 VALUES(58, 'Laxwoman58'); -INSERT INTO t1 VALUES(59, 'Laxwoman59'); -INSERT INTO t1 VALUES(60, 'Laxwoman60'); -INSERT INTO t1 VALUES(61, 'Laxwoman61'); -INSERT INTO t1 VALUES(62, 'Laxwoman62'); -INSERT INTO t1 VALUES(69, 'Laxwoman69'); -INSERT INTO t1 VALUES(70, 'Laxwoman70'); -INSERT INTO t1 VALUES(86, 'Laxwoman86'); -INSERT INTO t1 VALUES(87, 'Laxwoman87'); -INSERT INTO t1 VALUES(88, 'Laxwoman88'); -INSERT INTO t1 VALUES(89, 'Laxwoman89'); -INSERT INTO t1 VALUES(1189, 'Laxwoman89'); -INSERT INTO t1 VALUES(2289, 'Laxwoman89'); -COMMIT; -INSERT INTO t1 VALUES(3389, 'Laxwoman89'); -COMMIT; diff --git a/test/tools/csqldump/exp.test006.ksh b/test/tools/csqldump/exp.test006.ksh deleted file mode 100644 index bc5c27b6..00000000 --- a/test/tools/csqldump/exp.test006.ksh +++ /dev/null @@ -1,105 +0,0 @@ -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT DEFAULT '10' ); -CREATE INDEX indx1 on t1 ( f1 ) HASH ; -CREATE INDEX indx2 on t1 ( f2 ) HASH ; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(131,10); -INSERT INTO t1 VALUES(141,10); -INSERT INTO t1 VALUES(13,41); -INSERT INTO t1 VALUES(143,41); -INSERT INTO t1 VALUES(153,41); -INSERT INTO t1 VALUES(163,41); -INSERT INTO t1 VALUES(151,10); -INSERT INTO t1 VALUES(1631,10); -INSERT INTO t1 VALUES(163,41); -INSERT INTO t1 VALUES(13,41); -INSERT INTO t1 VALUES(23,41); -INSERT INTO t1 VALUES(551,10); -INSERT INTO t1 VALUES(631,10); -INSERT INTO t1 VALUES(43,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(33,41); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(4,41); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(41,10); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(43,41); -INSERT INTO t1 VALUES(53,41); -INSERT INTO t1 VALUES(63,41); -INSERT INTO t1 VALUES(51,10); -INSERT INTO t1 VALUES(631,10); -INSERT INTO t1 VALUES(63,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(51,10); -INSERT INTO t1 VALUES(631,10); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(4,41); -INSERT INTO t1 VALUES(41,10); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(43,41); -INSERT INTO t1 VALUES(53,41); -INSERT INTO t1 VALUES(63,41); -INSERT INTO t1 VALUES(51,10); -INSERT INTO t1 VALUES(631,10); -INSERT INTO t1 VALUES(63,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(51,10); -INSERT INTO t1 VALUES(631,10); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(4,41); -INSERT INTO t1 VALUES(41,10); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(43,41); -INSERT INTO t1 VALUES(53,41); -INSERT INTO t1 VALUES(63,41); -INSERT INTO t1 VALUES(51,10); -INSERT INTO t1 VALUES(631,10); -INSERT INTO t1 VALUES(63,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(51,10); -INSERT INTO t1 VALUES(631,10); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(31,10); -INSERT INTO t1 VALUES(4,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(43,41); -INSERT INTO t1 VALUES(53,41); -INSERT INTO t1 VALUES(63,41); -INSERT INTO t1 VALUES(51,10); -INSERT INTO t1 VALUES(631,10); -INSERT INTO t1 VALUES(63,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(51,10); -INSERT INTO t1 VALUES(6317,10); -INSERT INTO t1 VALUES(3,41); -INSERT INTO t1 VALUES(3,413); -INSERT INTO t1 VALUES(3,431); -INSERT INTO t1 VALUES(3,941); -INSERT INTO t1 VALUES(631,10); -INSERT INTO t1 VALUES(431,10); -INSERT INTO t1 VALUES(14,41); -COMMIT; diff --git a/test/tools/csqldump/exp.test007.ksh b/test/tools/csqldump/exp.test007.ksh deleted file mode 100644 index 26c7f848..00000000 --- a/test/tools/csqldump/exp.test007.ksh +++ /dev/null @@ -1,23 +0,0 @@ -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT ); -CREATE INDEX indx on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(0,5); -INSERT INTO t1 VALUES(1,5); -INSERT INTO t1 VALUES(2,5); -INSERT INTO t1 VALUES(3,5); -INSERT INTO t1 VALUES(4,5); -INSERT INTO t1 VALUES(5,5); -INSERT INTO t1 VALUES(6,5); -INSERT INTO t1 VALUES(7,5); -INSERT INTO t1 VALUES(8,5); -INSERT INTO t1 VALUES(9,5); -INSERT INTO t1 VALUES(999991,5); -INSERT INTO t1 VALUES(999992,5); -INSERT INTO t1 VALUES(999993,5); -INSERT INTO t1 VALUES(999994,5); -INSERT INTO t1 VALUES(999995,5); -INSERT INTO t1 VALUES(999996,5); -INSERT INTO t1 VALUES(999997,5); -INSERT INTO t1 VALUES(999998,5); -INSERT INTO t1 VALUES(999999,5); -COMMIT; diff --git a/test/tools/csqldump/exp.test008.ksh b/test/tools/csqldump/exp.test008.ksh deleted file mode 100644 index 9d761f17..00000000 --- a/test/tools/csqldump/exp.test008.ksh +++ /dev/null @@ -1,131 +0,0 @@ -CREATE TABLE kishor (fld1 INT NOT NULL , name1 CHAR (32)); -CREATE INDEX kishor_idx1_Primary on kishor ( fld1 ) HASH UNIQUE; -CREATE TABLE ravi (fld2 INT NOT NULL , name1 CHAR (32)); -CREATE INDEX ravi_idx1_Primary on ravi ( fld2 ) HASH UNIQUE; -CREATE TABLE kiran (fld3 INT NOT NULL , name1 CHAR (32)); -CREATE INDEX kiran_idx1_Primary on kiran ( fld3 ) HASH UNIQUE; -CREATE TABLE anand (fld4 INT NOT NULL , name1 CHAR (32)); -CREATE INDEX anand_idx1_Primary on anand ( fld4 ) HASH UNIQUE; -CREATE TABLE vikas (fld5 INT NOT NULL , name1 CHAR (32)); -CREATE INDEX vikas_idx1_Primary on vikas ( fld5 ) HASH UNIQUE; -CREATE TABLE vikram (fld6 INT NOT NULL , name1 CHAR (32)); -CREATE INDEX vikram_idx1_Primary on vikram ( fld6 ) HASH UNIQUE; -CREATE TABLE vinod (fld7 INT NOT NULL , name1 CHAR (32)); -CREATE INDEX vinod_idx1_Primary on vinod ( fld7 ) HASH UNIQUE; -CREATE TABLE jayant (fld8 INT NOT NULL , name1 CHAR (32)); -CREATE INDEX jayant_idx1_Primary on jayant ( fld8 ) HASH UNIQUE; -CREATE TABLE rahul (fld9 INT NOT NULL , name1 CHAR (32)); -CREATE INDEX rahul_idx1_Primary on rahul ( fld9 ) HASH UNIQUE; -CREATE TABLE ramesh (fld10 INT NOT NULL , name1 CHAR (32)); -CREATE INDEX ramesh_idx1_Primary on ramesh ( fld10 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO kishor VALUES(11, 'raksha1'); -INSERT INTO kishor VALUES(2, 'Laxkshya2'); -INSERT INTO kishor VALUES(32, 'Laksxhya3'); -INSERT INTO kishor VALUES(4, 'Lakhya4'); -INSERT INTO kishor VALUES(5, 'Laka5'); -INSERT INTO kishor VALUES(63, 'shya6'); -INSERT INTO kishor VALUES(7, 'Laksya7'); -INSERT INTO kishor VALUES(18, 'Lakya8'); -INSERT INTO kishor VALUES(97, 'Lakhya9'); -INSERT INTO kishor VALUES(104, 'Laa10'); -COMMIT; -INSERT INTO ravi VALUES(11, 'Lakshy'); -INSERT INTO ravi VALUES(22, 'raksha2'); -INSERT INTO ravi VALUES(33, 'raksha3'); -INSERT INTO ravi VALUES(44, 'Lak4'); -INSERT INTO ravi VALUES(55, 'raksha5'); -INSERT INTO ravi VALUES(66, 'Lakya6'); -INSERT INTO ravi VALUES(77, 'raksha7'); -INSERT INTO ravi VALUES(88, 'Laksa8'); -INSERT INTO ravi VALUES(99, 'Laksya9'); -INSERT INTO ravi VALUES(100, 'Lashya10'); -COMMIT; -INSERT INTO kiran VALUES(31, 'raksha1'); -INSERT INTO kiran VALUES(42, 'Lakshya2'); -INSERT INTO kiran VALUES(53, 'raksha3'); -INSERT INTO kiran VALUES(64, 'Lakshya4'); -INSERT INTO kiran VALUES(58, 'raksha5'); -INSERT INTO kiran VALUES(63, 'Lakshya6'); -INSERT INTO kiran VALUES(74, 'raksha7'); -INSERT INTO kiran VALUES(87, 'Lakshya8'); -INSERT INTO kiran VALUES(94, 'raksha9'); -INSERT INTO kiran VALUES(10, 'Lakshya10'); -COMMIT; -INSERT INTO anand VALUES(12, 'Lakshya1'); -INSERT INTO anand VALUES(23, 'raksha2'); -INSERT INTO anand VALUES(35, 'Lakshya3'); -INSERT INTO anand VALUES(48, 'Lakshya4'); -INSERT INTO anand VALUES(53, 'raksha5'); -INSERT INTO anand VALUES(66, 'Lakshya6'); -INSERT INTO anand VALUES(79, 'Lakshya7'); -INSERT INTO anand VALUES(81, 'raksha8'); -INSERT INTO anand VALUES(94, 'Lakshya9'); -INSERT INTO anand VALUES(105, 'Lakshya10'); -COMMIT; -INSERT INTO vikas VALUES(1, 'Lakshya1'); -INSERT INTO vikas VALUES(2, 'Lakshya2'); -INSERT INTO vikas VALUES(3, 'raksha3'); -INSERT INTO vikas VALUES(4, 'Lakshya4'); -INSERT INTO vikas VALUES(5, 'Lakshya5'); -INSERT INTO vikas VALUES(6, 'Lakshya6'); -INSERT INTO vikas VALUES(7, 'Lakshya7'); -INSERT INTO vikas VALUES(8, 'Lakshya8'); -INSERT INTO vikas VALUES(9, 'raksha9'); -INSERT INTO vikas VALUES(10, 'Lakshya10'); -COMMIT; -INSERT INTO vikram VALUES(1, 'Lakshya1'); -INSERT INTO vikram VALUES(2, 'raksha2'); -INSERT INTO vikram VALUES(3, 'Lakshya3'); -INSERT INTO vikram VALUES(4, 'raksha4'); -INSERT INTO vikram VALUES(5, 'Lakshya5'); -INSERT INTO vikram VALUES(6, 'Lakshya6'); -INSERT INTO vikram VALUES(7, 'raksha7'); -INSERT INTO vikram VALUES(8, 'Lakshya8'); -INSERT INTO vikram VALUES(9, 'Lakshya9'); -INSERT INTO vikram VALUES(10, 'Lakshya10'); -COMMIT; -INSERT INTO vinod VALUES(1, 'Lakshya1'); -INSERT INTO vinod VALUES(2, 'raksha2'); -INSERT INTO vinod VALUES(3, 'Lakshya3'); -INSERT INTO vinod VALUES(4, 'Lakshya4'); -INSERT INTO vinod VALUES(5, 'raksha5'); -INSERT INTO vinod VALUES(6, 'Lakshya6'); -INSERT INTO vinod VALUES(7, 'Lakshya7'); -INSERT INTO vinod VALUES(8, 'raksha8'); -INSERT INTO vinod VALUES(9, 'Lakshya9'); -INSERT INTO vinod VALUES(10, 'Lakshya10'); -COMMIT; -INSERT INTO jayant VALUES(1, 'Lakshya1'); -INSERT INTO jayant VALUES(2, 'raksha2'); -INSERT INTO jayant VALUES(3, 'Lakshya3'); -INSERT INTO jayant VALUES(4, 'Lakshya4'); -INSERT INTO jayant VALUES(5, 'raksha5'); -INSERT INTO jayant VALUES(6, 'Lakshya6'); -INSERT INTO jayant VALUES(7, 'Lakshya7'); -INSERT INTO jayant VALUES(8, 'raksha8'); -INSERT INTO jayant VALUES(9, 'Lakshya9'); -INSERT INTO jayant VALUES(10, 'Lakshya10'); -COMMIT; -INSERT INTO rahul VALUES(1, 'Lakshya1'); -INSERT INTO rahul VALUES(2, 'Lakshya2'); -INSERT INTO rahul VALUES(3, 'raksha3'); -INSERT INTO rahul VALUES(4, 'Lakshya4'); -INSERT INTO rahul VALUES(5, 'Lakshya5'); -INSERT INTO rahul VALUES(6, 'raksha6'); -INSERT INTO rahul VALUES(7, 'Lakshya7'); -INSERT INTO rahul VALUES(8, 'Lakshya8'); -INSERT INTO rahul VALUES(9, 'Lakshya9'); -INSERT INTO rahul VALUES(10, 'Lakshya10'); -COMMIT; -INSERT INTO ramesh VALUES(1, 'Lakshya1'); -INSERT INTO ramesh VALUES(2, 'Lakshya2'); -INSERT INTO ramesh VALUES(3, 'Lakshya3'); -INSERT INTO ramesh VALUES(4, 'Lakshya4'); -INSERT INTO ramesh VALUES(5, 'Lakshya5'); -INSERT INTO ramesh VALUES(6, 'raksha6'); -INSERT INTO ramesh VALUES(7, 'raksha7'); -INSERT INTO ramesh VALUES(8, 'raksha8'); -INSERT INTO ramesh VALUES(9, 'raksha9'); -INSERT INTO ramesh VALUES(10, 'Lakshya10'); -COMMIT; diff --git a/test/tools/csqldump/exp.test010.ksh b/test/tools/csqldump/exp.test010.ksh deleted file mode 100644 index 93c53306..00000000 --- a/test/tools/csqldump/exp.test010.ksh +++ /dev/null @@ -1,32 +0,0 @@ -CREATE TABLE t1 (f1 INT NOT NULL , f2 CHAR (32)); -CREATE INDEX t1_idx1_Primary on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(51, 'Praba'); -INSERT INTO t1 VALUES(2, 'Lakshya2'); -INSERT INTO t1 VALUES(3, 'Lakshya3'); -INSERT INTO t1 VALUES(4, 'Kishor'); -INSERT INTO t1 VALUES(5, 'Lakshya5'); -INSERT INTO t1 VALUES(6, 'Lakshya6'); -INSERT INTO t1 VALUES(7, 'Lakshya7'); -INSERT INTO t1 VALUES(58, 'Lakshya8'); -COMMIT; -INSERT INTO t1 VALUES(9, 'Lakshya9'); -INSERT INTO t1 VALUES(10, 'Lakshya10'); -INSERT INTO t1 VALUES(11, 'Lakshya11'); -INSERT INTO t1 VALUES(12, 'Kiran'); -INSERT INTO t1 VALUES(69, 'Lakshya13'); -INSERT INTO t1 VALUES(14, 'Lakshya14'); -INSERT INTO t1 VALUES(15, 'Lakshya15'); -INSERT INTO t1 VALUES(16, 'Lakshya16'); -COMMIT; -INSERT INTO t1 VALUES(31, 'Lakshya17'); -INSERT INTO t1 VALUES(18, 'jitendra'); -INSERT INTO t1 VALUES(19, 'Lakshya19'); -INSERT INTO t1 VALUES(20, 'Lakshya20'); -INSERT INTO t1 VALUES(21, 'Lakshya21'); -INSERT INTO t1 VALUES(72, 'suman'); -INSERT INTO t1 VALUES(23, 'Lakshya23'); -INSERT INTO t1 VALUES(24, 'Lakshya24'); -COMMIT; -INSERT INTO t1 VALUES(25, 'Lakshya25'); -COMMIT; diff --git a/test/tools/csqldump/exp.test011.ksh b/test/tools/csqldump/exp.test011.ksh deleted file mode 100644 index 7c8e027a..00000000 --- a/test/tools/csqldump/exp.test011.ksh +++ /dev/null @@ -1,17 +0,0 @@ -CREATE TABLE vikas (fld5 INT NOT NULL , name1 CHAR (32)); -CREATE INDEX vikas_idx1_Primary on vikas ( fld5 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO vikas VALUES(1, 'Lakshya1'); -INSERT INTO vikas VALUES(2, 'Lakshya2'); -INSERT INTO vikas VALUES(3, 'raksha3'); -COMMIT; -INSERT INTO vikas VALUES(4, 'Lakshya4'); -INSERT INTO vikas VALUES(5, 'Lakshya5'); -INSERT INTO vikas VALUES(6, 'Lakshya6'); -COMMIT; -INSERT INTO vikas VALUES(7, 'Lakshya7'); -INSERT INTO vikas VALUES(8, 'Lakshya8'); -INSERT INTO vikas VALUES(9, 'raksha9'); -COMMIT; -INSERT INTO vikas VALUES(10, 'Lakshya10'); -COMMIT; diff --git a/test/tools/csqldump/exp.test012.ksh b/test/tools/csqldump/exp.test012.ksh deleted file mode 100644 index 56e83945..00000000 --- a/test/tools/csqldump/exp.test012.ksh +++ /dev/null @@ -1,167 +0,0 @@ -CREATE TABLE t1 (f1 INT NOT NULL , f2 INT ); -CREATE INDEX t1_idx1_Primary on t1 ( f1 ) HASH UNIQUE; -SET AUTOCOMMIT OFF; -INSERT INTO t1 VALUES(0,1); -INSERT INTO t1 VALUES(1,11); -INSERT INTO t1 VALUES(2,21); -INSERT INTO t1 VALUES(3,31); -INSERT INTO t1 VALUES(4,41); -INSERT INTO t1 VALUES(5,51); -INSERT INTO t1 VALUES(6,61); -INSERT INTO t1 VALUES(7,71); -INSERT INTO t1 VALUES(8,81); -INSERT INTO t1 VALUES(9,91); -INSERT INTO t1 VALUES(10,101); -INSERT INTO t1 VALUES(11,111); -INSERT INTO t1 VALUES(12,121); -INSERT INTO t1 VALUES(13,131); -INSERT INTO t1 VALUES(14,141); -INSERT INTO t1 VALUES(15,151); -INSERT INTO t1 VALUES(16,161); -INSERT INTO t1 VALUES(17,171); -INSERT INTO t1 VALUES(18,181); -INSERT INTO t1 VALUES(19,191); -INSERT INTO t1 VALUES(20,201); -INSERT INTO t1 VALUES(21,211); -INSERT INTO t1 VALUES(22,221); -INSERT INTO t1 VALUES(23,231); -INSERT INTO t1 VALUES(24,241); -COMMIT; -INSERT INTO t1 VALUES(25,251); -INSERT INTO t1 VALUES(26,261); -INSERT INTO t1 VALUES(27,271); -INSERT INTO t1 VALUES(28,281); -INSERT INTO t1 VALUES(29,291); -INSERT INTO t1 VALUES(30,301); -INSERT INTO t1 VALUES(31,311); -INSERT INTO t1 VALUES(32,321); -INSERT INTO t1 VALUES(33,331); -INSERT INTO t1 VALUES(34,341); -INSERT INTO t1 VALUES(35,351); -INSERT INTO t1 VALUES(36,361); -INSERT INTO t1 VALUES(37,371); -INSERT INTO t1 VALUES(38,381); -INSERT INTO t1 VALUES(39,391); -INSERT INTO t1 VALUES(40,401); -INSERT INTO t1 VALUES(41,411); -INSERT INTO t1 VALUES(42,421); -INSERT INTO t1 VALUES(43,431); -INSERT INTO t1 VALUES(44,441); -INSERT INTO t1 VALUES(45,451); -INSERT INTO t1 VALUES(46,461); -INSERT INTO t1 VALUES(47,471); -INSERT INTO t1 VALUES(48,481); -INSERT INTO t1 VALUES(49,491); -COMMIT; -INSERT INTO t1 VALUES(50,501); -INSERT INTO t1 VALUES(51,511); -INSERT INTO t1 VALUES(52,521); -INSERT INTO t1 VALUES(53,531); -INSERT INTO t1 VALUES(54,541); -INSERT INTO t1 VALUES(55,551); -INSERT INTO t1 VALUES(56,561); -INSERT INTO t1 VALUES(57,571); -INSERT INTO t1 VALUES(58,581); -INSERT INTO t1 VALUES(59,591); -INSERT INTO t1 VALUES(60,601); -INSERT INTO t1 VALUES(61,611); -INSERT INTO t1 VALUES(62,621); -INSERT INTO t1 VALUES(63,631); -INSERT INTO t1 VALUES(64,641); -INSERT INTO t1 VALUES(65,651); -INSERT INTO t1 VALUES(66,661); -INSERT INTO t1 VALUES(67,671); -INSERT INTO t1 VALUES(68,681); -INSERT INTO t1 VALUES(69,691); -INSERT INTO t1 VALUES(70,701); -INSERT INTO t1 VALUES(71,711); -INSERT INTO t1 VALUES(72,721); -INSERT INTO t1 VALUES(73,731); -INSERT INTO t1 VALUES(74,741); -COMMIT; -INSERT INTO t1 VALUES(75,751); -INSERT INTO t1 VALUES(76,761); -INSERT INTO t1 VALUES(77,771); -INSERT INTO t1 VALUES(78,781); -INSERT INTO t1 VALUES(79,791); -INSERT INTO t1 VALUES(80,801); -INSERT INTO t1 VALUES(81,811); -INSERT INTO t1 VALUES(82,821); -INSERT INTO t1 VALUES(83,831); -INSERT INTO t1 VALUES(84,841); -INSERT INTO t1 VALUES(85,851); -INSERT INTO t1 VALUES(86,861); -INSERT INTO t1 VALUES(87,871); -INSERT INTO t1 VALUES(88,881); -INSERT INTO t1 VALUES(89,891); -INSERT INTO t1 VALUES(90,901); -INSERT INTO t1 VALUES(91,911); -INSERT INTO t1 VALUES(92,921); -INSERT INTO t1 VALUES(93,931); -INSERT INTO t1 VALUES(94,941); -INSERT INTO t1 VALUES(95,951); -INSERT INTO t1 VALUES(96,961); -INSERT INTO t1 VALUES(97,971); -INSERT INTO t1 VALUES(98,981); -INSERT INTO t1 VALUES(99,991); -COMMIT; -INSERT INTO t1 VALUES(100,1001); -INSERT INTO t1 VALUES(101,1011); -INSERT INTO t1 VALUES(102,1021); -INSERT INTO t1 VALUES(103,1031); -INSERT INTO t1 VALUES(104,1041); -INSERT INTO t1 VALUES(105,1051); -INSERT INTO t1 VALUES(106,1061); -INSERT INTO t1 VALUES(107,1071); -INSERT INTO t1 VALUES(108,1081); -INSERT INTO t1 VALUES(109,1091); -INSERT INTO t1 VALUES(110,1101); -INSERT INTO t1 VALUES(111,1111); -INSERT INTO t1 VALUES(112,1121); -INSERT INTO t1 VALUES(113,1131); -INSERT INTO t1 VALUES(114,1141); -INSERT INTO t1 VALUES(115,1151); -INSERT INTO t1 VALUES(116,1161); -INSERT INTO t1 VALUES(117,1171); -INSERT INTO t1 VALUES(118,1181); -INSERT INTO t1 VALUES(119,1191); -INSERT INTO t1 VALUES(120,1201); -INSERT INTO t1 VALUES(121,1211); -INSERT INTO t1 VALUES(122,1221); -INSERT INTO t1 VALUES(123,1231); -INSERT INTO t1 VALUES(124,1241); -COMMIT; -INSERT INTO t1 VALUES(125,1251); -INSERT INTO t1 VALUES(126,1261); -INSERT INTO t1 VALUES(127,1271); -INSERT INTO t1 VALUES(128,1281); -INSERT INTO t1 VALUES(129,1291); -INSERT INTO t1 VALUES(130,1301); -INSERT INTO t1 VALUES(131,1311); -INSERT INTO t1 VALUES(132,1321); -INSERT INTO t1 VALUES(133,1331); -INSERT INTO t1 VALUES(134,1341); -INSERT INTO t1 VALUES(135,1351); -INSERT INTO t1 VALUES(136,1361); -INSERT INTO t1 VALUES(137,1371); -INSERT INTO t1 VALUES(138,1381); -INSERT INTO t1 VALUES(139,1391); -INSERT INTO t1 VALUES(140,1401); -INSERT INTO t1 VALUES(141,1411); -INSERT INTO t1 VALUES(142,1421); -INSERT INTO t1 VALUES(143,1431); -INSERT INTO t1 VALUES(144,1441); -INSERT INTO t1 VALUES(145,1451); -INSERT INTO t1 VALUES(146,1461); -INSERT INTO t1 VALUES(147,1471); -INSERT INTO t1 VALUES(148,1481); -INSERT INTO t1 VALUES(149,1491); -COMMIT; -INSERT INTO t1 VALUES(150,1501); -INSERT INTO t1 VALUES(151,1511); -INSERT INTO t1 VALUES(152,1521); -INSERT INTO t1 VALUES(153,1531); -INSERT INTO t1 VALUES(154,1541); -INSERT INTO t1 VALUES(155,1551); -INSERT INTO t1 VALUES(156,1561); -COMMIT; diff --git a/test/tools/csqldump/inputtest002.sql b/test/tools/csqldump/inputtest002.sql deleted file mode 100644 index c015e545..00000000 --- a/test/tools/csqldump/inputtest002.sql +++ /dev/null @@ -1,26 +0,0 @@ -create table t1 (f1 int, f2 char(30), primary key (f1)); -insert into t1 values(51, 'Praba'); -insert into t1 values(2, 'Lakshya2'); -insert into t1 values(3, 'Lakshya3'); -insert into t1 values(4, 'Kishor'); -insert into t1 values(5, 'Lakshya5'); -insert into t1 values(6, 'Lakshya6'); -insert into t1 values(7, 'Lakshya7'); -insert into t1 values(58, 'Lakshya8'); -insert into t1 values(9, 'Lakshya9'); -insert into t1 values(10, 'Lakshya10'); -insert into t1 values(11, 'Lakshya11'); -insert into t1 values(12, 'Kiran'); -insert into t1 values(69, 'Lakshya13'); -insert into t1 values(14, 'Lakshya14'); -insert into t1 values(15, 'Lakshya15'); -insert into t1 values(16, 'Lakshya16'); -insert into t1 values(31, 'Lakshya17'); -insert into t1 values(18, 'jitendra'); -insert into t1 values(19, 'Lakshya19'); -insert into t1 values(20, 'Lakshya20'); -insert into t1 values(21, 'Lakshya21'); -insert into t1 values(72, 'suman'); -insert into t1 values(23, 'Lakshya23'); -insert into t1 values(24, 'Lakshya24'); -insert into t1 values(25, 'Lakshya25'); diff --git a/test/tools/csqldump/inputtest003.sql b/test/tools/csqldump/inputtest003.sql deleted file mode 100644 index 848873e1..00000000 --- a/test/tools/csqldump/inputtest003.sql +++ /dev/null @@ -1,101 +0,0 @@ -create table t1(f1 int, f2 char(30), primary key (f1)); -insert into t1 values(123, 'india'); -insert into t1 values(72, 'Lakshya72'); -insert into t1 values(73, 'Lakshya73'); -insert into t1 values(74, 'Lakshya74'); -insert into t1 values(456, 'Lakshya75'); -insert into t1 values(76, 'Lakshya76'); -insert into t1 values(77, 'Lakshya77'); -insert into t1 values(78, 'Lakshya78'); -insert into t1 values(79, 'Lakshya79'); -insert into t1 values(80, 'Lakshya80'); -insert into t1 values(81, 'Lakshya81'); -insert into t1 values(82, 'Lakshya82'); -insert into t1 values(40, 'Lakshya40'); -insert into t1 values(41, 'Lakshya41'); -insert into t1 values(42, 'Lakshya42'); -insert into t1 values(43, 'Lakshya43'); -insert into t1 values(44, 'Lakshya44'); -insert into t1 values(45, 'Lakshya45'); -insert into t1 values(46, 'Lakshya46'); -insert into t1 values(47, 'Lakshya47'); -insert into t1 values(18, 'Lakshya18'); -insert into t1 values(555, 'Malaysia63'); -insert into t1 values(64, 'Lakshya64'); -insert into t1 values(65, 'Lakshya65'); -insert into t1 values(66, 'Lakshya66'); -insert into t1 values(67, 'Lakshya67'); -insert into t1 values(68, 'Lakshya68'); -insert into t1 values(19, 'Lakshya19'); -insert into t1 values(823, 'Lakshya83'); -insert into t1 values(84, 'Lakshya84'); -insert into t1 values(85, 'Lakshya85'); -insert into t1 values(11, 'Lakshya11'); -insert into t1 values(12, 'Lakshya12'); -insert into t1 values(13, 'Lakshya13'); -insert into t1 values(14, 'Lakshya14'); -insert into t1 values(15, 'Lakshya15'); -insert into t1 values(16, 'Lakshya16'); -insert into t1 values(17, 'Lakshya17'); -insert into t1 values(530, 'Lakshya30'); -insert into t1 values(31, 'Lakshya31'); -insert into t1 values(32, 'Lakshya32'); -insert into t1 values(33, 'Lakshya33'); -insert into t1 values(34, 'Lakshya34'); -insert into t1 values(35, 'Lakshya35'); -insert into t1 values(36, 'Pakistan'); -insert into t1 values(37, 'Lakshya37'); -insert into t1 values(777, 'Lakshya38'); -insert into t1 values(39, 'Lakshya39'); -insert into t1 values(20, 'Lakshya20'); -insert into t1 values(21, 'Lakshya21'); -insert into t1 values(22, 'Lakshya22'); -insert into t1 values(23, 'Lakshya23'); -insert into t1 values(24, 'Lakshya24'); -insert into t1 values(25, 'Lakshya25'); -insert into t1 values(26, 'Lakshya26'); -insert into t1 values(27, 'Lakshya27'); -insert into t1 values(28, 'Lakshya28'); -insert into t1 values(29, 'Lakshya29'); -insert into t1 values(48, 'Lakshya48'); -insert into t1 values(49, 'Lakshya49'); -insert into t1 values(50, 'Lakshya50'); -insert into t1 values(51, 'Lakshya51'); -insert into t1 values(142, 'Lakshya52'); -insert into t1 values(53, 'Lakshya53'); -insert into t1 values(54, 'Lakshya54'); -insert into t1 values(55, 'Lakshya55'); -insert into t1 values(56, 'Lakshya56'); -insert into t1 values(90, 'Lakshya90'); -insert into t1 values(91, 'Lakshya91'); -insert into t1 values(92, 'Lakshya92'); -insert into t1 values(93, 'Lakshya93'); -insert into t1 values(94, 'Lakshya94'); -insert into t1 values(95, 'Lakshya95'); -insert into t1 values(96, 'Lakshya96'); -insert into t1 values(97, 'Lakshya97'); -insert into t1 values(98, 'Lakshya98'); -insert into t1 values(99, 'Lakshya99'); -insert into t1 values(100, 'Lakshya100'); -insert into t1 values(1, 'Lakshya1'); -insert into t1 values(2, 'Lakshya2'); -insert into t1 values(3, 'Lakshya3'); -insert into t1 values(4, 'Lakshya4'); -insert into t1 values(5, 'Lakshya5'); -insert into t1 values(6, 'Lakshya6'); -insert into t1 values(7, 'Lakshya7'); -insert into t1 values(8, 'Lakshya8'); -insert into t1 values(9, 'Lakshya9'); -insert into t1 values(10, 'Lakshya10'); -insert into t1 values(57, 'Lakshya57'); -insert into t1 values(58, 'Lakshya58'); -insert into t1 values(59, 'Lakshya59'); -insert into t1 values(60, 'Lakshya60'); -insert into t1 values(61, 'Lakshya61'); -insert into t1 values(62, 'Lakshya62'); -insert into t1 values(69, 'Lakshya69'); -insert into t1 values(70, 'Lakshya70'); -insert into t1 values(86, 'Lakshya86'); -insert into t1 values(87, 'Lakshya87'); -insert into t1 values(88, 'Lakshya88'); -insert into t1 values(89, 'Lakshya89'); diff --git a/test/tools/csqldump/inputtest004.sql b/test/tools/csqldump/inputtest004.sql deleted file mode 100644 index 7ed987b6..00000000 --- a/test/tools/csqldump/inputtest004.sql +++ /dev/null @@ -1,100 +0,0 @@ -create table t1(f1 int, f2 char(30), primary key (f1)); -insert into t1 values(123, 'india'); -insert into t1 values(72, 'Laxman72'); -insert into t1 values(73, 'Laxman73'); -insert into t1 values(74, 'Laxman74'); -insert into t1 values(456, 'Laxman75'); -insert into t1 values(76, 'Laxman76'); -insert into t1 values(77, 'Laxman77'); -insert into t1 values(78, 'Laxman78'); -insert into t1 values(79, 'Laxman79'); -insert into t1 values(80, 'Laxman80'); -insert into t1 values(81, 'Laxman81'); -insert into t1 values(82, 'Laxman82'); -insert into t1 values(40, 'Laxman40'); -insert into t1 values(41, 'Laxman41'); -insert into t1 values(42, 'Laxman42'); -insert into t1 values(43, 'Laxman43'); -insert into t1 values(44, 'Laxman44'); -insert into t1 values(45, 'Laxman45'); -insert into t1 values(46, 'Laxman46'); -insert into t1 values(47, 'Laxman47'); -insert into t1 values(18, 'Laxman18'); -insert into t1 values(555, 'Malaysia63'); -insert into t1 values(64, 'Laxman64'); -insert into t1 values(65, 'Laxman65'); -insert into t1 values(66, 'Laxman66'); -insert into t1 values(67, 'Laxman67'); -insert into t1 values(68, 'Laxman68'); -insert into t1 values(19, 'Laxman19'); -insert into t1 values(823, 'Laxman83'); -insert into t1 values(84, 'Laxman84'); -insert into t1 values(85, 'Laxman85'); -insert into t1 values(11, 'Laxman11'); -insert into t1 values(12, 'Laxman12'); -insert into t1 values(13, 'Laxman13'); -insert into t1 values(14, 'Laxman14'); -insert into t1 values(15, 'Laxman15'); -insert into t1 values(16, 'Laxman16'); -insert into t1 values(17, 'Laxman17'); -insert into t1 values(530, 'Laxman30'); -insert into t1 values(31, 'Laxman31'); -insert into t1 values(32, 'Laxman32'); -insert into t1 values(33, 'Paris3'); -insert into t1 values(34, 'Laxman34'); -insert into t1 values(35, 'Laxman35'); -insert into t1 values(36, 'Pakistan'); -insert into t1 values(37, 'Laxman37'); -insert into t1 values(777, 'Laxman38'); -insert into t1 values(39, 'Laxman39'); -insert into t1 values(20, 'Laxman20'); -insert into t1 values(21, 'Laxman21'); -insert into t1 values(22, 'Laxman22'); -insert into t1 values(23, 'Laxman23'); -insert into t1 values(24, 'Laxman24'); -insert into t1 values(25, 'Laxman25'); -insert into t1 values(26, 'Laxman26'); -insert into t1 values(27, 'Laxman27'); -insert into t1 values(28, 'Laxman28'); -insert into t1 values(29, 'Laxman29'); -insert into t1 values(48, 'London'); -insert into t1 values(49, 'Laxman49'); -insert into t1 values(50, 'Laxman50'); -insert into t1 values(51, 'Laxman51'); -insert into t1 values(142, 'Laxman52'); -insert into t1 values(53, 'Laxman53'); -insert into t1 values(54, 'Laxman54'); -insert into t1 values(55, 'Laxman55'); -insert into t1 values(56, 'Laxman56'); -insert into t1 values(90, 'Laxman90'); -insert into t1 values(91, 'Laxman91'); -insert into t1 values(92, 'Laxman92'); -insert into t1 values(93, 'Laxman93'); -insert into t1 values(94, 'Laxman94'); -insert into t1 values(95, 'Laxman95'); -insert into t1 values(96, 'Laxman96'); -insert into t1 values(97, 'Laxman97'); -insert into t1 values(98, 'Laxman98'); -insert into t1 values(99, 'Laxman99'); -insert into t1 values(1, 'Laxman1'); -insert into t1 values(2, 'Laxman2'); -insert into t1 values(3, 'Laxman3'); -insert into t1 values(4, 'Laxman4'); -insert into t1 values(5, 'Laxman5'); -insert into t1 values(6, 'Laxman6'); -insert into t1 values(7, 'Laxman7'); -insert into t1 values(8, 'Laxman8'); -insert into t1 values(9, 'Laxman9'); -insert into t1 values(10, 'Laxman10'); -insert into t1 values(57, 'Laxman57'); -insert into t1 values(58, 'Laxman58'); -insert into t1 values(59, 'Laxman59'); -insert into t1 values(60, 'Laxman60'); -insert into t1 values(61, 'Laxman61'); -insert into t1 values(62, 'Laxman62'); -insert into t1 values(69, 'Laxman69'); -insert into t1 values(70, 'Laxman70'); -insert into t1 values(86, 'Laxman86'); -insert into t1 values(87, 'Laxman87'); -insert into t1 values(88, 'Laxman88'); -insert into t1 values(89, 'Laxman89'); diff --git a/test/tools/csqldump/inputtest005.sql b/test/tools/csqldump/inputtest005.sql deleted file mode 100644 index a6aab0af..00000000 --- a/test/tools/csqldump/inputtest005.sql +++ /dev/null @@ -1,102 +0,0 @@ -create table t1(f1 int, f2 char(30), primary key (f1)); -insert into t1 values(123, 'india'); -insert into t1 values(72, 'Laxwoman72'); -insert into t1 values(25, 'Laxwoman25'); -insert into t1 values(77, 'Laxwoman77'); -insert into t1 values(78, 'Laxwoman78'); -insert into t1 values(79, 'Laxwoman79'); -insert into t1 values(80, 'Laxwoman80'); -insert into t1 values(26, 'Laxwoman26'); -insert into t1 values(27, 'Laxwoman27'); -insert into t1 values(28, 'Laxwoman28'); -insert into t1 values(29, 'Laxwoman29'); -insert into t1 values(48, 'London'); -insert into t1 values(49, 'Laxwoman49'); -insert into t1 values(50, 'Laxwoman50'); -insert into t1 values(51, 'Laxwoman51'); -insert into t1 values(142, 'Laxwoman52'); -insert into t1 values(53, 'Laxwoman53'); -insert into t1 values(54, 'Laxwoman54'); -insert into t1 values(55, 'Laxwoman55'); -insert into t1 values(56, 'Laxwoman56'); -insert into t1 values(90, 'Laxwoman90'); -insert into t1 values(91, 'Laxwoman91'); -insert into t1 values(92, 'Laxwoman92'); -insert into t1 values(93, 'Laxwoman93'); -insert into t1 values(94, 'Laxwoman94'); -insert into t1 values(95, 'Laxwoman95'); -insert into t1 values(73, 'Laxwoman73'); -insert into t1 values(74, 'Laxwoman74'); -insert into t1 values(456, 'Laxwoman75'); -insert into t1 values(76, 'Laxwoman76'); -insert into t1 values(81, 'Laxwoman81'); -insert into t1 values(82, 'Laxwoman82'); -insert into t1 values(40, 'Laxwoman40'); -insert into t1 values(41, 'Laxwoman41'); -insert into t1 values(42, 'Laxwoman42'); -insert into t1 values(43, 'Laxwoman43'); -insert into t1 values(44, 'Laxwoman44'); -insert into t1 values(45, 'Laxwoman45'); -insert into t1 values(46, 'Laxwoman46'); -insert into t1 values(47, 'Laxwoman47'); -insert into t1 values(18, 'Laxwoman18'); -insert into t1 values(555, 'Malaysia63'); -insert into t1 values(64, 'Laxwoman64'); -insert into t1 values(65, 'Laxwoman65'); -insert into t1 values(66, 'Laxwoman66'); -insert into t1 values(67, 'Laxwoman67'); -insert into t1 values(68, 'Laxwoman68'); -insert into t1 values(19, 'Laxwoman19'); -insert into t1 values(823, 'Laxwoman83'); -insert into t1 values(84, 'Laxwoman84'); -insert into t1 values(85, 'Laxwoman85'); -insert into t1 values(11, 'Laxwoman11'); -insert into t1 values(12, 'Laxwoman12'); -insert into t1 values(13, 'Laxwoman13'); -insert into t1 values(14, 'Laxwoman14'); -insert into t1 values(15, 'Laxwoman15'); -insert into t1 values(16, 'Laxwoman16'); -insert into t1 values(17, 'Laxwoman17'); -insert into t1 values(530, 'Laxwoman30'); -insert into t1 values(31, 'Laxwoman31'); -insert into t1 values(32, 'Laxwoman32'); -insert into t1 values(33, 'Paris3'); -insert into t1 values(34, 'Laxwoman34'); -insert into t1 values(35, 'Laxwoman35'); -insert into t1 values(36, 'Pakistan'); -insert into t1 values(37, 'Laxwoman37'); -insert into t1 values(777, 'Laxwoman38'); -insert into t1 values(39, 'Laxwoman39'); -insert into t1 values(20, 'Laxwoman20'); -insert into t1 values(21, 'Laxwoman21'); -insert into t1 values(22, 'Laxwoman22'); -insert into t1 values(23, 'Laxwoman23'); -insert into t1 values(24, 'Laxwoman24'); -insert into t1 values(96, 'Laxwoman96'); -insert into t1 values(97, 'Laxwoman97'); -insert into t1 values(98, 'Laxwoman98'); -insert into t1 values(1, 'Laxwoman1'); -insert into t1 values(2, 'Laxwoman2'); -insert into t1 values(3, 'Laxwoman3'); -insert into t1 values(4, 'Laxwoman4'); -insert into t1 values(5, 'Laxwoman5'); -insert into t1 values(6, 'Laxwoman6'); -insert into t1 values(7, 'Laxwoman7'); -insert into t1 values(8, 'Laxwoman8'); -insert into t1 values(9, 'Laxwoman9'); -insert into t1 values(10, 'Laxwoman10'); -insert into t1 values(57, 'Laxwoman57'); -insert into t1 values(58, 'Laxwoman58'); -insert into t1 values(59, 'Laxwoman59'); -insert into t1 values(60, 'Laxwoman60'); -insert into t1 values(61, 'Laxwoman61'); -insert into t1 values(62, 'Laxwoman62'); -insert into t1 values(69, 'Laxwoman69'); -insert into t1 values(70, 'Laxwoman70'); -insert into t1 values(86, 'Laxwoman86'); -insert into t1 values(87, 'Laxwoman87'); -insert into t1 values(88, 'Laxwoman88'); -insert into t1 values(89, 'Laxwoman89'); -insert into t1 values(1189, 'Laxwoman89'); -insert into t1 values(2289, 'Laxwoman89'); -insert into t1 values(3389, 'Laxwoman89'); diff --git a/test/tools/csqldump/inputtest006.sql b/test/tools/csqldump/inputtest006.sql deleted file mode 100644 index f603e260..00000000 --- a/test/tools/csqldump/inputtest006.sql +++ /dev/null @@ -1,103 +0,0 @@ -create table t1(f1 int not null, f2 int default '10'); -create index indx1 on t1(f1); -create index indx2 on t1(f2); -insert into t1(f1) values(131); -insert into t1(f1) values(141); -insert into t1 values(13, 41); -insert into t1 values(143, 41); -insert into t1 values(153, 41); -insert into t1 values(163, 41); -insert into t1(f1) values(151); -insert into t1(f1) values(1631); -insert into t1 values(163, 41); -insert into t1 values(13, 41); -insert into t1 values(23, 41); -insert into t1(f1) values(551); -insert into t1(f1) values(631); -insert into t1 values(43, 41); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1 values(33, 41); -insert into t1(f1) values(31); -insert into t1(f1) values(31); -insert into t1 values(4, 41); -insert into t1(f1) values(31); -insert into t1(f1) values(31); -insert into t1(f1) values(31); -insert into t1(f1) values(31); -insert into t1(f1) values(31); -insert into t1(f1) values(41); -insert into t1 values(3, 41); -insert into t1 values(43, 41); -insert into t1 values(53, 41); -insert into t1 values(63, 41); -insert into t1(f1) values(51); -insert into t1(f1) values(631); -insert into t1 values(63, 41); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1(f1) values(51); -insert into t1(f1) values(631); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1(f1) values(31); -insert into t1(f1) values(31); -insert into t1 values(4, 41); -insert into t1(f1) values(41); -insert into t1 values(3, 41); -insert into t1 values(43, 41); -insert into t1 values(53, 41); -insert into t1 values(63, 41); -insert into t1(f1) values(51); -insert into t1(f1) values(631); -insert into t1 values(63, 41); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1(f1) values(51); -insert into t1(f1) values(631); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1(f1) values(31); -insert into t1(f1) values(31); -insert into t1 values(4, 41); -insert into t1(f1) values(41); -insert into t1 values(3, 41); -insert into t1 values(43, 41); -insert into t1 values(53, 41); -insert into t1 values(63, 41); -insert into t1(f1) values(51); -insert into t1(f1) values(631); -insert into t1 values(63, 41); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1(f1) values(51); -insert into t1(f1) values(631); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1(f1) values(31); -insert into t1(f1) values(31); -insert into t1 values(4, 41); -insert into t1 values(3, 41); -insert into t1 values(43, 41); -insert into t1 values(53, 41); -insert into t1 values(63, 41); -insert into t1(f1) values(51); -insert into t1(f1) values(631); -insert into t1 values(63, 41); -insert into t1 values(3, 41); -insert into t1 values(3, 41); -insert into t1(f1) values(51); -insert into t1(f1) values(6317); -insert into t1 values(3, 41); -insert into t1 values(3, 413); -insert into t1 values(3, 431); -insert into t1 values(3, 941); -insert into t1(f1) values(631); -insert into t1(f1) values(431); -insert into t1 values(14, 41); diff --git a/test/tools/csqldump/inputtest008.sql b/test/tools/csqldump/inputtest008.sql deleted file mode 100644 index ef836b11..00000000 --- a/test/tools/csqldump/inputtest008.sql +++ /dev/null @@ -1,110 +0,0 @@ -create table kishor(fld1 int, name1 char(30), primary key (fld1)); -insert into kishor values(11, 'raksha1'); -insert into kishor values(2, 'Laxkshya2'); -insert into kishor values(32, 'Laksxhya3'); -insert into kishor values(4, 'Lakhya4'); -insert into kishor values(5, 'Laka5'); -insert into kishor values(63, 'shya6'); -insert into kishor values(7, 'Laksya7'); -insert into kishor values(18, 'Lakya8'); -insert into kishor values(97, 'Lakhya9'); -insert into kishor values(104, 'Laa10'); -create table ravi(fld2 int, name1 char(30), primary key (fld2)); -insert into ravi values(11, 'Lakshy'); -insert into ravi values(22, 'raksha2'); -insert into ravi values(33, 'raksha3'); -insert into ravi values(44, 'Lak4'); -insert into ravi values(55, 'raksha5'); -insert into ravi values(66, 'Lakya6'); -insert into ravi values(77, 'raksha7'); -insert into ravi values(88, 'Laksa8'); -insert into ravi values(99, 'Laksya9'); -insert into ravi values(100, 'Lashya10'); -create table kiran(fld3 int, name1 char(30), primary key (fld3)); -insert into kiran values(31, 'raksha1'); -insert into kiran values(42, 'Lakshya2'); -insert into kiran values(53, 'raksha3'); -insert into kiran values(64, 'Lakshya4'); -insert into kiran values(58, 'raksha5'); -insert into kiran values(63, 'Lakshya6'); -insert into kiran values(74, 'raksha7'); -insert into kiran values(87, 'Lakshya8'); -insert into kiran values(94, 'raksha9'); -insert into kiran values(10, 'Lakshya10'); -create table anand(fld4 int, name1 char(30), primary key (fld4)); -insert into anand values(12, 'Lakshya1'); -insert into anand values(23, 'raksha2'); -insert into anand values(35, 'Lakshya3'); -insert into anand values(48, 'Lakshya4'); -insert into anand values(53, 'raksha5'); -insert into anand values(66, 'Lakshya6'); -insert into anand values(79, 'Lakshya7'); -insert into anand values(81, 'raksha8'); -insert into anand values(94, 'Lakshya9'); -insert into anand values(105, 'Lakshya10'); -create table vikas(fld5 int, name1 char(30), primary key (fld5)); -insert into vikas values(1, 'Lakshya1'); -insert into vikas values(2, 'Lakshya2'); -insert into vikas values(3, 'raksha3'); -insert into vikas values(4, 'Lakshya4'); -insert into vikas values(5, 'Lakshya5'); -insert into vikas values(6, 'Lakshya6'); -insert into vikas values(7, 'Lakshya7'); -insert into vikas values(8, 'Lakshya8'); -insert into vikas values(9, 'raksha9'); -insert into vikas values(10, 'Lakshya10'); -create table vikram(fld6 int, name1 char(30), primary key (fld6)); -insert into vikram values(1, 'Lakshya1'); -insert into vikram values(2, 'raksha2'); -insert into vikram values(3, 'Lakshya3'); -insert into vikram values(4, 'raksha4'); -insert into vikram values(5, 'Lakshya5'); -insert into vikram values(6, 'Lakshya6'); -insert into vikram values(7, 'raksha7'); -insert into vikram values(8, 'Lakshya8'); -insert into vikram values(9, 'Lakshya9'); -insert into vikram values(10, 'Lakshya10'); -create table vinod(fld7 int, name1 char(30), primary key (fld7)); -insert into vinod values(1, 'Lakshya1'); -insert into vinod values(2, 'raksha2'); -insert into vinod values(3, 'Lakshya3'); -insert into vinod values(4, 'Lakshya4'); -insert into vinod values(5, 'raksha5'); -insert into vinod values(6, 'Lakshya6'); -insert into vinod values(7, 'Lakshya7'); -insert into vinod values(8, 'raksha8'); -insert into vinod values(9, 'Lakshya9'); -insert into vinod values(10, 'Lakshya10'); -create table jayant(fld8 int, name1 char(30), primary key (fld8)); -insert into jayant values(1, 'Lakshya1'); -insert into jayant values(2, 'raksha2'); -insert into jayant values(3, 'Lakshya3'); -insert into jayant values(4, 'Lakshya4'); -insert into jayant values(5, 'raksha5'); -insert into jayant values(6, 'Lakshya6'); -insert into jayant values(7, 'Lakshya7'); -insert into jayant values(8, 'raksha8'); -insert into jayant values(9, 'Lakshya9'); -insert into jayant values(10, 'Lakshya10'); -create table rahul(fld9 int, name1 char(30), primary key (fld9)); -insert into rahul values(1, 'Lakshya1'); -insert into rahul values(2, 'Lakshya2'); -insert into rahul values(3, 'raksha3'); -insert into rahul values(4, 'Lakshya4'); -insert into rahul values(5, 'Lakshya5'); -insert into rahul values(6, 'raksha6'); -insert into rahul values(7, 'Lakshya7'); -insert into rahul values(8, 'Lakshya8'); -insert into rahul values(9, 'Lakshya9'); -insert into rahul values(10, 'Lakshya10'); -create table ramesh(fld10 int, name1 char(30), primary key (fld10)); -insert into ramesh values(1, 'Lakshya1'); -insert into ramesh values(2, 'Lakshya2'); -insert into ramesh values(3, 'Lakshya3'); -insert into ramesh values(4, 'Lakshya4'); -insert into ramesh values(5, 'Lakshya5'); -insert into ramesh values(6, 'raksha6'); -insert into ramesh values(7, 'raksha7'); -insert into ramesh values(8, 'raksha8'); -insert into ramesh values(9, 'raksha9'); -insert into ramesh values(10, 'Lakshya10'); diff --git a/test/tools/csqldump/inputtest012.sql b/test/tools/csqldump/inputtest012.sql deleted file mode 100644 index 18889888..00000000 --- a/test/tools/csqldump/inputtest012.sql +++ /dev/null @@ -1,158 +0,0 @@ -create table t1 (f1 int, f2 int, primary key(f1)); -insert into t1 values (0, 01); -insert into t1 values (1, 11); -insert into t1 values (2, 21); -insert into t1 values (3, 31); -insert into t1 values (4, 41); -insert into t1 values (5, 51); -insert into t1 values (6, 61); -insert into t1 values (7, 71); -insert into t1 values (8, 81); -insert into t1 values (9, 91); -insert into t1 values (10, 101); -insert into t1 values (11, 111); -insert into t1 values (12, 121); -insert into t1 values (13, 131); -insert into t1 values (14, 141); -insert into t1 values (15, 151); -insert into t1 values (16, 161); -insert into t1 values (17, 171); -insert into t1 values (18, 181); -insert into t1 values (19, 191); -insert into t1 values (20, 201); -insert into t1 values (21, 211); -insert into t1 values (22, 221); -insert into t1 values (23, 231); -insert into t1 values (24, 241); -insert into t1 values (25, 251); -insert into t1 values (26, 261); -insert into t1 values (27, 271); -insert into t1 values (28, 281); -insert into t1 values (29, 291); -insert into t1 values (30, 301); -insert into t1 values (31, 311); -insert into t1 values (32, 321); -insert into t1 values (33, 331); -insert into t1 values (34, 341); -insert into t1 values (35, 351); -insert into t1 values (36, 361); -insert into t1 values (37, 371); -insert into t1 values (38, 381); -insert into t1 values (39, 391); -insert into t1 values (40, 401); -insert into t1 values (41, 411); -insert into t1 values (42, 421); -insert into t1 values (43, 431); -insert into t1 values (44, 441); -insert into t1 values (45, 451); -insert into t1 values (46, 461); -insert into t1 values (47, 471); -insert into t1 values (48, 481); -insert into t1 values (49, 491); -insert into t1 values (50, 501); -insert into t1 values (51, 511); -insert into t1 values (52, 521); -insert into t1 values (53, 531); -insert into t1 values (54, 541); -insert into t1 values (55, 551); -insert into t1 values (56, 561); -insert into t1 values (57, 571); -insert into t1 values (58, 581); -insert into t1 values (59, 591); -insert into t1 values (60, 601); -insert into t1 values (61, 611); -insert into t1 values (62, 621); -insert into t1 values (63, 631); -insert into t1 values (64, 641); -insert into t1 values (65, 651); -insert into t1 values (66, 661); -insert into t1 values (67, 671); -insert into t1 values (68, 681); -insert into t1 values (69, 691); -insert into t1 values (70, 701); -insert into t1 values (71, 711); -insert into t1 values (72, 721); -insert into t1 values (73, 731); -insert into t1 values (74, 741); -insert into t1 values (75, 751); -insert into t1 values (76, 761); -insert into t1 values (77, 771); -insert into t1 values (78, 781); -insert into t1 values (79, 791); -insert into t1 values (80, 801); -insert into t1 values (81, 811); -insert into t1 values (82, 821); -insert into t1 values (83, 831); -insert into t1 values (84, 841); -insert into t1 values (85, 851); -insert into t1 values (86, 861); -insert into t1 values (87, 871); -insert into t1 values (88, 881); -insert into t1 values (89, 891); -insert into t1 values (90, 901); -insert into t1 values (91, 911); -insert into t1 values (92, 921); -insert into t1 values (93, 931); -insert into t1 values (94, 941); -insert into t1 values (95, 951); -insert into t1 values (96, 961); -insert into t1 values (97, 971); -insert into t1 values (98, 981); -insert into t1 values (99, 991); -insert into t1 values (100, 1001); -insert into t1 values (101, 1011); -insert into t1 values (102, 1021); -insert into t1 values (103, 1031); -insert into t1 values (104, 1041); -insert into t1 values (105, 1051); -insert into t1 values (106, 1061); -insert into t1 values (107, 1071); -insert into t1 values (108, 1081); -insert into t1 values (109, 1091); -insert into t1 values (110, 1101); -insert into t1 values (111, 1111); -insert into t1 values (112, 1121); -insert into t1 values (113, 1131); -insert into t1 values (114, 1141); -insert into t1 values (115, 1151); -insert into t1 values (116, 1161); -insert into t1 values (117, 1171); -insert into t1 values (118, 1181); -insert into t1 values (119, 1191); -insert into t1 values (120, 1201); -insert into t1 values (121, 1211); -insert into t1 values (122, 1221); -insert into t1 values (123, 1231); -insert into t1 values (124, 1241); -insert into t1 values (125, 1251); -insert into t1 values (126, 1261); -insert into t1 values (127, 1271); -insert into t1 values (128, 1281); -insert into t1 values (129, 1291); -insert into t1 values (130, 1301); -insert into t1 values (131, 1311); -insert into t1 values (132, 1321); -insert into t1 values (133, 1331); -insert into t1 values (134, 1341); -insert into t1 values (135, 1351); -insert into t1 values (136, 1361); -insert into t1 values (137, 1371); -insert into t1 values (138, 1381); -insert into t1 values (139, 1391); -insert into t1 values (140, 1401); -insert into t1 values (141, 1411); -insert into t1 values (142, 1421); -insert into t1 values (143, 1431); -insert into t1 values (144, 1441); -insert into t1 values (145, 1451); -insert into t1 values (146, 1461); -insert into t1 values (147, 1471); -insert into t1 values (148, 1481); -insert into t1 values (149, 1491); -insert into t1 values (150, 1501); -insert into t1 values (151, 1511); -insert into t1 values (152, 1521); -insert into t1 values (153, 1531); -insert into t1 values (154, 1541); -insert into t1 values (155, 1551); -insert into t1 values (156, 1561); diff --git a/test/tools/csqldump/insert.c b/test/tools/csqldump/insert.c deleted file mode 100644 index d4f7bda3..00000000 --- a/test/tools/csqldump/insert.c +++ /dev/null @@ -1,73 +0,0 @@ -//TestCase: We need to start new server to test this. -//the default db size set is not enough to test this -#include -int main() -{ - Connection conn; - DbRetVal rv = conn.open("root", "manager"); - if (rv != OK) return 1; - DatabaseManager *dbMgr = conn.getDatabaseManager(); - if (dbMgr == NULL) { printf("Auth failed\n"); return 2;} - - TableDef tabDef; - tabDef.addField("f1", typeInt, 0, NULL, true); - tabDef.addField("f2", typeInt); - rv = dbMgr->createTable("t1", tabDef); - if (rv != OK) { printf("Table creation failed\n"); conn.close(); return 3; } - printf("Table created\n"); - - HashIndexInitInfo *idxInfo = new HashIndexInitInfo(); - strcpy(idxInfo->tableName, "t1"); - idxInfo->list.append("f1"); - idxInfo->isUnique = true; - idxInfo->isPrimary = true; - idxInfo->indType = hashIndex; - rv = dbMgr->createIndex("indx", idxInfo); - if (rv != OK) { printf("Index creation failed\n"); return ErrUnknown; } - delete idxInfo; - Table *table = dbMgr->openTable("t1"); - if (table == NULL) - { - printf("Unable to open table\n"); - dbMgr->dropTable("t1"); - conn.close(); - return 2; - } - int id1 = 0, id2 = 5; - table->bindFld("f1", &id1); - table->bindFld("f2", &id2); - int icount =0; - for (int i = 0 ; i < 10000 ; i++) - { - conn.startTransaction(); - for (int j = 0 ; j < 100 ; j++) { - id1= icount++; - rv = table->insertTuple(); - if (rv != OK) break; - } - if (rv != OK) break; - conn.commit(); - } - printf("Tuples inserted %d\n", icount); - table->setCondition(NULL); - rv = table->execute(); - if (rv != OK) - { - dbMgr->closeTable(table); - dbMgr->dropTable("t1"); - conn.close(); - } - void *fld2ptr, *fld3ptr, *tuple; - icount = 0; - while(true) - { - tuple = (char*)table->fetch() ; - if (tuple == NULL) {break;} - icount++; - } - table->closeScan(); - dbMgr->closeTable(table); - conn.close(); - if (icount != 1000000) return 3; - return 0; -} diff --git a/test/tools/csqldump/test001.ksh b/test/tools/csqldump/test001.ksh deleted file mode 100755 index 06c339e2..00000000 --- a/test/tools/csqldump/test001.ksh +++ /dev/null @@ -1,19 +0,0 @@ -#!/bin/sh -# Test Case -# check no option, ? -# check whether authentication is working -# -echo "Case 1: With no option:" -$CSQL_INSTALL_ROOT/bin/csqldump -if [ $? -ne 0 ] -then - exit 1; -fi - -echo "Case 2: With ? option:" -$CSQL_INSTALL_ROOT/bin/csqldump -? -if [ $? -ne 0 ] -then - exit 1; -fi -exit 0; diff --git a/test/tools/csqldump/test002.ksh b/test/tools/csqldump/test002.ksh deleted file mode 100755 index 80d49f49..00000000 --- a/test/tools/csqldump/test002.ksh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -input=${PWD}/tools/csqldump/inputtest002.sql -REL_PATH=. -if [ -s "$input" ] -then - REL_PATH=${PWD}/tools/csqldump -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/inputtest002.sql >/dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 1; -fi -rm -f /tmp/csql/csqltable.conf -touch /tmp/csql/csqltable.conf -$CSQL_INSTALL_ROOT/bin/csqldump -n 10 - -if [ $? -ne 0 ] -then - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/drop.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 4; -fi - -exit 0; diff --git a/test/tools/csqldump/test003.ksh b/test/tools/csqldump/test003.ksh deleted file mode 100755 index bd711e7c..00000000 --- a/test/tools/csqldump/test003.ksh +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/sh - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -input=${PWD}/tools/csqldump/inputtest003.sql -REL_PATH=. -if [ -s "$input" ] -then - REL_PATH=${PWD}/tools/csqldump -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/inputtest003.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump -n 20 -if [ $? -ne 0 ] -then - exit 2; -fi - -cnt=`$CSQL_INSTALL_ROOT/bin/csqldump | grep VALUES | wc -l` - -if [ $? -ne 0 -a $cnt -ne 100 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/drop.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 4; -fi - -exit 0; diff --git a/test/tools/csqldump/test004.ksh b/test/tools/csqldump/test004.ksh deleted file mode 100755 index 89459498..00000000 --- a/test/tools/csqldump/test004.ksh +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/sh - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -input=${PWD}/tools/csqldump/inputtest004.sql -REL_PATH=. -if [ -s "$input" ] -then - REL_PATH=${PWD}/tools/csqldump -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/inputtest004.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump -n 30 -if [ $? -ne 0 ] -then - exit 2; -fi - -cnt=`$CSQL_INSTALL_ROOT/bin/csqldump | grep VALUES | wc -l` - -if [ $? -ne 0 -a $cnt -ne 99 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/drop.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 4; -fi - -exit 0; diff --git a/test/tools/csqldump/test005.ksh b/test/tools/csqldump/test005.ksh deleted file mode 100755 index 870e3f45..00000000 --- a/test/tools/csqldump/test005.ksh +++ /dev/null @@ -1,39 +0,0 @@ -#!/bin/sh - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -input=${PWD}/tools/csqldump/inputtest005.sql -REL_PATH=. -if [ -s "$input" ] -then - REL_PATH=${PWD}/tools/csqldump -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/inputtest005.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump -n 25 -if [ $? -ne 0 ] -then - exit 2; -fi - -cnt=`$CSQL_INSTALL_ROOT/bin/csqldump | grep VALUES | wc -l` - -if [ $? -ne 0 -a $cnt -ne 101 ] -then - exit 3; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/drop.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 4; -fi - -exit 0; diff --git a/test/tools/csqldump/test006.ksh b/test/tools/csqldump/test006.ksh deleted file mode 100755 index 6973b1a6..00000000 --- a/test/tools/csqldump/test006.ksh +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -input=${PWD}/tools/csqldump/inputtest006.sql -REL_PATH=. -if [ -s "$input" ] -then - REL_PATH=${PWD}/tools/csqldump -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/inputtest006.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump -if [ $? -ne 0 ] -then - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/drop.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 3; -fi - -exit 0; diff --git a/test/tools/csqldump/test007.ksh b/test/tools/csqldump/test007.ksh deleted file mode 100755 index 40e40d48..00000000 --- a/test/tools/csqldump/test007.ksh +++ /dev/null @@ -1,43 +0,0 @@ -#!/bin/sh - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -CSQL_CONF=${PWD}/tools/csqldump/csql.conf -executable=${PWD}/tools/csqldump/insert -REL_PATH=. -if [ -s "$executable" -a -s "$CSQL_CONF" ] -then - REL_PATH=${PWD}/tools/csqldump -fi -rm /tmp/csql/csql.db -export CSQL_CONFIG_FILE=$REL_PATH/csql.conf -$CSQL_INSTALL_ROOT/bin/csqlserver >/dev/null 2>&1 & -pid=$! -sleep 8 -$REL_PATH/insert >/dev/null 2>&1 -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump >tmp.out -if [ $? -ne 0 ] -then - exit 2; -fi - -head -n 13 tmp.out -tail tmp.out -rm -f tmp.out - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/drop.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 3; -fi - -kill -9 $pid > /dev/null 2>&1 -ipcrm -M 1234 -M 4321 - -exit 0; diff --git a/test/tools/csqldump/test008.ksh b/test/tools/csqldump/test008.ksh deleted file mode 100755 index 4001e073..00000000 --- a/test/tools/csqldump/test008.ksh +++ /dev/null @@ -1,32 +0,0 @@ -#!/bin/sh - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail -input=${PWD}/tools/csqldump/inputtest008.sql -REL_PATH=. -if [ -s "$input" ] -then - REL_PATH=${PWD}/tools/csqldump -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/inputtest008.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump -n 25 -if [ $? -ne 0 ] -then - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/dropall.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 3; -fi - -exit 0; diff --git a/test/tools/csqldump/test009.ksh b/test/tools/csqldump/test009.ksh deleted file mode 100755 index 692aaa2f..00000000 --- a/test/tools/csqldump/test009.ksh +++ /dev/null @@ -1,20 +0,0 @@ -#!/bin/sh - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail - -# dump the data of not existing table, should say table does not exist - -REL_PATH=. -if [ -s "$input" ] -then - REL_PATH=${PWD}/tools/csqldump -fi - -$CSQL_INSTALL_ROOT/bin/csqldump -T t1 -if [ $? -ne 0 ] -then - exit 0; -fi - -exit 1; diff --git a/test/tools/csqldump/test010.ksh b/test/tools/csqldump/test010.ksh deleted file mode 100755 index 3c3c2340..00000000 --- a/test/tools/csqldump/test010.ksh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail - -input=${PWD}/tools/csqldump/inputtest002.sql -REL_PATH=. -if [ -s "$input" ] -then - REL_PATH=${PWD}/tools/csqldump -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/inputtest002.sql >/dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump -n 8 -T t1 - -if [ $? -ne 0 ] -then - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/drop.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 4; -fi - -exit 0; diff --git a/test/tools/csqldump/test011.ksh b/test/tools/csqldump/test011.ksh deleted file mode 100755 index 0885db6d..00000000 --- a/test/tools/csqldump/test011.ksh +++ /dev/null @@ -1,36 +0,0 @@ -#!/bin/sh - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail - - - -input=${PWD}/tools/csqldump/inputtest008.sql -REL_PATH=. -if [ -s "$input" ] -then - REL_PATH=${PWD}/tools/csqldump -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/inputtest008.sql >/dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump -n 3 -T vikas - -if [ $? -ne 0 ] -then - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/dropall.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 3; -fi - -exit 0; diff --git a/test/tools/csqldump/test012.ksh b/test/tools/csqldump/test012.ksh deleted file mode 100755 index de95cce0..00000000 --- a/test/tools/csqldump/test012.ksh +++ /dev/null @@ -1,34 +0,0 @@ -#!/bin/sh - -#Run this test only under csql/test or on this directory. -#Otherwise, it may fail - -input=${PWD}/tools/csqldump/inputtest012.sql -REL_PATH=. -if [ -s "$input" ] -then - REL_PATH=${PWD}/tools/csqldump -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/inputtest012.sql >/dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 1; -fi - -$CSQL_INSTALL_ROOT/bin/csqldump -n 25 -T t1 - -if [ $? -ne 0 ] -then - exit 2; -fi - -$CSQL_INSTALL_ROOT/bin/csql -u root -p manager -s $REL_PATH/drop.sql > /dev/null 2>&1 - -if [ $? -ne 0 ] -then - exit 3; -fi - -exit 0; -- 2.11.4.GIT