Anyone want to fix plperl for null array elements?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Anyone want to fix plperl for null array elements?
Дата
Msg-id 29781.1132278111@sss.pgh.pa.us
обсуждение исходный текст
Ответы Re: Anyone want to fix plperl for null array elements?  (Michael Fuhr <mike@fuhr.org>)
Re: Anyone want to fix plperl for null array elements?  ("Andrew Dunstan" <andrew@dunslane.net>)
Список pgsql-hackers
I think plperl should be fixed to translate undef to NULL when returning
an array, but currently it translates to an empty string:

pl_regression=# CREATE OR REPLACE function returns_array() returns text[] as $$
pl_regression$# return ['a,b','c"d',undef,'e-f']; $$ LANGUAGE plperl;
CREATE FUNCTION
pl_regression=# select returns_array();    returns_array
-----------------------{"a,b","c\"d","",e-f}
(1 row)

There might be some problems going in the other direction, too;
I haven't tried.  Anybody feeling eager to fix this?
        regards, tom lane


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

Предыдущее
От: Tom Lane
Дата:
Сообщение: Re: Some array semantics issues
Следующее
От: Alvaro Herrera
Дата:
Сообщение: Re: CLUSTER and clustered indices