7 Replies Latest reply on Apr 4, 2012 6:36 AM by TSGal

    Phantom Record Deletion

    TylerNelson

      Summary

      Phantom Record Deletion

      Product

      FileMaker Pro

      Version

      11

      Operating system version

      Windows

      Description of the issue

      Records are being deleted from database, seemingly at random and not by users. This has happened 3 times (that I've noticed) over the few weeks. At first it happened twice to the same Product record, while I was working actively on development (but not deleting records). The most recent incident happened while I was away for several days and not accessing the database at all. FM Server logged usual user activity, but none of these users have record deletion privileges. The first time, it deleted the very first record in my Products table (with the lowest record ID). I reverted to a backup from the previous day that had this record. Then the following week it disappeared again! Only the second time the related Vendor record also disappeared. Instead of reverting to a backup the second time, I simply recreated those records with the same ID. Then today I noticed 2 other products missing! The Product that was deleted before is still there. All Vendor records are in tact. The Product IDs for the records that were recently deleted are the next two in succession after the one that was deleted before.

      Steps to reproduce the problem

      Haven't been able to reproduce the problem.

      Expected result

      Only 1 user "developer" privilege set has record deletion privileges. I am the developer and I know that I am not deleting these records. This must be caused by some process and not by a user.

      Actual result

      Records are being deleted, seemingly on their own.

      Exact text of any error message(s) that appear

      None

      Configuration information

      Hosted on FM Server 11 with bulk client licenses.

      Workaround

      None

        • 1. Re: Phantom Record Deletion
          philmodjunk

          Any chance that the record might get overwritten by other data instead of deleted?

          • 2. Re: Phantom Record Deletion
            TylerNelson

            Pretty sure the records are being deleted. I have an Inventory table with orphan records that list Product IDs, which no longer exist in the Products table. When the Inventory record got deleted the same thing happened. When it first happened I was actively working on the database, working a lot with Product records (updating records with an iPad via Wifi, etc). I assumed that it was caused by some script reaching through some relationship that accidentally deleted something... But this last incident happened when the database was barely being used by a few users who didn't do much at all!

            • 3. Re: Phantom Record Deletion
              TSGal

              Tyler Nelson:

              Thank you for your posts.

              Is it possible users have full access privileges when running scripts?  Also, in the relationship, do you have the option checked to "Delete related records in this table when a record is delete in the other table"?  That is, if you delete a record, it would delete the related records, too.

              TSGal
              FileMaker, Inc.

              • 4. Re: Phantom Record Deletion
                TylerNelson

                I ran a Database Design Report and scanned all of my 266 relationships from top to bottom looking for a "Delete Related Records..." that was turned On. I actually did find one, but it was a relationship between two tables that are not in question. I unchecked it just in case. I used to have a button on the Products layout and the Vendors layout called "Delete" that simply showed a custom dialogue saying, "Do you really want to delete this Product/Vendor?". If the user clicked Yes it would delete the record (with full access privileges) after the native Filemaker prompt to confirm record deletion. That way a user would have to go through 2 prompts in order to delete something. However, a few months ago I noticed that a few important product/vendor records had been deleted... Assuming that this was a result of my silly users misusing the button I had given them, I simply removed the button, but didn't delete the script. Now that I think about it, this problem may have been present for more than a few weeks! In the DB Design Report it says that "deletion" script is not used on any layouts. I could delete it just in case, but that doesn't really make me feel very safe. 

                This doesn't seem to be a common issue that ANY developers I has spoken to are familiar with... Are there steps I can take to perhaps weed out some kind of corruption in the file? 

                • 5. Re: Phantom Record Deletion
                  TSGal

                  Tyler Nelson:

                  Thanks for the detailed information.  It definitely doesn't look like the delete related records was being used.

                  It is definitely possible the database file is damaged/corrupt.  Close the file, pull down the File menu and select "Recover".  Select the file, and let it create a Recovered file.  The Recover process will read the information from your original file and create a new Recovered file.  At the end of the recover, a summary will appear letting you know if any damage is found.

                  Recover will do its best to fix any problems in the file.  99% of the time, the recovered file is fine, but to be safe, you may want to revert to a backup file prior to when these deletions started occurring.

                  Continue to keep me updated with any changes.

                  TSGal
                  FileMaker, Inc.

                  • 6. Re: Phantom Record Deletion
                    TylerNelson

                    Hi. So I'm now hosting the recovered version of the database. Reverting to a previous version isn't practical because the database is still in a state of constant development and I'm not sure when exactly the problem started. I was prompted in the recovery process to carefully monitor the performance of my recovered database, and you mentioned that there's a 1% chance that the recovered file will not be "fine"... Just out of curiosity... What inconsistencies should I keep my eye out now that I'm using the recovered file? It didn't find any errors when it was done. I'm optimistically hoping that none of my records will delete themselves ever again... Are there specific issues that arise when using a recovered database??? Thanks.

                    Tyler

                    • 7. Re: Phantom Record Deletion
                      TSGal

                      Tyler Nelson:

                      The Recover option in FileMaker Pro will go through a file making sure it can read everything as intended.  If a problem is found, then FileMaker Pro will try to fix it, and if it cannot be fixed, the object/script/field/etc. will be removed before proceeding onwards.  If FileMaker found no errors during the recovery, then the problem may still exist, even with the new file.  Continue to monitor the problem, and when you notice disappearing records, try to recall what steps you had taken prior to that and write them down.  The first instance may not be helpful, but subsequent occurrences (hopefully not) may help narrow the focus and track down the issue.

                      TSGal
                      FileMaker, Inc.