Page 1 of 1

how to set dataset's attribute?

PostPosted: Wed May 29, 2013 7:38 am
by marshall25
hi all,

i want to create a PS file FILE01 with length 80, and i want from columm 1 to 10 have default value and fields be protected, i mean if i insert one record, the columm 1 to 10 will auto have default value(REC HDR), the edit parts will start columm 11.

how can i to create such dataset?

example:

=COLS> ----+----1----+----2----+----3----+----4----+----5----+----
000001 REC HDR   RECORD01                                         
000002 REC HDR   RECORD02                                         
000003 REC HDR   RECORD03                                         
000004 REC HDR   RECORD04                                         

Re: how to set dataset's attribute?

PostPosted: Wed May 29, 2013 7:53 am
by steve-myers
The operating system base function will allocate a data set, but except for an empty PDS directory, it will not put anything into the data set. You need a program of some sort to put something into the data set.

The only program I can think of that might be able to initialize a data set in the manner you just described might be the IEBDG utility. Unfortunately, in almost 45 years, I've never attempted to use it, so I can't help you beyond this. It is documented in DFSMSdfp Utilities for your z/OS release. I rather doubt IEBDG has been changed in any meaningful fashion in more than 40 years, so almost any Utilities manual you can find should be adequate.

Re: how to set dataset's attribute?

PostPosted: Wed May 29, 2013 8:13 am
by Robert Sample
how can i to create such dataset?
You cannot.

You need to find the TSO/ISPF bookshelf manual ISPF Edit and Edit Macros which will allow you to use TSO/ISPF to accomplish some of what you want -- look at the MASK facility. However, ISPF Edit works on a data set -- you don't get to determine that the first 10 bytes are protected (and the edit will start with byte 1), although you can use BNDS to limit the impact of commands.

Re: how to set dataset's attribute?

PostPosted: Wed May 29, 2013 5:43 pm
by NicC
you can also add a tab at cc10 so that the cursor will be placed at cc11 - at least, I suspect that is why my cursor goes to cc7 on a newline. It can be abore though as I then have to manually place it where I want.

Re: how to set dataset's attribute?

PostPosted: Wed May 29, 2013 9:13 pm
by Ed Goodman
If this is being used later, can you let the edit start in column 1, then ADD the fixed value to the front in a separate step?