DATABASE_INVALID_OPERRATOR
Error Cause
Unsupported operation or invalid database operator, used query operator not supported by database.
Solution
Check database operators
For JS SDK filter operation documentation, please refer to: MySQL Database/Filters
Usage format:
db.from("table_name").select().filter(column, operator, value)
| Parameter | Type | Required | Description |
|---|---|---|---|
| column | string | Required | Column to filter |
| operator | string | Required | Filter operator, follows MySQL syntax |
| value | any | Required | Filter value, follows MySQL syntax |
Usage example:
In the example, in is the filter operator
// Query records where title is in specified value list
// Query all records from articles table where title is in specified value list ["腾讯云开发", "云开发"]
const { data, error } = await db
.from("articles")
.select()
.filter("title", "in", "(腾讯云开发,云开发)");