# X_ENTITY_OPERATOR_UNKNOWN

## Means

a predicate names an operator outside the vocabulary

## Typical cause

an operator that is not one of the closed set `Operator` declares — usually a SQL symbol (`'>'` for `gt`) or a different case (`'GT'`), reaching the plan through a cast, an operator built from a string, or a test run with no typecheck. Refused where the chain is written (`andWhere`) and again by both drivers for a plan built by hand, identically: before this the memory driver matched NO row with no error and the Postgres driver failed with a misleading `X_SQL_UNSAFE`. 500 — nothing the caller sends changes the answer, and the repair is an edit to source

## Fix

the `fix` opens with the call, the operator meant substituted — `andWhere('likes', 'gt', value)   # operators: eq, neq, …` — and a placeholder with the whole list when nothing is close. SQL symbols map `>`→gt, `>=`→gte, `<`→lt, `<=`→lte, `=`→eq, `!=`/`<>`→neq; a known word in another case or with `_` maps to itself (`'GT'`, `'is_null'`). The list is `OPERATORS` in `@ultimat3/entity`, and `isOperator()` tests a value read off the wire

[Entity and database](/error-codes#entity-and-database)
