Re: [PATH] Jsonb, insert a new value into an array at arbitrary position
В списке pgsql-hackers по дате отправления:
| От | Petr Jelinek |
|---|---|
| Тема | Re: [PATH] Jsonb, insert a new value into an array at arbitrary position |
| Дата | |
| Msg-id | 56D48FD5.8030703@2ndquadrant.com обсуждение исходный текст |
| Ответ на | Re: [PATH] Jsonb, insert a new value into an array at arbitrary position (Dmitry Dolgov <9erthalion6@gmail.com>) |
| Список | pgsql-hackers |
On 29/02/16 18:19, Dmitry Dolgov wrote: > > I'd strongly prefer the jsonb_array_insert naming though > > I don't think it's a good idea to use set when this is used on > object, I think that we should throw error in that case. > > Well, I thought it's wrong to introduce different functions and > behaviour patterns for objects and arrays, because it's the one data > type after all. But it's just my opinion of course. > The problem I see with that logic is because we don't keep order of keys in the jsonb object the "insert" in the name will have misleading implications from the point of the user. Also it does not do anything for object that "set" doesn't do already, so why have two interfaces for doing same thing. -- Petr Jelinek http://www.2ndQuadrant.com/ PostgreSQL Development, 24x7 Support, Training & Services
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера