pg.ddx.io pgsql-sql@postgresql.org mailing list archive
help / color / mirror / Atom feedAntw: plpgsql function gets wierd with Null parameters
2+ messages / 2 participants
[nested] [flat]
* Antw: plpgsql function gets wierd with Null parameters
@ 2000-07-03 07:42 Gerhard Dieringer <DieringG@eba-haus.de>
2000-07-03 14:16 ` Re: Antw: plpgsql function gets wierd with Null parameters Tom Lane <tgl@sss.pgh.pa.us>
0 siblings, 1 reply; 2+ messages in thread
From: Gerhard Dieringer @ 2000-07-03 07:42 UTC (permalink / raw)
To: pgsql-sql; +Cc: " <Skeets and Kim Norquist" <norqu2@juno.com>
Skeets Norquist wrote:
> When I call the following plpgsql function with the last two parameters
> as Null, the first parameter loses it's value:
> ma=> select createFund('fred', null, null);
> ...
> However it works fine when I give values to the last two params:
> ma=> select createFund('fred', 'joe', 5);
> ...
It's a known bug of plpgsql that if one arg is NULL, all other args are also assumed to be NULL.
I think (hope) this will be fixed in a future version.
Gerhard
^ permalink raw reply [nested|flat] 2+ messages in thread
* Re: Antw: plpgsql function gets wierd with Null parameters
2000-07-03 07:42 Antw: plpgsql function gets wierd with Null parameters Gerhard Dieringer <DieringG@eba-haus.de>
@ 2000-07-03 14:16 ` Tom Lane <tgl@sss.pgh.pa.us>
0 siblings, 0 replies; 2+ messages in thread
From: Tom Lane @ 2000-07-03 14:16 UTC (permalink / raw)
To: Gerhard Dieringer <DieringG@eba-haus.de>; +Cc: pgsql-sql@postgresql.org, " <Skeets and Kim Norquist" <norqu2@juno.com>
"Gerhard Dieringer" <DieringG@eba-haus.de> writes:
> It's a known bug of plpgsql that if one arg is NULL, all other args
> are also assumed to be NULL. I think (hope) this will be fixed in a
> future version.
7.1. It is already fixed in current development sources.
BTW it's not actually plpgsql's fault, but that of the function-call
interface. The problem appears no matter what programming language
you write the function in.
regards, tom lane
^ permalink raw reply [nested|flat] 2+ messages in thread
end of thread, other threads:[~2000-07-03 14:16 UTC | newest]
Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2000-07-03 07:42 Antw: plpgsql function gets wierd with Null parameters Gerhard Dieringer <DieringG@eba-haus.de>
2000-07-03 14:16 ` Tom Lane <tgl@sss.pgh.pa.us>
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox