Re: Sv: how to build this query ??? Please help !!!

From: Tod McQuillin <devin(at)spamcop(dot)net>
To: Jens Hartwig <jhartwig(at)debis(dot)com>
Cc: Nikolaj Lundsgaard <Nikolaj(at)konfus(dot)dk>, <pgsql-sql(at)postgresql(dot)org>
Subject: Re: Sv: how to build this query ??? Please help !!!
Date: 2001-01-04 07:53:05
Message-ID: Pine.GSO.4.31.0101040151430.3519-100000@sysadmin
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

On Thu, 4 Jan 2001, Jens Hartwig wrote:

> > SELECT a_nr,
> > (SELECT count(*) FROM cylinders WHERE z_a_nr = a_nr) AS #cylinder,
> > [...]
> > FROM orders
>
> Is this a documented feature? Where can I find more information about
> this? I do not want to join the actual discussion about documentation
> of PostgreSQL but I never before have seen such a construct in SQL!

Subqueries are covered in Bruce Momjian's book:
http://www.postgresql.org/docs/aw_pgsql_book/node93.html

I don't think the PostgreSQL User's Manual mentions sub-selects.
--
Tod McQuillin

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Tom Lane 2001-01-04 08:31:59 Re: Sv: how to build this query ??? Please help !!!
Previous Message Markus Wagner 2001-01-04 07:31:29 postmaster: address already in use