AnsweredAssumed Answered

Random Corrupted Record

Question asked by DJacoby on Oct 4, 2017
Latest reply on Nov 28, 2017 by gdurniak

I created a navigation table, the purpose of which is to take the user back to the last record viewed in each of the Contacts, Companies or Projects tables from their last FM session.  For some reason that I have not been able to pinpoint, one record in the Navigation table is periodically corrupted.  It appears to always be the first record, and happens randomly, ie the table may be ok for weeks, then all fields in the one record appear as "?".


Records are added to / updated in the Navigation table as follows:

1) if user name is not found, create a record in Navigation with the User Name as the key.  Go to the first record in each of the tables (Contacts, Companies, Projects) and save the record keys for each in the user's Navigation record.

2) if the User Name is found, go to the record in the last table layout viewed.

3) as I navigate through the different layouts, I save current record ID's and Layout Names into Global Fields, then load this data into my Navigation records on file close for use the next time.


The problem that I am having is, when a find is performed on the User Name in the corrupted record (upon file open), FM does find a record.  However, the record is blank (or actually has question marks in every field), so there are no record ID's or layout names to navigate to. 


I tried to "catch" the error by saying if the User Name is found but the length of the User Name is 0 (which it is on these corrupted records), then "reset" the record by writing the user name, record ID's and record layouts back in to the record.  This resulted in an error "[101] record is missing."  


So I both have a record and don't have a record.


Any ideas on how I may be getting a corrupted record or how I might fix this?


What I have been doing is deleting the record, then turning off the index on the name field, setting the index to create as needed.  Just deleting the record does not work -- I have to reset the index.  I need a permanent fix that does not involve me manually resetting everything.


Attached is a screen print of what I see.  Help is appreciated!!!