Search

A severe error occurred on the current command. The results, if any, should be discarded. by Tim Schmidt

Active

4
0
Sign in
to vote
Type: Bug
ID: 530712
Opened: 2/3/2010 9:42:27 PM
Access Restriction: Public
0
Workaround(s)
0
User(s) can reproduce this bug
When viewing the query plan for a query requiring optimisation (will attach shortly), missing index details were provided. After creating the index and re-running the query a severe error occurs.

SELECT TEST_NO, RTRIM( TITLE ) AS TITLE
FROM dbo.TEST_TABLE1
WHERE CLASS_NO = 3
AND TEST_TYPE = 'AXB'
AND ( DATE_COMPLETED IS NOT NULL OR DATE_COMPLETED <= GETDATE() )
AND ( DATE_DECOMMISSIONED IS NULL OR DATE_DECOMMISSIONED > GETDATE() )
GO

After further investigation we found that the query had a logic error. One of the "OR" should be an "AND" as shown in the script. This resolves our issue and the query works fine however SQL Server should still 'handle' the other scenario.
Details (expand)
Product Language
English

Version

SQL Server 2005 SP3

Category

SQL Engine

Operating System

Win2003 Enterprise Server (SP2)
Operating System Language
English
Steps to Reproduce
Run script which will be attached shortly.
Actual Results
Msg 0, Level 11, State 0, Line 0
A severe error occurred on the current command. The results, if any, should be discarded.
Msg 0, Level 20, State 0, Line 0
A severe error occurred on the current command. The results, if any, should be discarded.
Expected Results
2 rows

Platform

 
File Attachments
File Name Submitted By Submitted On File Size  
SEVERE ERROR.sql (restricted) 2/3/2010 -
Sign in to post a comment.
Posted by Microsoft on 2/15/2010 at 5:04 PM
Hello,

I've resolved this item as a duplicate of another defect that was fixed. The KB article for the fix can be found here: http://support.microsoft.com/kb/969021/. This fix was released only as part of cumulative update (CU), i.e. it is not available as a standalone fix.

SQL Server 2005 SP3 Cumulative Update 3 (CU3) can be found by following link from the above article or directly at http://support.microsoft.com/kb/967909/.

The CU3 download is about 121 Mb.

I verified the fix on one of my machines. The build number after installing the SP3 CU3 should be 9.00.4220.00.

Regards,
Boris Baryshnikov.
Posted by Microsoft on 2/8/2010 at 7:01 PM
Hello!

Sorry for miscommunication on this one. I did repro this on SQL 2005 SP3 build. I reactivated the bug for further investigation.

Thank you for providing the self-contained repro!

Regards,
Boris Baryshnikov.
SQL Server Engine
Posted by Microsoft on 2/8/2010 at 4:31 PM
Thank you for submitting this issue. It has been fixed in SP2 and later service packs.
Sign in to post a workaround.