Only authorized user can run stored proc

  • I need to prevent "dbo"s from accidentally running a certain stored proc. Yet, I want a specific user to be able to execute the proc.

    Sounds simple to do but I haven't gotten it to work using permissions. Any ideas on how to do this or maybe a different approach?

    TIA,

    barkingdog

  • Another way to do this rather than using permissons would be to use

    system_user

    you could put a conditional statement at the begining of your procedure that only runs if system_user = YourUser

    if system_user = 'YourUser' begin

    it is just a suggestion i have not actualy tried this but it may give you what you need.

Viewing 2 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply