Show full text of running queries in PostgreSQL
postgresql, sql
Solution
There is a line in file postgresql.conf:
track_activity_query_size = 1024
After increasing this variable you will get more characters. Tested on postgresql 9.1. Changing above line requires restarting server.
Problem
I want to see the full text of running queries in PostgreSQL. When I run this command `SELECT procpid,current_query FROM pg_stat_activity ORDER BY procpid;` in dbshell it shows running queries, but for long queries, it does not show complete query. For example, if a query has a long text, it does not show the complete text of the query, it only shows 1024 characters of the query and not more. I want to know is there any way to show the complete query?