public inbox for [email protected]  
help / color / mirror / Atom feed
Re: Declaring a field that is also an out parameter in a function
4+ messages / 2 participants
[nested] [flat]

* Re: Declaring a field that is also an out parameter in a function
@ 2024-07-07 14:48 Adrian Klaver <[email protected]>
  2024-07-07 14:53 ` Re: Declaring a field that is also an out parameter in a function Pavel Stehule <[email protected]>
  0 siblings, 1 reply; 4+ messages in thread

From: Adrian Klaver @ 2024-07-07 14:48 UTC (permalink / raw)
  To: Pavel Stehule <[email protected]>; Michael Nolan <[email protected]>; +Cc: Tom Lane <[email protected]>; 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
[email protected]







^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: Declaring a field that is also an out parameter in a function
  2024-07-07 14:48 Re: Declaring a field that is also an out parameter in a function Adrian Klaver <[email protected]>
@ 2024-07-07 14:53 ` Pavel Stehule <[email protected]>
  2024-07-07 15:00   ` Re: Declaring a field that is also an out parameter in a function Adrian Klaver <[email protected]>
  0 siblings, 1 reply; 4+ messages in thread

From: Pavel Stehule @ 2024-07-07 14:53 UTC (permalink / raw)
  To: Adrian Klaver <[email protected]>; +Cc: Michael Nolan <[email protected]>; Tom Lane <[email protected]>; pgsql-general

ne 7. 7. 2024 v 16:48 odesílatel Adrian Klaver <[email protected]>
napsal:

> 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 am not sure if I understand the question. My  reply was related to
generic usage of aliases.

Report from plpgsql_check was correct - and related variables were not
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
> [email protected]
>
>


^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: Declaring a field that is also an out parameter in a function
  2024-07-07 14:48 Re: Declaring a field that is also an out parameter in a function Adrian Klaver <[email protected]>
  2024-07-07 14:53 ` Re: Declaring a field that is also an out parameter in a function Pavel Stehule <[email protected]>
@ 2024-07-07 15:00   ` Adrian Klaver <[email protected]>
  2024-07-07 15:02     ` Re: Declaring a field that is also an out parameter in a function Pavel Stehule <[email protected]>
  0 siblings, 1 reply; 4+ messages in thread

From: Adrian Klaver @ 2024-07-07 15:00 UTC (permalink / raw)
  To: Pavel Stehule <[email protected]>; +Cc: Michael Nolan <[email protected]>; Tom Lane <[email protected]>; pgsql-general

On 7/7/24 07:53, Pavel Stehule wrote:
> 
> 
> ne 7. 7. 2024 v 16:48 odesílatel Adrian Klaver 
> <[email protected] <mailto:[email protected]>> napsal:
> 
>     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 am not sure if I understand the question. My  reply was related to 
> generic usage of aliases.

The conversation was:

Mike Nolan

"I'm not sure why there's a warning about using an alias. 43.3.1 says
to use them for improved readability."

Pavel Stehule

"it is obsolete - aliases were used when Postgres doesn't support named 
arguments."

I was just trying to confirm that the warning was not for ALIAS being 
declared. That it was for what you state below.


> 
> Report from plpgsql_check was correct - and related variables were not 
> 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
>     [email protected] <mailto:[email protected]>
> 

-- 
Adrian Klaver
[email protected]







^ permalink  raw  reply  [nested|flat] 4+ messages in thread

* Re: Declaring a field that is also an out parameter in a function
  2024-07-07 14:48 Re: Declaring a field that is also an out parameter in a function Adrian Klaver <[email protected]>
  2024-07-07 14:53 ` Re: Declaring a field that is also an out parameter in a function Pavel Stehule <[email protected]>
  2024-07-07 15:00   ` Re: Declaring a field that is also an out parameter in a function Adrian Klaver <[email protected]>
@ 2024-07-07 15:02     ` Pavel Stehule <[email protected]>
  0 siblings, 0 replies; 4+ messages in thread

From: Pavel Stehule @ 2024-07-07 15:02 UTC (permalink / raw)
  To: Adrian Klaver <[email protected]>; +Cc: Michael Nolan <[email protected]>; Tom Lane <[email protected]>; pgsql-general

ne 7. 7. 2024 v 17:00 odesílatel Adrian Klaver <[email protected]>
napsal:

> On 7/7/24 07:53, Pavel Stehule wrote:
> >
> >
> > ne 7. 7. 2024 v 16:48 odesílatel Adrian Klaver
> > <[email protected] <mailto:[email protected]>> napsal:
> >
> >     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 am not sure if I understand the question. My  reply was related to
> > generic usage of aliases.
>
> The conversation was:
>
> Mike Nolan
>
> "I'm not sure why there's a warning about using an alias. 43.3.1 says
> to use them for improved readability."
>
> Pavel Stehule
>
> "it is obsolete - aliases were used when Postgres doesn't support named
> arguments."
>
> I was just trying to confirm that the warning was not for ALIAS being
> declared. That it was for what you state below.
>
>
ok



>
> >
> > Report from plpgsql_check was correct - and related variables were not
> > 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
> >     [email protected] <mailto:[email protected]>
> >
>
> --
> Adrian Klaver
> [email protected]
>
>


^ permalink  raw  reply  [nested|flat] 4+ messages in thread


end of thread, other threads:[~2024-07-07 15:02 UTC | newest]

Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2024-07-07 14:48 Re: Declaring a field that is also an out parameter in a function Adrian Klaver <[email protected]>
2024-07-07 14:53 ` Pavel Stehule <[email protected]>
2024-07-07 15:00   ` Adrian Klaver <[email protected]>
2024-07-07 15:02     ` Pavel Stehule <[email protected]>

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox