Pavel Stehule <pavel.steh...@gmail.com> writes: > FOR varname OVER [row | rec variable] > LOOP > {{body}} > END LOOP
> this syntax isn't final. The real type of control variable is > specified in runtime and can be changed between iterations. If you don't know the type or even the name of the field that varname currently represents, how is the loop body going to do anything useful? > This variable should be > writeable - so we are able to change any field of record. And that is just plain horrid. The loop variable is a separate variable, not a modifiable alias for a field, in every existing form of plpgsql loop. The idea of multiple instances of the loop body code seems like a mess anyway. I think this is basically hacking plpgsql beyond recognition to solve problems that are better solved in plperl or pltcl. regards, tom lane -- Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgsql-hackers