GeeCON Prague 2014*
The moose likes JDBC and the fly likes Faster access of ResultSet rows?? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


JavaRanch » Java Forums » Databases » JDBC
Bookmark "Faster access of ResultSet rows??" Watch "Faster access of ResultSet rows??" New topic
Author

Faster access of ResultSet rows??

Sumanth R Prasad
Greenhorn

Joined: Aug 14, 2003
Posts: 6
Hi...
I have about 100000 records which is returned in a resultset through a query...
I have to scan each row and append the first field onto a file..
Right now, I'm doing this..

The Problem is that the process is taking about 6-7 minutes, which is way too long for my requirement...
Can anyone plz suggest a better (faster) solution ??
Jamie Robertson
Ranch Hand

Joined: Jul 09, 2001
Posts: 1879

a little more info might help.
Which database and which driver are you using? Is this just an SQL dump( no processing, just writing a resultset to a text file )?
Jamie
Adrian Yan
Ranch Hand

Joined: Oct 02, 2000
Posts: 688
Just out of curiosity, are you querying more than one field? Why just just do a script-based dump? SQL_COMMAND_LINE "select column from table" > result.txt?
 
GeeCON Prague 2014
 
subject: Faster access of ResultSet rows??