SQL/MP Installation and Management Guide

Creating a Database
HP NonStop SQL/MP Installation and Management Guide523353-004
5-51
Creating Constraints on Data
For detailed information about loading index partitions in parallel, including the syntax
of the configuration file, see “Parallel Index Loading” in the SQL/MP Reference Manual
or use the SQLCI HELP command.
Creating Constraints on Data
The SQL/MP data dictionary provides for data validity checking. Application programs
do not have to perform data verification and checking, because a constraint defined on
a table ensures that SQL performs the checking. Constraints provide for independence
between data and code.
With SQL/MP, the definition of a constraint specifies a rule that all rows in the table
must satisfy. The RDBMS enforces the constraint criteria when the constraint is
created on a table with existing data and when rows of the table are updated or
Example 5-3. Sample Configuration File
== Sample configuration file for loading index
== partitions in parallel. Creates index AGEINDEX
== on table CUST, which is partitioned as follows:
== $DATA1.SALES.CUST
== $DATA2.SALES.CUST
== $DATA3.SALES.CUST
== \NEWYORK.$DATA1.SALES.CUST
== AGEINDEX is partitioned as follows:
== $DATA4.SALES.AGEINDEX
== $DATA5.SALES.AGEINDEX
== \NEWYORK.$DATA2.SALES.AGEINDEX
== \NEWYORK.$DATA3.SALES.AGEINDEX
== Set up a default priority for the RECGEN processes.
CREATEINDEX BASETABLE DEFAULT PRI ( 140 )
CREATEINDEX BASETABLE DEFAULT \NEWYORK PRI ( 140 )
== Set up default pools of scratch files for the sort
processes.
CREATEINDEX INDEX DEFAULT SCRATCH ($TEMP1,$TEMP2,$TEMP3)
CREATEINDEX INDEX DEFAULT \NEWYORK SCRATCH ($TEMP4,$TEMP5)
== Request that overflow scratch files avoid certain
== disks--those specified plus $SYSTEM and TM/MP audit
== trail disks.
CREATEINDEX INDEX DEFAULT NOSCRATCHON ($SYS*,$WORK*)
== Request that overflow scratch files use specific
== disks on the remote node.
CREATEINDEX INDEX DEFAULT \NEWYORK SCRATCHON ($TEMP*)
== Request that the $data3 sort process use $temp7 for
== scratch space.
CREATEINDEX INDEX \NEWYORK.$data3 SCRATCH ($TEMP7)
== End of Configuration File