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.  [ 3 posts ] 
Author Message
 Post subject: reading a colelction leads to UPDATEs
PostPosted: Tue Apr 22, 2008 11:17 pm 
Newbie

Joined: Tue Apr 22, 2008 11:14 pm
Posts: 3
I have a list of employees (1560 to be exact).
I iterate through the list of Employees in my web-application and then in the log fiel I see that Hibernate issues UPDATE statements to database on Employees! But the epmloyees did not change - I was just reading the collection and outputing the values to a web-page

Do I understand smth wrong?


Top
 Profile  
 
 Post subject: reading a colelction leads to UPDATEs
PostPosted: Wed Apr 23, 2008 2:39 am 
Senior
Senior

Joined: Thu Jun 21, 2007 8:03 am
Posts: 127
Location: UK
Hi,

It is possible that your accessors/mutators don't return 'exactly' the same value that was read in, making NHibernate think you changed something. The log output might reveal something too.

Could you post your mapping file, and indicate which version of NHibernate you are using?

Cheers,
Richard


Top
 Profile  
 
 Post subject: Re: reading a colelction leads to UPDATEs
PostPosted: Wed Apr 23, 2008 2:40 am 
Newbie

Joined: Tue Apr 22, 2008 11:14 pm
Posts: 3
FlukeFan wrote:
Hi,

It is possible that your accessors/mutators don't return 'exactly' the same value that was read in, making NHibernate think you changed something. The log output might reveal something too.

Could you post your mapping file, and indicate which version of NHibernate you are using?

Cheers,
Richard


Yeh, looks like you are right.
I posted this question in wrong forum - in NHibernate, while I'm using JavaEE 5 and EJB and JPA


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 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.