I have 4 async jobs running, reading data from a data que and calling same
program A with order number.

JOB1 --> Read Data Que --> Call Program A to read File X and update for the
order#
JOB2 --> Read Data Que --> Call Program A to read File X and update for the
order#
JOB3 --> Read Data Que --> Call Program A to read File X and update for the
order#
JOB4 --> Read Data Que --> Call Program A to read File X and update for the
order#

Order File X:
RRN ( X ) Primary Key Order number

3,561,503 55,008,465 19,083,706
3,561,505 55,008,467 19,083,707
3,561,507 55,008,469 19,083,708
3,561,509 55,008,471 19,083,709

Program A --> Does SETLL and READE on a conditional logical file using
order# as the key field.


- JOB1 processed order# 19,083,706 and giving MSGW record in use for
RRN(X) 3561509
- JOB2 processed order# 19,083,709 and kept the lock on RRN(X) 3561509
for over 60 seconds
- JOB3 processed order# 19,083,707 and giving MSGW record in use for
RRN(X) 3561509
- JOB4 processed order# 19,083,708 and giving MSGW record in use
for RRN(X) 3561509

Is there a bug in READE that for some reason its trying to read/lock a
record for a different key or I say next record? logic is simple order#
setll , order# reade.. When we get MSGW we just do a RETRY and all works
fine.

I noticed that someone had a similar issue but there is no clear answer of
this behaviour of READE.
article >>>>>>>>
https://itknowledgeexchange.techtarget.com/itanswers/rpgle-setll-reade-for-update-getting-record-lock-on-different-keying/

This thread ...


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

This mailing list archive is Copyright 1997-2019 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].