Re: jsonb_set() strictness considered harmful to data

Поиск
Список
Период
Сортировка
От Laurenz Albe
Тема Re: jsonb_set() strictness considered harmful to data
Дата
Msg-id d502306ecbad6b6fc5b02db80c82030c87e1497d.camel@cybertec.at
обсуждение исходный текст
Ответ на Re: jsonb_set() strictness considered harmful to data  ("David G. Johnston" <david.g.johnston@gmail.com>)
Ответы Re: jsonb_set() strictness considered harmful to data  ("David G. Johnston" <david.g.johnston@gmail.com>)
Re: jsonb_set() strictness considered harmful to data  (Stuart McGraw <smcg4191@mtneva.com>)
Список pgsql-general
David G. Johnston wrote:
> Now if only the vast majority of users could have and keep this level of understanding
> in mind while writing complex queries so that they remember to always add protections
> to compensate for the unique design decision that SQL has taken here...

You can only say that if you don't understand NULL (you wouldn't be alone).
If I modify a JSON with an unknown value, the result is unknown.
This seems very intuitive to me.

One could argue that whoever uses SQL should understand SQL.

But I believe that it is reasonable to suppose that many people who
use JSON in the database are more savvy with JSON than with SQL
(they might not have chosen JSON otherwise), so I agree that it makes
sense to change this particular behavior.

Yours,
Laurenz Albe
-- 
Cybertec | https://www.cybertec-postgresql.com




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

Предыдущее
От: "David G. Johnston"
Дата:
Сообщение: Re: jsonb_set() strictness considered harmful to data
Следующее
От: "Abraham, Danny"
Дата:
Сообщение: date function bug