On Thu, Apr 29, 2021 at 03:01:29PM +0000, Edson Richter wrote: > Which postgresql logging parameters should I activate to log the “number of tuples returned” for a query? > I would like to debug some dynamicly generated queries in the system that are returning a absurd number of tuples (> 2,6mi of records).
You can load the auto_explain extension and set: auto_explain.log_analyze
And then the "rows" are logged: Result (cost=0.00..0.01 rows=1 width=4) (actual time=0.002..0.004 rows=1 loops=1)