I use JCL VSAM for CA Allocate testing

This example was for an in-house program and is from 2005, so 13 years ago 
sounds right.  Obviously KEYLEN and KEYOFF are only needed for RECORG=KS.
//PTFXREF   DD   DISP=(,CATLG,DELETE),DSN=&SYSUID..PTFXREF, 
//          STORCLAS=TSO,                                   
//          LRECL=206,KEYLEN=7,KEYOFF=0,RECORG=KS,          
//          SPACE=(TRK,(10,10))                             


TSO ALLOC can also create VSAM files.  TSO DEFINE would be easier, but 
different syntax.
ALLOC DA('TST.XYZ.LDS') -   
 NEW CATALOG  -                          
 TRACKS -                                
 SPACE(5 5) -                            
LRECL(4096) -                            
RECORG(LS) -                             
DATACLAS(LDS) -                        
STORCLAS(SMSLDS) -                      
DSNTYPE(EXTREQ) -                        
DSKEYLBL(TEST.KEY)                    






-----Original Message-----
From: IBM Mainframe Discussion List [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf 
Of Clark Morris
Sent: Wednesday, July 11, 2018 10:48 AM
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Allocating VSAM in JCL was Re: z/OS JCl vs. VSE JCL: VSAM files

CAUTION: This email originated from outside of CA. Do not click links or open 
attachments unless you recognize the sender and know the content is safe.


[Default] On 10 Jul 2018 15:33:56 -0700, in bit.listserv.ibm-main 
johnrcl...@gmail.com (John Clifford) wrote:

>it is not the default but is the only correct way to access a vsam file.
>disp=shr,dsn=xxxx.vsam (possible bufno,bufni,...etc)
>
>Never disp=new or delete.   Disp=old can be used if you need to make sure
>you are the only one accessing the file but if it is open in CICS it 
>will hang.

As of over 13 years ago, you could allocate a VSAM file in JCL and even a 
temporary one.  I never used the facility but it is there.

Clark Morris
>
>On Tue, Jul 10, 2018 at 6:07 PM, Tony Thigpen <t...@vse2pdf.com> wrote:
>
>> So, DISP=SHR is not the default, as I thought was implied by John's 
>> statement that "Z/os VSAM is always accessed as DISP=SHR."
>>
>> Tony Thigpen
>>
>> Gibney, Dave wrote on 07/10/2018 05:49 PM:
>>
>>> If DISP=SHR (that is if not DISP is provided), then the JCL Default 
>>> of
>>> (NEW,PASS) would happen and the job would fail
>>>
>>> -----Original Message-----
>>>> From: IBM Mainframe Discussion List 
>>>> [mailto:IBM-MAIN@LISTSERV.UA.EDU] On Behalf Of Tony Thigpen
>>>> Sent: Tuesday, July 10, 2018 2:43 PM
>>>> To: IBM-MAIN@LISTSERV.UA.EDU
>>>> Subject: Re: z/OS JCl vs. VSE JCL: VSAM files
>>>>
>>>> Then, why does every VSAM DD for every z/OS site I have worked 
>>>> with, always include DISP=SHR?
>>>> (I guess, because it's a habit from non-VSAM files and nobody told 
>>>> them they did not have to do it.)
>>>>
>>>> Tony Thigpen
>>>>
>>>> John Clifford wrote on 07/10/2018 04:16 PM:
>>>>
>>>>> Z/os VSAM is always accessed as  DISP=SHR.
>>>>>
>>>>
>>>> -------------------------------------------------------------------
>>>> --- For IBM-MAIN subscribe / signoff / archive access instructions, 
>>>> send email to lists...@listserv.ua.edu with the message: INFO 
>>>> IBM-MAIN
>>>>
>>>
>>> --------------------------------------------------------------------
>>> -- For IBM-MAIN subscribe / signoff / archive access instructions, 
>>> send email to lists...@listserv.ua.edu with the message: INFO 
>>> IBM-MAIN
>>>
>>>
>>>
>> ---------------------------------------------------------------------
>> - For IBM-MAIN subscribe / signoff / archive access instructions, 
>> send email to lists...@listserv.ua.edu with the message: INFO 
>> IBM-MAIN
>>
>
>----------------------------------------------------------------------
>For IBM-MAIN subscribe / signoff / archive access instructions, send 
>email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions, send email to 
lists...@listserv.ua.edu with the message: INFO IBM-MAIN

----------------------------------------------------------------------
For IBM-MAIN subscribe / signoff / archive access instructions,
send email to lists...@listserv.ua.edu with the message: INFO IBM-MAIN

Reply via email to