Type: integer
Default: 1024 (1kB)
Min: 100 (100B)
Max: 1048576 (1MB)
Unit: B
Context: postmaster
Restart: true

Specifies the amount of memory reserved to store the text of the currently executing command for each active session, for the pg_stat_activity.query field. If this value is specified without units, it is taken as bytes. The default value is 1024 bytes. This parameter can only be set at server start.

Recommendations

Sets the truncation threshold of queries in pg_stat_activity (and pg_stat_statements). Increase it if you have really long queries which are being cut off, but there is significant extra memory usage for keeping longer queries.

Comments