Query using select max( @Version_field ) fails - why?

2008-11-26 Thread Brenckmann, Dirk
Hi. The entity causing the problem: === @Entity public class TypeEntity { @Id public ... getId(); @Id @Version public ... getVersion(); } The failing query: == pu for classes TRACE [ejbd 10] openjpa.Query - Executing query: [SELECT entity FROM

How to: GenerationType.Identity for mysql NOT NULL auto_increment @Id column

2008-11-26 Thread Brenckmann, Dirk
Hello, Database: mysql 4.1 Tablemanager: InnoDB CREATE TABLE db1.`type` ( `id` bigint(20) unsigned NOT NULL auto_increment, `name` varchar(100) NOT NULL default '', `description` varchar(100) default '', `userid` varchar(100) NOT NULL default '', `validFrom` timestamp NOT NULL default

Re: Callback to/from entity transactions

2008-07-08 Thread Brenckmann, Dirk
Hi Craig. After reading your response, it would seem to be a helpful option, if one could register something like an exception listener to the manager instance. This could propagate exceptions during "merge" and reduce the need for heavyweight "flush"es. It's not that I insist on this idea, but I'

Re: Q: Howto set TIMESTAMP column to null?

2008-07-02 Thread Brenckmann, Dirk
Hello Michael, ty 4 your answer. > After some experimentation found that using TIMESTAMP NULL had the desired > behavior - ie : > @Column(name = "validTo", columnDefinition = "TIMESTAMP NULL", > nullable = true, insertable = true, updatable = true) > @Temporal(TemporalType.TIMESTAMP)