openjpa-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Daryl Stultz <da...@6degrees.com>
Subject Re: Nullable unique constraints
Date Mon, 29 Jun 2009 15:26:06 GMT
On Mon, Jun 29, 2009 at 11:21 AM, Daryl Stultz <daryl@6degrees.com> wrote:

>  I don't see "unique" as an option to @Column and "nullable" defaults to
> true. Maybe you can give me an example.
>

Sorry, my mistake, I see it on @JoinColumn. I now have this:

@UniqueConstraint(columnNames = "entityid")
...
@JoinColumn(name = "entityid", nullable = true, unique = true)

But it is still trying to insert 0.

-- 
Daryl Stultz
_____________________________________
6 Degrees Software and Consulting, Inc.
http://www.6degrees.com
mailto:daryl@6degrees.com

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message