Copyright 2024 - BV TallVision IT

In some cases it would make sense to just wait. An update was done in the previous step and you want to continue processing, but you need to make sure all update steps are properly executed, just inform the system to wait. 

The WAIT UP TO n SECONDS statement is available for this. Rather then making the system do something for x many seconds, this statement sets an alarm clock and the first statement below the WAIT is executed only after the defined number of seconds have passed.

Before this statement became available, function module RZL_SLEEP produced the same effect. Have a glance just to see what it involves and stick to using WAIT.

When to use a wait step?

  • To allow a commit action to be completed. Database commits are complex and require a great number of steps. If you find data that has just been stored is not yet available, simply wait a few (3) seconds for it to "land".
  • You could as an alternative simply keep selecting the information you are after and simply try again if it is not available yet. A system resource consuming approach, that will get results a bit faster than having to wait for x seconds. The best of both worlds: do a wait step for 1 second every time the selection failed
  • Lock release - when locking is released (function DEQUEUE_) please be aware that this lock is not vanished the moment the function module is ended. Not immediately.
  • Triggers from change documents or events