otis-224947
Valued Member
Points: 61
More actions
April 13, 2005 at 7:38 pm
#113645
Guys,
Is there a way to start or stop the Agent using t-sql?
wz700
SSCertifiable
Points: 7133
April 13, 2005 at 8:31 pm
#552576
xp_cmdshell 'net stop sqlserveragent'
April 13, 2005 at 8:39 pm
#552577
It's that simple?
Thanks @wz700
andyobl
Right there with Babe
Points: 767
April 14, 2005 at 4:11 am
#552645
OR
EXEC sp_configure 'scan for startup procs', '1'
go
xp_servicecontrol 'stop', 'sqlserveragent'
xp_servicecontrol 'start', 'sqlserveragent'
EXEC sp_configure 'scan for startup procs', '0'
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply