PG-306: The bucket start time should be timestamp instead of TEXT.
parent
a392c98b5c
commit
bc19c99c0b
|
@ -30,7 +30,7 @@ CREATE FUNCTION pg_stat_monitor_internal(
|
|||
OUT elevel int,
|
||||
OUT sqlcode TEXT,
|
||||
OUT message text,
|
||||
OUT bucket_start_time text,
|
||||
OUT bucket_start_time timestamp,
|
||||
|
||||
OUT calls int8, -- 16
|
||||
|
||||
|
|
|
@ -139,7 +139,7 @@ CREATE FUNCTION pg_stat_monitor_internal(
|
|||
OUT elevel int,
|
||||
OUT sqlcode TEXT,
|
||||
OUT message text,
|
||||
OUT bucket_start_time text,
|
||||
OUT bucket_start_time timestamp,
|
||||
|
||||
OUT calls int8, -- 16
|
||||
|
||||
|
@ -190,7 +190,7 @@ $$
|
|||
BEGIN
|
||||
CREATE VIEW pg_stat_monitor AS SELECT
|
||||
bucket,
|
||||
bucket_start_time AS bucket_start_time,
|
||||
bucket_start_time::text AS bucket_start_time,
|
||||
userid::regrole,
|
||||
datname,
|
||||
'0.0.0.0'::inet + client_ip AS client_ip,
|
||||
|
@ -247,7 +247,7 @@ $$
|
|||
BEGIN
|
||||
CREATE VIEW pg_stat_monitor AS SELECT
|
||||
bucket,
|
||||
bucket_start_time AS bucket_start_time,
|
||||
bucket_start_time::text AS bucket_start_time,
|
||||
userid::regrole,
|
||||
datname,
|
||||
'0.0.0.0'::inet + client_ip AS client_ip,
|
||||
|
@ -307,7 +307,7 @@ $$
|
|||
BEGIN
|
||||
CREATE VIEW pg_stat_monitor AS SELECT
|
||||
bucket,
|
||||
bucket_start_time AS bucket_start_time,
|
||||
bucket_start_time::text AS bucket_start_time,
|
||||
userid::regrole,
|
||||
datname,
|
||||
'0.0.0.0'::inet + client_ip AS client_ip,
|
||||
|
|
|
@ -126,7 +126,7 @@ CREATE FUNCTION pg_stat_monitor_internal(
|
|||
OUT elevel int,
|
||||
OUT sqlcode TEXT,
|
||||
OUT message text,
|
||||
OUT bucket_start_time text,
|
||||
OUT bucket_start_time timestamp,
|
||||
|
||||
OUT calls int8, -- 16
|
||||
|
||||
|
|
|
@ -1845,7 +1845,7 @@ pg_stat_monitor_internal(FunctionCallInfo fcinfo,
|
|||
values[i++] = CStringGetTextDatum(tmp.error.message);
|
||||
|
||||
/* bucket_start_time at column number 15 */
|
||||
values[i++] = CStringGetTextDatum(pgss->bucket_start_time[entry->key.bucket_id]);
|
||||
values[i++] = CStringGetDatum(pgss->bucket_start_time[entry->key.bucket_id]);
|
||||
if (tmp.calls.calls == 0)
|
||||
{
|
||||
/* Query of pg_stat_monitor itslef started from zero count */
|
||||
|
|
Loading…
Reference in New Issue