openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bp_maggie <peicheng....@asia.bnpparibas.com>
Subject Re: Null field not persisted for Dates
Date Wed, 11 May 2011 08:41:31 GMT
I tested with this piece of code and it works:

//modified is the instance client had changed
Record modified = (Record) processClientRequest();
EntityManager em = emf.createEntityManager();
Record merged = (Record) em.merge(modified);
//assume begin is a date and client set the date to null, update the date
field after merged
merged.setBegin( modified.getBegin() );

--
View this message in context: http://openjpa.208410.n2.nabble.com/Null-field-not-persisted-for-Dates-tp5993519p6351057.html
Sent from the OpenJPA Users mailing list archive at Nabble.com.

Mime
View raw message