Bugs item #922733, was opened at 2004-03-24 23:15
Message generated for change (Comment added) made by loubyansky
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=376685&aid=922733&group_id=22866
Category: JBossCMP
Group: v3.2
>Status: Closed
>Resolution: Out of Date
Priority: 5
Submitted By: Nicolas Fournier (nicfournier)
>Assigned to: Alexey Loubyansky (loubyansky)
Summary: java.math.BigDecimal always dirty
Initial Comment:
JBoss 3.2.3
Sun JVM 1.4.2_03
MS SQL Database with Microsft SQL 2000 Driver SP2
I have entity beans with java.math.BigDecimal fields.
The problem I have is that JBoss always updates all
BigDecimal fields even if they are not modified by my
code.
I traced in the source and found a possible explanation:
BigDecimal gets the default INVALID_UNLESS_NULL
CMPFieldStateFactory. Looking at the isStateValid
method of this class:
public boolean isStateValid(Object state, Object
fieldValue)
{
return state == null ? fieldValue == null : false;
}
and tracing trough the code gives me a non null state
and fieldValue even if not updated. So isStateValid
returns false which marks the field as dirty which then
triggers an update.
I am fully available if more info required.
----------------------------------------------------------------------
>Comment By: Alexey Loubyansky (loubyansky)
Date: 2004-03-25 01:37
Message:
Logged In: YES
user_id=543482
It was fixed in 3.2.4RC1. It uses EQUALS.
----------------------------------------------------------------------
You can respond by visiting:
https://sourceforge.net/tracker/?func=detail&atid=376685&aid=922733&group_id=22866
-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
JBoss-Development mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-development