delete / delete_many
delete
Deletes a single record and returns it. Returns None if no record matches where.
Parameters
| Parameter | Type | Description |
|---|---|---|
where |
dict |
Unique field(s) to identify the record |
where must reference a field marked @id or @unique in the schema.
delete_many
Deletes all records matching where. Returns the number of rows deleted.
Delete everything in a table:
Parameters
| Parameter | Type | Description |
|---|---|---|
where |
dict |
Filter conditions (same syntax as find_many). Omit to delete all rows. |
where supports the same filter and relation-filter syntax as find_many. Returns 0 if no records match.