public inbox for [email protected]  
help / color / mirror / Atom feed
From: Shinoda, Noriyoshi (PN Japan FSIP) <[email protected]>
To: PostgreSQL-development <[email protected]>
Cc: [email protected] <[email protected]>
Cc: [email protected] <[email protected]>
Cc: [email protected] <[email protected]>
Cc: [email protected] <[email protected]>
Subject: [16Beta1][doc] pgstat: Track time of the last scan of a relation
Date: Wed, 31 May 2023 03:56:51 +0000
Message-ID: <DM4PR84MB17348EA11FA90A9BE896AF89EE489@DM4PR84MB1734.NAMPRD84.PROD.OUTLOOK.COM> (raw)

Hi, hackers.
 PostgreSQL 16 Beta1, added last access time to pg_stat_all_tables and pg_stat_all_indexes views by this patch [1].
According to the documentation [2], the data type of the columns added to these views is 'timestamptz'. 
However, columns of the same data type in pg_stat_all_tables.last_vacuum, last_analyze and other tables are unified to 'timestamp with time zone'. The attached patch changes the data type of the added column from timestamptz to timestamp with time zone.

[1] pgstat: Track time of the last scan of a relation
https://git.postgresql.org/gitweb/?p=postgresql.git;a=commit;h=c037471832e1ec3327f81eebbd8892e5c1042...
[2] pg_stat_activity view
https://www.postgresql.org/docs/16/monitoring-stats.html#MONITORING-PG-STAT-ALL-TABLES-VIEW

Regards,
Noriyoshi Shinoda


Attachments:

  [application/octet-stream] pg_stat_all_tables_doc_v1.diff (1.5K, ../DM4PR84MB17348EA11FA90A9BE896AF89EE489@DM4PR84MB1734.NAMPRD84.PROD.OUTLOOK.COM/2-pg_stat_all_tables_doc_v1.diff)
  download | inline diff:
diff --git a/doc/src/sgml/monitoring.sgml b/doc/src/sgml/monitoring.sgml
index 40ad419194..5cfdc70c03 100644
--- a/doc/src/sgml/monitoring.sgml
+++ b/doc/src/sgml/monitoring.sgml
@@ -4863,7 +4863,7 @@ SELECT pid, wait_event_type, wait_event FROM pg_stat_activity WHERE wait_event i
 
      <row>
       <entry role="catalog_table_entry"><para role="column_definition">
-       <structfield>last_seq_scan</structfield> <type>timestamptz</type>
+       <structfield>last_seq_scan</structfield> <type>timestamp with time zone</type>
       </para>
       <para>
        The time of the last sequential scan on this table, based on the
@@ -4891,7 +4891,7 @@ SELECT pid, wait_event_type, wait_event FROM pg_stat_activity WHERE wait_event i
 
      <row>
       <entry role="catalog_table_entry"><para role="column_definition">
-       <structfield>last_idx_scan</structfield> <type>timestamptz</type>
+       <structfield>last_idx_scan</structfield> <type>timestamp with time zone</type>
       </para>
       <para>
        The time of the last index scan on this table, based on the
@@ -5170,7 +5170,7 @@ SELECT pid, wait_event_type, wait_event FROM pg_stat_activity WHERE wait_event i
 
      <row>
       <entry role="catalog_table_entry"><para role="column_definition">
-       <structfield>last_idx_scan</structfield> <type>timestamptz</type>
+       <structfield>last_idx_scan</structfield> <type>timestamp with time zone</type>
       </para>
       <para>
        The time of the last scan on this index, based on the


view thread (5+ messages)  latest in thread

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: [email protected]
  Cc: [email protected], [email protected], [email protected], [email protected], [email protected]
  Subject: Re: [16Beta1][doc] pgstat: Track time of the last scan of a relation
  In-Reply-To: <DM4PR84MB17348EA11FA90A9BE896AF89EE489@DM4PR84MB1734.NAMPRD84.PROD.OUTLOOK.COM>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox