4 Replies Latest reply on Apr 3, 2009 10:47 AM by philmodjunk

    Capturing 'Record Modified By' info

    Sendnot

      Title

      Capturing 'Record Modified By' info

      Post

      I have an inventory system in FileMaker Pro 7, hosted by Filemaker Pro Server. Recently, we've become aware that some records have been changed and we'd like to be able to see who is making the changes. We do not use individual login names; we have, in our office, 4 people using the inventory, one of them being my boss and she wants full privileges to the database. Some of us in the office think that she might be the one screwing things up, but of course you just can't go accusing the boss, right?

       

      To add to the problem, she doesn't understand or like FileMaker Pro very much and she's not willing to learn, so she's trying to get rid of it in our organization (she has a tough job ahead of her!). I've seen her before trying to perform a simple find and I had to show her that you had to click the 'find' button on the left side of the screen to complete the query. This is why most of us think she could be the problem. I would like to be able to capture the I.P. address or the NIC info of any computer that modifies a record. I've looked at the Get(SystemIPAddress) and Get(SystemNICAddress), but how would I go about capturing that information when a record is modified? Would I have to trigger a script to copy the Get(SystemIPAddress) or Get(SystemNICAddress) into another field?

       

      I'd like for each of us who use the database to have their own logins & passwords, then it would be easy to track this, but she's incurious, incompetent and resistant to change, so I already know the answer if I suggest that to her. But if I can tag the computer that made the change, then I have some ammo to use...

       

      Thanks, TGIF!!! 

        • 1. Re: Capturing 'Record Modified By' info
          philmodjunk
            

          You've got the right idea. You can use a script trigger, If you have FMP 10, to capture and store the data. I'd simply use Get(username) instead of the more esoteric values you are capturing but the method is the same.

           

          Write a script to capture the info

           

          Set Field[Table::fieldname, "Table " & Get(currenttablename) & " modified from Layout " & Get(layoutname) & " on " & Getastext(Get(currentdate)) & " by " & Get(username)]

           

          Then on each layout, use the On Record Commit trigger to trigger this script.

           

          If you have multiple tables, create a similar script for each table if you want to log the info into field of the same table as that of the record being modified.

           

          If you want a centralized log table you'll need to add a few additional script steps so that you are appending a new log entry everytime a user triggers the script.

           

          To use the user name function instead of the other get functions, go to each computer except your bosses and give them unique user names by selecting Edit | Preferences. This won't affect passwords or accounts, but will appear in the log in dialog as the default account name. Just train your fellow workers to delete the user name from the Account field and to then manually enter the account name.

           

          Good luck with your boss. This sounds like a situation where you could win the battle by getting the smoking gun you want but lose the war because even with the evidence on your side, she's still the boss and will likely get what she wants.

           

          Computers are easy. People take a heck of a lot more work.

          • 2. Re: Capturing 'Record Modified By' info
            fitch
              

            Since he's using FM7, a script trigger would require a plugin. However, you can also implement an audit trail by using an auto-enter formula such as: Evaluate ( "GetAsText ( Get ( CurrentHostTimeStamp ) ) & \" \" & Get(SystemNICAddress)" ; Status )

             

            Which would update the tracking field when the Status field was modified.

            http://tinyurl.com/cevlwj

            • 3. Re: Capturing 'Record Modified By' info
              Sendnot
                

              "If you have FMP 10, to capture and store the data."

               

              That's part of the problem. We're stuck at FMP 7.0v3. I seriously doubt I can convince her that an upgrade is a good idea. Not that it isn't a good idea, mind you.

               

              So can this be accomplished in FMP 7? Or could I use my friend's FMP 10, make the mods and expect it will work when run in version 7?

              • 4. Re: Capturing 'Record Modified By' info
                philmodjunk
                  

                Sendnot wrote:

                "If you have FMP 10, to capture and store the data."

                 

                That's part of the problem. We're stuck at FMP 7.0v3. I seriously doubt I can convince her that an upgrade is a good idea. Not that it isn't a good idea, mind you.

                 

                So can this be accomplished in FMP 7? Or could I use my friend's FMP 10, make the mods and expect it will work when run in version 7?


                 

                I caught the reference to script trigger which is an FMP 10 only feature and missed the reference to FMP 7. Using your friend's FMP won't help as the feature won't work when you open the file in FMP 7. See a previous post in the thread for a better solution.