Run a SQL Job from JScript
SOLVED- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Run a SQL Job from JScript
I need to simply run a SQL Server Agent job. I don't need to return values; it is more of a middle man job. Could I do something like this:
var SJob;
var Sjob.ConnectionString = "all the stuff that goes in here...";
SJob.ProcedureName = "SendJobs";
SJob.ExecProc();
Or would I be going about this incorrectly?
Solved! Go to Solution.
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
What happened when you tried that?
Marsha_R
[Community Hero]
____
[Community Heroes] are not employed by SmartBear Software but
are just volunteers who have some experience with the tools by SmartBear Software
and a desire to help others. Posts made by [Community Heroes]
may differ from the official policies of SmartBear Software and should be treated
as the own private opinion of their authors and under no circumstances as an
official answer from SmartBear Software.
The [Community Hero] signature is used with permission by SmartBear Software.
https://community.smartbear.com/t5/custom/page/page-id/hall-of-fame
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Well, I haven't yet. Can't extend my trial either. Should get a license next week. It should work for an actual stored procedure, but this is for a job...
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @scmadden,
Have you managed to have this script worked?
Tanya Yatskovskaya
SmartBear Community and Education Manager
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @scmadden,
I've found the following example demonstrating how you can call an SQL stored procedure (even with parameters):
https://smartbear-cc.force.com/portal/KbArticleViewer?name=Call-an-SQL-Stored-Procedure
Tanya Yatskovskaya
SmartBear Community and Education Manager
