HiRDB Dataextractor Version 8 Description, User's Guide and Operator's Guide
This section presents execution examples of HiRDB Dataextractor. Figure 5-1 shows the system configuration for the execution examples.
Figure 5-1 System configuration for execution examples (when data is extracted from an ORACLE database)
| Table name | Column names and attributes |
|---|---|
| TORA01 | C01 CHAR(10), C02 NUMBER(10,8), C03 DATE |
| TORA02 | C01 CHAR(10), C02 NUMBER(10,8), C03 NUMBER |
$ORACLE_BASE /ORACLE8/ORACLE $ORACLE_HOME /ORACLE8/ORACLE/product/8.1.6 $ORA_NLS33 /ORACLE8/ORACLE/product/8.1.6/ocommon/nls/admin/data $NLS_LANG Japanese_Japan.JA16SJIS $ORACLE_SID hds1 $ORACLE_TERM hp $XTORAUSER "user01"/"user01" $PATH /opt/HIRDBXT/bin $LANG ja_JP.SJIS $XTHOST HOST2 $XTPORTNO 20052
:
:
160.16.150.120 HOST2
160.16.150.121 HOST3
:
:
CREATE TABLE T01(C01 CHAR(10),C02 DEC(10,8),C03 DATE,C04 TIME) CREATE TABLE T02(C01 CHAR(10),C02 DEC(10,8),C03 INT, C04 INT)
CREATE FIX TABLE T03(C01 CHAR(10),C02 DEC(10,8),C03 TIME)
:
:
hirdbxt1 20052/tcp # HiRDB Dataextractor
hirdbxt2 50000/tcp # HiRDB Dataextractor
:
:
:
:
hirdbxt1 stream tcp nowait user01
/opt/HIRDBXT/bin/pxtcntl pxtcntl /usr/home/user01/xtenv1
hirdbxt2 stream tcp nowait user02
/opt/HIRDBXT/bin/pxtcntl pxtcntl /usr/home/user02/xtenv2
:
:
set PDDIR=/HiRDB2 set PDCONFPATH=/HiRDB2/conf set PDUSER="user01"/"user01" set LANG=ja_JP.SJIS
set PDDIR=/HiRDB2 set PDCONFPATH=/HiRDB2/conf set PDUSER="user02"/"user02" set LANG=ja_JP.SJIS
:
:
hirdbxt 20052/tcp # HiRDB Dataextractor
:
:
:
:
hirdbxt stream tcp nowait user01
/opt/HIRDBXT/bin/pxtcntl pxtcntl /usr/home/user01/xtenv
:
:
set XTTMPDIR=/usr/home/user01/data set LANG=ja_JP.SJIS
Specify the xtrepO command on the data source system.
Copy table TORA01 at HOST1 into table T01 at HOST2. Specify the following options:
xtrepO -r T01 -s /usr/home/user01/clm TORA01
C01,C02,C03,C04
Copy table TORA02 at HOST1 into table T02 at HOST2. Specify the following options:
xtrepO -r T02 -d -l n -n 255 -m 100 -g -s /usr/home/user01/clm -v /usr/home/user01/null -w /usr/home/user01/whr TORA02
C01,C02,C03,0
WHERE C01<='0000010000'
1=NUM=('FFFFFFFFFF')
Copy table TORA01 at HOST1 into table T03 at HOST2. Specify the following options:
xtrepO -d -r t03 -n 40 -p 50000
-e /tmp/xtrep_log -g /usr/home/user01/lck TORA01
IN EXCLUSIVE MODE NOWAIT
Output table TORA01 at HOST1 to a file at HOST3. Specify the following options:
xtrepO -R dat -o TORA01 -h HOST3 -s /usr/home/user01/clm TORA01
C01,C02,C03
Output table TORA01 at HOST1 to a file at HOST3. Specify the following options:
xtrepO -R -o TORA01_BIN -h HOST3 -m 50 -s /usr/home/user01/clm -w /usr/home/user01/whr -L /usr/home/user01/cnv TORA01
C01,C02,C03
WHERE C01<='0000010000'
FORMAT FIELD_NUM 1 ATTR MCHAR(20)
FIELD_NUM 3 ATTR TIME
All rights reserved. Copyright (C) 2007, Hitachi, Ltd.