Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Including bit field in a group
Message
 
To
21/10/2015 17:22:31
General information
Forum:
Microsoft SQL Server
Category:
SQL syntax
Environment versions
SQL Server:
SQL Server 2012
Application:
Web
Miscellaneous
Thread ID:
01626293
Message ID:
01626308
Views:
38
>Usually, when I have a GROUP clause, and the select for the fields has to include additional fields, I simply use the MAX() syntax to add more fields which are not part of the group. However, I now need to include a bit field. A MAX() is not supported on a bit field. What would be the best approach to obtain that field in the field list?

If you don't care about the value of that field:
just add CAST(0 as bit) AS BitField in field list.
Against Stupidity the Gods themselves Contend in Vain - Johann Christoph Friedrich von Schiller
The only thing normal about database guys is their tables.
Previous
Next
Reply
Map
View

Click here to load this message in the networking platform