Return-Path: Delivered-To: apmail-openjpa-dev-archive@www.apache.org Received: (qmail 90359 invoked from network); 16 Feb 2011 19:53:46 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 16 Feb 2011 19:53:46 -0000 Received: (qmail 43786 invoked by uid 500); 16 Feb 2011 19:53:46 -0000 Delivered-To: apmail-openjpa-dev-archive@openjpa.apache.org Received: (qmail 43677 invoked by uid 500); 16 Feb 2011 19:53:45 -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 43667 invoked by uid 99); 16 Feb 2011 19:53:45 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Feb 2011 19:53:45 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED,T_RP_MATCHES_RCVD X-Spam-Check-By: apache.org Received: from [140.211.11.116] (HELO hel.zones.apache.org) (140.211.11.116) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 16 Feb 2011 19:53:44 +0000 Received: from hel.zones.apache.org (hel.zones.apache.org [140.211.11.116]) by hel.zones.apache.org (Postfix) with ESMTP id 5DECF1A9DD5 for ; Wed, 16 Feb 2011 19:53:24 +0000 (UTC) Date: Wed, 16 Feb 2011 19:53:24 +0000 (UTC) From: "Michael Dick (JIRA)" To: dev@openjpa.apache.org Message-ID: <125377029.876.1297886004366.JavaMail.tomcat@hel.zones.apache.org> In-Reply-To: <1394978774.856.1297885404334.JavaMail.tomcat@hel.zones.apache.org> Subject: [jira] Updated: (OPENJPA-1940) ReverseMapping tool does not find primary keys with Oracle MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/OPENJPA-1940?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ] Michael Dick updated OPENJPA-1940: ---------------------------------- Description: When running the reverse mapping tool on Oracle we are unable to identify the primary key column for a table. The root cause is the prepared statement generated by OracleDictionary. The parameter value uses the qualified name for the table instead of the unqualified name (e.g. SCOTT.SimpleEntity instead of SimpleEntity). The output of the tool will look something like this : 669 persistence-tests INFO [main] openjpa.jdbc.JDBC - Using dictionary class "org.apache.openjpa.jdbc.sql.OracleDictionary". 3128 persistence-tests INFO [main] openjpa.Tool - ReverseMappingTool : generating classes. 3132 persistence-tests INFO [main] openjpa.MetaData - Table "SCOTT.SIMPLEENTITY" could not be reverse mapped. This means that the table does not have a primary key (primary keys are required to establish unique identifiers for all persistent objects) and does not match a known pattern for a table used for cross-reference or value collections. 3133 persistence-tests INFO [main] openjpa.Tool - Generating annotations. 3282 persistence-tests INFO [main] openjpa.Tool - Writing generated class source code. 3283 persistence-tests INFO [main] openjpa.Tool - Writing generated metadata. was: The Oracle dictionary generates SQL to read PK information from the database, but uses the fully qualified table name as a parameter. The unqualified name should be used instead. Affects Version/s: 2.1.0 2.2.0 Fix Version/s: 2.2.0 Remaining Estimate: 0h Original Estimate: 0h Summary: ReverseMapping tool does not find primary keys with Oracle (was: Unable to obtain PK information from Oracle) > ReverseMapping tool does not find primary keys with Oracle > ---------------------------------------------------------- > > Key: OPENJPA-1940 > URL: https://issues.apache.org/jira/browse/OPENJPA-1940 > Project: OpenJPA > Issue Type: Bug > Components: jdbc > Affects Versions: 2.1.0, 2.2.0 > Reporter: Michael Dick > Assignee: Michael Dick > Fix For: 2.2.0 > > Original Estimate: 0h > Remaining Estimate: 0h > > When running the reverse mapping tool on Oracle we are unable to identify the primary key column for a table. > The root cause is the prepared statement generated by OracleDictionary. The parameter value uses the qualified name for the table instead of the unqualified name (e.g. SCOTT.SimpleEntity instead of SimpleEntity). > The output of the tool will look something like this : > 669 persistence-tests INFO [main] openjpa.jdbc.JDBC - Using dictionary class "org.apache.openjpa.jdbc.sql.OracleDictionary". > 3128 persistence-tests INFO [main] openjpa.Tool - ReverseMappingTool : generating classes. > 3132 persistence-tests INFO [main] openjpa.MetaData - Table "SCOTT.SIMPLEENTITY" could not be reverse mapped. This means that the table does not have a primary key (primary keys are required to establish unique identifiers for all persistent objects) and does not match a known pattern for a table used for cross-reference or value collections. > 3133 persistence-tests INFO [main] openjpa.Tool - Generating annotations. > 3282 persistence-tests INFO [main] openjpa.Tool - Writing generated class source code. > 3283 persistence-tests INFO [main] openjpa.Tool - Writing generated metadata. -- This message is automatically generated by JIRA. - For more information on JIRA, see: http://www.atlassian.com/software/jira