-->
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.  [ 1 post ] 
Author Message
 Post subject: LockMode.UPGRADE doesn't work with Informix database
PostPosted: Thu Jan 27, 2005 9:22 am 
Newbie

Joined: Fri Dec 05, 2003 10:54 am
Posts: 2
Hi,

I have a kinds of counter that I have to increase and I am doing the following action:

session = sf.openSession();
tx = session.beginTransaction();

DocNrCounterPJO counter = (DocNrCounterPJO ) aHibernateSession.get(DocNrCounterPJO .class, anId, aLockMode);
counter.currentStatus++;

// Do something...
Thread.sleep(10000);

session.update(counter);
session.flush();
session.commit();
session.close();

I am using Informix as target database and I saw that my row (counter) I selected is not locked. I can access it during the sleep time using an external SQL. The generated hibernate SQL statement seems to be correct (SELECT ... FOR UPDATE).

Can somebody help me? Where is the problem ?

Thanks for your answer it is very critical.

Yvan Hess

PS: I am using Hibernate 2.1.4


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

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.