Previous Topic: $SRV_IDR_LISTNext Topic: $SRV_READ_IMOD


$SRV_PDS_LIST

The $SRV_PDS_LIST routine returns a listing of all contained members in a PDS. If requested, the user-data field is returned as ISPF statistics.

Syntax

CALL $SRV_PDS_LIST ddname [ISPF]

Parameters

ddname

DDname to allow access to the PDS.

ISPF

If specified, the returned user-data field is formatted as ISPF statistics.

Returned Data

The RC special variable being set to 0 indicates a successful completion and the result is a returned null string. A non-zero value in the RC indicates that there are errors and the result is a returned error message.

Each PDS directory entry is returned on the stack. The first character of each record is a delimiter that is used to parse the individual fields. The order of the returned fields is as follows:

  1. Member name.
  2. ALIAS or TRUENAME, depending upon the entry.
  3. TTR of the start of the member (printable hexadecimal).
  4. Number of TTRs in the user data (whole number, meaningful for load libraries only).
  5. User data.

If ISPF was specified as an option and the user-data appears to be valid ISPF statistics, the user data field is converted to the following blank-delimited fields:

  1. The version and modification level that is specified as vv.mm. The vv and mm values are whole numbers in the range of 0 through 255.
  2. The creation date for this member. The format is mm/dd/yy.
  3. The date of last modification. The format is mm/dd/yy.
  4. The time of last modification. The format is hh:mm or hh:mm:ss where hh ranges from 0 through 24, mm ranges from 0 through 59, and ss ranges from 0 through 59. The hh, mm, and ss values are whole numbers.

    Note: ISPF began storing change seconds with Release 3.3. Prior releases only stored hours and minutes.

  5. The current size in lines (logical records) of the member. A whole number in the range of 0 through 65535.
  6. The size in lines (logical records) of the member when it was created. A whole number in the range of 0 through 65535.
  7. The number of times this member has been modified. A whole number in the range of 0 through 65535.
  8. The user ID of the user who most recently updated (or created) this member. A seven-character field (the eighth character, if any, is truncated), right-padded with blanks.