From: | Peter Eisentraut <peter(dot)eisentraut(at)2ndquadrant(dot)com> |
---|---|
To: | Robert Haas <robertmhaas(at)gmail(dot)com>, Haribabu Kommi <kommi(dot)haribabu(at)gmail(dot)com> |
Cc: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, Andres Freund <andres(at)anarazel(dot)de>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: New SQL counter statistics view (pg_stat_sql) |
Date: | 2016-09-21 15:25:14 |
Message-ID: | 4a0bc542-b718-a40c-27ed-551c83263dde@2ndquadrant.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On 9/14/16 4:01 PM, Robert Haas wrote:
> I think it is not a good idea to make the command names used here the
> plural forms of the command tags. Instead of "inserts", "updates",
> "imports", etc. just use "INSERT", "UPDATE", "IMPORT". That's simpler
> and less error prone - e.g. you won't end up with things like
> "refreshs", which is not a word.
How about having the tag not be a column name but a row entry. So you'd
do something like
SELECT * FROM pg_stat_sql WHERE tag = 'ALTER VIEW';
That way, we don't have to keep updating (and re-debating) this when new
command types or subtypes are added. And queries written for future
versions will not fail when run against old servers.
--
Peter Eisentraut http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Peter Eisentraut | 2016-09-21 15:29:21 | Re: Typo in pgstat.h |
Previous Message | Peter Eisentraut | 2016-09-21 15:20:10 | Re: [PATCH] get_home_path: use HOME |