In postgres I’m attempting to “upsert” some data into a table with multiple constraints. I know that postgres supports a ON CONFLICT (...) DO UPDATE SET ...
syntax to perform what is commonly called an upsert. My question is:
Is it possible to write an ON CONFLICT
clause that will match all (any) constraints on the table? If not, can I write multiple on conflict clauses for each of my constraints, presuming that each of my DO UPDATE SET
clauses would be the exact same in every case?
Assume I’m on the latest version of Postgres.