Jim Phillips wrote:
>In addition to the SHR;GMULTI Stan specified, I'd add LOCK and then use the
>EXCLUSIVE/
>UN-EXCLUSIVE verbs in the COBOL program(s) to logically lock the file when
>writing
>to it. I'd also add the FILE STATUS clause to the SELECT statement and
>interrogate
>the file status after each I/O operation (OPEN/EXCLUSIVE/WRITE/...). We do
>a similar
>process with MSG files (N writers and 1 reader) from COBOL programs and
>this is what
>works for us. YMMV.
I did this many, many years ago and concur with these recommendations.
The lock is important if the program ever writes consecutive records that
need to stay together.
Since this is a type of logging file, I would also add the Fcontrol (don't
remember the number) that forces the data to be written to disc. Pass the
FD name to the intrinsic as the file number. If you do this, you don't
need GMULTI.
John D. Alleyn-Day
Alleyn-Day International
408-286-6421 408-286-6474 (Fax)
[log in to unmask]http://www.Alleyn-Day.com