Postgres 15 will support MERGE
postgresql.org
Postgres 15 will support MERGE
1–6 of 6 posts
Re: Postgres 15 will support MERGE
#2This looks it takes an entire column and upserts all of its rows into another column, on the same or another table.
Is that correct? Is this part of the SQL standard? Is this the same as MERGE in SQL Server and Oracle (which has no counterpart in MySQL)?
IIRC upsert in PG is different than in Mysql, MS or Oracle; is that the same here?
Are there any good resources for this?
Re: Postgres 15 will support MERGE
#3Re: Postgres 15 will support MERGE
#4While Postgres docs are great (they usually are), I would love some more backgrond. This looks it takes an entire column and upserts all of its rows into another column, on the same or another table. Is that correct? Is this part of the SQL standard? Is this the same as MERGE in SQL Server and Oracle (which has no counterpart in MySQL)? IIRC upsert in PG is different than in Mysql, MS or Oracle; is that the same here…
Merge acts on multiple rows and columns at the same time.
Re: Postgres 15 will support MERGE
#5While Postgres docs are great (they usually are), I would love some more backgrond. This looks it takes an entire column and upserts all of its rows into another column, on the same or another table. Is that correct? Is this part of the SQL standard? Is this the same as MERGE in SQL Server and Oracle (which has no counterpart in MySQL)? IIRC upsert in PG is different than in Mysql, MS or Oracle; is that the same here…
Re: Postgres 15 will support MERGE
#6While Postgres docs are great (they usually are), I would love some more backgrond. This looks it takes an entire column and upserts all of its rows into another column, on the same or another table. Is that correct? Is this part of the SQL standard? Is this the same as MERGE in SQL Server and Oracle (which has no counterpart in MySQL)? IIRC upsert in PG is different than in Mysql, MS or Oracle; is that the same here…
(Microsoft seems to have added a BY TARGET/BY SOURCE specification to the WHEN NOT MATCHED clause, which is not in the standard. Oracle seems to do DELETE in a different, nonstandard way.)
"Upsert" (which is called INSERT ON CONFLICT UPDATE in Postgres) is a different animal. It is not part of the SQL standard, which is why every database system does its own stuff.