Re: Bug in comparison of empty jsonb arrays to scalars
От | Michael Paquier |
---|---|
Тема | Re: Bug in comparison of empty jsonb arrays to scalars |
Дата | |
Msg-id | CAB7nPqR_fzBDgyjKB092O9L5F8aYzUn4hgrF_K9axD45NOdcXA@mail.gmail.com обсуждение исходный текст |
Ответ на | Bug in comparison of empty jsonb arrays to scalars (Nikita Glukhov <n.gluhov@postgrespro.ru>) |
Ответы |
Re: Bug in comparison of empty jsonb arrays to scalars
|
Список | pgsql-hackers |
On Wed, Nov 9, 2016 at 8:31 AM, Nikita Glukhov <n.gluhov@postgrespro.ru> wrote: > Hi hackers. > > While working on jsonbstatistics, I found the following bug: > an empty jsonb array is considered to be lesser than any scalar, > but it is expected that objects > arrays > scalars. Sources? Does the JSON spec contain any information regarding comparison operators? I don't think so, so that would be up to the implementation to decide that, no? Btw I would agree with you that's quite unintuitive, but that's not wrong either to keep the current comparison algorithm because that's harmless for btree. We could have more regression tests to make the current behavior clear though. Thoughts from others are welcome. -- Michael
В списке pgsql-hackers по дате отправления: