[Info-vax] Cobol: Faster flushing of buffer to sequential file
George Cornelius
cornelius at eisner.decus.org
Fri Feb 4 23:16:13 EST 2011
In article <941ea11d-36c0-4110-9d8f-6d3b2d6fc323 at x1g2000yqb.googlegroups.com>, Hein RMS van den Heuvel <heinvandenheuvel at gmail.com> writes:
> Practically YES: Consensus. And Flush needed.
> Technically NO: The data IS written tot the disk.
> It's just that mere mortals can not see it there.
> So practically it ain't there :-).
Eureka! See below for a simple solution.
The OPEN verb can access the file. _And_ it will update the EOF
pointer for us at close time.
Note that there is probably nothing magic about DCL. Anything that
opens for shared _write_ will probably update the EOF pointer on
close.
George Cornelius
----------------------------------------------------------------------------
[As before, MAHER.EXE is at a read prompt, srl a directory listing variant]
GFC_EISNER> open/read/write/share xx my_file.dat
GFC_EISNER> read xx stuff
GFC_EISNER> say stuff
A message
GFC_EISNER> srl .dat/sin
Directory USR_SCRATCH:[CORNELIUS]
MY_FILE.DAT;1 0 4-FEB-2011 23:05:07.69
Total of 1 file, 0 blocks.
GFC_EISNER> close xx
GFC_EISNER> srl .dat/sin
Directory USR_SCRATCH:[CORNELIUS]
MY_FILE.DAT;1 1 4-FEB-2011 23:05:07.69
Total of 1 file, 1 block.
----------------------------------------------------------------------------
More information about the Info-vax
mailing list