Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

callablestatement.getobject takes long time

 
Chinni Bujji
Ranch Hand
Posts: 60
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi All,

I have stored procedure and I am trying to call it using a callable statement
but the number of rows in the table are huge and it will constantly increase
right now the number of rows are 22894772

and my stored procedure at a time should get me 25 records
my question is when we callablestatement.getobject() will it get total records in the table thats why it is taking too long approximately 2 minutes
or will it get 25 records into the resultset

thanks in advance
 
Rob Spoor
Sheriff
Pie
Posts: 20667
65
Chrome Eclipse IDE Java Windows
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Moving to JDBC
 
Jeanne Boyarsky
author & internet detective
Marshal
Posts: 34973
379
Eclipse IDE Java VI Editor
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
It depends on your database driver so you'll have to try it. Why not pass the start/end index to your stored procedure and let it only return the 25 rows you need?
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic