Re: Stalled post to pgsql-general

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Stalled post to pgsql-general
Дата
Msg-id 16411.1291218204@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Stalled post to pgsql-general  (Samba <saasira@gmail.com>)
Список pgsql-general
Samba <saasira@gmail.com> writes:
> REPOST!

Please fix the subject line to be something useful when you resend a
message.

>> I'm trying to assign the individual sub arrays to other array elements
>> like:
>>
>> other-array VARCHAR[];
>>
>> other_array=some_array[1];
>>
>> and I'm expecting to get '{samba,sarath,sreenivas}' for index 1 and *{samba,mukhesh,pavan}
>> *for index 2;*
>> *however, I'm getting NULL.

You need to use array slice syntax if you want to extract a sub-array
rather than a single element.  Try something like some_array[1:1].  See
http://www.postgresql.org/docs/9.0/static/arrays.html#ARRAYS-ACCESSING

            regards, tom lane

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

Предыдущее
От:
Дата:
Сообщение: Looking for auto starting procedures
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Cannot start Postgres- FATAL: invalid cache id: 19