Re: Arguments not being passed to a function

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Barry Lind <barry(at)xythos(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Arguments not being passed to a function
Date: 2000-05-28 15:18:15
Message-ID: 3049.959527095@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Barry Lind <barry(at)xythos(dot)com> writes:
> I am trying to call PL/pgSQL functions from JDBC via the Fastpath
> interface. The function is executing but none of the arguments to the
> function are getting set.

Looks like fastpath.c is passing a garbage isNull flag to the function
it calls :-(. None of the functions "usually" called this way pay
attention to isNull, but plpgsql functions sure do.

Turns out I had already fixed this for 7.1 as a side-effect of some
other work, but I will stick a patch into 7.0.1. If you're in a hurry,
the bug is in src/backend/tcop/fastpath.c, and the appropriate patch is

#ifndef NO_FASTPATH
+ isNull = false;
retval = fmgr_array_args(fid, nargs, arg, &isNull);
#else
retval = NULL;
#endif /* NO_FASTPATH */

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Bryan White 2000-05-28 15:23:13 Vacuum analyze vs just Vacuum
Previous Message Tom Lane 2000-05-28 15:07:18 Re: Questions about CURSORS