7 Replies Latest reply on Jul 16, 2014 11:21 AM by disabled_JohnWolff

    Script auditing

    PeterWindle

      Hello all...

       

      any chances there are tools out there that would give me a report on how many times a script has been run, or the last date it has been run?

        • 1. Re: Script auditing
          mikebeargie

          Moving forward? yes. There are things like FMBench: http://fmbench.com/, but it's really easy to make your own context-free transaction log that drops in at the start and end of each script.

           

          As far as looking back into stuff that's already been done before you implement any solution, not sure if FMDiff accesses that kind of info, but probably Winfried would have the knowledge to say if it was even possible.

           

          This might also help you:

          http://www.modularfilemaker.org/module/transactions/

          • 2. Re: Script auditing
            taylorsharpe

            When analyzing a system, I'll put a Perform script step at the beginning of all scripts that runs a script that creates a table telling who is running a script and when so I can figure out what are the primary scripts and what is unused, etc.  You have to create a table to store the scripting info. 

            • 3. Re: Script auditing
              BruceRobertson

              You create a new TABLE at the start of every script? You create the table by script?

              • 4. Re: Script auditing
                mikebeargie

                I'm sure Taylor is just an hour behind on CST and hasn't had his coffee yet...

                • 5. Re: Script auditing
                  taylorsharpe

                  Yeah... my bad.  I meant to say that you need to create a new record in a table and I stick info in it like what script is running, who is running it, timestamp, layout where it is being run, what computer is running it, maybe any script parameters, etc. 

                   

                  But you can create a table with a script using a plugin like MMQuery or via SQL is if you have a plugin that lets you do full SQL calls.  I really like MMQuery personally and there are some times where it is nice to be able to add fields or tables to a file via a script.  But this just is not one of them and it was a slip of my tongue to say create a table. 

                  • 6. Re: Script auditing
                    monkeybreadsoftware

                    You may be able to create table in script using SQL commands and plugin help.

                    But it's certainly not recommended as there are a ton of options FileMaker has which can't be configured using SQL.

                    • 7. Re: Script auditing

                      Hi Peter,

                       

                      If you can find a copy of Ray Cologon's FMP 10 Bible, he has the script steps listed for creating a Script Log kept in an off screen window. You can put the starting steps into a separate script and call it, as Taylor does, at the start of any script you wish to monitor. The concluding steps can be in a another script called after any exit point in the monitored script.

                       

                      Ray also enabled an error logging process by capturing an error, or any other piece of necessary info, to a $result varaible which gets written to the log as part of the concluding script.

                       

                      I hope this helps,

                       

                      John