tomee-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From agumbrecht <agumbre...@tomitribe.com>
Subject Re: OpenJPA and DTO problem
Date Wed, 14 May 2014 18:19:44 GMT
You should let the JPA provider manage the @Version field, don't try and
change it or read it yourself or you'll always get this error. It's
controlled internally by the provider and is to do with optimistic locking.

If you want to manage your own entity version the, i.e. versioned data row,
then use a different name/field and treat it like any other field - Don't
flag it with @Version.

Hope this helps.

Andy.



-----
    -- 
    Andy Gumbrecht

    http://www.tomitribe.com
    agumbrecht@tomitribe.com
    https://twitter.com/AndyGeeDe

    TomEE treibt Tomitribe ! | http://tomee.apache.org
--
View this message in context: http://openejb.979440.n4.nabble.com/OpenJPA-and-DTO-problem-tp4669332p4669334.html
Sent from the OpenEJB User mailing list archive at Nabble.com.

Mime
View raw message