2 Replies Latest reply on Jan 6, 2013 4:29 PM by pminich

    FM Server Adv. Server Side Scripting

    edwardlscott

      I have read all the posts I can find on this matter but other than this (http://fmforums.com/forum/topic/64713-server-side-imports-and-exports/), the available comments are too fuzzy to help much.

       

      A large, trusty script I wrote using FM Advanced 12 works well for me and relies on several table-to-table export/imports (controlled by scripted pre-Finds in the source tables). This all transpires within the same hosted file. The net result is to compile a set of records that constitute the Line Items of a Sales Order.

       

      Since it is too intensive for processing on the sales force iPads, I'm attempting to migrate it to run Server Side, but the Import commands I rely upon now generate an Error 100 (File is Missing) in the Server Log.

       

      Seeing a suggestion about a slave machine, I set up a slave FM Adv. 12 share on another machine with ONE script in it whose single script step (Perform Script) simply remotely runs my problematic server-side script (the server is set as a Remote Data Source). I reconfigured my scheduled script on the server to run a new script whose single script step (Perform Script) runs the slave machine's single script (now functioning as a call-back script). This script executes properly from a client session. To defeat me, when the server schedule executes that same script the single Perform Script step in it generates an Error 100 in the Server Log - so it doesn't execute and I'm beat.

       

      By the way, the FM Server instance is running on a Windows Server 2008 box, I have Mac and PC clients. Anyone solving this for me is eligible for a modest reward (if they aspire to more than the immense glory of addressing this issue).

       

      Regards,

      Ed

        • 1. Re: FM Server Adv. Server Side Scripting
          wimdecorte

          I reconfigured my scheduled script on the server to run a new script whose single script step (Perform Script) runs the slave machine's single script (now functioning as a call-back script).  This script executes properly from a client session. To defeat me, when the server schedule executes that same script the single Perform Script step in it generates an Error 100 in the Server Log - so it doesn't execute and I'm beat.

           

          The suggestion of using a slave (robot) machine to overcome script steps that are not supported server-side is to run EVERYTHING on the robot machine, not have the server initiate something on that robot machine.

           

          I'm not a big fan of robot machines (need to have a user logged into the OS at all times, need to baby-sit that the files are properly opened, need to monitor that the scripts execute...

           

          You can still do everything server-side but you need to do an intermediate step:  export to the FMS documents folder in csv format, import that into the other table.  FMS does not support direct FM-to-FM importing.

           

          Not sure how much data we're talking about on each execution but you could do this without the import and export by storing all the data in variables and transporting it that way between the tables.

          • 2. Re: FM Server Adv. Server Side Scripting
            pminich

            FMS will not import from within the same file. You need to export out to an

            intermediary file and pull the data back in. That might be your problem.

             

            --

            iPhone

            Pete Minich

             

             

            Direct/FaceTime/Text  - 781.223.8884

            1 of 1 people found this helpful