I believe You don’t need to update Configuration file for each record you process.
So, You can define the configuration file in Input mode to avoid record locks.
If you have case, where you need to update the configuration file, Use Extender (READ(N)) not to lock the file where ever you don’t need to update.
And, Use Extender ‘E’ (READ(E)) where ever you need the file in update mode and check for error after READ Statement.
Issue DLYJOB Command to wait for few seconds and retry the READ Opeation
DOW NOT %EOF(TESTFILE)
// Your Logic
KEY01 READ(E) TESTFILE
IF %ERROR()
DLYJOB //Mention Seconds
ITER
ENDIF
// Your Logic
ENDDO
Pradeep.
Discuss This Question: 1  Reply