Re: Strange behavior of "=" as assignment operator

From: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Stephen Frost <sfrost(at)snowman(dot)net>, Moshe Jacobson <moshe(at)neadwerx(dot)com>, pgsql-general <pgsql-general(at)postgresql(dot)org>, Stephen Dolan <stephen(at)neadwerx(dot)com>
Subject: Re: Strange behavior of "=" as assignment operator
Date: 2013-06-01 05:50:53
Message-ID: CAFj8pRAbLJ7_NGgnQ5UFDBrQ36B8GbsVJn7PJapm=1xmEDagAw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

2013/6/1 Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>:
> Stephen Frost <sfrost(at)snowman(dot)net> writes:
>> * Moshe Jacobson (moshe(at)neadwerx(dot)com) wrote:
>>> Any PG committers who can change this in 9.3?
>
>> It will certainly not be changed for 9.3.
>
> IMO, if we do anything about this at all, it should be to document the
> "=" option not remove it. If we change it, the squawks from people who
> were (perhaps unintentionally) depending on the current behavior will
> outnumber the plaudits from people who think that such a change is a
> good idea by several orders of magnitude.

Moving from undocumented feature to documented feature is solution.
But I don't like it.

This is not only one use case. Then we should to document possibility
GET DIAGNOSTICS var := ident and some others. And this can be strong
problem for people who start on Postgres and would to use Oracle.

I don't propose remove this undocumented feature in next few cycles.
But if we will have integrated plpgsql_check_function, then we can
raise a warning 3 cycles, and then we can drop it. For almost all
cases we can provide simple migration tool.

similar issue is ELSIF and ELSEIF (although it is documented).

Regards

Pavel

>
> regards, tom lane
>
>
> --
> Sent via pgsql-general mailing list (pgsql-general(at)postgresql(dot)org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-general

In response to

Browse pgsql-general by date

  From Date Subject
Next Message David Johnston 2013-06-01 06:36:59 Re: Strange behavior of "=" as assignment operator
Previous Message Tom Lane 2013-06-01 05:18:57 Re: Strange behavior of "=" as assignment operator