Re: BUG #3725: plsql does not report unknown functions at compile time

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: "Roger" <ramoloney(at)hotmail(dot)com>
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: BUG #3725: plsql does not report unknown functions at compile time
Date: 2007-11-06 17:57:01
Message-ID: 23952.1194371821@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-bugs

"Roger" <ramoloney(at)hotmail(dot)com> writes:
> At compile time, plpgsql does not report unknown functions. For example, if
> I have a function.
> p_Func(a,b,c)
> and I have calls to it such as:
> p_Func(a)
> p_Func(a,b)
> these are not reported at compile time. They are only found at run time.

This isn't a bug, no matter how much you complain about it.

If we made plpgsql reject such cases, it would break a whole lot of
things --- for example it would become impossible to create a pair of
mutually recursive functions. Moreover, it's not hard to think of
cases where it's simply not possible to check when the function is
created, because you can't be certain what input datatypes will be
involved and so it's not clear which function is to be called.

regards, tom lane

In response to

Browse pgsql-bugs by date

  From Date Subject
Next Message Tom Lane 2007-11-06 18:06:30 Re: BUG #3724: Duplicate values added to table despite unique index
Previous Message Tom Lane 2007-11-06 17:52:34 Re: Test suite fails on alpha architecture