File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes MS Acces Error Could not update; currently locked by user Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "MS Acces Error Could not update; currently locked by user " Watch "MS Acces Error Could not update; currently locked by user " New topic
Author

MS Acces Error Could not update; currently locked by user

Shankar Shanmugam
Greenhorn

Joined: Sep 12, 2001
Posts: 23
Hi All,

I am getting the below exception, when I try to update a record in MS-Access database. Its a desktop application that does the update in MS-Access.

java.sql.SQLException: [Microsoft][ODBC Microsoft Access Driver] Could not update; currently locked by user 'admin' on machine 'ZCHQ_B2B'.
at sun.jdbc.odbc.JdbcOdbc.createSQLException(Unknown Source)
at sun.jdbc.odbc.JdbcOdbc.standardError(Unknown Source)
at sun.jdbc.odbc.JdbcOdbc.SQLExecDirect(Unknown Source)
at sun.jdbc.odbc.JdbcOdbcStatement.execute(Unknown Source)
at sun.jdbc.odbc.JdbcOdbcStatement.executeUpdate(Unknown Source)

This error does not occur in all systems, it has happened in just one system and I am not able to re-create this error in my system.
Both the systems are Windows 2K with service pack 4.

I suspect either the driver or could be because that we use two different DBConnection and Process to update the same record.

Please reply if you guys have any suggestions.
Or, forward the same to your friends.

Thanks in Advance.


Shankar Shanmugam<br />Sun Certified Programmer for Java 2 Platform<br />Sun Certified Developer for Java 2 Platform<br />Email: shankar.s@vsnl.net<br /> "Walking on water and building IT Architecture from <br /> specification are easy if and only if both are frozen"<br />-----------------------------------------------
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

Unfortunately your problem is MS Access. It is notoriously bad at handling concurrent access. Its not really an RDBMS, rather a single user data repository.


JavaRanch FAQ HowToAskQuestionsOnJavaRanch
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: MS Acces Error Could not update; currently locked by user
 
Similar Threads
lock on MS Access 2000
code working in Appletviewer but not browser
DATABASE LOCKED????
Getting Exception as Could not find stored procedure 'sp_getNextMainGroup'
[Microsoft][ODBC Driver Manager] Invalid string or buffer length exception for 64 bit SQL Server