Previous Topic: Full Load ProcedureNext Topic: Segmented Load Procedure


Phased Load Procedure

Steps

Follow the steps shown next to perform a phased load:

Note: Optionally, back up the database areas between the load and build steps if you want to recover the data in the event of a failed job step.

Action

Statement

Identify the following tables:

  • All tables clustered through referential constraints; if multiple levels of clustering exist, the tables in each level must be loaded in a separate operation before those at a lower level
  • All referencing tables in linked index constraints where the referenced key is an index; if multiple levels of such a structure exist, the tables in the higher levels must be loaded before those at a lower level

 

In local mode, load and build all tables not identified in Step 1 above.

LOAD with the NO VALIDATE option

  • For each clustering level,load and build all tables clustered through referential constraints
  • For each linked index level, load and build all tables that participate in linked index constraints

LOAD with the NO VALIDATE option

Validate the referential constraints of all the loaded tables

VALIDATE SEGMENT

Example

In this example, the tables BENEFITS, COVERAGE, EMPLOYEE, and POSITION are loaded in a phased load procedure. The tables have the following characteristics:

Table

Characteristics

BENEFITS

References EMPLOYEE in a linked, clustered constraint

COVERAGE

References EMPLOYEE in a linked, clustered constraint

EMPLOYEE

References DEPARTMENT in an unlinked constraint

POSITION

References EMPLOYEE in a linked, clustered constraint

To load the tables, load and build the EMPLOYEE table first, followed by the remaining tables. After all 4 tables are loaded, validate the referential constraints that exist between them. Each of these statements must be executed in a separate job step:

load
  into demoempl.employee
  where position 150 = '415'
  no validate;

load 
  into demoempl.benefits
  where position 150 = '478'

  into demoempl.coverage
  where position 150 = '488'

  into demoempl.position
  where position 150 = '492'
  no validate;

  validate segment demoempl;