recapitulation: FOREACH-IN-ARRAY - Mailing list pgsql-hackers

From Pavel Stehule
Subject recapitulation: FOREACH-IN-ARRAY
Date
Msg-id AANLkTimD39qswcrWaYeFfNKuaN_UbkiQ6PZ-m+ob_5pK@mail.gmail.com
Whole thread Raw
List pgsql-hackers
Hello

I reread a discus to this topic. It's look like we can to find a
agreement on following syntax:

FOREACH var [,var [..]] [SLICE number] IN expr
LOOP
END LOOP;

In default mode, without keyword SLICE, it will iterate over every
field like "unnest" does. With SLICE keyword, it iterate over nested
arrays. Deep can be chosen. I don't see a reason why the deep should
be a dynamic. There can be a constant.

variable list is used only when item is record or row type.

I am not sure what is better keyword - SLICE or SLICING ?

Regards

Pavel Stehule


pgsql-hackers by date:

Previous
From: Sushant Sinha
Date:
Subject: Re: english parser in text search: support for multiple words in the same position
Next
From: Magnus Hagander
Date:
Subject: Streaming replication as a separate permissions