beautypg.com

Control file: load and extract, Example a-7 control file: load and extract – HP Neoview Release 2.4 Software User Manual

Page 91

background image

Example A-7 Control File: Load and Extract

/* Simple Load From File To Table & Extract From Neoview SQL Source To File */

version 1.0;

options
{
errors = 1000,
discards = 100,
rowsetsize = 5000,
}

dataformats
{
dataformat1 delimited
records separated by
fields delimited by <,>
optionally qualified by <">
(
FIRST_NAME char,
LAST_NAME char,
ADDRESS char,
ZIP int,
PHONE char,
SSN largeint,
INFO1 char,
INFO2 char
)

dataformat2 sql fields
(
FIRST_NAME char,
LAST_NAME char,
ADDRESS char,
ZIP int,
PHONE char,
SSN largeint,
INFO1 char,
INFO2 char
)

dataformat3 delimited
records separated by
fields delimited by <,>
optionally qualified by <">
(

(
SSN largeint,
FIRST_NAME char,
LAST_NAME char,
ADDRESS char,
ZIP int,
PHONE char,
INFO1 char,
INFO2 char
)

}

sources {
src1 file "./data_files/sn_nvt.dat"

tgt1 jdbc table NEO.nvt.sn_nvt options
(
system = "asl0101",
user = "user",
password = "transport",
datasource = "Admin_Load_DataSource",
url = "jdbc:hpt4jdbc://txnaslan01.txn.cpqcorp.net:18650/"
)

src2 jdbc sql "select * from NEO.nvt.sn_nvt_ext order by SSN" options
(
system = "asl0101",
user = "user",
password = "transport",
datasource = "Admin_Load_DataSource",
url = "jdbc:hpt4jdbc://txnaslan01.txn.cpqcorp.net:18650/"
)

tgt2 file "./data_files/sn_ext.dat"
}

maps {
map1 from dataformat1 to dataformat2
(
FIRST_NAME = FIRST_NAME,
LAST_NAME = LAST_NAME,
ADDRESS = ADDRESS,
ZIP = ZIP,

91