|
View previous topic :: View next topic
|
| Author |
Message |
poonam_madaan
New User
Joined: 01 Dec 2006 Posts: 3 Location: Bangalore
|
|
|
|
The DSNUPROC is used for loading a table from PS.
Can anyone please tell me what all the following DD names are (functions of those) and how can I get those (their space parameter and all)
| Code: |
//STEP030 EXEC DSNUPROC,SYSTEM=DB2P,UID='SDPREBA',UTPROC=''
//DSNUPROC.SYSREC DD DSN=PROD.ASDP232Z.ASDP238Z.BMCPS.BTGOUT (+1),
// DISP=SHR
// DD DSN=PROD.ASDP231Z.ASDP238Z.BMLVL.BTGOUT (+1),
// DISP=SHR
//DSNUPROC.SORTWK01 DD DSN=WORK.ASDP230Z.SDPREBA.SORTWK01,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE= (4000,(40,40),,,ROUND)
//DSNUPROC.SORTWK02 DD DSN=WORK.ASDP230Z.SDPREBA.SORTWK02,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE= (4000, (40, 40), ROUND)
//DSNUPROC.SORTWK03 DD DSN=WORK.ASDP230Z.SDPREBA.SORTWK03,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE=(4000,(40,40),,,ROUND)
//DSNUPROC.SYSDISC DD DSN=WORK.ASDP230Z.SDPREBA.REJECT,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE=(4000,(40,40),,,ROUND)
//DSNUPROC.SYSERR DD DSN=WORK.ASDP230Z.SDPREBA.ERR,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE= (4000,(40,40),,,ROUND)
//DSNUPROC.SYSMAP DD DSN=WORK.ASDP230Z.SDPREBA.MAPERR,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE= (4000,(40,40),,,ROUND)
//DSNUPROC.SYSUT1 DD DSN=WORK.ASDP230Z.SDPREBA.SYSUT1,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE=(CYL,(40,40),RLSE)
//DSNUPROC.SORTOUT DD DSN=WORK.ASDP230Z.SDPREBA.SORTOUT,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE= (CYL, (40, 40), RLSE)
//DSNUPROC.SYSIN DD DSN=APPL.HPDC.PROD.PARMLIB (CSDP2302), DISP=SHR
|
|
|
| Back to top |
|
 |
William Thompson
Global Moderator
Joined: 18 Nov 2006 Posts: 3156 Location: Tucson AZ
|
|
|
|
| poonam_madaan wrote: |
The DSNUPROC is used for loading a table from PS.
Can anyone please tell me what all the following DD names are (functions of those) and how can I get those (their space parameter and all)
//*********************************************************************
//* DB2-LOAD RESUME TABLE (SDPREBA)
//*********************************************************************
//STEP030 EXEC DSNUPROC, SYSTEM=DB2P, UID='SDPREBA', UTPROC=''
//DSNUPROC.SYSREC DD DSN=PROD.ASDP232Z.ASDP238Z.BMCPS.BTGOUT (+1),
// DISP=SHR
// DD DSN=PROD.ASDP231Z.ASDP238Z.BMLVL.BTGOUT (+1),
// DISP=SHR
//DSNUPROC.SORTWK01 DD DSN=WORK.ASDP230Z.SDPREBA.SORTWK01,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE= (4000,(40,40),,,ROUND)
//DSNUPROC.SORTWK02 DD DSN=WORK.ASDP230Z.SDPREBA.SORTWK02,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE= (4000, (40, 40), ROUND)
//DSNUPROC.SORTWK03 DD DSN=WORK.ASDP230Z.SDPREBA.SORTWK03,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE=(4000,(40,40),,,ROUND)
//DSNUPROC.SYSDISC DD DSN=WORK.ASDP230Z.SDPREBA.REJECT,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE=(4000,(40,40),,,ROUND)
//DSNUPROC.SYSERR DD DSN=WORK.ASDP230Z.SDPREBA.ERR,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE= (4000,(40,40),,,ROUND)
//DSNUPROC.SYSMAP DD DSN=WORK.ASDP230Z.SDPREBA.MAPERR,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE= (4000,(40,40),,,ROUND)
//DSNUPROC.SYSUT1 DD DSN=WORK.ASDP230Z.SDPREBA.SYSUT1,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE=(CYL,(40,40),RLSE)
//DSNUPROC.SORTOUT DD DSN=WORK.ASDP230Z.SDPREBA.SORTOUT,
// DISP= (MOD, DELETE, DELETE),
// UNIT=SYSDA,
// SPACE= (CYL, (40, 40), RLSE)
//DSNUPROC.SYSIN DD DSN=APPL.HPDC.PROD.PARMLIB (CSDP2302), DISP=SHR |
They appear to be overrides to the proc. And what do you mean by "how can I get those (their space parameter and all)"? |
|
| Back to top |
|
 |
rakesh pattanayak
New User
Joined: 29 May 2007 Posts: 16 Location: bangalore
|
|
|
|
Hi poonam,
i am giving you one sample Load steap to load in one of my JCL with explanation.
hope it will clarify your doubts.
++++++++++++++++++++++++++++++++++++++++++++++
//T1996NMA JOB (0, 1723),'NAVEEN', NOTIFY=&SYSUID
//*
//STEP14 EXEC DSNUPROC, SYSTEM=GRT1, UID='SDZCSMA', UTPROC=''
//*
//DSNUPROC.SYSREC DD DSN=T1996NM.ASDA725Z.SDZCSMA.LOAD,
// DISP=SHR
//DSNUPROC.SORTWK01 DD
DSN=T1996NM.CSDZ961Z.SDZVOTM.SORTWK01,
// DISP=(MOD,DELETE,DELETE),
// UNIT=SYSDA,
// SPACE=(4000,(40,40),,,ROUND)
//DSNUPROC.SORTWK02 DD DSN=T1996NM.CSDZ961Z.SDZVOTM.SORTWK02,
// DISP=(MOD,DELETE,DELETE),
// UNIT=SYSDA,
// SPACE=(4000,(40,40),,,ROUND)
//DSNUPROC.SORTWK03 DD
DSN=T1996NM.CSDZ961Z.SDZVOTM.SORTWK03,
// DISP=(MOD,DELETE,DELETE),
// UNIT=SYSDA,
// SPACE=(4000,(40,40),,,ROUND)
//DSNUPROC.SYSDISC DD DSN=&SYSUID..DXTDATA.PUSDSMX.REJECT,
// DISP=(MOD,CATLG),
// SPACE=(4000,(40,40),,,ROUND),
// UNIT=DISK
//DSNUPROC.SYSERR DD DSN=T1996NM.CSDZ961Z.SDZVOTM.ERR,
// DISP=(MOD,DELETE,DELETE),
// UNIT=SYSDA,
// SPACE=(4000,(40,40),,,ROUND)
//DSNUPROC.SYSMAP DD DSN=T1996NM.CSDZ961Z.SDZVOTM.MAP,
// DISP=(MOD,DELETE,DELETE),
// UNIT=SYSDA,
// SPACE=(4000,(40,40),,,ROUND)
//DSNUPROC.SYSUT1 DD DSN=T1996NM.CSDZ961Z.SDZVOTM.SYSUT1,
// DISP=(MOD,DELETE,DELETE),
// UNIT=SYSDA,
// SPACE=(4000,(40,40),,,ROUND)
//DSNUPROC.SORTOUT DD DSN=T1996NM.CSDZ961Z.SDZVOTM.SORTOUT,
// DISP=(MOD,DELETE,DELETE),
// UNIT=SYSDA,
// SPACE=(4000,(40,40),,,ROUND)
//DSNUPROC.SYSIN DD *
LOAD DATA REPLACE
LOG NO
INTO TABLE S.SDZCSMA
(
C_BC POSITION (00001:00002) CHAR
, C_DOM POSITION (00003:00004) CHAR
, C_DIST POSITION (00005:00006) CHAR
, C_DLR POSITION (00007:00011) CHAR
,C_BRAND POSITION(00012:00012) CHAR
,C_MG POSITION(00033:00034) CHAR
,C_PRC_CLASS POSITION(00013:00032) CHAR
,I_CURR_CONS POSITION(00065:00068) INTEGER
,I_CURR_ALLOC POSITION(00035:00039) INTEGER
,I_SCHED POSITION(00040:00043) INTEGER
,I_STOCK_SHIP POSITION(00044:00047) INTEGER
,I_TOTAL_AVAIL POSITION(00048:00051) INTEGER
,I_90_DAY_SLS POSITION(00052:00055) INTEGER
,I_PY_90_DAY_SLS POSITION(00056:00059) INTEGER
,I_FRCST_ALLOC POSITION(00060:00064) INTEGER
,I_SEQ POSITION(00069:00070) SMALLINT
)
//*
Let us discuss the significance of the colored words.
a. DSNUPROC
This is one utility we use to load a table.
b. SYSTEM = GRT1
When we do any operation on test tables we specify GRT1 for production tables we will mention DB2P.
c. UID = < table name >
d. UTPROC
UTPROC is an optional indicator used to determine whether the user wishes to initially start the requested utility or to restart a previous execution of the utility. If omitted, the utility will be initially started. Otherwise, the utility will be restarted by entering the following.
Values:
Restart (phase) = restart the utility at the beginning of the phase executed last.
Restart = restart the utility at the last or current commit point.
e. DSNUPROC.SYSREC
In this DSN name we will give our file to be loaded.
f. DSNUPROC.SORTWK01, DSNUPROC.SORTWK02, DSNUPROC.SORTWK03
These are the sort work files
g. DSNUPROC.SYSERR
Duplicate key error info. goes to SYSERR
h. DSNUPROC.SYSMAP
Allow enough space to store for each row being loaded
i.DSNUPROC.SYSUT1
Populates sysut1 with index and foreign key data
j. DSNUPROC.SYSDISC
Referntial constraint violations go to SYSDISC.
In SYSIN DD * we will specify how to load the table. We can Load table with 2 options.
1. LOAD REPLACE
2. LOAD RESUME
Load replace will clear the table and load a fresh set of data where as the LOAD resume will append the data.
In the SYSIN we have
C_BC POSITION (00001:00002) CHAR
Here C_BC is the column name.
In the position we specify the starting and ending location of that variable in file
And then the data type of the column.
+++++++++++++++++++++++++++++++++++++++++++++++ |
|
| Back to top |
|
 |
ofer71
Global Moderator

Joined: 27 Dec 2005 Posts: 2358 Location: Israel
|
|
| Back to top |
|
 |
|
|
 |
All times are GMT + 6 Hours |
|