Microsoft KB Archive/197563

= FIX: Error Message Should Be Clearer When There Are Multiple SELECTs in a Stored Procedure =

Article ID: 197563

Article Last Modified on 3/14/2006

-

APPLIES TO


 * Microsoft SQL Server 6.5 Standard Edition

-



This article was previously published under Q197563



BUG #: 17913 (SQLBUG_65)



SYMPTOMS
In versions of SQL Server earlier than SQL Server 6.5 Service Pack 5, if you erroneously attempt to open a server cursor on a stored procedure that contains more statements than a single SELECT statement, you will receive the following somewhat incomplete error message:

Cannot open a cursor on a stored procedure that has anything other than a single select statement in it.



STATUS
Microsoft has confirmed this to be a problem in SQL Server 6.5. This problem has been corrected in Service Pack 5a for Microsoft SQL Server 6.5.For more information, click the following article number to view the article in the Microsoft Knowledge Base:

197177 INF: How to Obtain SQL Server 6.5 Service Pack 5a

For more information, contact your primary support provider.



MORE INFORMATION
The error message is accurate, but it does not provide complete information to allow the developer to address the error.

Based on customer feedback, this error message has been changed to be clearer. With SQL Server 6.5 Service Pack 5, the error message now reads:

A server cursor is not allowed on a stored procedure with more than one SELECT statement. Use a default result set or client cursor.

Additional query words: prodsql st sproc

Keywords: kbbug kbfix KB197563

-

[mailto:TECHNET@MICROSOFT.COM Send feedback to Microsoft]

© Microsoft Corporation. All rights reserved.