BUG: Stored Procedure Behavior Inconsistent When Grouping by a Bit Column (174854)
The information in this article applies to:
This article was previously published under Q174854 SYMPTOMS
BUG #: 17248 (6.50)
When you create a stored procedure that involves a temporary table and a
WHERE clause on a bit column, the following happens:
- After initial creation, the stored procedure runs fine.
- After restarting SQL Server or loading the database from a dump, executing
the stored procedure generates the following error message:
Msg 252, Level 16, State 1 Can't group by a bit field.
WORKAROUND
To work around this problem, do either of the following:
- Use a tinyint instead of a bit column (this is the preferred solution).
-or-
- Replace the temporary table with a permanent table.
STATUS
Microsoft has confirmed this to be a problem in SQL Server version 6.5. We
are researching this problem and will post new information here in the
Microsoft Knowledge Base as it becomes available.
Modification Type: | Major | Last Reviewed: | 10/3/2003 |
---|
Keywords: | kbBug kbusage KB174854 |
---|
|