Re: call stored function from ecpg w/cursor - Mailing list pgsql-novice

From Michael Fuhr
Subject Re: call stored function from ecpg w/cursor
Date
Msg-id 20070501140559.GA4094@winnie.fuhr.org
Whole thread Raw
In response to Re: call stored function from ecpg w/cursor  (Andrew Jarcho <ajarcho@nyc.rr.com>)
Responses Re: call stored function from ecpg w/cursor
Re: call stored function from ecpg w/cursor
List pgsql-novice
On Tue, May 01, 2007 at 03:03:58AM -0400, Andrew Jarcho wrote:
> Thank you for your continued help. A stripped down but fully
> (mal)functioning version of the code is attached. The error, according
> to the logfile ecpg_debug.log, occurs in the file callProcsViaC.pgc and
> is clearly marked there. A lot of the included code is just for
> completeness/reference.

The ms_getInvolvedInCase() function returns a composite type.
Instead of

  EXEC SQL DECLARE c_1 CURSOR FOR SELECT ms_getInvolvedInCase(:mstsCaseID);

try

  EXEC SQL DECLARE c_1 CURSOR FOR SELECT * FROM ms_getInvolvedInCase(:mstsCaseID);

--
Michael Fuhr

pgsql-novice by date:

Previous
From: Andrew Jarcho
Date:
Subject: Re: call stored function from ecpg w/cursor
Next
From: Andrew Jarcho
Date:
Subject: Re: call stored function from ecpg w/cursor