I think this is just one of the quirky things IBM has been getting away with 
for years.  It's that way, because the VSAM designers built it that way.
It's not a big enough issue to go out an fix it (e.g. Have the IDCAMS DEFINE 
command (possibly optional) open the KSDS just defined, for OUTOUT and write a 
null record and then  delete it.
I recently found out that some IBM utilities (IMS DBRC) actually expect a 
cluster in "create mode", when switching to a new secondary RECON dataset.  If 
you provide an initialize cluster, the DBRC utility ABENDS and says the dataset 
had been used before and no valid header record could be found.
So I doubt IBM will ever provide an option to do this in the DEFINE command.

There are programs available on the CBT Tape (CBTTAPE.ORG) that will initialize 
a new cluster (intelligently).  Personally, I like the INITKSDS program. 

Roger W. Suhr
suhr...@gmail.com


-----Original Message-----
From: IBM Mainframe Discussion List <IBM-MAIN@LISTSERV.UA.EDU> On Behalf Of 
Paul Gilmartin
Sent: Tuesday, May 29, 2018 20:51
To: IBM-MAIN@LISTSERV.UA.EDU
Subject: Re: empty KSDS behavior - why?

On Tue, 29 May 2018 20:42:53 -0400, Doug Shupe wrote:

>LOADED vs UNLOADED.
>
>Read the VSAM DEMISTIFIED Redbooks.
>
>When you define a VSAM file it is in an UNLOADED state, REPRO will open for 
>output and work just fine.
>
>If you write a record and delete the record the VSAM file is now in a LOADED 
>state. You should be able to open I/O or REPRO with the REPLACE option.
>
>I surely might have missed what your trying to do but this is not rocket 
>science and has been this way for years..
>
Antiquity doesn't make something right.  The Fugitive Slave Act was the law of 
the land for years.

-- gil

----------------------------------------------------------------------
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