These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 
Author Message
 Post subject: Slower and slower
PostPosted: Tue Nov 09, 2004 4:52 am 
Beginner
Beginner

Joined: Thu Jul 22, 2004 4:32 am
Posts: 31
Hi all:

There is 30,000 records in my database, and I use hibernate's paging strategy(setFirstResult() and setMaxResults()).
When I get first 10 records,It is fast. Or any 10 records in first 1000 records,It is also fast. But when I get 10 records in last 1000 records,It is very very slow, I don't know why?
who can tell me?

Any suggestion will be appreciate!

Hibernate version: 2.1
Database: MS SQL Server 2000
JDBC Driver: weblogic.jdbc.mssqlserver4.Driver
Web Server: Weblogic 8.1 SP3


Top
 Profile  
 
 Post subject:
PostPosted: Tue Nov 09, 2004 5:40 am 
Hibernate Team
Hibernate Team

Joined: Thu Dec 18, 2003 9:55 am
Posts: 1977
Location: France
if you are using a long session, clear it every page

_________________
Anthony,
Get value thanks to your skills: http://www.redhat.com/certification


Top
 Profile  
 
 Post subject:
PostPosted: Tue Nov 09, 2004 10:52 pm 
Beginner
Beginner

Joined: Thu Jul 22, 2004 4:32 am
Posts: 31
Thanks for your replay, but I don't have a long session,

ArrayList al = new ArrayList();
//add 10 records to list
al.add(....);
al.add(....);
................
session.setAttribute("al",al);


Top
 Profile  
 
 Post subject:
PostPosted: Sun Nov 14, 2004 10:21 pm 
Beginner
Beginner

Joined: Thu Jul 22, 2004 4:32 am
Posts: 31
Who could tell me?
Why?


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 4 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.