[Mat] Rewrite Fi Le [Using {Iihne-Num - IBM 5110 Basic Reference Manual

Hide thumbs Also See for 5110:
Table of Contents

Advertisement

[ 1
KEY rel-exp Char-var}]
[MAT] REWRITE FI LE [USING {Iihne-num}
~
file-ref,
{.
}
c ar-var
J
REC=
Integer
arith-var
172
arith-var
arith-arr-var
char-var
char-arr-var
str-func
MAT array-name [(rows [ ,columns] )]
[ {
[,EXIT line-num]
[,EOF line-num] [,IOERR line-num]
[MAT] REWRITE FILE
[
.
] [
{ NOREC line-num
}J}]
,CONV Ilne-num
'NO KEY line-num
The [MAT] REWRITE FILE statement allows you to change or update an
existing record in a file (record I/O). The file, however, must satisfy the
following requirements:
• The parameter ALL must have been specified in the OPEN FILE statement
for the file.
• If the KEY or REC= parameter is not included in the [MAT] REWRITE FILE
statement, the last access to the file must have been a READ FILE or
REREAD FI LE statement for the record to be changed.
Upon execution, the variables or arrays in the [MAT] REWRITE FILE
statement are transferred to a buffer for the file reference specified. That
buffer will contain the last record read from the file. If the record contains a
key field (for key-indexed access), the field may not be altered. Variable values
are converted for record output just as they are for the [MAT] WRITE
statement, except that the X control specification in the FORM statement
causes data to be bypassed rather than blanked.
The syntax of the [MAT] REWRITE FILE statement is as shown above, where
all of the parameters have the same meaning as those described for the
[MAT] READ FILE statement.
\
'-.
'
...
/

Hide quick links:

Advertisement

Table of Contents
loading

Table of Contents