-->
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: Boolean value changing on Read
PostPosted: Sun Oct 11, 2009 7:27 pm 
Newbie

Joined: Sun Oct 11, 2009 7:17 pm
Posts: 8
Hi

This seems uber simple which is why it is baffling me.
I have a Boolean variable that keeps changing to true when it is read.

I have a property <property name="suspended" type="java.lang.Boolean" not-null="true"/>

It is set to false which I can see that has taken effect in the database but then when I read the object back Hibernate sets the value to try

I have a brake point on
Code:
   public void setSuspended (java.lang.Boolean suspended) {
      this.suspended = suspended;
   }

And see that is where it is being set when the object is initialised.

The first write and the following read are done in different transactions.

Any ideas even what to look at?

Cheers

_________________
Kremsoft
Software Development Outsourcing http://www.kremsoft.com


Top
 Profile  
 
 Post subject: Re: Boolean value changing on Read
PostPosted: Mon Oct 12, 2009 4:19 am 
Newbie

Joined: Sun Oct 11, 2009 7:17 pm
Posts: 8
You would think by now I would know not to code in the middle of the night with a hangover

I had in my JSP <s:if test="suspended = true"> obviously reassigning the variable to true. Arrr was driving me nuts!

_________________
Kremsoft
Software Development Outsourcing http://www.kremsoft.com


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.