mirror of
https://github.com/percona/pg_stat_monitor.git
synced 2026-02-04 22:16:20 +00:00
PG-150: Logging CMD Type like SELECT, UPDATE, INSERT, DELETE.
This commit is contained in:
@@ -99,8 +99,12 @@ CREATE VIEW pg_stat_monitor AS SELECT
|
||||
queryid,
|
||||
query,
|
||||
application_name,
|
||||
(string_to_array(relations, ',')) relations,
|
||||
(string_to_array(cmd_type, ',')) cmd_type,
|
||||
(string_to_array(relations, ',')) AS relations,
|
||||
CASE
|
||||
WHEN query like 'BEGIN' THEN ''
|
||||
WHEN query like 'END' THEN ''
|
||||
ELSE (string_to_array(cmd_type, ','))[1]
|
||||
END AS cmd_type,
|
||||
elevel,
|
||||
sqlcode,
|
||||
message,
|
||||
|
||||
Reference in New Issue
Block a user