openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From fengyi <>
Subject Re: [openjpa-2.2.1] when i cascade merge entity. a exception thrown
Date Wed, 03 Jul 2013 08:15:31 GMT
but at the same time , i find a strange thing,it's not reasonable.

when i query a object which have an date Field. after query,the entity
manager closed.
then i want set a new date
there is a exception:
<openjpa-2.2.1-runknown fatal user error>
org.apache.openjpa.persistence.InvalidStateException: The context has been
closed.  The stack trace at which the context was closed is held in the
embedded exception.

if i set a new Date ,ie:
there is another
<openjpa-2.2.1-runknown nonfatal store error>
org.apache.openjpa.util.StoreException: java.util.Date cannot be cast to

if i didn't modify the date:
the exception is :
<openjpa-2.2.1-runknown nonfatal store error>
org.apache.openjpa.util.StoreException:$util$Date$proxy cannot be cast to

only i set null can update success. now i lose my self!
any tip?
or anyone knows which situation will encounter  this error and explain this
i can avoid this situation use cascade merge as i mentioned above!

View this message in context:
Sent from the OpenJPA Users mailing list archive at

View raw message