1

In pg_stat_statements output ("query" field):

SELECT * FROM users WHERE id = ?

How can I get the details of "?" from query in pg_stat_statements? Can anybody tell me about this, because I want to track if anyone execute some query. Can we also know which ip address this query execute from? so I can monitor if anyone make some modification data in database.

Thanks for the help.

bakekoq
  • 11
  • 2

1 Answers1

0

You can use pg_stat_monitor, it has that feature.

Ibrar Ahmed
  • 1,039
  • 1
  • 13
  • 25