SQL 如何每天自动运行存储过程
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/7997328/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
How to run a stored procedure automatically every day
提问by Joshua
How do I set up to run a stored procedure automatically every day in SQL Server 2008 R2?
如何在 SQL Server 2008 R2 中设置每天自动运行存储过程?
回答by Carth
回答by James Becwar
You need to use the Job scheduler in the sql agent. Sql express doesn't include it so I just have a batch file run as a scheduled task to run it. -James
您需要在 sql 代理中使用作业调度程序。Sql express 不包含它,所以我只有一个批处理文件作为计划任务运行来运行它。-詹姆士
回答by Andrey Marchuk
Was discussed here: Scheduled run of stored procedure on SQL server
在这里讨论过: SQL server 上存储过程的预定运行
回答by Maess
Under SQL agent you need to go to the job scheduler and create a job that runs the stored proc. Once you have created the job you can create one or more schedules for the job. http://msdn.microsoft.com/en-us/library/ms135739.aspx
在 SQL 代理下,您需要转到作业调度程序并创建一个运行存储过程的作业。创建作业后,您可以为该作业创建一个或多个计划。http://msdn.microsoft.com/en-us/library/ms135739.aspx