db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stanley Bradbury <Stan.Bradb...@gmail.com>
Subject Re: resultsets from stored procedures?
Date Sat, 29 Mar 2008 00:51:56 GMT
David Parker wrote:
> I would like to be able to create a java stored procedure that returns 
> a ResultSet. Ideally, I would be able to call this as a function from 
> within an SQL statement.
> The application requires that given a parent-child relationship where 
> a given row can have a chain of ancestors, we need to be able to get 
> all of the ancestor ids as a flat list, or row set. In Oracle I am 
> using a CONNECT BY for this operation. (Has anybody thought about 
> implementing that in Derby?).
> Any pointers to doc on how to return a resultset from a procedure 
> would be much appreciated, as would any comments, suggestions, 
> warnings, dire predictions, etc....
> Thanks.
> - DAP
> ===========================================
> David Parker
> david@smallsolid.com
> (401) 263-1782
I regularly refer to this article on the WIKI.  There is an example at 
the bottom that returns a resultSet


I don't know about returning a resultSet to a function but it can be 
done with a procedure. 

View raw message