Re: is array bug? (array[][])[] = NULL

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: is array bug? (array[][])[] = NULL
Дата
Msg-id 27308.1086360400@sss.pgh.pa.us
обсуждение исходный текст
Ответ на is array bug? (array[][])[] = NULL  (Pavel Stehule <stehule@kix.fsv.cvut.cz>)
Список pgsql-bugs
Pavel Stehule <stehule@kix.fsv.cvut.cz> writes:
> I expect v1 = [1,2], but v1 is null.
> What is wrong?

Postgres arrays don't work that way; you're assuming the semantics are
like C which they aren't.

You could get an approximation to what you want with array slicing, viz
    v2[1:1][1:2]
but note that this doesn't decrease the dimensionality of the result.

            regards, tom lane

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

Предыдущее
От: contact
Дата:
Сообщение: build postgresql-7.4.2 fails: FATAL: semctl(35, 16, SETVAL, 536) failed: Inv,alid argument
Следующее
От: Tom Lane
Дата:
Сообщение: Re: build postgresql-7.4.2 fails: FATAL: semctl(35, 16, SETVAL, 536) failed: Inv,alid argument