Re: SPI_exec doesn't return proc context (on 9.1) - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: SPI_exec doesn't return proc context (on 9.1)
Date
Msg-id 1297376539-sup-8672@alvh.no-ip.org
Whole thread Raw
In response to Re: SPI_exec doesn't return proc context (on 9.1)  (Pavel Stehule <pavel.stehule@gmail.com>)
Responses Re: SPI_exec doesn't return proc context (on 9.1)  (Tom Lane <tgl@sss.pgh.pa.us>)
List pgsql-hackers
Excerpts from Pavel Stehule's message of sáb ene 29 16:56:40 -0300 2011:
> 2011/1/29 Tom Lane <tgl@sss.pgh.pa.us>:

> > The less crocky way to do that is to use SPI_palloc() for something that
> > should be allocated in the outer context.
> 
> I understand. Is there some way, where I can use a cstring_to_text
> function? There isn't simple way to get a saveCtx.
> 
> some like SPI_copyDatum ... ?

I wrote such a patch some time ago but never applied it ...
http://archives.postgresql.org/message-id/20091116162531.GA3669@alvh.no-ip.org
I still wonder if it's useful enough to be applied.  Would it solve your
use case?

-- 
Álvaro Herrera <alvherre@commandprompt.com>
The PostgreSQL Company - Command Prompt, Inc.
PostgreSQL Replication, Consulting, Custom Development, 24x7 support


pgsql-hackers by date:

Previous
From: David Fetter
Date:
Subject: Re: [COMMITTERS] pgsql: Remove more SGML tabs.
Next
From: "Joshua D. Drake"
Date:
Subject: Debian readline/libedit breakage