| Author |
Best practice to access large data from database
|
Bob Moor
Greenhorn
Joined: May 24, 2010
Posts: 6
|
|
Dear Friends,
I have requirement to fetch 5 Million records from Oracle db and display using JAVA and JSP. Each record is 1 KB size.
The database table is online table used to store the transaction details, the rows will keep increasing. I am not allowed to use stored procedures also.
1) Fetching 5 Million record and displaying in 1 attempt is not feasible as JDBC has limitation and also the User has to wait too long to see the data.
I am thinking of processing the records in subset, for example.. Display first 10000 records then if the users wants next 10000 records fetch and display the next 10000 record.
Are there any other best practices to implement the above requiremen? Please suggest..
Thanks in advance ,
Bob
|
 |
Jan Cumps
Bartender
Joined: Dec 20, 2006
Posts: 2350
|
|
"tec tech", please check your private messages for a JavaRanch administrative matter.
Welcome to JavaRanch.
You can check our FAQs on Pagination, or read our Journal on the subject.
Regards, Jan
|
OCUP UML fundamental
ITIL foundation
|
 |
Bob Moor
Greenhorn
Joined: May 24, 2010
Posts: 6
|
|
Dear Jan,
Thanks for your response. All the example are using rownum. My table rows increase every second hence I dont think I can use rownum.
rowid should solve the problem but I dont know to build query with rowid. any suggestions?
|
 |
Christophe Verré
Sheriff
Joined: Nov 24, 2005
Posts: 14685
|
|
tec tech wrote:any suggestions?
Please check your private messages first.
|
[My Blog]
All roads lead to JavaRanch
|
 |
 |
|
|
subject: Best practice to access large data from database
|
|
|