Re: SQL question
Posted in 1996
On 17 Oct 1996, rickt wrote:
> If I have the following SQL
> select column1, count(*) from tablefoo
> group by column1>
> It returns 24 rows with various counts.
>
> Is there a way to return just the number of rows that would have been
> returned. (ie just the number 24)
> I know I could put it in a temp table and then count that but, yuk
>
Hmmmm, kinda interesting to me. Initial reaction was to just use count(*)
to devine the number of rows until I realized that perhaps you are
grouping to differentiate some rows from others? Does that work? Why not
just select count(*) from foo with no group by if all you want is a
count?
elderbox@teleport.COM Public Access User --- Not affiliated with Teleport
Public Access UNIX and Internet at (503) 220-1016 (2400-28800, N81)