× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



George,

My memories are hazy because its been a while since I've used an output-only
file.  My recollections indicate that the system is working as designed in
your case.  An output file is treated as SEQONLY(*YES).  If you want other
programs to have access to all records, I think that you would need to open
the file for update/add rather than output or force the data to disk using
an operation (FEOD) or an override.

The information below is from the RPG User's Guide:

"For output files and for input files that do not use random functions (such
as SETLL, SETGT, CHAIN, or ADD) and that have only one record format, the
RPG/400 compiler defaults to or operates as though SEQONLY(*YES) had been
specified on the CL command OVRDBF. (The RPG/400 compiler does not operate
as though SEQONLY(*YES) had been specified for update files.) SEQONLY(*YES)
allows multiple records to be placed in internal data management buffers;
the records are then passed to the RPG/400 compiler one at a time on input.
...  To prevent this problem, use the CL command OVRDBF and specify the
option SEQONLY(*NO), which indicates that you do not want multiple records
transferred for a sequentially processed file."

Regards,
Andy Nolen-Parkhouse

> On Behalf Of George Kinney
> Subject: Record commitment and SVCPGM question
> 
> I've been in the process of refactoring a lot of old applications, and in
> the process have started to move some of the functions into SVCPGMs.
> 
> Today I ran into an odd situation, and I don't know if I caused it, or if
> its just my own ignorance of what is supposed to be going on.
> 
> Basically, I have a SVCPGM (TESTUTIL) that reads/updates a couple of files
> (say FILE1 (update), FILE2 (output only)).
> 
> I call a program , that calls procedures in the SVCPGM from the command
> line.  What I notice is that changes to FILE1 are immediately obvious,
> while
> writes to FILE2 aren't visible (via DSPPFM or DBU) until I log-off,
> terminating the SVCPGM. (It was compiled with ACTGRP(*CALLER), as was the
> program that is referencing it.)
> 
> What bothers me is that I can't see the records that are being written
> until
> after the SVCPGM terminates.  Is this normal? I am not using any
> commitment
> control that I am aware of.





As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.