Documentation Comments
Use this form to comment on this topic. You can also provide any general observations about the Online Documentation, or request that additional information be added in a future release.
RealityV15.1Online Documentation (MoTW) Revision 7
FLUSH Statement (DataBasic) (m618703+flush_s.htm)
Clears the read / write data caches, forcing a data write if required and causing subsequent READSEQ and READBLK statements to re-read the source data.
FLUSH seqfile.variable {SETTING setting-var} {ON ERROR statement(s)} [ THEN statement(s) | ELSE statement(s) ]
seqfile-var The name of a variable containing a sequential file reference (assigned via an OPENSEQ statement).
setting-varThe name of a variable to which the return status is assigned. See Operation for details of the possible values for this variable.
statement(s)A sequence of one or more valid DataBasic statements, either separated by semicolons, or contained on separate lines and followed by an END statement.
See Operation for details of the circumstances under which the different clauses are executed.
The following details circumstances under which the different clauses are executed and the values returned in setting-var:
Clause Executed | Reason | setting-var | STATUS() Value |
---|---|---|---|
THEN | Flush successful | Current position | 0 |
ELSE | File or item does not exist | 2420 | 206 |
ON ERROR | Item not opened for sequential access (not opened with OPENSEQ) | B45 | 12 |
File or item not open | B12 | 12 | |
General file error | Error number | Error number |
Notes: