pg.ddx.io  pgvector/pgvector GitHub issues and pull requests  
help / color / mirror / Atom feed
From: mgoldenbe (@mgoldenbe) <noreply+mgoldenbe@github.com>
To: pgvector/pgvector <noreply+pgvector-pgvector@github.com>
Subject: Re: [pgvector/pgvector] issue #259: Understanding HNSW + filtering
Date: Thu, 26 Oct 2023 09:39:29 +0000
Message-ID: <gh-pgvector-pgvector-259-c1780765601@github.com> (raw)
In-Reply-To: <gh-pgvector-pgvector-259@github.com>
References: <gh-pgvector-pgvector-259@github.com>

@knizhnik 

> But what if new category is added? Once again - you can create trigger which creates index but ...

Either a trigger, or do `CREATE INDEX` just like you do `INSERT INTO` to insert the new category.


> But for larger number of categories - I expect that overhead (including planning time) will be quite large.

Why isn't the partial index creation time `O(1)`? Why should it depend on the number of partial indices that already exist?


> Also if you create partial index for each category value, then you will note able to rung queries `where category > 100` or `where category in (1,2,3)`

I run only `where category = some_category`. But regardless, why would `where category in (1,2,3)` not work? As for `where category > 100`, it would probably just not use the indices.

view thread (90+ messages)  latest in thread

Message-ID: <gh-pgvector-pgvector-259-c1780765601@github.com>
Permalink:  ../gh-pgvector-pgvector-259-c1780765601@github.com/

 · 


This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox