On Mon, Dec 7, 2009 at 11:37 AM, KARR, DAVID (ATTCINW) <dk0...@att.com>wrote:
> It doesn't make sense to have a unique constraint on a > NULLABLE column. > I disagree. A property can be optional and be required to be unique when it is specified. In my application I have such a case. I omitted the Unique annotation from my class but left the constraint in the database (OpenJPA refused to insert null into a foreign key column). Using PostgreSQL, nulls are ignored regarding uniqueness. -- Daryl Stultz _____________________________________ 6 Degrees Software and Consulting, Inc. http://www.6degrees.com mailto:da...@6degrees.com