Re: Extending error-location reports deeper into the system - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Extending error-location reports deeper into the system
Date
Msg-id 25870.1219605628@sss.pgh.pa.us
Whole thread Raw
In response to Re: Extending error-location reports deeper into the system  (Gregory Stark <stark@enterprisedb.com>)
List pgsql-hackers
Gregory Stark <stark@enterprisedb.com> writes:
> "Tom Lane" <tgl@sss.pgh.pa.us> writes:
>> If we didn't set the locations to unknown, then errors complaining about
>> problems arising within a rule would try to print pointers to locations in
>> the calling query's text having the same offsets as the problematic item had
>> in the original CREATE RULE or similar command. Not what we want.

> Just an idle thought... we could include the original source text with the
> rule as well. Though how easy it would be to use when we expand the rule is
> another question.

Then you'd need some way of keeping track of *which* query string
various nodes in the merged query tree were referencing.  I'm not
willing to go there, at least not in this pass at the problem.

> The original objection included caveats that there may be other sites that
> have uncertainty about whether to include the line number. Are you sure there
> aren't any?

Well, if there are, we'll find out when we actually try to do the work.
Right now, however, I feel confident that we don't want equality to
depend on syntactic position because it never has in the past.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [PATCHES] VACUUM Improvements - WIP Patch
Next
From: Stefan Kaltenbrunner
Date:
Subject: Re: What in the world is happening on spoonbill?