HeatWave User Guide/Reference/ Generating tpch Sample Data

10.11 Generating tpch Sample Data

Examples in this guide and in theHeatWave Quickstartuse thetpchsample database, which is an ad-hoc decision support database derived from theTPC Benchmark™ H (TPC-H)specification. For an overview of thetpchschema, refer to theLogical Database Designsection of thespecification document.

TheHeatWave Quickstartdescribes how to create thetpchschema and tables and loadtpchsample data. The following instructions describe how to generatetpchsample data using thedbgenutility. The instructions assume you are on a Linux system that hasgccandmakelibraries installed.

To generatetpchsample data:

  1. Download the TPC-H tools zip file fromTPC Download Current.

  2. Extract the zip file to a location on your system.

  3. Change to thedbgendirectory and make a copy of the makefile template.

    $ cd 2.18.0/dbgen $ cp makefile.suite makefile
  4. Configure the following settings in the makefile:

    CC = gcc DATABASE= ORACLE MACHINE = LINUX WORKLOAD = TPCH
  5. Runmaketo build thedbgenutility:

    $ make
  6. Issue the followingdbgencommand to generate a 1GB set of data files for thetpchdatabase:

    $ ./dbgen -s 1

    The operation may take a few minutes. When finished, the following data files appear in the working directory, one for each table in thetpchdatabase:

    $ ls -1 *.tbl customer.tbl lineitem.tbl nation.tbl orders.tbl partsupp.tbl part.tbl region.tbl supplier.tbl