如何从SharePoint运行或启动Sql Server Agent作业(单击按钮时)? [英] How to Run or Start Sql Server Agent Job from SharePoint(When I Click the button)?
本文介绍了如何从SharePoint运行或启动Sql Server Agent作业(单击按钮时)?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
如何从SharePoint运行或启动Sql Server Agent作业(单击按钮时)?
解决方案
针对连接执行以下代码:
USE msdb; 转到 EXEC dbo.sp_start_job N ' 每周销售数据备份'; GO
您可以按照我的有关使用Sqlserver .Net对象开始作业的文章进行操作:
使用C#管理SQL Server代理作业 [ ^ ]
How to Run or Start Sql Server Agent Job from SharePoint(When I Click the button)??
解决方案
Execute the following code against a connection :
USE msdb ; GO EXEC dbo.sp_start_job N'Weekly Sales Data Backup' ; GO
You can follow my article on starting the job using Sqlserver .Net objects:
Manage SQL Server Agent Jobs using C#[^]
这篇关于如何从SharePoint运行或启动Sql Server Agent作业(单击按钮时)?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文