to_json(NULL) should to return JSON null instead NULL

Поиск
Список
Период
Сортировка
От Pavel Stehule
Тема to_json(NULL) should to return JSON null instead NULL
Дата
Msg-id CAFj8pRBdi4Ud-=8kfM28i7fa=B6t=nFTM3UK5qNBm9TjazC99A@mail.gmail.com
обсуждение исходный текст
Ответы Re: to_json(NULL) should to return JSON null instead NULL  ("Shulgin, Oleksandr" <oleksandr.shulgin@zalando.de>)
Список pgsql-hackers
Hi

currently JSON support NULL value - but we doesn't convert NULL to JSON correctly

postgres=# select to_json(NULL::text) IS NULL;
┌──────────┐
│ ?column? │
╞══════════╡
│ t        │
└──────────┘
(1 row)


probably should be json "null";

like

postgres=# select json 'null' is null;
┌──────────┐
│ ?column? │
╞══════════╡
│ f        │
└──────────┘
(1 row)


?

Regards


Pavel

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

Предыдущее
От: Noah Misch
Дата:
Сообщение: Re: [BUGS] Compile fails on AIX 6.1
Следующее
От: "Shulgin, Oleksandr"
Дата:
Сообщение: Re: to_json(NULL) should to return JSON null instead NULL