I am using Postgres as my Database. I need to know whether I can extract all the queries that got executed with out logging them as logging all the queries will degrade the performance of database. So, provide a way I can get all the queries that got executed with out logging the queries.
|
If not logging the queries, there is no chance. However, if you are looking for some statistics to find e.g. queries which are executed very often and therefore an optimization could make sense: Checkout pg_stat_statment-extension |
|||||||||
|
You can try by capturing the traffic with tshark and some filters : https://www.wireshark.org/docs/dfref/p/pgsql.html It will not be very proper but should work. |
|||||||||
|