Re: [GENERAL] Calling V1 function from within the server

2006-05-02 Thread Don Y
Martijn van Oosterhout wrote: On Tue, May 02, 2006 at 11:24:34AM -0700, Don Y wrote: Hi, If I define: Datum barcode_checksum(PG_FUNCTION_ARGS) PG_FUNCTION_INFO_V1(barcode_checksum) and now want to *use* that function within some other (related) function, how can I invoke it? The intuiti

Re: [GENERAL] Calling V1 function from within the server

2006-05-02 Thread Martijn van Oosterhout
On Tue, May 02, 2006 at 11:24:34AM -0700, Don Y wrote: > Hi, > > If I define: > > Datum barcode_checksum(PG_FUNCTION_ARGS) > > PG_FUNCTION_INFO_V1(barcode_checksum) > and now want to *use* that function within some other > (related) function, how can I invoke it? The intuitive You want Dire

[GENERAL] Calling V1 function from within the server

2006-05-02 Thread Don Y
Hi, If I define: Datum barcode_checksum(PG_FUNCTION_ARGS) PG_FUNCTION_INFO_V1(barcode_checksum) Datum barcode_checksum(PG_FUNCTION_ARGS) { barcode value; short result; label = (barcode) PG_GETARG_INT32(0); // compute barcode PG_RETURN_INT16(result); } and now want to *use* that f