December 7, 2010 at 11:15 am
I have a simple little script that runs a job on a server:
SQLCMD -S MyServer -Q "USE MSDB EXEC sp_start_job @job_name = 'MyJob'"
It works fine for me, but I want a user with no other permissions to be able to use it from her desktop. What are the minimum permissions required, and where do they need to be? Assume the code the job calls is in 'MyDB'.
December 8, 2010 at 5:49 am
create a user with databaseRole :SQLAgentOperatorRole
-------Bhuvnesh----------
I work only to learn Sql Server...though my company pays me for getting their stuff done;-)
December 8, 2010 at 10:50 am
Perfect. That did the job (so to speak). If the job executes sp code that performs data operations on tables in a specific database it appears that the job's permissions handle that. Is that correct?
December 9, 2010 at 12:12 am
Richard Ray-222778 (12/8/2010)
If the job executes sp code that performs data operations on tables in a specific database it appears that the job's permissions handle that. Is that correct?
You need to map that user with Sp related database and give database role : dbowner
-------Bhuvnesh----------
I work only to learn Sql Server...though my company pays me for getting their stuff done;-)
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply