Re: Define index?

2009-07-09 Thread ljnelson
d Nelson > > http://n2.nabble.com/user/SendEmail.jtp?type=node&node=3233323&i=1>> > wrote: > > > >> Is it possible to define a non-unique index in OpenJPA? Hibernate > offers > >> the @Index annotation to do this as part of its DDL generation >

Re: Define index?

2009-07-09 Thread Michael Dick
Hi Laird I forgot to add this bit, it *is* in the manual, but it's easier to find once you know what you're looking for. Link to the relevant section : http://openjpa.apache.org/builds/latest/docs/manual/manual.html#ref_guide_mapping_jpa_constraints It's something we can expand on though, maybe

Re: Define index?

2009-07-09 Thread Michael Dick
I think you're looking for the org.apache.openjpa.persistence.jdbc.Index annotation : ex : import org.apache.openjpa.persistence.jdbc.Index; @Entity public class Person { . . . @Index private int myint; . . . } SQL generation (DB2) : 3786 laird TRACE [main] openjpa.jdbc.SQL -

Define index?

2009-07-09 Thread Laird Nelson
Is it possible to define a non-unique index in OpenJPA? Hibernate offers the @Index annotation to do this as part of its DDL generation machinery. My apologies if this was mentioned; I didn't see it in http://openjpa.apache.org/builds/latest/docs/manual/manual.html. Thanks, Laird