22.7.2 Example 2: Data loading from all audit trail files in the HiRDB file system area

This example loads all data load waiting audit trail files in the HiRDB file system area (/secarea) into the audit trail table (table name SQL_AUDIT_TRAIL). The following is the specification of the pdload command for this example:

Example pdload command specification

pdload -b -W SQL_AUDIT_TRAIL /pdload/control_file

Explanation
  • The -b and -W options must be specified.
  • Specify the audit trail table for the table name.
  • The following explains the contents of the control information file:

Example of specifying the control information file

source bes1:(uoc)
srcuoc param='dir=/secarea,file=all,mode=normal'

Explanation
source bes1:(uoc): Specifies the server name (bes1) for the HiRDB/Parallel Server. You can specify a server name in the unit where the audit trail files are located. You may specify any server name in the unit, but if you specify a back-end server, you can eliminate a communication bottleneck.
dir: Specifies the HiRDB file system area that stores the audit trail files to be data loaded.
file=all: Specifies that all audit trail files in the HiRDB file system area are to be data loaded. However, the current file and files in shutdown status are excluded.
mode=normal: Specifies that data load completed files are not to be data loaded.
Remarks
If mode=force is specified, data load completed files are also data loaded. You would specify force in the situation explained below. Note that when force is specified, the same data may be recorded twice, so care must be taken not to record data that has already been recorded.
  • If the audit trail table's data was deleted inadvertently and there is no backup, it would be appropriate to data load all audit trail files in order to recover the audit trail table
Table 22-14 shows whether data loading can be executed, depending on the audit trail file status and user specified values.

Table 22-14 Whether or not data is loaded depending on the audit trail file status and user specified values

Audit trail file statusUser specified value
Shutdown statusData load statusmodefile=file-namefile=all
Not shutdownData load waitingnormalExecutes data load processing from the audit file.
Data load completedSkips data load processing from the audit file, and continues processing.Does not perform data load processing from the audit file.
ShutdownData load waiting
Data load completed
Not shutdownData load waitingforceExecutes data load processing from the audit file.This is a user specification error.
Data load completed
ShutdownData load waitingSkips data load processing from the audit file, and continues processing.
Data load completed
[Figure]Current[Figure]Skips data load processing from the audit file, and continues processing.Does not perform data load processing from the audit file.
Legend:
[Figure]: Not applicable.