Re: Order of Operations for Update Command - Mailing list pgsql-docs

From Tom Lane
Subject Re: Order of Operations for Update Command
Date
Msg-id 13643.1472142781@sss.pgh.pa.us
Whole thread Raw
In response to Order of Operations for Update Command  (simonwhite@dciphercomputing.com)
List pgsql-docs
simonwhite@dciphercomputing.com writes:
> Does the Update command update the columns in the order they are listed?

Notionally, they're all done concurrently.  This is embodied in our
docs by defining the update source expressions thus:

    An expression to assign to the column. The expression can use the
    old values of this and other columns in the table.

> Can an updated column's new value be used in the value calculation for a
> subsequent column?

No, see above.

            regards, tom lane


pgsql-docs by date:

Previous
From: simonwhite@dciphercomputing.com
Date:
Subject: Order of Operations for Update Command
Next
From: jens.timmerman@gmail.com
Date:
Subject: does md5 really help against sniffing?