当前位置:Gxlcms > mysql > HowtostartaDBjobbybatchfile

HowtostartaDBjobbybatchfile

时间:2021-07-01 10:21:17 帮助过:44人阅读

Copy below code into atext file, and modify the extension name from txt to bat. ECHO Executing job ECHO. pause osql -U User_ID -P Password -S Server_IP -Q EXEC msdb.dbo.sp_start_job 'DB_Job_Name' ECHO job execution completed pause CLS EXIT

Copy below code into a text file, and modify the extension name from txt to bat.

ECHO Executing job
ECHO.
pause
osql -U "User_ID" -P "Password" -S "Server_IP" -Q "EXEC msdb.dbo.sp_start_job 'DB_Job_Name' "

ECHO job execution completed
pause
CLS
EXIT

人气教程排行