A term query treats the query as a single token. Because it does not apply any additional tokenization or processing
to the query, it is useful when looking for exact matches.The term query should not be confused with the match query, which auto-tokenizes
the query string.
term can be used to filter over custom Postgres enums
if the query term is explicitly cast to the enum type. If JSON syntax is used, the underlying ordinal value of the enum must be used.
Copy
Ask AI
-- Assume we have indexed an enum called colorSELECT description, rating, categoryFROM mock_itemsWHERE id @@@ paradedb.term('color', 'red'::color);