From: | Bruce Momjian <bruce(at)momjian(dot)us> |
---|---|
To: | Bruce Momjian <bruce(at)momjian(dot)us> |
Cc: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: log_error_verbosity function display |
Date: | 2010-02-11 11:03:08 |
Message-ID: | 201002111103.o1BB38c24074@momjian.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Bruce Momjian wrote:
> Tom Lane wrote:
> > Bruce Momjian <bruce(at)momjian(dot)us> writes:
> > > Right now, log_error_verbosity displays the source code error location
> > > in this format:
> >
> > > LOCATION: parserOpenTable, parse_relation.c:858
> >
> > > I think it would be clearer to add '()' next to the function name. We
> > > use '() to display function names in our docs and I think using '()'
> > > would clarify the output, e.g.:
> >
> > > LOCATION: parserOpenTable(), parse_relation.c:858
> >
> > Seems like a waste of log space to me. The convention about writing ()
> > to decorate function names is hardly universal, and anyway it's mainly
> > useful to mark things that the reader might not realize are function
> > names. This can't be anything else.
>
> I suggested it because it wasn't obvious to me it was a function name,
> so I figured others might not recognize it. Remember, we deal with the
> C code all the time so we have to consider how the general user would
> see it.
FYI, here is the output that had me confused:
ERROR: 42P01: relation "lkjasdf" does not exist at character 15
LOCATION: parserOpenTable, parse_relation.c:858
STATEMENT: select * from lkjasdf;
Without the '()', I thought the LOCATION related to the query error
location, not the source code error location. This is what the new
format would look like, which I think is clearer:
ERROR: 42P01: relation "lkjasdf" does not exist at character 15
LOCATION: parserOpenTable(), parse_relation.c:858
STATEMENT: select * from lkjasdf;
Of course, maybe the word LOCATION is wrong and it should be FUNCTION:
ERROR: 42P01: relation "lkjasdf" does not exist at character 15
FUNCTION: parserOpenTable(), parse_relation.c:858
STATEMENT: select * from lkjasdf;
or SOURCE:
ERROR: 42P01: relation "lkjasdf" does not exist at character 15
SOURCE: parserOpenTable(), parse_relation.c:858
STATEMENT: select * from lkjasdf;
--
Bruce Momjian <bruce(at)momjian(dot)us> http://momjian.us
EnterpriseDB http://enterprisedb.com
+ If your life is a hard drive, Christ can be your backup. +
From | Date | Subject | |
---|---|---|---|
Next Message | Andres Freund | 2010-02-11 11:04:07 | Re: Re: [COMMITTERS] pgsql: Remove old-style VACUUM FULL (which was known for a little while |
Previous Message | Simon Riggs | 2010-02-11 10:37:37 | Re: Re: [COMMITTERS] pgsql: Make standby server continuously retry restoring the next WAL |