-->
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.  [ 2 posts ] 
Author Message
 Post subject: Hibernate problem
PostPosted: Sun Oct 21, 2007 12:39 pm 
Newbie

Joined: Sun Oct 21, 2007 12:35 pm
Posts: 2
Hi all,
i have one MYSQL database and two application uses hibernate. Problem is that: When I create sessionFactory from one application and do some select and then create sessionFactory from second application and update some data from DB using in select(first application), DB is changed by update. But first application show still old data before update. Only when i create new sessionFactory from first app select show correct data..

Can you help me where is problem?

Thanks


Top
 Profile  
 
 Post subject:
PostPosted: Sun Oct 21, 2007 10:52 pm 
Senior
Senior

Joined: Sat Aug 19, 2006 6:31 pm
Posts: 139
You don't need a new session factory in the 1st app. A new session would do. You can even do a session.refresh.

Hibernate would not automatically re-sync with the db.

_________________
Don't forget to rate the reply if it helps..:)

Budyanto


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