Re: proposal: FOREACH-IN-ARRAY (probably for 9.2?) - Mailing list pgsql-hackers

From Tom Lane
Subject Re: proposal: FOREACH-IN-ARRAY (probably for 9.2?)
Date
Msg-id 2099.1292607073@sss.pgh.pa.us
Whole thread Raw
In response to Re: proposal: FOREACH-IN-ARRAY (probably for 9.2?)  (Andrew Dunstan <andrew@dunslane.net>)
Responses Re: proposal: FOREACH-IN-ARRAY (probably for 9.2?)  ("David E. Wheeler" <david@kineticode.com>)
List pgsql-hackers
Andrew Dunstan <andrew@dunslane.net> writes:
> On 12/17/2010 12:15 PM, Pavel Stehule wrote:
>> The reason for this is bigger space for possible
>> future features related to FOREACH loop.

> So what you're saying is we need to allow ugliness now so we can have 
> more ugliness in future? I don't find that a convincing argument. I 
> share the dislike for this syntax.

Well, we did beat up Pavel over trying to shoehorn this facility into
the existing FOR syntax, so I can hardly blame him for thinking this
way.  The question is whether we're willing to assume that FOREACH will
be limited to iterating over arrays, meaning we'll be stuck with
inventing yet another initial keyword if some other fundamentally
different concept comes along.  Right at the moment I can't think of
any plausible candidates, but ...
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: proposal: FOREACH-IN-ARRAY (probably for 9.2?)
Next
From: Pavel Stehule
Date:
Subject: Re: proposal: FOREACH-IN-ARRAY (probably for 9.2?)