Re: [GENERAL] C Language Stored Procedure Returning No Data

2006-02-03 Thread Michael Fuhr
On Fri, Feb 03, 2006 at 09:07:48AM -0500, Jeff Trout wrote: > On Feb 2, 2006, at 7:17 PM, Michael Fuhr wrote: > >If you declare the function with "RETURNS bytea" then the function > >must return something; if zero-length data and NULL aren't suitable > >for indicating no data then you could raise a

Re: [GENERAL] C Language Stored Procedure Returning No Data

2006-02-03 Thread Jeff Trout
On Feb 2, 2006, at 7:17 PM, Michael Fuhr wrote: On Wed, Feb 01, 2006 at 12:56:30PM -0500, [EMAIL PROTECTED] wrote: From a C stored procedure, how can I tell Postgres to pass on to the Java client that there is No Data? A zero length byte array or a null value is not the same as No Data. If y

Re: [GENERAL] C Language Stored Procedure Returning No Data

2006-02-02 Thread Michael Fuhr
On Wed, Feb 01, 2006 at 12:56:30PM -0500, [EMAIL PROTECTED] wrote: > From a C stored procedure, how can I tell Postgres to pass on to > the Java client that there is No Data? A zero length byte array or > a null value is not the same as No Data. If you declare the function with "RETURNS bytea" the

[GENERAL] C Language Stored Procedure Returning No Data

2006-02-02 Thread bfraci
  We have a Java client that is using JDBC to communicate with the Postgres database. We have a stored procedure, foo, that is written in C which returns a byte array (bytea) to the Java client. This function takes in a couple of integers and based upon their values can return a byte array or no da