Re: Array_append does not work with Array variables in PL/pgSQL?

Поиск
Список
Период
Сортировка
От Josh Berkus
Тема Re: Array_append does not work with Array variables in PL/pgSQL?
Дата
Msg-id 200404011348.26646.josh@agliodbs.com
обсуждение исходный текст
Ответ на Re: Array_append does not work with Array variables in PL/pgSQL?  (Joe Conway <mail@joeconway.com>)
Ответы Re: Array_append does not work with Array variables in PL/pgSQL?
Список pgsql-sql
Joe,

> You have to initialize the array to something non-null, even if that be 
> an empty array (note that there is a difference). When trying to append 
> an element to a NULL valued array, you wind up with a NULL result. It is 
> similar to:

Aha!

I knew that I was missing something fundamental.

BTW, did you get my e-mail to Hackers about ARRAY[] IS NULL?

-- 
-Josh BerkusAglio Database SolutionsSan Francisco



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

Предыдущее
От: Joe Conway
Дата:
Сообщение: Re: Array_append does not work with Array variables in PL/pgSQL?
Следующее
От: Joe Conway
Дата:
Сообщение: Re: Array_append does not work with Array variables in PL/pgSQL?