Question & Answer
Question
How do you create an onpladm load job using multiple files (arrays)
Answer
INTRODUCTION
This article describes the steps needed to create and run an ASCII delimited unload job to multiple files defined in a device array using the High Performance Loader (HPL) command line utility onpladm.
For additional details on other functionality please refer to the High Performance Loader User's Guide.
STEPS
1. Create a specification file
- BEGIN OBJECT DEVICEARRAY device_array_name
BEGIN SEQUENCE
TYPE device_type
FILE device_path
TAPEBLOCKSIZE tapeblock_size
TAPEDEVICESIZE tapedevice_size
PIPECOMMAND pipe_commandname
END SEQUENCE
END OBJECT
device_array_name
device-array name
device_type
type of device in uppercase letters (PIPE, FILE,or TAPE)
device path
path to the device only valid if device type is file or tape
tapeblock_size
tape-block size
tapedevice_size
tape-device size in megabytes
pipe_commandname
pipe command name
- Example (Specification file named makarray):
BEGIN OBJECT DEVICEARRAY loadit
BEGIN SEQUENCE
TYPE FILE
FILE "/tmp/data1.unl"
TAPEBLOCKSIZE 0
TAPEDEVICESIZE 0
PIPECOMMAND
END SEQUENCE
BEGIN SEQUENCE
TYPE FILE
FILE "/tmp/data2.unl"
TAPEBLOCKSIZE 0
TAPEDEVICESIZE 0
PIPECOMMAND
END SEQUENCE
BEGIN SEQUENCE
TYPE FILE
FILE "/tmp/data3.unl"
TAPEBLOCKSIZE 0
TAPEDEVICESIZE 0
PIPECOMMAND
END SEQUENCE
END OBJECT
2. Create an object using a specification file:
- onpladm create object -F specification_file
- specification_file
actual filename containing the array specifications
- Example:
onpladm create object -F makarray
3. Run this command at the command line to create an unload job:
jobname name you choose for the job filename full pathname of file or device array you are unloading to or loading from database_name name of database where your table resides table_name name of table being loaded or unloaded Example of unload job created : onpladm create job load_tab1 -d unloadit -D testdb -t tab1 -fua |
- onpladm run job jobname -fu
jobname
name you choose for the job
- Example of unload job run:
onpladm run job load_tab1 -fl
Connecting to onpload, Please wait...
Successful connection to onpload established
Wed Oct 15 09:51:27 2008
SHMBASE 0x000000010a000000
CLIENTNUM 0x0000000049020000
Session ID 1
Load Database -> testdb
Load Table -> tab1
Device Array -> loadit
Record Mapping -> load_tab1
Convert Reject -> /tmp/load_tab1.rej
Filter Reject -> /tmp/load_tab1.flt
09:51:30 Records Processed -> 10389
Table 'tab1' will be read-only until level 0 archive
Database Load Completed -- Processed 11424 Records
Records Inserted-> 11424
Detected Errors--> 0
Engine Rejected--> 0
Wed Oct 15 09:51:31 2008
Job Completed Successfully ... connection closed
*********************************************************
ls -l /tmp/data*
-rw-rw---- 1 informix informix 345375 Oct 10 15:56 /tmp/data1.unl
-rw-rw---- 1 informix informix 342749 Oct 10 15:56 /tmp/data2.unl
-rw-rw---- 1 informix informix 337996 Oct 10 15:56 /tmp/data3.unl
*************************************
Commands used
***********************************
onpladm create object -F makarray
onpladm create job load_tab1 -d loadit -D testdb -t tab1 -fla
onpladm run job load_tab1 -fu
Related Information
[{"Product":{"code":"SSGU8G","label":"Informix Servers"},"Business Unit":{"code":"BU053","label":"Cloud & Data Platform"},"Component":"Not Applicable","Platform":[{"code":"PF002","label":"AIX"},{"code":"PF025","label":"Platform Independent"},{"code":"PF008","label":"DYNIX\/ptx"},{"code":"PF010","label":"HP-UX"},{"code":"PF015","label":"IRIX"},{"code":"PF016","label":"Linux"},{"code":"PF022","label":"OS X"},{"code":"PF027","label":"Solaris"},{"code":"PF033","label":"Windows"}],"Version":"10.0;11.1;11.5;11.7","Edition":"","Line of Business":{"code":"LOB10","label":"Data and AI"}}]
Was this topic helpful?
Document Information
Modified date:
16 June 2018
UID
swg21321883