I have a JSONB column which holds data like the following:
[[5567, 6288290106102], [7922, 1565590655290]
The general format is:
[[container_nr, position], ...]
[container_nr, position] tuples can be in this column one or more times.
I have to search (equality matching is fine with multiple
<> would be better, but the docs say it’s not yet supported) for the container_nr.
What’s the most efficient way to solve this (storage and index-wise)?
Currently I do two JSONB columns, one for the above and another with the
[container_nr1, container_nr2, ...] and use an inverted index on the latter.
Is there a better way to do this?