Skip site navigation (1) Skip section navigation (2)

Re: c-function returning multiple rows

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: alexey(at)price(dot)ru
Cc: pgsql-bugs(at)postgresql(dot)org
Subject: Re: c-function returning multiple rows
Date: 2001-04-26 14:55:40
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-bugspgsql-interfaces
Alexey Nalbat <alexey(at)price(dot)ru> writes:
> I digged into sources and supposed that line 61 in fmgr.h might be
> 'struct ReturnSetInfo *resultinfo;' instead of 'struct Node
> *resultinfo;'. But I'm not sure if it is correct.

No, it isn't.  fmgr.h is correct as given, because the resultinfo
field might point at various different kinds of Nodes.  You need to
do an IsA test and then a cast, instead.  See the code in
src/backend/executor/functions.c for an example.

			regards, tom lane

In response to


pgsql-bugs by date

Next:From: pgsql-bugsDate: 2001-04-26 17:20:13
Subject: Cannot unzip binary tar.gz file for IRIX 6.5.7I
Previous:From: Peter EisentrautDate: 2001-04-26 14:49:10
Subject: Re: Startup Problems on Win2K

pgsql-interfaces by date

Next:From: Alex PilosovDate: 2001-04-26 15:25:43
Subject: Re: can external C-function get multiple rows?
Previous:From: Tom LaneDate: 2001-04-26 14:41:21
Subject: Re: can external C-function get multiple rows?

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group