Received: from www.fr.netcentrex.net (unknown [62.161.167.249]) by postgresql.org (Postfix) with ESMTP id E50A9475C3F for ; Thu, 28 Feb 2002 09:44:28 -0500 (EST) Received: from TINTIN ([213.56.166.199]) by www.fr.netcentrex.net with SMTP (Microsoft Exchange Internet Mail Service Version 5.5.2653.13) id FT11G562; Thu, 28 Feb 2002 15:44:32 +0100 Message-ID: <0b7101c1c066$6ec1b3f0$c7a638d5@fr.netcentrex.net> Reply-To: =?iso-8859-1?Q?C=E9line_Rivi=E8re?= From: =?iso-8859-1?Q?C=E9line_Rivi=E8re?= To: Subject: Stored procedures returning TEXT Date: Thu, 28 Feb 2002 15:44:31 +0100 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_0B6E_01C1C06E.D076D9B0" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4133.2400 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4133.2400 X-Archive-Number: 200203/40 X-Sequence-Number: 6922 This is a multi-part message in MIME format. ------=_NextPart_000_0B6E_01C1C06E.D076D9B0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hello, In 1999, someone asked you about the following problem. I have exactly the same and couldn't solve it. Could you help me ? Thanks. C=E9line --------------------------------------------------------------------- Preinstalled postgresql-6.4.2 on Linux-Elf Who know how write function(language 'c') which return text type? I try #include "postgres.h" text test(text *t) { return(*t); } ... made test.so, create function test(text) returns text as 'path_to_test.so' language 'c' and finaly pgsql test=3D>select test('abc'); pqReadData() -- backend closed the channel unexpectedly. This probably means the backend terminated abnormally before or while processing the request. We have lost the connection to the backend, so further processing is impossible. Terminating. Anybody have some examples working text-type c-functions? Please send me if you have ------=_NextPart_000_0B6E_01C1C06E.D076D9B0 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Hello,
 
In 1999, someone asked you about the following problem. I have exactly= =20 the
same and couldn't solve it. Could you help me ?
 
Thanks.

C=E9line
 
---------------------------------------------------------------------<= /DIV>
 
Preinstalled postgresql-6.4.2 on=20 Linux-Elf
Who know how write function(language 'c') which return text=20 type?
I try
#include "postgres.h"

text test(text=20 *t)
{
return(*t);
}
...
made test.so,
create function=20 test(text) returns text as 'path_to_test.so' language
'c'
and=20 finaly
pgsql
test=3D>select test('abc');
pqReadData() -= -=20 backend closed the channel=20 unexpectedly.
        This probably m= eans=20 the backend terminated abnormally before or
while processing the=20 request.
We have lost the connection to the backend, so further processi= ng=20 is
impossible.  Terminating.
Anybody have some examples= =20 working text-type c-functions?
Please send me if you=20 have
------=_NextPart_000_0B6E_01C1C06E.D076D9B0--