Re: Query permissions



Copy the sql from each query for the form and subforms and put the sql in the
corresponding form's record source property. Make sure you add the WITH
OWNERACCESS OPTION clause at the end of these queries. In the form's open
event, use the currentuser() function and see if this user is a member of
HugosGroup or the Admins groups. If they're not, use vba code to lock every
input control (so the user can't make any changes to the data) and add this
line:

Me.allowadditions = false

so they can't add any new records either. Give all groups except the Admins
group only open/run permission on the forms. The Admins group keeps
administrator permission. You can delete the original query that doesn't
have the WITH OWNERACCESS OPTION clause unless the query is used somewhere
else in the app.

Now Hugo and the Admins group can read, edit, add and delete records in the
form and subforms and the normal users can't.

Chris
Microsoft MVP


RipperT wrote:
Using Access 2002. I have 3 nested subforms that are each based on their own
query. I want all users to have read permissions to the data in these forms.
I want one user (we'll call him Hugo) to be able to read, update, modify and
delete data in these forms. I have removed all permissions on the base
tables and given Read permissions to my custom users group for each query.
I've given read, update, modify and delete permissions on each query to the
group called HugosGroup, and Hugo is the only member of that group (except
for my test user). Yet, Hugo cannot read, update, modify and delete any of
the data, he can only read it, as with the other users. I don't understand
why. If I use WITH OWNERACCESS OPTION in the queries, then everybody can
read, update, modify and delete the data. I've read the Access help file and
the SECFAQ and they seem to contradict each other. How do I allow only Hugo
to read, update, modify and delete?
Many thanks,
Ripper

--
Message posted via AccessMonster.com
http://www.accessmonster.com/Uwe/Forums.aspx/access-security/200810/1

.



Relevant Pages

  • Re: User permissions dropping out
    ... I don't see why the user needs 'modify table design' to run an update table query. ... You could achieve this by removing all permissions on the tables for the Read-only user and making the Update Query 'RWOP' (a setting in the properties of the query. ... I must set the permissions to 'modify table design' for a particular table that is updated when the db is opened, thru the 'Autoexec' macro. ...
    (microsoft.public.access.security)
  • Query permissions
    ... I want all users to have read permissions to the data in these forms. ... tables and given Read permissions to my custom users group for each query. ... I've given read, update, modify and delete permissions on each query to the ... group called HugosGroup, and Hugo is the only member of that group (except ...
    (microsoft.public.access.security)
  • Re: Changing query at runtime
    ... Thanks Joan, I already tried that, but after giving the qtemp object Read ... Design, Modify Design and even Admin permissions, I still get the "You do ... option" clause in the query. ... and give users modify permissions to the query. ...
    (microsoft.public.access.security)
  • Re: Query permissions
    ... permissions from the underlying tableand use only queries to get at the ... only to view data or to be able to modify it through your query. ... I want one user (we'll call him Hugo) to be able to read, update, modify ...
    (microsoft.public.access.security)
  • Re: need some SQL help
    ... hugo, do you know how I'd modify your query to return only a count of the ... Prev by Date: ...
    (comp.databases.theory)