[DB2-L] Exemple JCL for overrid SDSNLOAD i storeproc

Douwe van Sluis

[DB2-L] Exemple JCL for overrid SDSNLOAD i storeproc
Hanne,

Try using the WLM provided variable for the DB2 subsystem name &IWMSSNM.
WLM assigns the DB2 membername to this variable. Below is owner WLM
Setting:
Appl Environment Name . . DB0USP00
Description . . . . . . . Stored procedures DB0U APF
Subsystem type . . . . . DB2
Procedure name . . . . . DB0USP00
Start parameters . . . . APPLENV=DB0USP00,DB2SSID=&IWMSSNM,JOBNAM
E=&IWMSSNM.SP00

We also use this variable in the jobname, so we can see what member
started this WLM Appl Env.

The Started Task JCL look like (left out some DD's):

//***********************************************************
//* WLM ENVIRONMENT T.B.V. APF AUTHORIZED PROGRAMS *
//***********************************************************
//SP00 PROC RGN=0K,APPLENV=XXXXXXXX,DB2SSID=XXXX,NUMTCB=100
//IEFPROC EXEC PGM=DSNX9WLM,REGION=&RGN,TIME=NOLIMIT,
// PARM='&DB2SSID,&NUMTCB,&APPLENV'
//STEPLIB DD DISP=SHR,DSN=DB2.&DB2SSID..SDSNEXIT
// DD DISP=SHR,DSN=DB2.&DB2SSID..SDSNLOAD

We have created an ALIAS for the DB2.<member>.SDSNLOAD, ...SDSNEXIT,
Etc. to a real version related dataset (DB2.V08R1M10.SDSNLOAD or
DB2.V09R1M00.SDSNLOAD).
We have gone even further, this Version SDSNLOAD, is resolved using a
symbolic related alias; ergo it uses a system variable to resolve the
version.
We switch version just by changing the system variable.
We can have one member on V8 NFM and one on V9 CM easily by this setup.
The switch between versions is easy. Most of our maintenance lies in the
preparation phase. We usually only need to stop the member switch system
variable and start the member again.
Most of the time during actual implementation is spent to run our IVP
procedures.

Hope this helps, feel free to ask additional questions.
Vriendelijke groet,
Douwe van Sluis

-----Oorspronkelijk bericht-----
Van: DB2 Data Base Discussion List [mailto:[login to unmask email] Namens
Hanne Lyssand
Verzonden: maandag 21 januari 2008 15:52
Aan: [login to unmask email]
Onderwerp: [DB2-L] Exemple JCL for overrid SDSNLOAD i storeproc


Dear listserve members
Can anyone be willing to share an exampel JCL on how to switch between
SDSNLOADS when one member is in v9.1 and the other in 8.
We have a naming convention that is not so good.

For the v9.1 system the name is SYS1.TEST.SDSNLOAD
The V8 have SYSS.DB1T.SDSNLOAD

I can make a copy of the datasets so that I can use &DB2SSN overrid but
is there an other way?

Best regards
Hanne

Our current JCL:
//*************************************************************
//* DB2TW02 FOR VPS STORED PROCS PL1 /ASSEMBER/SQL
//*************************************************************
//DB2TW02 PROC RGN=0K,APPLENV=DB2TW02,DB2SSN=DB2T,NUMTCB=40
//IEFPROC EXEC PGM=DSNX9WLM,REGION=&RGN,TIME=NOLIMIT,
// PARM='&DB2SSN,&NUMTCB,&APPLENV'
//STEPLIB DD DISP=SHR,DSN=VS.TEST.LOAD
// DD DISP=SHR,DSN=SYS1.TEST.SDSNEXIT
// DD DISP=SHR,DSN=SYS1.TEST.SDSNLOAD
//JESJCLIN DD SYSOUT=X,HOLD=YES
//JESMSGLG DD SYSOUT=X,HOLD=YES
//JESJCL DD SYSOUT=X,HOLD=YES
//JESYSMSG DD SYSOUT=X,HOLD=YES
//SYSTSPRT DD SYSOUT=X,HOLD=YES
//SYSOUT DD SYSOUT=X,HOLD=YES
//SYSUDUMP DD SYSOUT=X,HOLD=YES
//SYSPRINT DD SYSOUT=X,HOLD=YES
//SYSERR DD SYSOUT=X,HOLD=YES
//STDOUT DD SYSOUT=X,HOLD=YES
//STDERR DD SYSOUT=X,HOLD=YES
//CEEDUMP DD SYSOUT=X,HOLD=YES
//IKSTHOI DD DUMMY


The IDUG DB2-L Listserv is only part of your membership in IDUG. DB2-L
list archives, the FAQ, and delivery preferences are at www.idug.org
under the Listserv tab. While at the site, you can also access the IDUG
Online Learning Center, Tech Library and Code Place, see the latest IDUG
conference information, and much more.
If you have not yet signed up for Basic Membership in IDUG, available at
no cost, click on Member Services

The IDUG DB2-L Listserv is only part of your membership in IDUG. DB2-L
list archives, the FAQ, and delivery preferences are at www.idug.org
under the Listserv tab. While at the site, you can also access the IDUG
Online Learning Center, Tech Library and Code Place, see the latest IDUG
conference information, and much more.
If you have not yet signed up for Basic Membership in IDUG, available at
no cost, click on Member Services

The IDUG DB2-L Listserv is only part of your membership in IDUG. DB2-L list archives, the FAQ, and delivery preferences are at http://www.idug.org/lsidug under the Listserv tab. While at the site, you can also access the IDUG Online Learning Center, Tech Library and Code Place, see the latest IDUG conference information, and much more. If you have not yet signed up for Basic Membership in IDUG, available at no cost, click on Member Services at http://www.idug.org/lsms

Roy Reynolds

Re: Exemple JCL for overrid SDSNLOAD i storeproc
(in response to Douwe van Sluis)
Here's how I deal with different release levels for each subsystem.
I create aliases for each subsystem that point to TEST libraries or PROD
libraries.
The alias delete/define occurs in a step that precedes DB2xMSTR for each
subsystem startup proc. This ensures all JCL can refer only to the its DB2
subsystem alias and that each alias will point to the correct DB2
version/release/maint-level.
This ensures JCL changes can be eliminated for DB2 version/maint migrations
and means I don't have to IEBCOPY DB2 libraries across subsystems.
Using this technique would mean you stored procs wouldn't have to sync up
their 'Includes' with any other JCL. Since nothing referencing a DB2
subsystem can run when it is 'down', all applications and associated started
tasks are in sync when the alias technique is used.
HTH.
Roy

The IDUG DB2-L Listserv is only part of your membership in IDUG. DB2-L list archives, the FAQ, and delivery preferences are at http://www.idug.org/lsidug under the Listserv tab. While at the site, you can also access the IDUG Online Learning Center, Tech Library and Code Place, see the latest IDUG conference information, and much more. If you have not yet signed up for Basic Membership in IDUG, available at no cost, click on Member Services at http://www.idug.org/lsms