How to fix Postgres error "operator does not exist" using pgvector
How to fix Postgres error "operator does not exist" using pgvector: I finally found the problem; you have to install pg_vector on the extensions schema.
I finally found the problem; you have to install pgvector on the extensions schema. If you are following https://github.com/supabase/supabase/blob/master/supabase/migrations/20230126220613doc_embeddings.sql. Most likely you wont get it work for some reason. Just manually enable the extension in database tab.
Context: Stack Overflow #75904637 (accepted answer, 3 votes): I have a Postgres function to find the top 10 most relevant vectors. I called this function from a supabase serverless function, but logs returned 500. The error I get is related to the ` operator. It seems that PostgreSQL cannot find this operator for the vector type provided by the pgvector extension. Detailed Log message: Failed to match page sections: {"code":"42883","details":null,"hint":"No operator matches the given name and argument types. You might need to add explicit type casts.","message":"operator does not exist: extensions.vector extensions.vector"} `` Postgres function:...
Matched source
Source: Published skill Original query: "How to fix Postgres error "operator does not exist" using pgvector" Key terms: does, error, exist, operator, pgvector, postgres, using
Maintainer review
No maintainer verification is recorded for this version.
This records the version a maintainer checked. It does not assert that the version is the latest upstream release.