pg_stat_statements vs. SELECT FOR UPDATE

From: Andrew Gierth <andrew(at)tao11(dot)riddles(dot)org(dot)uk>
To: pgsql-hackers(at)lists(dot)postgresql(dot)org
Subject: pg_stat_statements vs. SELECT FOR UPDATE
Date: 2019-01-19 14:43:10
Views: Raw Message | Whole Thread | Download mbox | Resend email
Lists: pgsql-hackers

pg_stat_statements considers a plain select and a select for update to
be equivalent, which seems quite wrong to me as they will have very
different performance characteristics due to locking.

The only comment about it in the code is:

/* we ignore rowMarks */

I propose that it should not ignore rowMarks, per the attached patch or
something similar.

(thanks to Vik Fearing for preliminary testing)

Andrew (irc:RhodiumToad)

Attachment Content-Type Size
pgss.patch text/x-patch 1.7 KB


Browse pgsql-hackers by date

  From Date Subject
Next Message Daniel Verite 2019-01-19 14:50:20 Re: Alternative to \copy in psql modelled after \g
Previous Message Andrew Gierth 2019-01-19 14:06:08 Re: Ryu floating point output patch