From: | "Steve Moyle" <steve(dot)moyle(at)comlab(dot)ox(dot)ac(dot)uk> |
---|---|
To: | <pgsql-general(at)postgresql(dot)org> |
Subject: | Logging 'rows returned' |
Date: | 2004-03-23 16:08:17 |
Message-ID: | 7AD21E1CF02B334AA47460F0D6A7DCD80F152C@chester.nuff.ox.ac.uk |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-general |
Dear All,
Is it possible to have the number of 'rows returned' (or 'rows
effected') in the logging information? If so, what settings do I need
in postgresql.conf?
E.g. I would like something like:
Mar 23 16:00:05 bandicoot postgres[30294]: [21] LOG: query: select *
from encoding;
=> Mar 23 16:00:05 bandicoot postgres[30294]: [21] LOG: __3 rows__
I have tried to turn on the query planner logging in the hope that the
information would be contained in the logs, but am confused with the
settings required for the planner to emit to the logs.
Here is what my relevant section of the postgresql.conf
# -- begin postgresql.conf --
syslog = 2 # range 0-2
syslog_facility = 'LOCAL6' # must match postgres logging entry in
/etc/syslog.conf
syslog_ident = 'postgres'
silent_mode = false
log_connections = true
log_timestamp = true
log_pid = true
log_statement = true
log_duration = true
log_min_error_statement = debug1
log_source_port = true
log_hostname = true
log_statement_stats = true
show_query_stats = true
debug_print_parse = true
debug_print_rewritten = true
debug_print_plan = true
debug_pretty_print = true
log_min_messages = debug1
server_min_messages = debug1
client_min_messages = debug1
log_error_verbosity = verbose
# -- end postgresql.conf --
(You might notice I have turned lots of stuff on -- this is done in
panic ;-) to try and get row counts out).
Any help appreciated.
Dr Steve Moyle
Research Officer
Oxford University Computing Laboratory
Wolfson Building
Parks Road
Oxford
OX1 3QD
ENGLAND
Telephone: +44 (0) 780 1749 587
Fax: +44 (0) 1865 273 839
Email: steve(dot)moyle(at)comlab(dot)ox(dot)ac(dot)uk
From | Date | Subject | |
---|---|---|---|
Next Message | Sailesh Krishnamurthy | 2004-03-23 16:39:21 | Re: linked list rewrite |
Previous Message | Guy Fraser | 2004-03-23 16:00:58 | Re: PHP or JSP? That is the question. |