#!/bin/sh

# set global env setting
. /opt/jilroy/checkit//bin/env

# create the database
cd $DB_HOME


# parameters driver, manager, user, pwd, dbname
$INSTALLDIR/bin/createdb

# create the tables
$INSTALLDIR/bin/createtables TABLE
$INSTALLDIR/bin/inventory
$INSTALLDIR/bin/createtables INDEX

# init scheduled jobs file
$INSTALLDIR/bin/loadjobsfromfile.sh $INSTALLDIR/conf/dbschedulerprocesses.xml

# fill tables after the database creation
$INSTALLDIR/bin/inittables.sh
