Lock a specific table Access 2013

KEKeogh

Registered User.
Local time
Today, 02:53
Joined
May 4, 2011
Messages
80
My apologies if this has been asked before.

I have a table with a list of our reps for the company but for some reason over the course of working in other forms all the reps but one will delete.

Not sure what form is causing this to happen but I'm thinking if I can lock the reps table then maybe I can stop it from happening anymore.

Thanks for any help.
 
Do you want to prevent users deleting records or delete the one you can't at the moment?

End users should only interact with data using forms.
They should never have any access to tables or queries.
Forms can be locked partly or completely to prevent deletion or editing as you wish.
 
Hi. Do you have referential integrity enforced on the reps table? If you're trying to delete all reps records and one won't, maybe there is a child record associated with it, and you'll have to delete it first before you can delete the rep record. Just a thought...
 
theDBGuy has a point.

If you enforce Referential Integrity (as you should), the user will not be able to delete a rep if he has a relationship with some other table.

Not necessarily.
If RI is applied along with Cascade Delete you will be able to delete the record and the related record(s) in the child table will also be deleted. Access will warn you first of the consequences.
See Relationships and Referential Integrity
 
Hi Pat
My response was aimed at the 'general audience' for clarification rather than at yourself or the DBGuy ;)
 

Users who are viewing this thread

Back
Top Bottom