pg.ddx.io  pgsql-sql@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Ottó Havasvölgyi <havasvolgyi.otto@gmail.com>
To: pgsql-sql@postgresql.org
Subject: Treating result of subselect as row
Date: Tue, 6 Nov 2007 11:09:30 +0100
Message-ID: <34608c0c0711060209h6056b717x4ce746ab342868c9@mail.gmail.com> (raw)

Hi,

If I have a subselect that returns one row, then how can I use this in
expressions that expects row constructors in the operands, like OVERLAPS or
IN ?

SELECT (subselect1) OVEPLAPS (subselect2)   -- both subselect returns one
row and two columns

OR:

SELECT (SubselectWithOneRow) IN (subselect2)   -- but here subselect2 may
return many rows, but column counts are equal

I tried these in 8.2 without success.

Thanks,
Otto

Message-ID: <34608c0c0711060209h6056b717x4ce746ab342868c9@mail.gmail.com>
Permalink:  ../34608c0c0711060209h6056b717x4ce746ab342868c9@mail.gmail.com/
Also on:    postgresql.org/message-id/34608c0c0711060209h6056b717x4ce746ab342868c9@mail.gmail.com

 · 

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-sql@postgresql.org
  Cc: havasvolgyi.otto@gmail.com
  Subject: Re: Treating result of subselect as row
  In-Reply-To: <34608c0c0711060209h6056b717x4ce746ab342868c9@mail.gmail.com>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox