Re: looking for an array-extract-item-as-it operator

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: looking for an array-extract-item-as-it operator
Дата
Msg-id 14748.1452120648@sss.pgh.pa.us
обсуждение исходный текст
Ответ на looking for an array-extract-item-as-it operator  (Peter Krauss <ppkrauss@gmail.com>)
Список pgsql-hackers
Peter Krauss <ppkrauss@gmail.com> writes:
> I need to access an array-item from an array of arrays.

Multi-dimensional arrays in Postgres are not "arrays of arrays".
If you persist in thinking they are, it's mostly going to lead you
astray about what will work or not.

Having said that, you might find that plpgsql's 
FOREACH ... SLICE ... IN ARRAY ... LOOP
construct would help you, if you need to iterate through the
rows sequentially.

http://www.postgresql.org/docs/9.4/static/plpgsql-control-structures.html#PLPGSQL-FOREACH-ARRAY
        regards, tom lane



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Peter Krauss
Дата:
Сообщение: looking for an array-extract-item-as-it operator
Следующее
От: Jim Nasby
Дата:
Сообщение: Re: No Issue Tracker - Say it Ain't So!