> Did you try integer arrays with GIN (inverted index) ? I now tried this, and GIN turned out to be linear time, compared with GIST which was acceptable time. However I tested this only for Z=infinity, for Z=1000, GIST/GIN are both not acceptable.
pgsql-performance by date:
Соглашаюсь с условиями обработки персональных данных