Priyam Saikia Ruchika Mishra
Create, Insert, Run Query and Drop new tables. Run SQL queries in existing tables.
We have run the tpchgen program available from the TPC-H website to generate our own test data instances of size 1GB. This data is at the located inside the directory A5/tpch/.
- ------------ Instructions to run: ------------ *
- Login to thunder.cise.ufl.edu .
- Extract files from Zip folder.
- Change directory to corresponding extracted folder.
- Type ‘make’ without the quotes and enter.
- The executables are now ready. The executable for the program created by our code is named "entryPoint4_2" and is located in "./bin/".
- Please follow the below instructions to compile and run the main program or GTests.
To run the program, do:
-
Type './bin/entryPoint4_2' without quotes and press enter.
-
Type any query (sample query given at the end) and press .
-
For eg, we can create, insert into, run some query and drop the partsupp table using the following commands,
CREATE TABLE partsupp (ps_partkey INTEGER, ps_suppkey INTEGER, ps_availqty INTEGER, ps_supplycost DOUBLE, ps_comment STRING) AS HEAP; INSERT tpch/partsupp.tbl INTO partsupp; SET OUTPUT STDOUT; SELECT ps.ps_partkey, ps.ps_suppkey, ps.ps_availqty FROM partsupp AS ps WHERE (ps.ps_partkey < 100) AND (ps.ps_suppkey < 50); DROP TABLE partsupp;
-
If you are trying to create a table, make sure a. it's schema is present in the tcph/catalog b. it's .tbl file is present in the tpch/ for loading c. the table record (relations and attributes) is also present in ./stats.txt file
To run a test case, do:
- Type './bin/test' without quotes and press enter.
- Check if all the testcases have executed.