Application Development Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 

F-03 Account bbbbb is currently blocked by user YYYYYY

ronaldo_aparecido
Contributor
0 Kudos

Hi community

I have a call transaction in loop to F-03 transaction and sometimes i receive a message :

Account 111111 is currently blocked by user YYYYYY

Are there a function or a way to see if account is blocked and i can use while command and exit of this while when the account is unblocked?

Thanks

1 ACCEPTED SOLUTION

maciej_domagaa
Contributor
0 Kudos

You might use fm ENQUEUE_READ to check what locks are currently set in the system.

But it's not a good idea to use it in a loop, on and on, just in order to exit that loop. If you are able to spot a message like: "Account 111111 is currently blocked..." then why do you need to check this once again by calling some other function ? If your loop is able identify that message (returned by "call transaction" I suppose) then it's enough to decide whether to exit or not.

regards

4 REPLIES 4

maciej_domagaa
Contributor
0 Kudos

You might use fm ENQUEUE_READ to check what locks are currently set in the system.

But it's not a good idea to use it in a loop, on and on, just in order to exit that loop. If you are able to spot a message like: "Account 111111 is currently blocked..." then why do you need to check this once again by calling some other function ? If your loop is able identify that message (returned by "call transaction" I suppose) then it's enough to decide whether to exit or not.

regards

0 Kudos

Thanks

Maciej Domagala

I using wait up to seconds and solve the problem .

Thanks

0 Kudos

HI the wait up to is bad to performance are there other way ?

0 Kudos

If this is a batch input called in a loop and you get an error message due to lock set by the transaction called in previous loop pass (because the update has not finished yet) - then instead of checking whether the lock has been released or not - and instead of using "wait up to" - put this staement in your program before the loop begins:

set update task local

This way you force the system to perform the update within the current workprocess - not using asynchronous update processes. As a result when the "call transaction" finishes, the update is already finished: data saved to the database and locks already released.