Hi,Rick

Thanks for your reply.

The persistence.xml is :
<?xml version="1.0" encoding="UTF-8"?>
<persistence version="2.0"
xmlns="http://java.sun.com/xml/ns/persistence";
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
xsi:schemaLocation="http://java.sun.com/xml/ns/persistence
http://java.sun.com/xml/ns/persistence/persistence_2_0.xsd";>
  <persistence-unit name="CourseSelectPU" transaction-type="RESOURCE_LOCAL">
    <provider>org.apache.openjpa.persistence.PersistenceProviderImpl</provider>
    <class>entities.Book1</class>
    <class>entities.Book2</class>
    <class>entities.Book3</class>
    <properties>
      <property name="openjpa.ConnectionPassword" value="app"/>
      <property name="openjpa.ConnectionDriverName"
value="org.apache.derby.jdbc.ClientDriver"/>
      <property name="openjpa.ConnectionUserName" value="app"/>
      <property name="openjpa.ConnectionURL"
value="jdbc:derby://localhost:1527/sample"/>
      <property name="openjpa.jdbc.SynchronizeMappings"
value="buildSchema(ForeignKeys=true)"/>
      <property name="openjpa.AutoDetach" value="close, commit, nontx-read"/>
    </properties>
  </persistence-unit>
</persistence>

Any comments?Thanks in advance!

Reply via email to