Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
DB Engine
SQL ServerMSDESQL Server CE
Services
Analysis (Data Mining)Analysis (OLAP)DTSIntegration ServicesNotification ServicesReporting Services
Programming
CLRConnectivitySQLXML
Other Technologies
ClusteringEnglish QueryFull-Text SearchReplicationService Broker
General
Data WarehousingPerformanceSecuritySetupSQL Server ToolsOther SQL Server Topics
DirectoryUser Groups
Related Topics
MS AccessOther DB ProductsMS Server Products.NET DevelopmentVB DevelopmentJava DevelopmentMore Topics ...

SQL Server Forum / General / Security / March 2008

Tip: Looking for answers? Try searching our database.

doing select without grant

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
Roy Goldhammer - 20 Mar 2008 12:07 GMT
Hello there

I have store procedure with dinamic sql which run select from 2 tables.

I want my users to run my store procedure without granting the select on
them.

How can i do it?
Uri Dimant - 20 Mar 2008 12:49 GMT
Roy
Grant EXECUTE permission on stored procedure

> Hello there
>
[quoted text clipped - 4 lines]
>
> How can i do it?
Roy Goldhammer - 20 Mar 2008 13:45 GMT
Sorry uri.

But if there is dinamic sql inside the query I need Grant permission of what
happen in the tables

> Roy
> Grant EXECUTE permission on stored procedure
[quoted text clipped - 7 lines]
>>
>> How can i do it?
Uri Dimant - 20 Mar 2008 14:01 GMT
Roy, sorry , I need to go home, a lot of work :-)))
Please read Erland's article about the subject
http://www.sommarskog.se/grantperm.html#Certificates

> Sorry uri.
>
[quoted text clipped - 12 lines]
>>>
>>> How can i do it?
Erland Sommarskog - 20 Mar 2008 15:56 GMT
> I have store procedure with dinamic sql which run select from 2 tables.
>
> I want my users to run my store procedure without granting the select on
> them.
>
> How can i do it?

If you are on SQL 2000, forget about it.

If you are on SQL 2005, sign the procedure with a certificate and
grant permission to a created from the certificate. Details here:
http://www.sommarskog.se/grantperm.html

Signature

Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se

Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.