MS Access 2002 Previously updated fields revert to previous values

Database issues
Microsoft Access
Microsoft Access 2002
I have a single user application where I update a status table through VB code using DAO. This particular table has 1 record and 66 fields. As part of the processing, two of these fields are updated after which the table is closed.

Later in the processing, I update a different field again for this single record using the mechanism … DoCmd.RunSQL "UPDATE tblCurrentStatus SET Fib382IBLRCounter = 0”. The problem is that while the new data is updated, the two fields that I previously updated as described above have now returned to their previous values. It is almost as if a previous version of the record and/or table was reinstated prior to the latest update.

Any thoughts on what might be happening? Bruce

Software/Hardware used:
MS Access 2002, VB

Answer Wiki

Thanks. We'll let you know when a new response is added.

Did you use the .Update method after you edited the record? When you use .edit it just builds a copy in a buffer and does not put it into the table until you .update.

Discuss This Question: 1  Reply

There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.
  • Rbrucejones
    Yes, .update was used and I could see the new data in the table while stepping through the code in debug mode. I have just found the problem which appears to originate from some VB code changes. I went back to a working version of the system that was several days old and in the function where it appeared the problems were coming from, I copied the VB code from the new version function back into the previous functioning version and was able to replicate the problem. I manually reapplied the code changes to the previously working function in question, verified its functioning then copied this into the new version and everything works as it should. Although the code was exactly the same (used a code comparison utility) I can only surmise there was something obviously corrupted in the VB code that was causing this problem. I can only further assume that Access maintains a certain amount of data or previous versions of records/table in some sort of temporary buffer after the data is committed to the table which is why I was seeing previous data reappearing. Not sure why this would be the case but is the only plausible conclusion I have been able to see. Thanks for the help, Bruce
    60 pointsBadges:

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

Thanks! We'll email you when relevant content is added and updated.


Share this item with your network: