Re: Controlling changes in plpgsql variable resolution - Mailing list pgsql-hackers

From David E. Wheeler
Subject Re: Controlling changes in plpgsql variable resolution
Date
Msg-id A6D45BB3-3993-4DF8-A536-EC62464E06C6@kineticode.com
Whole thread Raw
In response to Re: Controlling changes in plpgsql variable resolution  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Controlling changes in plpgsql variable resolution
List pgsql-hackers
On Oct 19, 2009, at 12:05 PM, Tom Lane wrote:

>> What about adopting the modifier syntax you're adding to COPY?
>
> Where exactly would you put the modifier, and why is that better than
> the existing #option convention?

CREATE OR REPLACE FUNCTION foo()
RETURNS BOOLEAN
LANGUAGE plpgsql WITH opt1, opt2
AS $$...$$;

That is, the specification of options is made outside of the language  
in question. It might only effect a particular language (plpgsql in  
this case) and be ignored otherwise (or trigger an exception), but  
it's clean and very much like what you have elsewhere.

Best,

David


pgsql-hackers by date:

Previous
From: "Eric B. Ridge"
Date:
Subject: Re: Controlling changes in plpgsql variable resolution
Next
From: Tom Lane
Date:
Subject: Re: Controlling changes in plpgsql variable resolution