deanrasheed · GitHub

Commits on Aug 21, 2026

  1. Allow EXCLUDED in RETURNING list of INSERT ON CONFLICT DO SELECT/UPDATE.

    This allows an INSERT ... ON CONFLICT DO SELECT/UPDATE command to
    return the excluded values, when conflicts occur. For rows that do not
    conflict, the excluded values returned are NULL.
    This builds on the infrastructure added to support OLD/NEW values in
    the RETURNING list, except that in the case of EXCLUDED, there is no
    need for the special syntax to change the name of the excluded
    pseudo-relation in the RETURNING list. (That was required for OLD/NEW,
    because those names were already used in some situations, such as
    trigger functions, but there is no such problem with excluded.)
    Discussion: https://postgr.es/m/CAEZATCXXu2ohYmn=4YrRQa9yNwD_fdEEOTBPgM_5jhQOFcaQ4g@mail.gmail.com

    authored and Commitfest Bot committed

    Aug 21, 2026
    Configuration menu

    Browse the repository at this point in the history

  2. Configuration menu

    Browse the repository at this point in the history

Read the original on github.com ↗