[ 
https://issues.apache.org/jira/browse/OPENJPA-1940?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Michael Dick resolved OPENJPA-1940.
-----------------------------------

    Resolution: Fixed

> 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
>            Reporter: Michael Dick
>            Assignee: Michael Dick
>             Fix For: 2.1.1, 2.2.0
>
>         Attachments: OPENJPA-1940.diff.txt
>
>   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

        

Reply via email to