5 Replies Latest reply on Sep 8, 2009 1:06 PM by TSGal

    Server side loop crashes FMS 10



      Server side loop crashes FMS 10

      Description of the issue

      I created a server side script to update a field with related data so that it can be indexed.  The field works fine from 10 client but crashed the server. Brand new FMPA 10.3 file  ( but it does look at data in a 'foreign' table.  but the TO is in the graph.No on open or close scripts subscript that   goto layoutshow all recordsgoto first recordloop  IF [ related data  local field ]    set field;   commit end ifgoto next record - exit after last end loop  Get the error: Schedule "Update Ticklers" scripting error (101) at "zServerRobot : Test Server mod Tickler : Go to Record/Request/Page". twice then the server rolled.   

        • 1. Re: Server side loop crashes FMS 10

          Sorry Server is 2003 v 5.2.3790


          Fms is 10.0.1.xx

          I updated it to but I am afraid to run the script again. 

          • 2. Re: Server side loop crashes FMS 10



            Thank you for your post.


            An error 101 is "Record is missing".  Therefore, you may want to trap for that error and decide what you want to do at that point.


            Go to Layout  [ <layout name> ]

            Show All Records

            If [ Get ( FoundCount ) = 0 ]

               Exit Script

            End If 

            Go to Record/Request/Page [ First ]


               If [ Count ( <related table>::<field> ) > 0 ]

                  If [ related data ≠ local field ]

                     Set Field [ ... ] 

                     Commit Records

                  End If 

               End If

               Go to Record [ Next ; Exit after last ]

            End Loop




            That is, I put in two error checks.  The first error check occurs in the third step as it checks to make sure there are records in the table.  If not, the script is exited.  In your original script, if you go to the first record of a table that has no records, you would get a 101 error.


            The second error check occurs just inside the loop as it checks to make sure there are related records.  If so, then we evaluate a value in the related record with a value in the current table.  In your original script, if there is no related value for a record, you would also get a 101 error.


            If you need clarification for any of the above steps, please let me know.



            FileMaker, Inc. 

            • 3. Re: Server side loop crashes FMS 10

              This does not solve the problem.


              The script still kills the server.


              I redid the script and put it in a different interface file ( brand new) and it runs but nothing happens.  


              I think moved it to one of the "data files"  instead of an interface file, and it worked.


              The may be a permissions thing, even though the script is running with a full access, filemaker user, because there are authentication errors ( in the log)  and when it runs and kills it, it does not log  opening the the other related files,

              When the new script runs, it doesn't open any files.  but when it runs on from the data file, it opens up both files, runs and then closes them.

              • 4. Re: Server side loop crashes FMS 10

                If I remember correctly, external file references on a server side script must refer only to relative path references and they don't work for references that use an explcit IP address instead. This wouldn't explain the crash, but it would explain the error code you are seeing.


                Check your file references and see if they are (or can be changed to: ) File: Filename

                • 5. Re: Server side loop crashes FMS 10



                  Thank you for the additional information.


                  The explanation from PhilModJunk is correct (Thank you!).  However, even with that information, it still should not cause a crash.


                  My first thought is that the file is corrupt.  Can you tell me more about the history of the file?  That is, was it created in FileMaker Pro 10, or did it come from a previous version?  Or versions?


                  If possible, I would like to obtain a copy of your files (or just the necessary files) so I can try it here.  I have sent you a private message (top of this page - right side - X Messages) with instructions where to send the file.



                  FileMaker, Inc.