FIX: DTS "Execute SQL Task" Terminates Prematurely Without Completing All Commands in Batch

Article translations Article translations
Article ID: 238523 - View products that this article applies to.
This article was previously published under Q238523
This article has been archived. It is offered "as is" and will no longer be updated.
BUG #: 55660 (SQLBUG_70)
Expand all | Collapse all

On This Page

SYMPTOMS

The Data Transformation Services (DTS) "Execute SQL Task" terminates without completely processing all the commands in a batch. If the task calls a stored procedure that performs multiple data modification operations, the task can return prematurely after the first command, even before all the other commands are executed.

CAUSE

The task returns after the first command is completed since the "Execute SQL Task" option expects only one result set.

WORKAROUND

Instead of calling the procedure from a "Execute SQL Task", call the procedure using OSQL.exe. This call can be added to a DTS package using "Execute Process Task".

Setting the NOCOUNT option ON, inside the stored procedure, may help since the DONE_IN_PROC messages are not sent and the procedure may complete without any other messages.

STATUS

Microsoft has confirmed this to be a problem in SQL Server 7.0. This problem has been corrected in U.S. Service Pack 2 for Microsoft SQL Server 7.0. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
254561 INF: How to Obtain Service Pack 2 for Microsoft SQL Server 7.0 and Microsoft Data Engine (MSDE) 1.0
For more information, contact your primary support provider.

REFERENCES

SQL Server Books Online; topic: "SET"; search on: "NOCOUNT".

For more information on client/server TDS interaction, refer to the following article in the Microsoft Knowledge Base:
180775 INF: Client Effects on SQL Server Throughput
The concepts described in the article and related links apply to any DB-Library, ODBC or SQL OLEDB client.

Properties

Article ID: 238523 - Last Review: October 21, 2013 - Revision: 2.1
APPLIES TO
  • Microsoft SQL Server 7.0 Standard Edition
Keywords: 
kbnosurvey kbarchive kbbug kbfix KB238523

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com