Hello,
I am using Hibernate, so i have a Table users and a one-to-many that points to a Inbox Table.
The Problems is that it may happen that a User has 10000 messages in his Inbox.
How does Hibernate work. Does it load all the 10000 Messages into the User.messages List?
Wouldnt it be a memory problem when i have 20 Users with 10000 Messages each.
When i want to get the first 10 messages of a user, would it be better to go over "session.createQuery" with a LIMIT statement than over user.getMessages.iterator() ???
I hope you can help me understandin how Hibernate works, and help me with my lil problem. :P
Thank you
daniel
|