Re: Declaring a field that is also an out parameter in a function

From: Adrian Klaver <adrian(dot)klaver(at)aklaver(dot)com>
To: Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, Michael Nolan <htfoot(at)gmail(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, "pgsql-general(at)postgresql(dot)org" <pgsql-general(at)postgresql(dot)org>
Subject: Re: Declaring a field that is also an out parameter in a function
Date: 2024-07-07 14:48:36
Message-ID: 3f8781c5-d625-4f24-b96d-56a45a0dd257@aklaver.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

On 7/7/24 07:42, Pavel Stehule wrote:
> I'm not sure why there's a warning about using an alias. 43.3.1 says
> to use them for improved readability.
>
>
> it is obsolete - aliases were used when Postgres doesn't support named
> arguments.

Is that was what it was complaining about or the fact they where
declared and never used?

>
> I  don't know any good reason why one variable can use more than one name.

Section 43.3.2. ALIAS provides the pros/cons.

>
> There can be an exception when argument names are very long, but
> generally they are not used.
>
>
>
> Mike Nolan
>

--
Adrian Klaver
adrian(dot)klaver(at)aklaver(dot)com

In response to

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Pavel Stehule 2024-07-07 14:53:24 Re: Declaring a field that is also an out parameter in a function
Previous Message David G. Johnston 2024-07-07 14:47:15 Re: Declaring a field that is also an out parameter in a function