Re: query with =ALL - Mailing list pgsql-sql

From Tom Lane
Subject Re: query with =ALL
Date
Msg-id 5688.1087242100@sss.pgh.pa.us
Whole thread Raw
In response to Re: query with =ALL  ("Jaime Casanova" <el_vigia_ec@hotmail.com>)
Responses Re: query with =ALL
List pgsql-sql
"Jaime Casanova" <el_vigia_ec@hotmail.com> writes:
> AND
> CPA.cur_paralelo = ALL (SELECT cur_paralelo FROM aca_t_curso ...)

Wait a second ... we are all overthinking the problem.  The subselect
returns three *different* values.  It is not possible for any
CPA.cur_paralelo values to be simultaneously equal to all three.
So this test certainly fails at every row of CPA.

Perhaps you meant "= ANY"?
        regards, tom lane


pgsql-sql by date:

Previous
From: "Subbiah, Stalin"
Date:
Subject: Scalar subqueries
Next
From: "Jaime Casanova"
Date:
Subject: Re: query with =ALL