pg.ddx.io  pgvector/pgvector GitHub issues and pull requests  
help / color / mirror / Atom feed
From: xak2000 (@xak2000) <noreply+xak2000@github.com>
To: pgvector/pgvector <noreply+pgvector-pgvector@github.com>
Subject: Re: [pgvector/pgvector] issue #167: Set ivfflat.probes
Date: Thu, 25 Sep 2025 15:13:34 +0000
Message-ID: <gh-pgvector-pgvector-167-c3334671131@github.com> (raw)
In-Reply-To: <gh-pgvector-pgvector-167@github.com>
References: <gh-pgvector-pgvector-167@github.com>

I encountered similar problem:

```
SHOW hnsw.ef_search;
```

Resulted in:

```
SQL Error [42704]: ERROR: unrecognized configuration parameter "hnsw.ef_search"
```

And

```
SELECT * FROM pg_settings WHERE name LIKE '%hnsw%';
```

Resulted in empty result.

I experimented a little and both queries are starting to work after I do in the current session any action, that initializes `pgvector` extension. E.g. It could be `CREATE TABLE` with a `vector` column. Or a `SELECT` from such table using any distance-calculating function in the query (e.g. `SELECT *, embedding <=> '[1]' AS distance FROM vector_store;`).

If I re-connect to the DB after this, the `SHOW hnsw.ef_search;` command starts to return an "unrecognized configuration parameter" error again.

So, it looks like the `pgvector` extension does not initialize automatically until something that "touches" it happens.
That is the reason why sometimes `SHOW` and `SELECT .. FROM pg_settings` works, while sometimes it does not work.

@ankane 
> Also, it's a regular Postgres config variable, so any behavior isn't specific to pgvector.

So, I would say, while it is a regular config variable, the behavior is still not exactly standard/expected. With all regular Postgres config variables you can always run `SHOW` to get the current value of this variable, while with `pgvector` variables the ability to successfully do this depends on sneaky conditions.

view thread (10+ messages)

Message-ID: <gh-pgvector-pgvector-167-c3334671131@github.com>
Permalink:  ../gh-pgvector-pgvector-167-c3334671131@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