Jan 3 2012, 04:15 PM
've got a C# application thats connecting to a 2002 access DB. When a user opens some information the DB locks and no other users can get in. Is there a way to allow for user concurrency in the DB?
Jan 3 2012, 04:30 PM
Is it on a server/LAN drive? Look for read/write rights to the FOLDER where the db is.
Jan 3 2012, 04:48 PM
users are able to connect and edit information in the database, only not concurrently.
If we're not using the access front end is it still necessary to split the database?
Jan 3 2012, 04:48 PM
and yes its on a server
Jan 3 2012, 05:05 PM
You have nothing to split; it already is split because you have no Access front end. But any user with access to the data must also create, write to and delete the .ldb file located in the folder where the Access database is. If the users do not have read/write rights to that folder, the lock file (.ldb) cannot be created, and only one user will have exclusive access to the data. So - I'm guessing here - all users have read/write to the .mdb file, but do not have read/write/create/delete rights to the folder (and all files contained in that folder).
It will work fine - you should have no problems, but this is the first thing to check.
Jan 3 2012, 05:29 PM
Doesnt look like thats the case.
Any other ideas as to what I could check?
Jan 3 2012, 06:25 PM
Yes, I would check to see that the lock file .ldb is there when it's open from your app, and disappears - erased when no one should have it. If it's still there when it shouldn't be then check on the modified date (just for interest) and then delete it while in a users account. It should delete easily. Then when it's deleted, start over. There is a utility that will identify all users that have the lock file, but do the preceding first.
You also want to make sure some third party - yourself perhaps - doesn't have exclusive rights to either file. This means that everyone who has any rights at all must have full rights to the directory. That's the most misunderstood part of all this. If anyone has any rights to the directory, it must be full rights: Create, modify and delete.
Then I'd open it directly using any Access from a user account - don't use the app for now, and from a second account also simultaneously - all to separate the possible app problems from possible Access problems. That should tell you if the app is perhaps not opening it for multi-use, which is the next thing I'd check if all this doesn't pan out.
Jan 4 2012, 06:40 AM
> I've got a C# application thats connecting to a 2002 access DB
But how? Can you provide the connections string, please?
Jan 4 2012, 12:20 PM
Connection string is an oledb datasource: <add key="DBConnStr" value="Provider=Microsoft.Jet.OLEDB.4.0;Data Source=C:\~\proj.mdb"/>
The LDB is disappearing correctly and exclusive rights doesn't seem to be the problem either.
I'm now in the process of the multi user login test.
Any other ideas in the meantime?
Jan 4 2012, 03:10 PM
No more new ideas right now, but The Access multi-user test is crucial as is the connection string, if it turns out it's the app. I'd guess you know that the odbc connection string just modifies a number of parameters in the actual internal connection string, so a trace or stop set to examine the full extent of the connection will be necessary.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here