Re: Subselects returning array and ANY...

From: Josh Berkus <josh(at)agliodbs(dot)com>
To: "Dawid Kuroczko" <qnex42(at)gmail(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: Subselects returning array and ANY...
Date: 2008-02-28 00:45:21
Message-ID: 200802271645.22055.josh@agliodbs.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Dawid,

> But you are right, though! I just need to leave off the subselect!
> Thanks! SELECT h.* FROM haystack h JOIN needles ON straw = ANY (straws);
>
> (not exactly what I was looking for, but it works ;))

Yeah, the problem with your first query is that it's returning a rowset of
arrays, not a single array. This means that ANY() doesn't know exactly
what to do with it.

--
--Josh

Josh Berkus
PostgreSQL @ Sun
San Francisco

In response to

Browse pgsql-sql by date

  From Date Subject
Next Message Tom Lane 2008-02-28 05:30:44 Re: operator class
Previous Message Dawid Kuroczko 2008-02-28 00:34:42 Re: Subselects returning array and ANY...