PD (Print Directory) and PDRES (Print Directory Resident Files)

The PD (Print Directory) command displays summary and detailed information about disk files and cataloged tape files. The PDRES (Print Directory and Resident Files Only) command displays summary and detailed information about resident disk files.

The PD and PDRES commands also can display the directory of a wrapped container. When these commands are used this way, both commands return the same information. For information about wrapped containers, refer to the discussion of the WRAP and UNWRAP commands in WFL Made Simple.

Syntax for Disk Files and Cataloged Tape Files

──┬─ PD ────┬─┬─┬─<file name>──────┬───────────────────────────┬───────►  
  └─ PDRES ─┘ │ └─<long file name>─┘                           │
              ├─┬─<directory>──────┬───────────────────────────┤
              │ └─<long directory>─┘                           │
              ├──────────────────────┬──────┬─ = ─┬─┬──────────┤
              ├─<directory>─ / ──────┤      └─ - ─┘ └─ number ─┘
              └─<long directory>─ / ─┘
►─┬────────────────────────────┬──────────────────────────────┤
  └─ ON ─┬─<family name>───────┤
         └─<CD name>─┬─(CDROM)─┤
                     └─(CD)────┘

<directory>

──┬─ (<name>) ─────────────────────────────┬──────────┤
  ├─ *USERCODE ────────────────────────────┤
  │                       ┌◄────────────┐  │
  ├─────────────────────┬─┴─/11\─<name>─┴──┘
  ├─ (<name>)───────────┤
  ├─ *USERCODE/<name>/ ─┤
  └─ * ─────────────────┘

<long directory>

──┬─ (<name>) ─────────────────────────────┬──────────┤
  ├─ *USERCODE ────────────────────────────┤
  │                       ┌◄────────────┐  │
  ├─────────────────────┬─┴─/20\─<name>─┴──┘
  ├─ (<name>)───────────┤
  ├─ *USERCODE/<name>/ ─┤
  └─ * ─────────────────┘

<number>

A positive integer used after an equal sign (=) or minus sign (–) that specifies the depth under the given directory of the file name to be displayed.

Syntax for Wrapped Containers

──┬─ PD ────┬─┬─┬─<file name>──────┬───────────────┬── IN ─<container name>────►  
  └─ PDRES ─┘ │ └─<long file name>─┘               │
              ├──────────────────────────┬─┬─ = ─┬─┘
              ├─<directory>───────┬┬─────┤ └─ - ─┘ 
              └─<long directory>──┘└─ / ─┘
►─┬────────────────────────────┬──────────────────────────────┤
  └─ ON ─┬─<family name>───────┤
         └─<CD name>─┬─(CDROM)─┤
                     └─(CD)────┘

<container name>

The file name of a wrapped container. Its syntax is the same as <file name>.

Explanation

PD <file name>

PD <long file name>

Displays information about the presence of the named file on the family disk, and other information about the file. The default family name is always DISK. If the file is not resident on the family and if there is no archive or catalog backup information for the file, the message NO FILE is displayed. If <file name> ends in a minus sign (−), enclose <file name> in quotation marks (" ").

Cataloged tape file entries also can be queried with the PD command. Information about the cataloged tape file is returned only if the system is running with the CATALOGING operating system option (option 23) set and active; otherwise, the message NO FAMILY is displayed. TAPE is the family name for tape files on a cataloging system.

PDRES <file name>

PDRES <long file name>

Displays the names and status of resident disk files and the names of directories that contain resident disk files. The default family name is always DISK. If the file is not resident on the family and if no archive or catalog backup information exists for the file, the system displays the following message: NO FILE. If the file is not resident, but if archive or catalog backup information exists for the file, the system displays the response FILE NOT RESIDENT. If <file name> ends in a minus sign (−), enclose <file name> in quotation marks (" ").

PD <directory>

PD <long directory>

Displays the directory name (if the directory exists) and confirms that it is a directory. No files under that directory are listed. To list these files, enter the following command:

PD <directory>/=

or

PD <long directory>/=

PDRES <directory>

PDRES <long directory>

Displays the directory name if resident files exist under the directory. However, the system does not list the files in the directory. To list the resident files under the directory, enter the following command:

PDRES <directory>/=

or

PDRES <long directory>/=

PD =

Displays the first level of all file names in the pack directory.

PDRES =

Displays the first level of all directories that contain resident files, as well as the names of all resident files with only one node in their name.

PD <directory>=

PD <long directory>=

PD <directory>/=

PD <long directory>/=

Displays a list of all file names in the directory, which have the specified directory name as their prefix. If the directory name specified is also a file name, the file name is included in the list.

PDRES <directory>=

PDRES <long directory>=

PDRES <directory>/=

PDRES <long directory>/=

Displays a list of file names of all the resident disk files, which have the specified directory name as their prefix. If the directory name specified is also a file name, the file name is included in the list.

PD *USERCODE =

Displays a list of all file names in the directory that have usercodes as their prefix.

PDRES *USERCODE =

Displays a list of file names of all the resident disk files that have usercodes as their prefix.

<number>

A positive integer used after an equal sign (=) or minus sign (−) that specifies the depth under the given directory of the file name to be displayed. If you specify 0, the system displays all levels. Using 0 is a useful method for displaying all levels of all files on a pack family.

ON <family name>

Specifies the family to be searched. The default is always DISK.

(CD)

(CDROM)

Specify that the family directory is on a CD-ROM unit. The PD command is used for ISO 9660 format CD-ROMs. To read a library maintenance format CD-ROM, use the TDIR (Tape Directory) command.

PDRES operates the same as PD for CD and CD-ROM.

PD <file name> IN <container name>

PD <long file name> IN <container name>

PDRES <file name> IN <container name>

PDRES <long file name> IN <container name>

Display information about the specified file in the specified container. If the container is encrypted, the response includes ATTRIBUTES NOT AVAILABLE.

If the file is not present in the container's directory, the message NO FILE is displayed.

See the Work Flow Language Programming Reference Manual and the FILENAME description in the File Attributes Programming Reference Manual for more information on long file names.

PD <directory>= IN <container name>

PD <directory>/= IN <container name>

PDRES <directory>= IN <container name>

PDRES <directory>/= IN <container name>

Display a list of all file names in the specified directory of the specified container.

PD = IN <container name>

PDRES = IN <container name>

Display a list of all file names in the specified container.

Examples of PD Commands

Example 1

This example causes the system to display the first level of all names in the directory of the family disk:

PD =
     MV (DIRECTORY)
     SC (DCALGOLSYMBOL)
     SH (DIRECTORY)
     YY (DATA)
     B59 (DIRECTORY)
     ELS (DIRECTORY)
     NEW (DIRECTORY)
     PTD (DIRECTORY)
     RPG (DIRECTORY)
     TPS (DIRECTORY)
     WFL (DIRECTORY)
     YM3 (ALGOLCODE)

Example 2

This example causes the system to display information about all directories and files under the directory named OBJECT on a pack named ACCOUNTS:

PD OBJECT/= ON ACCOUNTS
  OBJECT (DIRECTORY)
  . DOCOL (ALGOLCODE) & (DIRECTORY)
  . . PCN (ALGOLCODE)
  . TELEX (DCALGOLCODE)
  . LISTDOC (ALGOLCODE)
  . RAILROAD (ALGOLCODE)
  . LISTNOTES (ALGOLCODE)

Example 3

This example causes the system to display as many as 4 levels of node names for directories and files ON DISK:

PD = 4
  MV(DIRECTORY)
  . JOB(DIRECTORY)
  . . COPY(DIRECTORY)
  . . . MV(DIRECTORY)
  . PATCHFOR(DIRECTORY)
  SC(DIRECTORY)
  .
  .
  .

Example 4

This example causes the system to display information for all files under the directory named MV/JOB ON DISK:

PD MV/JOB/=
  MV (DIRECTORY)
  . JOB (DIRECTORY)
  . . COPY (DIRECTORY)
  . . . MV (DIRECTORY)
  . . . . 330 (DIRECTORY)
  . . . . . FILES (JOBSYMBOL)

Example 5

This example causes the system to display information to indicate that a WFL directory is on DISK family:

PD WFL
     FILE WFL ON DISK (DIRECTORY)

Example 6

This example causes the system to display information about the file named SYSTEM/CARDLINE on a pack named SYS571:

PD SYSTEM/CARDLINE ON DISK

FILE SYSTEM/CARDLINE ON DISK (ALGOLCODE)                      
  CREATION DATE= Thursday, September 8, 2022 AT 07:06:24 EDT  
LASTACCESS DATE= Friday, September 9, 2022 AT 05:00:31 EDT    
     ALTER DATE= Thursday, September 8, 2022 AT 07:06:24 EDT  
 ATTMODIFY DATE= Saturday, September 10, 2022 AT 06:38:14 EDT 
    BACKUP DATE= Thursday, September 8, 2022 AT 07:06:24 EDT  
  COPYDEST DATE= Saturday, September 10, 2022 AT 06:38:14 EDT 
COPYSOURCE DATE= Monday, September 12, 2022 AT 00:08:05 EDT   
   EXECUTE DATE= Thursday, September 8, 2022 AT 07:06:24 EDT  
      READ DATE= Friday, September 9, 2022 AT 05:00:31 EDT    
TOTAL SECTORS: 72 (1,512 PER AREA, CRUNCHED)                  
TOTAL BYTES: 12,960 (13 KB)                                   
SECURITY = OWNER *:RWX, GROUP <none>:RX, OTHER:RX             
 (PUBLIC - USAGE: READ ONLY)                                  
TARGET: LEVEL6                                                
LICENSEKEY: 630-FILEHANDLING-Z50                              
RELEASEID:  MCP 63 [63.046.000] (63.046)                      
PRODUCT:  A-SERIES/COPY-TOOLS/CARDLINE                        
SEG0 SIGNATURE: A305C4320B3F                                  
DATA SIGNATURE: 51A612E63972                                  
NO ARCHIVE BACKUP RECORD FOR FILE

Examples That Show the Difference Between PD and PDRES Displays

Example 1

This set of examples shows a PD command and display for a directory that contains nonresident files followed by a PDRES command and display for the same directory:

PD A/=ON PACK
     A (DIRECTORY)
     B (DIRECTORY)
       1 (NULLFILE) (NR)
       2 (NULLFILE) (NR)
     C (DIRECTORY)
       1 (NULLFILE) (NR)
       2 (NULLFILE) (NR)
PDRES A/=ON PACK
     NO FILES

Example 2

This example shows the display for a PD command compared to the display for a PDRES command when nonresident files are listed in the directory:

PD = ON PACK
     BD (DIRECTORY)
     DA (DCALGOLCODE)
     XFILES (DIRECTORY)
     SYSTEM (DIRECTORY)
     OLDPROG (NULLFILE) (NR)
PDRES = ON PACK
     BD (DIRECTORY)
     DA (DCALGOLCODE)
     XFILES (DIRECTORY)
     SYSTEM (DIRECTORY)

Example of a PD Command for CD-ROM

This example causes the system to display information about the directory or file named LIB/A4DOCS/“4DOCS.ASA“on a CD-ROM named CDLIB_A400:

PD LIB/A4DOCS/"A4DOCS.ASA" ON CDLIB_A400(CD)
FILE *LIB/A4DOCS/”A4DOCS.ASA” ON CDLIN_A400 (DATA)            
  CREATION DATE= Monday, August 15, 2005 AT 20:36:19
LASTACCESS DATE= Monday, August 15, 2005 AT 20:36:19
     ALTER DATE= Monday, August 15, 2005 AT 20:36:19
 ATTMODIFY DATE= Monday, August 15, 2005 AT 20:36:19
    BACKUP DATE= Monday, August 15, 2005 AT 20:36:19
  COPYDEST DATE= Monday, August 15, 2005 AT 20:36:19
COPYSOURCE DATE= Monday, August 15, 2005 AT 20:36:19
   EXECUTE DATE= Monday, August 15, 2005 AT 20:36:19
      READ DATE= Monday, August 15, 2005 AT 20:36:19
TOTAL SECTORS: 16 (16 PER AREA)
TOTAL BYTES: 2,880 (3 KB)
SECURITY = OWNER *:RWX, GROUP <none>:RX, OTHER:RX
 (PUBLIC - USAGE: READ ONLY)
NO ARCHIVE BACKUP RECORD FOR FILE

Examples of PD Commands for Containers

Example 1

The following PD command displays information about a file that is present in the container:

PD *SYSTEM/PRINT/ROUTER IN (SMYTHE)CONT ON MCPS
  CONTAINER (SMYTHE)CONT ON MCPS [UNSIGNED, WRAPPED ON SSR511]
  FILE *SYSTEM/PRINT/ROUTER (DCALGOLCODE)
    CREATION DATE = Monday, August 8, 2005 AT 15:04:41
  LASTACCESS DATE = Friday, August 12, 2005 AT 23:57:02 PDT
       ALTER DATE = Monday, August 8, 2005 AT 15:04:41
   ATTMODIFY DATE = Wednesday, August 10, 2005 AT 13:09:21 PDT
      BACKUP DATE = Monday, August 8, 2005 AT 15:04:41
    COPYDEST DATE = Wednesday, August 10, 2005 AT 13:09:18 PDT
  COPYSOURCE DATE = Monday, August 8, 2005 AT 15:04:41
     EXECUTE DATE = Friday, August 12, 2005 AT 23:57:02 PDT
        READ DATE = Monday, August 8, 2005 AT 15:04:41
  TOTAL SECTORS: 747 (504 PER AREA, CRUNCHED)
	 TOTAL BYTES: 134,460 (134 KB)
  SECURITY = OWNER *:RWX, GROUP <none>:RX, OTHER:RX
    (PUBLIC - USAGE: READ ONLY)

The following PD command attempts to display information about a file, but the file is not present in the container:

PD *SYSTEM/MCP IN (SMYTHE)CONT ON MYCD(CD)
     NO FILE

Example 2

The following PD command displays a directory of nonusercoded files in a container:

PD *SYSTEM/= IN (SMYTHE)CONT ON MYCD(CDROM)
  CONTAINER (SMYTHE)CONT ON MYCD [UNSIGNED, WRAPPED ON SSR511]
  *SYSTEM/PRINT/BACKUP/PROCESSOR
  *SYSTEM/PRINT/REMOTE/SERVER
  *SYSTEM/PRINT/REMOTE/PROCITEMS
  *SYSTEM/PRINT/ROUTER
  *SYSTEM/PRINT/DRIVERS
  *SYSTEM/PRINT/SUPPORT
  *SYSTEM/PRINT/VIRTUALS
  *SYSTEM/PRINT/BNAROUTER

The following PD command displays a directory of files under a particular usercode in a container:

PD (SMYTHE)= IN (SMYTHE)CONT
  CONTAINER (SMYTHE)CONT [UNSIGNED, WRAPPED ON SSR511]
  (SMYTHE)OBJECT/TEST/PROG
  (SMYTHE)OBJECT/TEST/LIB

Example 3

This following PD command displays all the files in a container.

PD = IN SOFTCONT ON PACK
  CONTAINER SOFTCONT ON PACK [SIGNED, WRAPPED ON SSR511]
  *SYSTEM/PRINT/BACKUP/PROCESSOR
  *SYSTEM/PRINT/REMOTE/SERVER
  *SYSTEM/PRINT/REMOTE/PROCITEMS
  *SYSTEM/PRINT/ROUTER
  *SYSTEM/PRINT/DRIVERS
  (SMYTHE)TEST/PROG
  (SMYTHE)OBJECT/TEST/PROG
  (LAD)SOURCE/LIB
  (FRANKEL)OBJECT/PEEKPOKE