On Sep 16, 2023, at 16:50, Erik Wienhold <ewie@ewie.name> wrote:
> "For these operators, a GIN index extracts clauses of the form
> **accessors_chain = constant** out of the jsonpath pattern, and does the
> index search based on the keys and values mentioned in these clauses."
>
> I don't know if this is a general limitation of GIN indexes or just how these
> operators are implemented right now.
>
> [1] https://www.postgresql.org/docs/current/datatype-json.html#JSON-INDEXING
The detail that jumps out at me is this one on jsonb_path_ops:
“Basically, each jsonb_path_ops index item is a hash of the value and the key(s) leading to it”
Because jsonb_path_ops indexes hashes, I would assume it would only support path equality. But it’s not clear to me
fromthese docs that jsonb_ops also indexes hashes. Does it?
Best,
D