IBM Mainframe Forum Index
 
Log In
 
IBM Mainframe Forum Index Mainframe: Search IBM Mainframe Forum: FAQ Register
 

GDG Generation creation using Model in version for DCB


IBM Mainframe Forums -> JCL & VSAM
Post new topic   Reply to topic
View previous topic :: View next topic  
Author Message
santosh100678

New User


Joined: 21 Sep 2009
Posts: 55
Location: Kolkatta

PostPosted: Mon Mar 29, 2010 7:36 pm
Reply with quote

Actually i want to create o/pt using DCB for GDG base

1. In first step GDG define
2. In second step define model of GDG
3. I want to create output file using DCB of model of step2
but face error and it shows step3 MTPLD01.TEST.GDG(+1),RECFM is U and
one more question if i change model1 and sme i refer in step3 then also
face error

//MTPLD01A JOB (COBCOMPILE),'SANTOSH',CLASS=X,MSGCLASS=X,
// REGION=8M,NOTIFY=&SYSUID,RESTART=STEP3
//* TO CREATE GDG
//STEP1 EXEC PGM=IDCAMS
//SYSIN DD *
DEFINE GDG( -
NAME(MTPLD01.TEST.GDG) -
LIMIT(03) -
NOEMPTY -
SCRATCH)
/*
//SYSPRINT DD SYSOUT=*
//STEP2 EXEC PGM=IEFBR14
//MODEL DD DSN=MTPLD01.TEST.GDG(+1),DISP=(NEW,CATLG,DELETE),
// SPACE=(TRK,(10,25),RLSE),UNIT=SYSDA,
// DCB=(LRECL=145,RECFM=FB,BLKSIZE=0)
//*
//STEP3 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=MTPLD01.TEST.SORT1,DISP=SHR (file lenght is 133 of input)
//SORTOUT DD DSN=MTPLD01.TEST.GDG(+1), (ouput file is 145 but using model.gdg as dcb face error )
// DISP=(NEW,CATLG,DELETE),UNIT=SYSDA,
// SPACE=(TRK,(100,50),RLSE),
// DCB=(MODEL.GDG)
//SYSIN DD *
SORT FIELDS=COPY
OUTREC FIELDS=(1:1,8,11:16,5,132X)
Back to top
View user's profile Send private message
dick scherrer

Moderator Emeritus


Joined: 23 Nov 2006
Posts: 19244
Location: Inside the Matrix

PostPosted: Mon Mar 29, 2010 8:41 pm
Reply with quote

Hello,

Suggest you remove STEP2.

Possibly there is something i misunderstand. . .
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8697
Location: Dubuque, Iowa, USA

PostPosted: Mon Mar 29, 2010 9:11 pm
Reply with quote

You need to contact your site support group and determine how the data set MODEL.GDG was set up. It may require LRECL and BLKSIZE to be specified in your JCL for example.
Back to top
View user's profile Send private message
santosh100678

New User


Joined: 21 Sep 2009
Posts: 55
Location: Kolkatta

PostPosted: Mon Mar 29, 2010 9:29 pm
Reply with quote

Hi,

according to my understanding if i create a model gdg and after that i create version of that model GDG suppose my base model is
MTPLD01.TEST.GDG and i have to create MTPLD01.TEST.GDG(+1)
MTPLD01.TEST.GDG(+2) and i want to use DCB of these dataset what model have suppose
my model datset MTPLD01.TEST.GDG this and its (LRECLLRECL=145,RECFM=FB,BLKSIZE=0)
now i want to create new version of GDG
MTPLD01.TEST.GDG(+1)
with using DCB parameter of my model datset
(LRECLLRECL=145,RECFM=FB,BLKSIZE=0)
so could you expalin in detail
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8697
Location: Dubuque, Iowa, USA

PostPosted: Mon Mar 29, 2010 10:20 pm
Reply with quote

I think your confusion comes in understanding the model DSCB (note -- it is NOT a model GDG, but a model DSCB). The model DSCB is set up on disk, has absolutely nothing to do with YOUR GDG, and is not required for system-managed GDG allocations. You appear to be attempting to use a previous generation of your GDG as the model, and that's not how it works. In your JCL, your model DSCB is MODEL.GDG. This is a data set set up by your site support group specifically for creation of GDG generations. The DCB characteristics you do not provide for your GDG will be defined from the DCB of MODEL.GDG -- not any previous generation of your GDG. There may be only one model DSCB on a system, or there may be hundreds -- it depends upon how your site is set up.

I would recommend coding the DCB for your new generation as
Code:
DCB=(MODEL.GDG,LRECL=145,RECFM=FB,BLKSIZE=0)
Back to top
View user's profile Send private message
santosh100678

New User


Joined: 21 Sep 2009
Posts: 55
Location: Kolkatta

PostPosted: Tue Mar 30, 2010 12:38 pm
Reply with quote

thanks for explanation

then robert it is unnecessary to give Code:
DCB=(MODEL.GDG)
then only we code for DCB for new version acoording to requrement
(DCB=LRECL=145,RECFM=FB,BLKSIZE=0)

only my concern
if i give name is model1 then what i can put for next genration
//MODEL1 DD DSN=MTPLD01.TEST.GDG(+1),
// DISP= (NEW,CATLG,DELETE),
// SPACE=(TRK,(10,25),RLSE),UNIT=SYSDA,
// DCB=(LRECL=145,RECFM=FB,BLKSIZE=0)

//STEP3 EXEC PGM=SORT
//SYSOUT DD SYSOUT=*
//SORTIN DD DSN=MTPLD01.TEST.SORT1,DISP=SHR (file lenght is 133 of input)
//SORTOUT DD DSN=MTPLD01.TEST.GDG(+1), (ouput file is 145 but using model.gdg as dcb face error )
// DISP=(NEW,CATLG,DELETE),UNIT=SYSDA,
// SPACE=(TRK,(100,50),RLSE),
// DCB=(MODEL.GDG)
//SYSIN DD *
SORT FIELDS=COPY
OUTREC FIELDS=(1:1,8,11:16,5,132X)
_________________

can i write model1.GDG,lrecl,blksize,recfm
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8697
Location: Dubuque, Iowa, USA

PostPosted: Tue Mar 30, 2010 4:51 pm
Reply with quote

Code:
//MODEL1 DD DSN=MTPLD01.TEST.GDG(+1),
// DISP= (NEW,CATLG,DELETE),
// SPACE=(TRK,(10,25),RLSE),UNIT=SYSDA,
// DCB=(MODEL.GDG,LRECL=145,RECFM=FB,BLKSIZE=0)
works just fine. If you are creating a new generation of a GDG, and the GDG is not under SMS control, I don't think you have an option -- the model DSCB is required. As I said earlier, there is no relationship between the GDG name you are creating and the model name -- they are distinct and different entities.
Back to top
View user's profile Send private message
expat

Global Moderator


Joined: 14 Mar 2007
Posts: 8797
Location: Welsh Wales

PostPosted: Wed Mar 31, 2010 2:36 pm
Reply with quote

Robert, I believe that you will find that using a DATACLAS for a non SMS GDG will also work.

After all, one of the aims of SMS when it was intorduced was to get people to move away from the use of model GDG / DSCB. Just so long as the correct RECFM and LRECL parameters are supplied, there will be no problems.

Code:
//DDNAME   DD DSN=whatever (+1),DISP=(,CATLG,DELETE),
//            SPACE=(CYL,(pri,sec),RLSE),
//            RECFM=??,LRECL=nnnnn

But depending on the set up of your site, you may not even need space parameters.
Back to top
View user's profile Send private message
Robert Sample

Global Moderator


Joined: 06 Jun 2008
Posts: 8697
Location: Dubuque, Iowa, USA

PostPosted: Wed Mar 31, 2010 4:40 pm
Reply with quote

Expat, I totally agree with what you're saying. But the o/p seems to be using a model DSCB and I'm not sure if it is because the GDG is not under SMS control or because there's a lack of understanding of the site standards.
Back to top
View user's profile Send private message
View previous topic :: :: View next topic  
Post new topic   Reply to topic View Bookmarks
All times are GMT + 6 Hours
Forum Index -> JCL & VSAM

 


Similar Topics
Topic Forum Replies
No new posts isfline didnt work in rexx at z/OS ve... CLIST & REXX 7
No new posts DFHPI1008 JSON generation failed COBOL Programming 0
No new posts Started task using a generation dataset JCL & VSAM 7
No new posts How to copy the -1 version of a membe... TSO/ISPF 4
No new posts Report generation JCL & VSAM 18
Search our Forums:

Back to Top