Take the 2-minute tour ×
Database Administrators Stack Exchange is a question and answer site for database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.

I don't want a restricted database role to be able to view table and stored procedure definitions and code.

So I do

deny view definition to some_db_role

It does appear though that this is not capable of being overridden.

grant view definition on dbo.some_proc to some_db_role 

seems to have no effect.

Worse

grant view definition, references on symmetric key::some_key to some_db_role

seems to have no effect. Basically if you deny view definition at the db level then symmetric keys are unusable by that role\user.

Am I missing something? Is there any way to grant rights to objects that override the rights of the db level deny?

share|improve this question
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.