datafuselabs / jsonb

JSONB implement in rust
Apache License 2.0
62 stars 8 forks source link

feat: add exists_any_keys & exists_all_keys #38

Closed akoshchiy closed 10 months ago

akoshchiy commented 10 months ago

Added exists_any_keys & exists_all_keys (supporting operators ?|, ?, ?& for https://github.com/datafuselabs/databend/issues/11270).

Searching object key doesn't seems to be optimal. We can optimize it to logarithmic via bsearch, but we should add offset-encoding support at first (like postgres does).

b41sh commented 10 months ago

Added exists_any_keys & exists_all_keys (supporting operators ?|, ?, ?& for datafuselabs/databend#11270).

Searching object key doesn't seems to be optimal. We can optimize it to logarithmic via bsearch, but we should add offset-encoding support at first (like postgres does).

Yes, it is true that key searches perform poorly, and we can optimize it later on