[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[ale] any SQL gurus?

On Wed, 2004-01-21 at 11:04, Jason Etheridge wrote:
> > select t.name from t TITLE, c COPY where c.owner = "whoever" and
> > 	c.title_key = f.title_key;
> So it's not a list I need, but a count.  Hrmm.

	I think GROUP BY would come in handy.  Lemme see, it's been a few years
here, so pardon the rustiness of the following:

	select count(*), t.name
          from TITLE t, COPY c
         where c.title_key = t.title_key
      group by t.name

and this is from the INGRES dialect, so "count(*)" may not be proper in

kernel, n.: A part of an operating system that preserves the
medieval traditions of sorcery and black art.