Tom Lane wrote:
> Dmitry Fomichev <[EMAIL PROTECTED]> writes:
> > I am running 7.2b3 and trying to make something like this work (new
> > refcursor stuff):
>
> > CREATE TABLE t (c text);
>
> > CREATE FUNCTION errtest(refcursor, text) RETURNS refcursor AS '
> > BEGIN
> >         OPEN $1 FOR SELECT c FROM t WHERE c=$2;
> >         RETURN $1;
> > END;
> > ' LANGUAGE 'plpgsql';
>
> > INSERT INTO t VALUES ('123');
>
> > BEGIN;
> > SELECT errtest('rs', '123');
> > FETCH ALL IN rs;
> > COMMIT;
>
> > I am getting this error after FETCH ALL....
>
> > psql:errtest.sql:15: ERROR:  MemoryContextAlloc: invalid request size
> > 2139062147
>
> Nasty.  It looks like SPI_cursor_open needs to be careful to copy
> by-reference parameter values into the memory context created for
> the cursor portal.  Will fix.

    It doesn't do? Blame it on me. Thanks.


Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me.                                  #
#================================================== [EMAIL PROTECTED] #



_________________________________________________________
Do You Yahoo!?
Get your free @yahoo.com address at http://mail.yahoo.com


---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

http://archives.postgresql.org

Reply via email to