Re: Executing Jobs via a SQL Statement



EXEC sp_start_job '<job name>'

Note that you still need to be the owner of a job or a member of the
sysadmin server role to start jobs with sp_start_job, and that the
permissions are not transferable.

--
Jacco Schalkwijk
SQL Server MVP


"JEH" <JEH@xxxxxxxxxxxxxxxxxxxxxxxxx> wrote in message
news:660F3EA9-7D83-42B9-8AB9-73C91BE54C27@xxxxxxxxxxxxxxxx
> Does anyone know of a way to execute a job from a SQL Statement?


.



Relevant Pages

  • Re: Problems creating subscription...
    ... The distribution agent job has been implicitly created and ... 'ROUSES.COM\LarryDSI' is a member of sysadmin server role and cannot be ... granted to or revoked from the proxy. ...
    (microsoft.public.sqlserver.replication)
  • Re: how could i hide my finacial data to sa when i store them in sql server 2k?
    ... Where does the info reside? ... You can adde the user to db_denydatareader role and make sure that he/she is ... not a member of sysadmin server role. ...
    (microsoft.public.sqlserver.security)
  • Re: GK - Granting on all objects but not on JOBs ?????
    ... You have to be member of SYSADMIN server role or member of DB_OWNER role ... in MSDB database. ... procedures etc) and NOT on JOBs? ...
    (microsoft.public.sqlserver.security)
  • Problems changing dts packages.
    ... we have a user that create some dts packages. ... He is the owner of the ... Onlye members of the sysadmin server role can change the dts or the ... How can i resolve this problem without adding to the sysadmin server ...
    (microsoft.public.sqlserver.dts)
  • Re: Basic Server Roles (security) question
    ... Are you member of sysadmin server role as well? ... > I want to add a consulting firm of ours to have full access to a ... > nothing I can find talks about this kind of granularity in security. ...
    (microsoft.public.sqlserver.security)