Issue Details (XML | Word | Printable)

Key: OPENJPA-400
Type: Bug Bug
Status: Open Open
Priority: Major Major
Assignee: Unassigned
Reporter: Tom Mutdosch
Votes: 0
Watchers: 0
Operations

If you were logged in you would be able to see more operations.
OpenJPA

schema defined in the orm.xml's persistence-unit-defaults is not honored

Created: 12/Oct/07 02:05 PM   Updated: 08/Jul/08 04:56 PM
Return to search
Component/s: jpa
Affects Version/s: None
Fix Version/s: None

Time Tracking:
Not Specified

Issue Links:
Incorporates
 
Reference
 


 Description  « Hide
I have a number of entities that were generated from a connection using a non-default schema. I am trying to specify the default schema to use for all of my entities (these entities are Java-annotated classes).

In my orm.xml I specified:
     <persistence-unit-metadata>
<persistence-unit-defaults>
<schema>ADMINISTRATOR</schema>
</persistence-unit-defaults>
</persistence-unit-metadata>

As per the spec, it seems that all of my entities should use this defined schema, unless they override it. However, this does not seem to have any effect and at runtime, queries are generated that are still trying to use the default schema (the username).

If I instead use the openjpa property to set the schema in my persistence.xml:
<properties>
<property name="openjpa.jdbc.Schema" value="ADMINISTRATOR"/>
</properties>

This works fine. But it is not very portable, which is why I was trying to do this in the orm.xml.

 All   Comments   Work Log   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
No work has yet been logged on this issue.