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 Mike Lewis on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Access Security locking tables

Status
Not open for further replies.

dbapps

Programmer
Oct 21, 2002
9
0
0
GB
I have a split database which I want to secure to stop users from viewing the datatables on the BE but still update/add and delete data via the FE. Using access security I can stop them viewing the tables but when the FE trys to re-attach itself It comes up with the error saying that the user does not have the necessary permissions.

Does anyone have and idea how to carry out the action but still allow reattachment.

Regards
Dave
 
You will need to pass the username/password in the Connect property of the TableDef object when you reattach the tables. The normal Connect string will have a "DATABASE=mydb.mdb;", I *think* you need to add "UID=username;PWD=password"
 
Actually, no, Norris's method is not how you want to go about it.

Get the Access Secuity FAQ, either from MS or from my website. Read it a few times (it's rather dense). That will answer all of your questions.

Basically, what you have to do is secure both the front end and the back end with the same workgroup file and give user groups (not the users themselves) the appropriate permissions.

Once you get the hang of it it's really quite simple. But it will take a while to get the hang of it.

Jeremy

==
Jeremy Wallace
AlphaBet City Dataworks
Affordable Development, Professionally Done

Please post in the appropriate forum with a descriptive subject; code and SQL, if referenced; and expected results. See thread181-473997 for more pointers.
 
Adding on to what Jeremy said:

For most purposes, a linked table object is the same as the table it's linked to, but that's not true in the security system. In it, the link object is an independent object with its own permissions. Reattaching a table modifies that link object, so the user needs Modify Design permission on the link in order to reattach. This does not transfer the same permission to the table in the back end, which has its own permissions which are separately enforced.

Since you got far enough to get this security error message, I assume you already have a good grasp of how the security system works. If you don't, though, take Jeremy's advice and study the FAQ. If nothing else, you'll benefit from the peace of mind of knowing you didn't leave a gaping hole that you're not aware of. A lot of people make that mistake.

Rick Sprague
Want the best answers? See faq181-2886
To write a program from scratch, first create the universe. - Paraphrased from Albert Einstein
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top