On Fri, Jan 13, 2017 at 7:24 PM, Peter Geoghegan <pg@heroku.com> wrote:
> MERGE isn't UPSERT, and isn't even in competition with UPSERT as a
> feature. I've written reams of text explaining why this is so in
> precise detail, ...
No matter how much text you write, I doubt that I will ever believe
that statement.
Leaving that aside, Serge is entirely right about the underlying
principle. We extend the standard all the time. The only policy we
have is that we try pretty hard not to adopt standard syntax with
non-standard semantics. If we pick our own semantics we pick our own
syntax, too, so as not to get in the way of later attempts to
implement the standard syntax with the standard semantics.
Of course, the other principle here is that the people who write the
code get a large share in deciding what ultimately happens. If
somebody submits an actual patch in this area, fine. If this is just
an argument about what would be better for someone else to implement,
it's mostly a waste of time. Anybody who does work in this area is
likely to have their own strong opinion on what should be implemented
- and they are likely to implement precisely that thing. That doesn't
guarantee acceptance, but it gets you further than bikeshedding from
the sidelines.
--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company