Re: C function question - Mailing list pgsql-general

From Tom Lane
Subject Re: C function question
Date
Msg-id 15007.1233695021@sss.pgh.pa.us
Whole thread Raw
In response to Re: C function question  (Alvaro Herrera <alvherre@alvh.no-ip.org>)
Responses Re: C function question
List pgsql-general
Alvaro Herrera <alvherre@alvh.no-ip.org> writes:
> Grzegorz Jaśkiewicz wrote:
>> for whatever reason, taht doesn't return the real char that was passed in.

> Yeah ... try DatumGetBpCharP instead.  PG_GETARG_CHAR is for type "char"
> with quotes, which is a completely different thing.

Or maybe the C code does just what he wants, and the problem is that he
needs to declare the function correctly at the SQL level (ie, with
second argument "char" not char(1)).

            regards, tom lane

pgsql-general by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: C function question
Next
From: Tom Lane
Date:
Subject: Re: Fastest way to drop an index?