SQL Server Q&A

As a software engineer, I focus on .NET, especially asp.net, C#, WCF and so on, and I am also very interested in Search Engine Optimization.

Entries Tagged ‘sql server error’

FIX: SELECT from Computed Column That References UDF Causes SQL Server to Terminate

Symptoms
A SELECT statement may generate an exception that causes the SQL Server instance to terminate unexpectedly if all of the following conditions are true: The SELECT statement retrieves a computed column.The computed column references a user defined function (UDF).The UDF accesses table data.An implicit data type conversion is necessary for one of the UDF parameters. No stack dump or other message related to the exception is written to the SQL Server error log.
Resolution
To resolve this problem, obtain the latest service pack for Microsoft SQL Server 2000. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
290211?(http://support.microsoft.com/kb/290211/EN-US/) INF: How To Obtain the Latest SQL Server 2000 Service PackNOTE: The following hotfix was created before the release of Microsoft SQL Server 2000 Service Pack 3.
The English version of this fix should have the following file attributes or later:
SQL Server 2000 Service Pack 1
This hotfix build is designed to be applied on a server that is running SQL Server 2000 Service Pack 1:

VersionFile nameDescription————————————————8.00.0469Sqlservr.exeSP1-based hotfix SQL Server 2000 Service Pack 2
This hotfix build is designed to be applied on a server running SQL Server 2000 Service Pack 2:

VersionFile nameDescription————————————————8.00.0552Sqlservr.exeSP2-based hotfix NOTE: Because of file dependencies, the most recent hotfix or feature that contains the files may also contain additional files.

FIX: Restoring a SQL Server 7.0 database backup in SQL Server 2000 Service Pack 3 (SP3) may cause an assertion error in the Xdes.cpp file

Symptoms
In Microsoft SQL Server 2000 Service Pack 3 (SP3), when you try to restore a database backup, the restoration may fail, and a retail assertion with error 3624 may occur. You may see an error message that is similar to the following in the SQL Server error log files as a result of the assertion error:

SQL Server Assertion: File: <xdes.cpp>, line=9860
Failed Assertion = ‘IS_OFF_SAFE (XDES_OUTCOME_ONLY, m_status)’
This problem occurs when all the following conditions are true: You take the database backup from a Microsoft SQL Server 7.0 database.While you take the database backup, transactions that involve multiple databases are logged in the transaction logs.You restore the database backup in Microsoft SQL Server 2000.
Resolution
Service pack informationTo resolve this problem, obtain the latest service pack for Microsoft SQL Server 2000. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
290211?(http://support.microsoft.com/kb/290211/) How to obtain the latest SQL Server 2000 service pack
Hotfix informationThe English version of this fix has the file attributes (or later) that are listed in the following table. The dates and times for these files are listed in coordinated universal time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.

DateTimeVersionSizeFile name————————————————————————–07-Feb-200316:14786,432 bytesDistmdl.ldf07-Feb-200316:142,359,296 bytesDistmdl.mdf29-Jan-200312:25180 bytesDrop_repl_hotfix.sql31-Jan-200311:022000.80.763.01,557,052 bytesDtsui.dll29-Jan-200312:251,402 bytesInst_repl_hotfix.sql07-Feb-200317:102000.80.765.090,692 bytesMsgprox.dll29-Jan-200311:487.0.9466.0344,064 bytesMsvcr70.dll29-Jan-200311:482000.80.722.057,904 bytesOsql.exe29-Jan-200315:48746,470 bytesInstdist.sql07-Feb-200314:231,065,895 bytesReplmerg.sql07-Feb-200317:102000.80.765.0221,768 bytesReplprov.dll07-Feb-200317:102000.80.765.0307,784 bytesReplrec.dll29-Jan-200315:481,084,318 bytesReplsys.sql29-Jan-200311:482000.80.534.0127,548 bytesSqdedev.dll29-Jan-200311:482000.80.194.0180,290 bytesSqlunirl.dll07-Feb-200317:102000.80.765.0176,696 bytesSqlmap70.dll07-Feb-200317:102000.80.765.057,920 bytesSqlrepss.dll07-Feb-200317:112000.80.765.07,528,529 bytesSqlservr.exe07-Feb-200317:102000.80.765.045,644 bytesSqlvdi.dll07-Feb-200317:102000.80.765.082,492 bytesSsnetlib.dllNote Because of file dependencies, the most recent hotfix or feature that contains these files may also contain additional files.
Important This hotfix build is designed for a server that is running Microsoft SQL Server 2000 Service Pack 3.

FIX: Restoring a SQL Server 7.0 database backup in SQL Server 2000 Service Pack 2 (SP2) may cause an assertion error in the Xdes.cpp file

Symptoms
When you try to restore a database backup, the restoration may fail, and a retail assertion with error 3624 may occur. You may see the following error message in the SQL Server error log files as a result of the assertion error:

SQL Server Assertion: File: <xdes.cpp>, line=9860
Failed Assertion = ‘IS_OFF_SAFE (XDES_OUTCOME_ONLY, m_status)’
This problem occurs when all the following conditions are true: You take the database backup from a Microsoft SQL Server 7.0 database.Whileyou take the database backup, transactions that involve multiple databases are logged in the transaction logs.You restore the database backup in SQL Server 2000 Service Pack 2 (SP2).
Resolution
A supported hotfix is available from Microsoft. However, this hotfix is intended to correct only the problem that is described in this article. Apply this hotfix only to systems that are experiencing this specific problem.
If the hotfix is available for download, there is a “Hotfix download available” section at the top of this Knowledge Base article. If this section does not appear, submit a request to Microsoft Customer Service and Support to obtain the hotfix.
Note If additional issues occur or if any troubleshooting is required, you might have to create a separate service request. The usual support costs will apply to additional support questions and issues that do not qualify for this specific hotfix. For a complete list of Microsoft Customer Service and Support telephone numbers or tocreate a separate service request, visit the following Microsoft Web site:
http://support.microsoft.com/contactus/?ws=support(http://support.microsoft.com/contactus/?ws=support)Note The “Hotfix download available” form displays the languages for which the hotfix is available. If you do not see your language, it is because a hotfix is not available for that language.
The English version of this fix has the file attributes (or later) that are listed in the following table. The dates and times for these files are listed in coordinated universal time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.

DateTimeVersionSizeFile namePlatform————————————————————————-09-Dec-200221:392000.80.714.07,471,185Sqlservr.exeX86 Note Because of file dependencies, the most recent hotfix or feature that contains these files may also contain additional files.
Important This hotfix build is designed for a server that is running Microsoft SQL Server 2000 Service Pack 2:

FIX: Parallel Hash Join with Empty Result Set Incorrectly Flows Error Back on Client Connection

Symptoms
If you run a SQL Server Data Manipulation Language (DML) statement from a DB-Library based application against a Microsoft SQL Server 7.0 server, the error handler for the application may incorrectly fire and only report the following error message:

DB-LIBRARY Error 10007, Severity 5:
General SQL Server error: Check messages from the SQL Server.Note that this error message accompanies a wide range of SQL Server errors that are reported back to the client from the server. However, in this scenario the preceding error message is the only error reported and it is not accompanied by any other specific error messages.
Resolution
If a parallel hash join produces an empty result set, internal exception 3602 is used to coordinate the shutdown of worker threads that were created to process the parallel hash plan. The internal 3602 exception is an internal control exception that is used to direct processing flow inside SQL Server and is expected behavior in this case.
However, the fact that it is causing an error to be sent back on the client connection, which in turn causes the DB-Library error handler to fire is not expected behavior.

FIX: Invalid Use of the Getdate Function May Cause Access Violation

Symptoms
An invalid use of the Getdate function within a function may cause an access violation and the following error message appears in Query Analyzer:

Server: Msg 443, Level 16, State 1, Procedure fnTestDate, Line 4
Invalid use of ‘getdate’ within a function.
ODBC: Msg 0, Level 19, State 1
SqlDumpExceptionHandler: Process 51 generated fatal exception c0000005
EXCEPTION_ACCESS_VIOLATION. SQL Server is terminating this process.
Connection BrokenYou may find the following error messages in the SQL Server error log when the access violation occurs:

00603513 Module(sqlservr+00203513) (walk_exp_tree+00000016)006034BD Module(sqlservr+002034BD) (get_expression_str+00000038)005C679A Module(sqlservr+001C679A) (yyparse+0000145C)00444BEC Module(sqlservr+00044BEC) (sqlpars+0000003C)00411685 Module(sqlservr+00011685) (CSQLSource::FTransform+0000013C)00449527 Module(sqlservr+00049527) (CSQLStrings::FTransform+000001A1)00413632 Module(sqlservr+00013632) (CSQLSource::Execute+0000015B)0044912C Module(sqlservr+0004912C) (language_exec+000003E1)00412B1F Module(sqlservr+00012B1F) (process_commands+000000E0)41073537 Module(UMS+00003537) (ProcessWorkRequests+0000024A)41073355 Module(UMS+00003355) (ThreadStartRoutine+000000BC)7800A27B Module(MSVCRT+0000A27B) (beginthread+000000CE)77DB2C18 Module(KERNEL32+00002C18) (GetModuleHandleA+0000007A)
Resolution
To resolve this problem, obtain the latest service pack for Microsoft SQL Server 2000. For additional information, click the following article number to view the article in theMicrosoft Knowledge Base:
290211?(http://support.microsoft.com/kb/290211/EN-US/) INF: How to Obtain the Latest SQL Server 2000 Service Pack

FIX: Indexed View May Cause a Handled Access Violation in CIndex::SetLevel1Names

Symptoms
A query based on an indexed view may cause a handled access violation exception in the CIndex::SetLevel1Names function and end the connection of the client
that submitted the query. Additionally, messages similar to the following are written
to the SQL Server error log:

2002-12-30 13:17:01.99 spid51 Using ‘dbghelp.dll’ version ‘4.0.5′
*Stack Dump being sent to C:\Program Files\Microsoft SQL Server\MSSQL\log\SQL00001.dmp
2002-12-30 13:17:01.99 spid51 Error: 0, Severity: 19, State: 0
2002-12-30 13:17:01.99 spid51 SqlDumpExceptionHandler: Process 51 generated fatal exception c0000005 EXCEPTION_ACCESS_VIOLATION. SQL Server is terminating this process..
Resolution
Service pack informationTo resolve this problem, obtain the latest service pack for Microsoft SQL Server 2000. For additional information, click the following article number to view the article in the Microsoft Knowledge Base:
290211?(http://support.microsoft.com/kb/290211/) How to obtain the latest SQL Server 2000 service pack
Hotfix information The English version of this fix has the file attributes (or later) that are listed in the following table. The dates and times for these files are listed in coordinated universal time (UTC). When you view the file information, it is converted to local time. To find the difference between UTC and local time, use the Time Zone tab in the Date and Time tool in Control Panel.

DateTimeVersionSizeFile name————————————————————————-17-Jan-200220:452000.80.568.029,244 bytesDbmslpcn.dll30-Aug-200213:08786,432 bytesDistmdl.ldf30-Aug-200213:082,359,296 bytesDistmdl.mdf11-Dec-200209:50180 bytesDrop_repl_hotfix.sql02-Jul-200207:352000.80.650.0107,088 bytesImpprov.dll11-Dec-200209:501,402 bytesInst_repl_hotfix.sql19-Jul-200208:56774,516 bytesInstdist.sql20-Aug-200208:242000.80.679.0111,172 bytesLogread.exe15-Dec-200215:212000.80.717.090,692 bytesMsgprox.dll06-Apr-200218:082000.80.606.062,024 bytesOdsole70.dll02-Jan-200217:5918,185 bytesQfe356326.sql20-Aug-200208:472000.80.679.0135,748 bytesQrdrsvc.exe26-Aug-200214:492000.80.679.0406,088 bytesRdistcom.dll03-Oct-200117:36437,302 bytesReplcom.sql20-Aug-200208:332000.80.679.0152,136 bytesReplmerg.exe25-Nov-200213:431,004,990 bytesReplmerg.sql15-Dec-200215:212000.80.717.0221,768 bytesReplprov.dll15-Dec-200215:212000.80.717.0303,688 bytesReplrec.dll03-Oct-200117:36986,906 bytesReplsys.sql03-Oct-200117:36881,228 bytesRepltran.sql26-Aug-200214:492000.80.679.0283,208 bytesRinitcom.dll16-Sep-200214:31390,045 bytesSecurityhotfix.sql26-Aug-200214:492000.80.679.028,672 bytesSqlagent.dll26-Aug-200210:392000.80.679.0311,872 bytesSqlagent.exe28-Aug-200208:322000.80.679.049,152 bytesSqlagent.rll26-Aug-200214:492000.80.679.053,824 bytesSqlcmdss.dll28-Aug-200208:402000.80.679.012,288 bytesSqlcmdss.rll24-Oct-200209:372000.80.695.0176,696 bytesSqlmap70.dll27-Dec-200221:392000.80.721.07,471,185 bytesSqlservr.exe01-Nov-200210:562000.80.698.045,644 bytesSqlvdi.dll17-Jan-200220:452000.80.568.029,244 bytesSsmslpcn.dll19-Dec-200216:552000.80.719.082,492 bytesSsnetlib.dll19-Dec-200218:092000.80.720.025,148 bytesSsnmpn70.dll06-Apr-200218:082000.80.606.070,208 bytesXplog70.dll06-Apr-200218:082000.80.606.053,828 bytesXpqueue.dll06-Apr-200218:082000.80.606.0156,228 bytesXprepl.dll11-Jul-200217:002000.80.658.0279,104 bytesXpstar.dll16-Sep-200215:122000.80.686.098,872 bytesXpweb70.dll NOTE: Because of file dependencies, the most recent hotfix or feature that contains the files may also contain additional files.