|
-
May 3rd, 2009, 11:09 PM
#2
Re: Multiple Count(*) in SELECT
There's no way to create a single result set with two different WHERE clauses. COUNT tells you how many records are in a group so how can the same group have two different numbers of records in it? If you want two different WHERE clauses then you need two different queries. You can perform a UNION to concatenate the two result sets but then you'll have each group in the final result set twice.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|