Article ID: 318171 - Last Review: April 25, 2002 - Revision: 1.0 FIX: Binding a Variable to More Than One Output Parameter May Cause an Access ViolationThis article was previously published under Q318171
BUG #: 100768 (SQLBUG_70)
SYMPTOMS
If you bind a Transact-SQL local variable to more than one OUTPUT parameter for a stored procedure, the execution of the batch that includes the variable and stored procedure may fail with an access violation or may lead to an access violation for other SQL Server threads.
RESOLUTIONTo 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:
301511
(http://support.microsoft.com/kb/301511/EN-US/
)
INF: How to Obtain the Latest SQL Server 7.0 Service Pack
WORKAROUND
To work around this behavior, bind a local variable to only one unique OUTPUT parameter for a stored procedure execution.
STATUSMicrosoft 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. MORE INFORMATION
The following Transact-SQL batch demonstrates an example of this problem:
There is no unique stack dump signature that you will see if an access violation occurs because of this problem. However, for reference, the following stack dump is an example of one you may see: 0x00426f59 Module(sqlservr+26f59) (CSsStr::LConvertToStr+4c) 0x00427278 Module(sqlservr+27278) (CXVariant::ConvertToStr+429) 0x0041b589 Module(sqlservr+1b589) (CXVariant::ConvertToTi+2a2) 0x005327e6 Module(sqlservr+1327e6) (CParamExchange::ExtractOutParams+d4 0x00518c8c Module(sqlservr+118c8c) (CStmtExec::XretLocalExec+177) 0x00518afa Module(sqlservr+118afa) (CStmtExec::XretExecute+253) 0x004145f1 Module(sqlservr+145f1) (CMsqlExecContext::ExecuteStmts+11a) 0x0041409f Module(sqlservr+1409f) (CMsqlExecContext::Execute+16a)
| Article Translations
|
Back to the top
