Skip to content

Commit 043e3e0

Browse files
committed
Use proper GetDatum function in pg_stat_get_slru().
This commit changes pg_stat_get_slru() so that it uses TimestampTzGetDatum() for stats_reset field because that field stores the timestamp with time zone value. Previously Int64GetDatum() was used. Author: Fujii Masao Reviewed-by: Tomas Vondra Discussion: https://postgr.es/m/b8784fe6-1401-ab35-aa14-d57b5bb8e312@oss.nttdata.com
1 parent f3d23d8 commit 043e3e0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/backend/utils/adt/pgstatfuncs.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1757,7 +1757,7 @@ pg_stat_get_slru(PG_FUNCTION_ARGS)
17571757
values[5] = Int64GetDatum(stat.blocks_exists);
17581758
values[6] = Int64GetDatum(stat.flush);
17591759
values[7] = Int64GetDatum(stat.truncate);
1760-
values[8] = Int64GetDatum(stat.stat_reset_timestamp);
1760+
values[8] = TimestampTzGetDatum(stat.stat_reset_timestamp);
17611761

17621762
tuplestore_putvalues(tupstore, tupdesc, values, nulls);
17631763
}

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy