Knowledge Base

FIX: AV if Subquery GROUP BY and HAVING with ROUND()

Article ID: 154887

Article Last Modified on 10/3/2003


APPLIES TO


This article was previously published under Q154887

SYMPTOMS

A select that contains a subquery combined with a GROUP BY and a HAVING clause with the function ROUND() results in the following error message and terminates with a thread level Access Violation (AV):
Msg 913, Level 22, State 2
Could not find row in Sysdatabases with database id 0.
Run DBCC CHECKTABLE on Sysdatabases.

WORKAROUND

Re-code the query so that it does not fit the pattern.

STATUS

Microsoft has confirmed this to be a problem in the Microsoft SQL Server version 6.50.201. This problem has been corrected in U.S. Service Pack 2 for Microsoft SQL Server version 6.5. For more information, contact your primary support provider.

Additional query words: default

Keywords: kbbug kbfix kbprogramming KB154887