WRITE command
Writes a new record to a file on a local or a remote system. In Smalltalk, the parameters of the WRITE command are contained in two classes: CICSWrite and CICSWriteResult. 
See CICS Application Programming Reference for the syntax of the command and a description of its parameters. 
Defined instance methods
Parameters supplied to CICS in CICSWrite
 
|  |  |  |  |  | 
| FILE(filename)  | file:  | Input  | Fixed(8)  |   | 
| FROM(data-area)  | from:  | Input  | Variable  |   | 
| KEYLENGTH(data-value)  | keylength:  | Input  | Binary 16  |   | 
| LENGTH(data-value)  | length:  | Input  | Binary 16  |   | 
| MASSINSERT  | massinsert  | Input  | Switch  |   | 
| RBA  | rba  | Input  | Switch  |   | 
| RIDFLD(data-area)  | ridfld:  | I/O  | Variable  |   | 
| RRN  | rrn  | Input  | Switch  |   | 
| SYSID(systemname)  | sysid:  | Input  | Fixed(4)  |   | 
Parameters returned by CICS in CICSWriteResult
 
|  |  |  |  |  | 
| RESP  | resp  | Output  | Fixed(2)  | Inherited from CICSResult.  | 
| RESP2  | resp2  | Output  | Fixed(2)  | Inherited from CICSResult.  | 
| RIDFLD(data-area)  | ridfld  | I/O  | Variable  |   | 
Example
Writes data into an KSDS file. MyKsdsFile is a subclass of OsPtr. 
| newRecord  result |
 
newRecord  := MyKsdsFile new.
newRecord  lastName: 'Record'.
newRecord  firstName: 'New'.
newRecord  city: 'NewCounty'.
newRecord  state: 'NS'.
 
result := CICS write
               file: 'KSDSF1';
               from: newRecord;
               keylength: 20;
               ridfld: (newRecord  lastName abrPadWithBlanks: 20);
               length: 80;
               exec.
Last modified date: 07/09/2019