Types and functions related to PG’s and Sqlite’s
ON CONFLICT clause
Upsert is currently supported by diesel for the following database systems:
- PostgreSQL version 9.5 or newer
- Sqlite3 version 3.24.0 or newer
See the methods on
for usage examples.
Constructing an upsert statement from an existing select statement requires a where clause on sqlite due to a ambiguity in their parser. See the corresponding documentation for details.
ON CONFLICT DO UPDATEclause.