Is it harmful to update columns which aren't changed?

by Katrin   Last Updated September 25, 2018 21:06 PM

Say I have a table with some columns:

    key int PRIMARY KEY,
    c1  int,
    c2  text,
    c3  timestamptz

I now fetch a row from the table:

SELECT * FROM t WHERE id = 180;

In my application, I now only change the value of one column, let's say c2. Is it harmful performance-wise to do:

SET    t1 = <exact the same value as before>,
       t2 = <new value>,
       t3 = <exact the same value as before>
WHERE  key = 180;

instead of:

SET    t2 = <new value>
WHERE  key = 180;


Related Questions

find out postgresql query progress

Updated October 01, 2018 04:06 AM

Updating rows in a large table in sql server

Updated March 27, 2017 16:06 PM

Performance on updating row

Updated January 15, 2018 19:06 PM

Updating large table worked before, now taking hours

Updated February 27, 2016 01:02 AM