Re: Syntax decisions for pl/pgsql RAISE extension - Mailing list pgsql-hackers

From Decibel!
Subject Re: Syntax decisions for pl/pgsql RAISE extension
Date
Msg-id 9153FDE9-FF2F-4898-976E-F4E206281762@decibel.org
Whole thread Raw
In response to Syntax decisions for pl/pgsql RAISE extension  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
On May 12, 2008, at 11:53 AM, Tom Lane wrote:
> 3. I think we should allow the user to specify the error message the
> same way as the other options, that is
>     RAISE level USING MESSAGE = string_expression [ , ... ]
> The %-format business has always struck me as a bit weird, and it's
> much more so if we aren't handling the other error report components
> in the same fashion.  So we ought to provide an alternative that's
> more uniform.


I'm entirely in favor of allowing string expressions; that's always  
been a huge shortcoming in RAISE.

I'm entirely opposed to getting rid of % substitution. It's  
incredibly useful; I have it in probably 80% of my RAISE statements.  
It encourages providing more detailed error messages, which is a Good  
Thing.
-- 
Decibel!, aka Jim C. Nasby, Database Architect  decibel@decibel.org
Give your computer some brain candy! www.distributed.net Team #1828



pgsql-hackers by date:

Previous
From: Andrew Dunstan
Date:
Subject: Re: odd output in restore mode
Next
From: Alvaro Herrera
Date:
Subject: Re: psql wrapped format default for backslash-d commands