pg.ddx.io  pgsql-jdbc@postgresql.org mailing list archive  
help / color / mirror / Atom feed
I can't retrieve a scrollable ResultSet from CallableStatement
2+ messages / 2 participants
[nested] [flat]

* I can't retrieve a scrollable ResultSet from CallableStatement
@ 2006-08-21 08:06 student23 <student23@o2.pl>
  2006-08-29 16:19 ` Re: I can't retrieve a scrollable ResultSet fr Kris Jurka <books@ejurka.com>
  0 siblings, 1 reply; 2+ messages in thread

From: student23 @ 2006-08-21 08:06 UTC (permalink / raw)
  To: pgsql-jdbc

Hi,

I'm using posgresql 7.4 and I'm trying to receive a scrollable and updatable ResulSet with jdbc. But when I when I check the type of the ResultSet I've retrieved its always FORWARD_ONLY. I use jdbc3 driver.

the code:

       CallableStatement call = con.prepareCall("{ ? = call getRefcursor () }", ResultSet.TYPE_SCROLL_INSENSITIVE, ResultSet.CONCUR_UPDATABLE);

        call.registerOutParameter(1, Types.OTHER);
        call.execute();
        ResultSet rs = (ResultSet) call.getObject(1);

        rs.last();   //this line throws the Exception
 
What do I need to do, to make it work!



^ permalink  raw  reply  [nested|flat] 2+ messages in thread

* Re: I can't retrieve a scrollable ResultSet fr
  2006-08-21 08:06 I can't retrieve a scrollable ResultSet from CallableStatement student23 <student23@o2.pl>
@ 2006-08-29 16:19 ` Kris Jurka <books@ejurka.com>
  0 siblings, 0 replies; 2+ messages in thread

From: Kris Jurka @ 2006-08-29 16:19 UTC (permalink / raw)
  To: student23 <student23@o2.pl>; +Cc: pgsql-jdbc



On Mon, 21 Aug 2006, student23 wrote:

> I'm using posgresql 7.4 and I'm trying to receive a scrollable and 
> updatable ResulSet with jdbc. But when I when I check the type of the 
> ResultSet I've retrieved its always FORWARD_ONLY. I use jdbc3 driver.
>
> What do I need to do, to make it work!
>

I recently committed a fix to CVS for 8.0, 8.1 and HEAD branches to make 
these ResultSets scrollable, so you will need to build a new jar file from 
CVS.  These ResultSets cannot be updatable because the server does not 
support updatable cursors.

Kris Jurka




^ permalink  raw  reply  [nested|flat] 2+ messages in thread


end of thread, other threads:[~2006-08-29 16:19 UTC | newest]

Thread overview: 2+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2006-08-21 08:06 I can't retrieve a scrollable ResultSet from CallableStatement student23 <student23@o2.pl>
2006-08-29 16:19 ` Re: I can't retrieve a scrollable ResultSet fr Kris Jurka <books@ejurka.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox