Received: from makus.postgresql.org (makus.postgresql.org [98.129.198.125]) by mail.postgresql.org (Postfix) with ESMTP id 2257B19BA3A5 for ; Thu, 31 May 2012 02:06:49 -0300 (ADT) Received: from sss.pgh.pa.us ([66.207.139.130]) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1SZxay-0006dV-3s for pgsql-general@postgresql.org; Thu, 31 May 2012 05:06:48 +0000 Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id q4V56ZWq028336; Thu, 31 May 2012 01:06:35 -0400 (EDT) To: Evan Rempel cc: "pgsql-general@postgresql.org" Subject: Re: Change request - log line prefix In-reply-to: References: <4F8B6AA1.1040709@zvelo.com> <20120416065717.70a31a6361ac5d7bdad416e8@frank.uvena.de> <4F8BD91C.6070405@zvelo.com> <4F8BDAB2.7010209@frank.uvena.de> <4F8C248E.7070307@zvelo.com> <4F8CC11A.5020003@d2.com> <4F8CDB95.3040407@zvelo.com> , <4F8E04D9.6010402@zvelo.com> Comments: In-reply-to Evan Rempel message dated "Wed, 30 May 2012 21:05:23 -0700" Date: Thu, 31 May 2012 01:06:35 -0400 Message-ID: <28335.1338440795@sss.pgh.pa.us> From: Tom Lane X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201205/734 X-Sequence-Number: 187751 Evan Rempel writes: > Even when the wrap column is set to a very large value (32k) STATEMENT lines still wrap according to the line breaks in > the original SQL statement. > Wrapped line no longer have the prefix - difficult to grep the log for everything pertaining to a particular database or user > Wrapped lines no longer have the log line status - difficult to auto-ignore all NOTICE status log lines when they wrap, or > ignore all user STATEMENT lines because they almost always wrap. I think your life would be better if you used CSV log format. > In conclusion, I would like to see a logging change that included the prefix on EVERY line, and included the STATUS on every line. This doesn't really sound like an improvement to me. It's going to make the logs bulkier, but they're still not automatically parseable in any meaningful sense. CSV is the way to go if you want machine-readable logs. regards, tom lane