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

From Stephen Frost
Subject Re: Controlling changes in plpgsql variable resolution
Date
Msg-id 20091019145439.GI17756@tamriel.snowman.net
Whole thread Raw
In response to Controlling changes in plpgsql variable resolution  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Controlling changes in plpgsql variable resolution
Re: Controlling changes in plpgsql variable resolution
List pgsql-hackers
* Tom Lane (tgl@sss.pgh.pa.us) wrote:
> I think there are basically three behaviors that we could offer:
>
> 1. Resolve ambiguous names as plpgsql (historical PG behavior)
> 2. Resolve ambiguous names as query column (Oracle behavior)
> 3. Throw error if name is ambiguous (useful for finding problems)

4. Resolve ambiguous names as query column, but throw warning

#4 would be my vote, followed by #3.  To be perfectly honest, I'd be a
whole lot happier with a pl/pgsql that let me prefix variable names with
a '$' or similar to get away from this whole nonsense.  I've been very
tempted to tell everyone I work with to start prefixing their variables
names with '_' except that it ends up looking just plain ugly.
Thanks,
    Stephen

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Application name patch - v2
Next
From: Dave Page
Date:
Subject: Re: Application name patch - v2