No operator matches the given name and argument types. You might need to add explicit type casts
Hitting this error when running postgres with the following queries in python
cur.execute("""
SELECT name, category, subcategory
FROM items
ORDER BY embedding <-> %s
LIMIT 3;
""", (query_emb,))
Appparently the fix is as follows
cur.execute("""
SELECT name, category, subcategory
FROM items
ORDER BY embedding <-> %s::vector
LIMIT 3;
""", (query_emb,))
Comments