Logger into table and/or to cli

Started by Thiemo Kellnerabout 10 years ago4 messagesgeneral
Jump to latest
#1Thiemo Kellner
thiemo@gelassene-pferde.biz

Hi all

I would like to log from within pgsql into table and/or to command
line, something like https://sourceforge.net/projects/plnsqllogger/ .
Does anybody know of an open source solution available?

Kind regards

Thiemo

--
Auf Gelassene Pferde kann man bauen!
+49 (0)1578-772 37 37
+41 (0)78 947 36 21
sip: thiemo.kellner@iptel.org
http://www.gelassene-pferde.biz
Mitglied bei http://www.keep-it-natural.org
Öffentlicher PGP-Schlüssel:
http://pgp.mit.edu/pks/lookup?op=get&search=0x8F70EFD2D972CBEF

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

#2Berend Tober
btober@computer.org
In reply to: Thiemo Kellner (#1)
Re: Logger into table and/or to cli

Thiemo Kellner, NHC Barhufpflege wrote:

I would like to log from within pgsql into table and/or to command line, something like
https://sourceforge.net/projects/plnsqllogger/ . Does anybody know of an open source solution
available?

I like "18.8.4. Using CSV-Format Log Output", although it does not log directly to a data base
table. Rather, it produces comma-separated-value text files that you can easily copy into a data
base table for analysis or other purposes.

See the manual at

http://www.postgresql.org/docs/9.5/static/runtime-config-logging.html

--
Sent via pgsql-general mailing list (pgsql-general@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-general

#3Thiemo Kellner, NHC Barhufpflege
thiemo.kellner@gelassene-pferde.biz
In reply to: Berend Tober (#2)
Re: Logger into table and/or to cli

If I have understood correctly, the application logging would polute
the server log with that solution. And it looks rather clumsy to me to
import the log file into a table. Much more it would require to ignore
somehow already imported log entries not to get multiple entries when
the import shall take place at any arbitrary point in time.

Zitat von Berend Tober <btober@computer.org>:

Thiemo Kellner, NHC Barhufpflege wrote:

I would like to log from within pgsql into table and/or to command
line, something like
https://sourceforge.net/projects/plnsqllogger/ . Does anybody know
of an open source solution
available?

I like "18.8.4. Using CSV-Format Log Output", although it does not
log directly to a data base table. Rather, it produces
comma-separated-value text files that you can easily copy into a
data base table for analysis or other purposes.

See the manual at

http://www.postgresql.org/docs/9.5/static/runtime-config-logging.html

--
Auf Gelassene Pferde kann man bauen!
+49 (0)1578-772 37 37 (Mo, Di)
+41 (0)78 947 36 21 (Mi - Fr)
Skype: thiemo.kellner
http://www.gelassene-pferde.biz
Mitglied bei http://www.keep-it-natural.org
Öffentlicher PGP-Schlüssel:
http://pgp.mit.edu/pks/lookup?op=get&amp;search=0x8F70EFD2D972CBEF

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

#4Thiemo Kellner
thiemo@gelassene-pferde.biz
In reply to: Berend Tober (#2)
Re: Logger into table and/or to cli

Thanks for your hint. If I have understood correctly, the application
logging would polute the server log with that solution. And it looks
rather clumsy to me to import the log file into a table. Much more it
would require to ignore somehow already imported log entries not to
get multiple entries when the import shall take place at any arbitrary
point in time.

Zitat von Berend Tober <btober@computer.org>:

Thiemo Kellner, NHC Barhufpflege wrote:

I would like to log from within pgsql into table and/or to command
line, something like
https://sourceforge.net/projects/plnsqllogger/ . Does anybody know
of an open source solution
available?

I like "18.8.4. Using CSV-Format Log Output", although it does not
log directly to a data base table. Rather, it produces
comma-separated-value text files that you can easily copy into a
data base table for analysis or other purposes.

See the manual at

http://www.postgresql.org/docs/9.5/static/runtime-config-logging.html

--
Auf Gelassene Pferde kann man bauen!
+49 (0)1578-772 37 37
+41 (0)78 947 36 21
sip: thiemo.kellner@iptel.org
http://www.gelassene-pferde.biz
Mitglied bei http://www.keep-it-natural.org
Öffentlicher PGP-Schlüssel:
http://pgp.mit.edu/pks/lookup?op=get&amp;search=0x8F70EFD2D972CBEF

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.