May 19, 2003 at 1:36 pm
I would like to return a row count of each group for several groups returned a single query. I am not summing a numeric value in the rows, I just want an individual row count displayed for each group. My query is below. With the group by I return 1600 rows, without 250,000
select author
from profile profile inner join
matter matter on profile.matter = matter.system_id
where client_id = '3999' and matter_id = '1'
group by author
thanks
May 19, 2003 at 3:03 pm
Use COUNT(*) will give you a row count, adding author will give based on related author in grouping. Can you give us an example of what you have to start with, what you get and what you want if COUNT(*) does not meat your needs.
May 20, 2003 at 10:35 am
You mean something like this?
select author, count(*)
from profile inner join
matter on profile.System_id = matter.system_id
where client_id = '3999' and matter_id = '1'
group by author
John Zacharkan
John Zacharkan
May 20, 2003 at 12:08 pm
This did it. Thank you much
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply