Article ID: 249730 - View products that this article applies to.
This article was previously published under Q249730
This article has been archived. It is offered "as is" and will no longer be updated.
BUG #: 226979 (Shiloh_bugs)
BUG #: 56134 (SQLBUG_70)
A scheduled Microsoft SQL Server 7.0 Transact-SQL (T-SQL) task may run slower in SQL Server 7.0 or SQL Server 2000 than in Query Analyzer or Microsoft SQL Server 6.5.
Because the SQL Server Agent has to share server resources with the SQL Server engine, the SQL Server Agent introduces a delay when you process T-SQL task output. The purpose of the delay is to avoid consuming all available CPU resources when you run the task.
This behavior is designed to:
To resolve this problem, obtain the latest service pack for Microsoft SQL Server 7.0. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
(https://support.microsoft.com/kb/301511/EN-US/ )INF: How to Obtain the Latest SQL Server 7.0 Service Pack
To obtain maximum throughput when there is only one scheduled job, create the task as a scheduled Cmdexec task that runs the OSQL utility.
If you have procedures that return several empty result sets (informational DONE_IN_PROC messages), you can reduce the number of delays that occur when you run the task as a scheduled T-SQL task by adding a SET NOCOUNT ON statement to the beginning of the stored procedure or T-SQL batch.
Microsoft has confirmed that this is a problem in the Microsoft products that are listed at the beginning of this article.
This problem was first corrected in Microsoft SQL Server 7.0 Service Pack 4.