2 Replies Latest reply on Apr 29, 2014 10:22 AM by philmodjunk

    Server-side script (scheduled) error

    ThierryGuemboura

      Summary

      Server-side script (scheduled) error

      Product

      FileMaker Server

      Version

      13.0.1

      Operating system version

      Server 2008r2

      Description of the issue

      For years I have used Dacons Mailit plug-in. Since I upgraded to FMS13 I was not able to run successfully my scheduled Get Mail and Send Mail server-side scripts.
      I noticed in the server log the following:
      1) Errors shows that the server in executing the startup script of the application
      2) After including a script step to avoid the server to execute the startup script, the right script starts but errors 101 and 401 show up in the log. The script though has Error Capture on and the loop is properly scripted to stop when 0 records.
      These are the same scripts I have been using for years, so I would lean towards a FMS13 bad behavior rather than a script error

      Steps to reproduce the problem

      1) Schedule a script using mailit plug-in to Get Mail
      2) Run the script and check server Event.log

      Expected result

      1) Application startup script should not be executed
      2) Properly scripted "perform find" and Loop reaching 0 should not generate errors

      Actual result

      Opposite of expected results described above

      Exact text of any error message(s) that appear

      1) Proof that Startup script is launched:
      SERVER1     Schedule "Mail_send_by_server" scripting error (3) at "ICU-Claims : Startup : Freeze Window".
      2014-04-25 11:58:00.486 -0400     Information     645     SERVER1     Schedule "Mail_send_by_server" scripting error (3) at "ICU-Claims : Startup : Allow Formatting Bar".
      2014-04-25 11:58:00.486 -0400     Information     645     SERVER1     Schedule "Mail_send_by_server" scripting error (3) at "ICU-Claims : Startup : Set Use System Formats".
      2014-04-25 11:58:00.486 -0400     Information     645     SERVER1     Schedule "Mail_send_by_server" scripting error (3) at "ICU-Claims : Register & Check Mailit 5.0 Email

      2) Errors in scheduled script:
      2014-04-25 11:58:00.783 -0400     Information     645     SERVER1     Schedule "Mail_send_by_server" scripting error (101) at "ICU-Claims : Go to Folder by Server : Set Field".
      2014-04-25 11:58:00.783 -0400     Information     645     SERVER1     Schedule "Mail_send_by_server" scripting error (101) at "ICU-Claims : Set Message Contacts : Go to Record/Request/Page".
      2014-04-25 11:58:00.798 -0400     Information     645     SERVER1     Schedule "Mail_send_by_server" scripting error (401) at "ICU-Claims : Set Message Contacts : Perform Find".
      2014-04-25 11:58:00.798 -0400     Information     645     SERVER1     Schedule "Mail_send_by_server" scripting error (101) at "ICU-Claims : Send Message by Server : Go to Record/Request/Page".

      Workaround

      1) In Application Startup Script: Step to catch server and "Exit" script

      ICU_FMS13_Error_Log.PNG

        • 1. Re: Server-side script (scheduled) error
          TSGal

               Thierry Guemboura:

               Thank you for your post.

               When you execute a server-side script, a new client is created, and any startup scripts will be executed.  Placing a conditional statement in the startup script to check for a server side script is correct.  See Knowledge Base Article #11893 for more information at:

          http://help.filemaker.com/app/answers/detail/a_id/11893

               Please also see section 4 of Knowledge Base Article #12541 regarding unsupported scripts steps now reporting error 3:

          http://help.filemaker.com/app/answers/detail/a_id/12541

               Errors 101 (record is missing) and 401 (no records match the request) will occur when no records are found.  Can you post the relevant parts of your scripts where this is failing?  Especially where the Find criteria is empty (Error 400 - last line of screen shot).

               TSGal
               FileMaker, Inc.

          • 2. Re: Server-side script (scheduled) error
            philmodjunk
                 

                      Errors 101 (record is missing) and 401 (no records match the request) will occur when no records are found.

                 And this can be a case of your script executing normally with no actual error that needed to be logged, but FileMaker logged it as an error any way.

                 A find that finds no records and thus produces an empty set is one example.

                 Also, Go to next record with "exit after last" specified  logs a 101 error when this option causes the script to exit the loop even though this is the normal expected behavior of your script.