IBM SC34-5764-01 Server User Manual


 
CD
 CD
dirid

CD changes the RFS file system directory.
Operands
dirid
specifies a partial or full REXX File System directory that becomes the new current working directory
for you.
If dirid is not specified, the current working directory is retrieved and placed in the REXX special
variable RESULT, instead of changing the current working directory.
A full directory ID is in the form: poolid:\dirid1\...\diridn
When a full directory ID is specified, it completely replaces the previous directory setting.
A partial directory ID does not begin with a poolid. In this case, the partial directory ID is appended to
the end of the existing directory ID. If the partial directory ID begins with two periods, this indicates
that one directory level is removed (from the right), before the new partial directory ID is appended to
the end. In this case, a backslash is required before the directory ID.
For example: If the current directory is POOL1:\USERS\USER1\ABC and you enter CD ..\XYZ the new
current directory will be POOL1:\USERS\USER1\XYZ.
The default directory ID for you is poolid:\USERS\userid\, where poolid: is the file pool identifier of the
first RFS file pool defined and userid is your CICS signon user ID. If you are not signed onto CICS,
userid defaults to the value in CICS DFLTUSER.
Return Codes
0 Normal return
521 Error in retrieving file pool definition
522 Error in creating default RFS directory
523 Error in storing current RFS directory information
524 RFS directory does not exist or access not authorized
525 Error in retrieving directory information
526 Invalid file pool/directory
527 Cannot go back past root directory
528 Error setting result value
Examples
'CD \USERS\USER2\XYZ'
This example changes your current working directory to \USERS\USER2\XYZ in the file pool you are
currently using regardless of the previous directory setting.
If your current directory is \USERS\USER2 and you enter:
'CD XYZ'
then your current directory is changed to \USERS\USER2\XYZ.
Note
The CD command works in conjunction with the PATH command identifying the search order for the
execution of REXX execs. The current directory (specified by the CD command) is always searched first
Commands
Chapter 25. REXX/CICS Commands 321