Re: How to COUNT rows when they have a COUNT in them

2004-06-15 Thread Brian Mansell
as very slow as there are a LOT of rows and this method returned all > of them. > > >From: Garth Webb <[EMAIL PROTECTED]> > >To: Dave Torr <[EMAIL PROTECTED]> > >CC: [EMAIL PROTECTED] > >Subject: Re: How to COUNT rows when they have a COUNT in them >

Re: How to COUNT rows when they have a COUNT in them

2004-06-15 Thread Dave Torr
; on 4.1 (seems to need the SubQuery feature)? If so I will upgrade > immediately! > > > >From: Yayati Kasralikar <[EMAIL PROTECTED]> > >To: Dave Torr <[EMAIL PROTECTED]> > >CC: [EMAIL PROTECTED] > >Subject: Re: How to COUNT rows when they have a COUNT in

Re: How to COUNT rows when they have a COUNT in them

2004-06-15 Thread Michael Stassen
To: Dave Torr <[EMAIL PROTECTED]> CC: [EMAIL PROTECTED] Subject: Re: How to COUNT rows when they have a COUNT in them Date: Mon, 14 Jun 2004 23:37:15 -0400 Following query does what you want: SELECT COUNT(*) from (c) as temp -Yayati Dave Torr wrote: Probably simple but I can't figure i

Re: How to COUNT rows when they have a COUNT in them

2004-06-15 Thread Garth Webb
pgrade > immediately! > > > >From: Yayati Kasralikar <[EMAIL PROTECTED]> > >To: Dave Torr <[EMAIL PROTECTED]> > >CC: [EMAIL PROTECTED] > >Subject: Re: How to COUNT rows when they have a COUNT in them > >Date: Mon, 14 Jun 2004 23:37:15 -0400 >

Re: How to COUNT rows when they have a COUNT in them

2004-06-15 Thread Martijn Tonies
Just a note... > Thanks - this did not work for me as I am on 4.0.17 - presumably this works > on 4.1 (seems to need the SubQuery feature)? If so I will upgrade > immediately! This isn't a subquery -- this is a Derived Table. With regards, Martijn Tonies Database Workbench - developer tool for

Re: How to COUNT rows when they have a COUNT in them

2004-06-14 Thread Michael Stassen
EMAIL PROTECTED] Subject: Re: How to COUNT rows when they have a COUNT in them Date: Mon, 14 Jun 2004 23:37:15 -0400 Following query does what you want: SELECT COUNT(*) from (SELECT COUNT(*) as c FROM pet GROUP BY owner HAVING c>1) as temp -Yayati Dave Torr wrote: Probably simple but I can't fi

Re: How to COUNT rows when they have a COUNT in them

2004-06-14 Thread Dave Torr
NT rows when they have a COUNT in them Date: Mon, 14 Jun 2004 23:37:15 -0400 Following query does what you want: SELECT COUNT(*) from (SELECT COUNT(*) as c FROM pet GROUP BY owner HAVING c>1) as temp -Yayati Dave Torr wrote: Probably simple but I can't figure it out! THe manual section 3.3

Re: How to COUNT rows when they have a COUNT in them

2004-06-14 Thread Yayati Kasralikar
Following query does what you want: SELECT COUNT(*) from (SELECT COUNT(*) as c FROM pet GROUP BY owner HAVING c>1) as temp -Yayati Dave Torr wrote: Probably simple but I can't figure it out! THe manual section 3.3.4.8 has the example SELECT owner, COUNT(*) FROM pet GROUP BY owner which is fine.

How to COUNT rows when they have a COUNT in them

2004-06-14 Thread Dave Torr
Probably simple but I can't figure it out! THe manual section 3.3.4.8 has the example SELECT owner, COUNT(*) FROM pet GROUP BY owner which is fine. Now what I want to do is count the number of rows this returns. Actually of course this is trivial - I can just count how many owners there are. Wha