Re: The empty list?

From: Jesper Krogh <jesper(at)krogh(dot)cc>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Aaron Bono <postgresql(at)aranya(dot)com>, pgsql-sql(at)postgresql(dot)org
Subject: Re: The empty list?
Date: 2006-11-03 06:46:13
Message-ID: 454AE5B5.4050106@krogh.cc
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Tom Lane wrote:
> Jesper Krogh <jesper(at)krogh(dot)cc> writes:
>> ... the right-hand-side of on
>> in operation will allways be a list (if I havent forgotten something).
>
> IN (SELECT ...) for one thing.

Isn't that "just" a list of rows(complex value) instead of an list of
types(simple values)?

>> ... but missing SQL for the empty list basically means that
>> we cant handle the empty set encoded in the empty array without
>> explicitly introducing code for this size of array. From a
>> programatically viewpoint, this seems quite odd.
>
> FWIW, as of 8.2 the best option will probably be to use
> "col = ANY (array)", which does support zero-length arrays
> if you use either an out-of-line parameter or an array literal.

That looks nice.. is ANY in the SQL-spec?

Jesper
--
Jesper Krogh, jesper(at)krogh(dot)cc

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message Tom Lane 2006-11-03 06:58:08 Re: delete and select with IN clause issues
Previous Message Jeff Frost 2006-11-03 06:42:35 Re: delete and select with IN clause issues