Solved

Error: "Another user edited this record"

Posted on 2009-05-18
1
223 Views
Last Modified: 2012-05-07
I have a linked Oracle table in Access application (via ODBC). There is a checkbox before each record, and there are a "select all" checkbox at the bottom of the page for selecting all the records.

The select checkbox is bound to "selected" field in Oracle table (0 or -1). And "select all" checkbox is bound to a query to update "status" of all records to 0 or -1. Everything seems good, except sometimes, when you check one record, and select "select all records", it will display error messages like:
1. "The data has been changed: Another user edited this record and saved the changes before you attempted to save your changes. Re-edit the record"
2. run-time error '3197' "the microsoft jet database engine stopped the process because you and another user are attempting to change the same data at the same time."

This is a serious problem, I kind of know it's beecause access will store the table in its cache, and if the selected status change, it will report "Another user edited this record". But could anyone give me detailed solution for this problem? Thanks a lot.
0
Comment
Question by:heyday2004
1 Comment
 
LVL 84

Accepted Solution

by:
Scott McDaniel (Microsoft Access MVP - EE MVE ) earned 500 total points
ID: 24421113
In Access, you should either (a) perform ALL data manipulation in your form or (b) perform ALL data manipulation through queries/code, but you should NOT combine the two. This is the cause of the error - while there may be only one user (yourself) working in the db at the same time, that user is trying to manipulate the same dataset in two different places (i.e. your form and your query), so Access considers that to be 2 users.

You can try issuing a Save before you execute your "UpdateAll" query:

Me.Dirty = False
<now run your query to update all the records>

This forces Access to save any pending changes. However, since you're working with ORacle, you may still have some issues with this depending on the refresh intervals and such. However, this typically takes care of it.
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The first two articles in this short series — Using a Criteria Form to Filter Records (http://www.experts-exchange.com/A_6069.html) and Building a Custom Filter (http://www.experts-exchange.com/A_6070.html) — discuss in some detail how a form can be…
As tax season makes its return, so does the increase in cyber crime and tax refund phishing that comes with it
Polish reports in Access so they look terrific. Take yourself to another level. Equations, Back Color, Alternate Back Color. Write easy VBA Code. Tighten space to use less pages. Launch report from a menu, considering criteria only when it is filled…
With Secure Portal Encryption, the recipient is sent a link to their email address directing them to the email laundry delivery page. From there, the recipient will be required to enter a user name and password to enter the page. Once the recipient …

829 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question