3 Replies Latest reply on Mar 30, 2017 5:29 AM by PeterDoern

    ScriptResult from POS-script not returned when wait on completion is off

    maxperts

      Hi There,

       

      I need to do a task on the server that normally takes about 105 seconds to complete. From 90.000 records I need to get a MAX from a field.

      I did two things:

      a     run this task as a POS-script using an SQL-statement and returning the result using the [exit script].

      b     the client script that orders the POS-script to run does [get(Scriptresult)].

       

      Sounds simple and it works. I thought to up the game a notch.

      Since the POS-script takes about a minute and a half to finish I thought to use a [pause script: 105 seconds] to give the layout back to the user while waiting for the POS-script to finish. Since the script resumes after that period we could simple get the result and put it in a global variable to be used in any other given script later.

       

      The client script step [perform on server: wait for completions:off] will never give the result back.

      Is this a 'duh' moment or am I missing something here ?