April 16, 2012 at 9:30 am
I have to grant execute permissions to all sql logins on a particular store proc.
Can someone help me with a query to do so.
I am confused about how to grant to all users is there a group or something which defines all users?
Thanks,
April 16, 2012 at 9:47 am
The easiest way would be to grant execute to public for this procedure. Otherwise you'll have to list every group or login in the grant statement.
April 16, 2012 at 9:49 am
Pink123 (4/16/2012)
I have to grant execute permissions to all sql logins on a particular store proc.Can someone help me with a query to do so.
I am confused about how to grant to all users is there a group or something which defines all users?
Thanks,
Unless you are going to makeq every sql login a sysadmin then you have to grant execute to the databases users. Typically what you do is create a role and do grant execute on myproc to myrole
After you are finished adding allcthe other permssions the role needs you add allcthe database users that need the permission to be members of that rolall object permissions are assist gned to a user or role but anlot of people say login when they really meant user
Lowell
April 16, 2012 at 10:55 am
Thanks for the reply.What does public implies here and how do I do it in a query.
Thanks,
April 16, 2012 at 2:51 pm
Public is default database role that all users are a member of. GRANT EXECUTE on [PROC_NAME] to PUBLIC. The result is that every user of the database and any new user(s) that are added will automatically be given permissions to execute this procedure. If this procedure is sensitive in nature, then it should only be granted to specific groups or users.
April 17, 2012 at 7:45 am
Thanks so much.This is what I was looking for.
Thanks,
Viewing 6 posts - 1 through 5 (of 5 total)
You must be logged in to reply to this topic. Login to reply