Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Database 'xxx' is read-only 2

Status
Not open for further replies.

Ezeasy

MIS
Feb 7, 2002
37
US
We have a database that is on a server with four users two users have read/write/update permission and the other two have only read permission to it. Depending who accesses the DB first all other users get the "The database 'xxx' is read-only" message. Anyone have any ideas why? Any help would be appreciated. Thanks in advance.
 
Access generates a .ldb file to manage connections. The .ldb file is created when the database is opened first. If one of the two users that have read only permission opens the database first, then the .ldb file cannot be created. If the .ldb file cannot be created, Access (Jet) cannot manage what each connection is doing, so it provides the first connection with the appropriate authorities, then everyone else is read-only.

Hope that helps.

Lee
 
Thanks Lee,
What would be the best way to avoid this and to allow different permissions?
 
All users should have read/write permissions to the directories and you should control access to data using Access's user-level security.

Ed Metcalfe.

Please do not feed the trolls.....
 
All users should have file create/delete permissions as well, otherwise the .ldb still may not be created. And I agree with Ed2020 - use Access security. If you have never used Access security, make a back up of the database(s) and work on the backups - you can lock yourself out completely. Read up on security first - hundreds of valueable articles on the net - but the main thing is to make a backup FIRST and work on the backup. That way if anything goes wrong, the production application is still working just fine :)

Lee
 
Unfortunately this means there's nothing stopping users deleting the MDB file(s) but there's not a lot you can do about that!

Ed Metcalfe.

Please do not feed the trolls.....
 
Not sure which networking platform you're using, but if you revoke permission to delete files at the folder (rather than file) level, this has two effects:

1) The master database can't be deleted but can still be written to.

2) The first user will create an LDB file, but it won't get deleted when the last user closes the system.

It doesn't matter though, because later use of the DB will re use it.

To revoke delete permission:

On Windows 2000/XP/2003:
On XP you need to turn off simple file sharing first.

Right click the folder, choose Properties. Click on the Security tab and highlight the user or group of users you want to set permissions for. Untick "Inherit from Parent the permissions" and choose Copy. This will define permissions for that folder as explicit rather than inherited. (Ensure that you give yourself or a group you are a member of full control on the folder).
Click OK.

Right click the folder again, properties. Click the security tab and highlight the user or group you want to set permissions for.
Click Advanced, highlight "Full Control" from the above folder, click Edit... then untick the Allow column against Delete Subfolders and Files.
Click OK on the Permission entry for <x> screen. Click OK on the Advanced Security Settings folder. Click OK on the folder properties screen.

If this folder is shared for network access, you can get away with change level permission on this folder (full control not required).

If you are using a Novell Netware network, things are a little different: use the inherited rights mask to remove the Erase permission from the folder.

For anyone using a different network system, sorry, not really au fait with it.

John
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top