FIX: GROUP BY Clause without Index Executes More SlowlyID: Q152800
|
If a Transact-SQL query contains a GROUP BY clause and an index is not defined on the column involved in GROUP BY, the query exhibits better performance when executed on the SQL server with no service packs or service pack 1, as opposed to SQL Servers with service pack 2 installed. This performance anomaly is exhibited only on the Alpha platform.
Sort the columns in the GROUP BY clause. Alternately, define an index encompassing the columns involved in the GROUP BY clause and make sure the index is used when grouping the columns in the query.
Microsoft has confirmed this to be a problem in Microsoft SQL Server version 6.0. This problem has been corrected in U.S. Service Pack 1 for Microsoft SQL Server version 6.5. For more information, contact your primary support provider.
Additional query words: GROUP BY clause Alpha index query
Keywords : kbprg SSrvDRI kbbug6.00 kbfix6.50.sp1
Version : 6.0
Platform : NT WINDOWS
Issue type : kbprb
Last Reviewed: March 27, 1999