Skip to content

interma/iTPCH

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

iTPCH

interma's tpch test for greenplum

It used for a personal test env with small Scale Factor (e.g. 100).

Guides:

cd dbgen

# 01 compile dbgen
make

# 02 generate raw data (1GB)
./dbgen -vf -s 1
# and remove ending |
sed -i -e "s/|$//g" *.tbl

# 03 create tables
psql tpch -f ../schema.sql

# 04 import data via copy command
psql tpch -c "\\COPY nation FROM 'nation.tbl' WITH DELIMITER '|';"
psql tpch -c "\\COPY part FROM 'part.tbl' WITH DELIMITER '|';"
psql tpch -c "\\COPY customer FROM 'customer.tbl' WITH DELIMITER '|';"
psql tpch -c "\\COPY orders FROM 'orders.tbl' WITH DELIMITER '|';"
psql tpch -c "\\COPY partsupp FROM 'partsupp.tbl' WITH DELIMITER '|';"
psql tpch -c "\\COPY region FROM 'region.tbl' WITH DELIMITER '|';"
psql tpch -c "\\COPY supplier FROM 'supplier.tbl' WITH DELIMITER '|';"
psql tpch -c "\\COPY lineitem FROM 'lineitem.tbl' WITH DELIMITER '|';"

cd ..
# 05 run all queries
psql tpch -c "analyze;"
psql tpch -f query.sql > result.txt
# then check result
grep Time results.txt

About

interma's tpch test for greenplum

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published