A "COMPUTE BY statements not supported" exception occurs when you use the COMPUTE BY clause in SQL Server (311540)
The information in this article applies to:
- Microsoft ADO.Net 2.0
- Microsoft ADO.NET (included with the .NET Framework)
- Microsoft Visual Basic .NET (2002)
- Microsoft Visual Basic .NET (2003)
- Microsoft SQL Server 2000 (all editions)
- Microsoft SQL Server 7.0
This article was previously published under Q311540 This article refers to the following Microsoft .NET
Framework Class Library namespaces:
- System.Data.OleDb
- System.Data.SqlClient
SYMPTOMS When you attempt to use the COMPUTE BY clause with the
Microsoft SQL Server .NET Data Provider, you receive the following exception:
An unhandled exception of type
'System.InvalidOperationException' occurred in system.data.dll.
Additional information: COMPUTE BY statements not supported. Note The COMPUTE BY clause in a SQL Server statement generates
subtotals within the result set. CAUSE This behavior is caused by a limitation of the SQL Server
.NET Data Provider.
The SQL Server .NET Data Provider does not
support all SQL syntax statements.
RESOLUTION To resolve this issue, use ADO through COM Interop, or use
the OLE DB .NET Data Provider. STATUSThis
behavior is by design.REFERENCES For more information about ADO.NET objects and syntax, see
the Microsoft .NET Framework SDK Documentation, or browse to the following MSDN
Web site: For more details about the .NET Framework and the COM Interop
layer, browse to the following MSDN Web site:
Modification Type: | Minor | Last Reviewed: | 3/9/2006 |
---|
Keywords: | kbtshoot kberrmsg kbnofix kbprb kbSqlClient kbStoredProc kbSystemData KB311540 kbAudDeveloper |
---|
|