jsonb_set: update or upsert default?

Поиск
Список
Период
Сортировка
От Andrew Dunstan
Тема jsonb_set: update or upsert default?
Дата
Msg-id 555FE456.2070501@dunslane.net
обсуждение исходный текст
Ответы Re: jsonb_set: update or upsert default?  ("David E. Wheeler" <david@justatheory.com>)
Список pgsql-hackers
The proposed flag for jsonb_set (the renamed jsonb_replace) in the patch 
I recently published is set to false, meaning that the default behaviour 
is to require all elements of the path including the last to be present. 
What that does is effectively UPDATE for jsonb. If the flag is true, 
then the last element can be absent, in which case it's created, so this 
is basically UPSERT for jsonb. The question is which should be the 
default. We got into the weeds on this with suggestions of throwing 
errors on missing paths, but that's going nowhere, and I want to get 
discussion back onto the topic of what should be the default.

cheers

andrew



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

Предыдущее
От: Ryan Pedela
Дата:
Сообщение: Re: [PATCH] Generalized JSON output functions
Следующее
От: Eric Ridge
Дата:
Сообщение: Re: Change pg_cancel_*() to ignore current backend