Alvaro Herrera wrote:
Tom Lane wrote:
Andrew Dunstan <[EMAIL PROTECTED]> writes:
Tom Lane wrote:
Well, if we want to cram all that stuff in there, how shall we do it?
It seems wrong to put all those lines into one text field, but I'm
not sure I want to add six more text fields to the CSV format
either.  Thoughts?
Really? Six? In any case, would that be so bad? It would mean six extra commas per line in the log file, and nothing much in the log table unless there were content in those fields.
Yeah --- the lines output in the plain-stderr case that are not covered
in the other are

        DETAIL
        HINT    
        QUERY           (this is an internally-generated query that failed)
        CONTEXT         (think "stack trace")
        LOCATION        (reference to code file/line reporting the error)
        STATEMENT       (user query that led to the error)

Here is a patch to do this.  It emits all of these as separate columns,
which are output empty if they are not present.  Of course, the commas
are emitted all the time.

Thanks. I will look at it in detail later today.

Not sure I understand what this comment I noticed on a very brief glance is about:

 /* assume no newlines in funcname or filename... */

If it's about what to quote, we need to quote anything that might contain a 
newline, quote or comma. Filenames certainly come into that category.

cheers

andrew




---------------------------(end of broadcast)---------------------------
TIP 3: Have you checked our extensive FAQ?

              http://www.postgresql.org/docs/faq

Reply via email to