Re: Add value to error message when size extends - Mailing list pgsql-hackers

From Marti Raudsepp
Subject Re: Add value to error message when size extends
Date
Msg-id CABRT9RCSnfYS4mcM0qLif=r6aRyrDe+H8-38RCaA=hdbcJeKTA@mail.gmail.com
Whole thread Raw
In response to Re: Add value to error message when size extends  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Add value to error message when size extends  (Tom Lane <tgl@sss.pgh.pa.us>)
Re: Add value to error message when size extends  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On Sun, Jan 19, 2014 at 8:10 PM, Tom Lane <tgl@sss.pgh.pa.us> wrote:
> Complaining about a too-long varchar string in this style
> seems practically guaranteed to violate that.

Agreed. But I think it would be useful to add the length of the string
being inserted; we already have it in the len variable.

> One thing that occurs to me just now is that perhaps we could report
> the failure as if it were a syntax error

That would be cool, if it can be made to work.

Regards,
Marti



pgsql-hackers by date:

Previous
From: David Rowley
Date:
Subject: Re: [PATCH] Negative Transition Aggregate Functions (WIP)
Next
From: Tom Lane
Date:
Subject: Re: Add value to error message when size extends