Return-Path: Delivered-To: apmail-openjpa-dev-archive@www.apache.org Received: (qmail 66395 invoked from network); 28 Aug 2007 15:57:56 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.2) by minotaur.apache.org with SMTP; 28 Aug 2007 15:57:56 -0000 Received: (qmail 84796 invoked by uid 500); 28 Aug 2007 15:57:50 -0000 Delivered-To: apmail-openjpa-dev-archive@openjpa.apache.org Received: (qmail 84745 invoked by uid 500); 28 Aug 2007 15:57:50 -0000 Mailing-List: contact dev-help@openjpa.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@openjpa.apache.org Delivered-To: mailing list dev@openjpa.apache.org Received: (qmail 84728 invoked by uid 99); 28 Aug 2007 15:57:50 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 28 Aug 2007 08:57:50 -0700 X-ASF-Spam-Status: No, hits=-100.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO brutus.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 28 Aug 2007 15:58:46 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id C979B71418E for ; Tue, 28 Aug 2007 08:57:30 -0700 (PDT) Message-ID: <17467476.1188316650815.JavaMail.jira@brutus> Date: Tue, 28 Aug 2007 08:57:30 -0700 (PDT) From: "Pinaki Poddar (JIRA)" To: dev@openjpa.apache.org Subject: [jira] Commented: (OPENJPA-340) @UniqueConstraint and corresponding XML ignored In-Reply-To: <22821027.1188315690950.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/OPENJPA-340?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12523267 ] Pinaki Poddar commented on OPENJPA-340: --------------------------------------- Currently partial support exists. Unique constraints can be specified at @Table annotation is processed. For example, given @Entity @Table(name="Person",uniqueConstraints=@UniqueConstraint(columnNames={"first","last"})) public class Person { @Id private long id; private String first; private String last; } will generate following table schema CREATE TABLE Person (id BIGINT NOT NULL, first VARCHAR(255), last VARCHAR(255), PRIMARY KEY (id), UNIQUE (first, last)) > @UniqueConstraint and corresponding XML ignored > ----------------------------------------------- > > Key: OPENJPA-340 > URL: https://issues.apache.org/jira/browse/OPENJPA-340 > Project: OpenJPA > Issue Type: Bug > Reporter: Patrick Linskey > Fix For: 1.1.0 > > > OpenJPA ignores @UniqueConstraint annotations (and the corresponding XML declaration) when generating database schemas. This should be rectified. > A workaround is to set the -ignoreErrors flag to true when running mappingtool, which will let schema creation continue despite the error. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.