0

I want to read size of members of a pds For example:-

my pds name is - my.pds.cics
If i browse this pds I will find details like below:
     name     prompt size     created ..............
____PDS1             0051e   25/03/2016
____PDS2             006be   25/03/2016
____PDS3             0078e   25/03/2016
____PDS4             0051g   25/03/2016

I want to read the size of all the members of this pds and store it in variable. ex. var1 = 0051e

Please help me how to o it.I tried using lmmfind. Can anyone help me with the codes in REXX.

Ahmad Aghazadeh
  • 16,571
  • 12
  • 101
  • 98
uz_support
  • 57
  • 2
  • 6
  • 1
    You should have a look at a near duplicate question here [Read the size of the member of the pds](http://stackoverflow.com/questions/36180974/read-the-size-of-the-member-of-the-pds) – MikeT Mar 25 '16 at 19:38

1 Answers1

0

Have you looked at the variables available in LMMFIND

if it is a load module, ZLSIZE should hold the size

if it is a FB file and ispf stats are set, ZLCNORCE will hold the number of records. and

 size = NumberOfRecord * RecordLength

if it is VB, you are stuffed.

The other option is to treat the file as a recfm=u and write a program and read the raw data. You should be able calculate the approximate size from the Member-start/end positions. There are IBM manuals that document the format.

Bruce Martin
  • 10,358
  • 1
  • 27
  • 38
  • Although not necessarily that efficient, you aren't stuffed if it's VB. You could do either VB or FB buy getting the directory list using either LMMLIST and then read through all records via EXECIO, which can handle VB (obtaining and accumulating the record lengths). – MikeT Mar 26 '16 at 12:00