sql-job

How do I make a sql job step quit reporting failure

Hi I have a sql job step like this Declare @Result varchar(255) exec myprocedure @Result = @Result output What I want to do: if @Result = 'Error' then mark the job as failed, how can I achieve that? ...

What happens to a SQL job if it doesn't finish?

Let's say there's a SQL job that runs a stored procedure every one minute. What happens, if it takes more than a minute? Does it start the procedure again (having 2 of them running in the same time) or it waits for the previous to finish? ...

SQL Stored Procedure fails to update data while the script in it works manually

I have a SQL Script that I execute in a job to transform tables periodically. To speed it up I put that script in a stored procedure and executed it with a job. It worked faster. The problem occurs at times when the stored procedure even though it executes it doesn't work. I use the script manually and run it and everything works fine....

Select Statements in Jobs

I have inherited a few jobs and I am trying to understand why select statements would be in their steps. I would think that select statements would be pointless in an automated job that displays nothing for an end user. ...

Calling web service from SQL Agent Job not working

I have a a SQL 2000 DTS package that is scheduled to run from a SQL 2005 SQL Agent job. In this DTS there is a ActiveX step that has the following VBScript to call a webservice. Dim http: set http = CreateObject("MSXML2.ServerXMLHTTP.6.0") http.setProxy 2, "http://123.45.67.89:8080" http.open "GET", "http://mywebservices.com/MyWebMet...

Reading the contents of a SQL Server job in VB.NET

I am writing an application that will call a SQL Server job on all our client's systems. I'm able to execute it, and wait until it's finished. It has an output file that's save location is hard coded into the job however, and this is not the same location on all client's. Since the job is identical on systems minus this one value, I wa...