Previous topic |
Next topic |
Contents |
Contact z/OS |
Library |
PDF
SAVE_LENGTH—Set or Query Length for Variable-Length Data z/OS ISPF Edit and Edit Macros SC19-3621-00 |
|
The SAVE_LENGTH macro command sets or queries the length to be used to save each record in a variable-length file. It does not enable you to truncate the nonblank portion of a record, but it does enable you to extend a record. When records are written to disk, they are padded on the end with blanks as needed. SyntaxAssignment statement syntax >>-ISREDIT--(varname)-- = --SAVE_LENGTH--+-label---+----------->< '-linenum-' >>-ISREDIT--SAVE_LENGTH--+-linenum-+-- = --value--------------->< '-label---' DescriptionYou can use the SAVE_LENGTH macro command to set or query the minimum length that is used to store an individual record in a variable-length data set. When setting a length, the length is automatically adjusted to include the nonblank portion of the line. When retrieving the length, the number returned reflects the line length that would be used if the line were saved immediately. This is the greater of these two values:
You can use the SAVE_LENGTH command in edit macros to define line commands to prompt the user for final record lengths or to check the record length. You might also use it to substitute a visible character for trailing blanks to make editing easier. Use of the SAVE_LENGTH command does not prevent the editor from working on data past the specified record length. The length set and returned by the SAVE_LENGTH command is only used when the data is written and does not affect the operation of any other edit functions. Return codes
ExamplesTo save the number of characters
that are saved for the last line in the file when PRESERVE OFF is
active:
To
set the minimum line length for the last line in the file and to set
PRESERVE ON active:
Another edit macro sample using the SAVE_LENGTH command can be found in the ISRSETLN member of the ISPF EXEC library. |
Copyright IBM Corporation 1990, 2014
|