|
Oracle® Containers for J2EE Enterprise JavaBeans Developer's Guide
10g Release 3 (10.1.3) B14428-01 |
|
![]() Previous |
![]() Next |
You can configure OC4J to automatically generate all required mappings at deployment time (see "Using Deployment XML"). To use this feature, you must:
Omit all container-managed relationship configuration (see "Configuring an EJB 2.1 CMP Entity Bean Container-Managed Persistence Field").
Ensure that no toplink-ejb-jar.xml is present in the EJB module (see "What is the toplink-ejb-jar.xml File?").
You can use this feature in conjunction with automatic database table creation (see "Configuring Automatic Database Table Creation").
To configure default mapping, configure the orion-ejb-jar.xml file element pm-properties subelement default-mapping as Table 14-4 shows.
Table 14-4 orion-ejb-jar.xml File pm-properties Subentries for default-mapping
| Entry | Description |
|---|---|
|
|
Optional element that determines what TopLink will do to prepare the database tables that are being mapped to. Valid values are:
If no The This setting overrides autocreate-tables and autodelete-tables configuration at the application (EAR) or system level. For more information, see "Automatic Database Table Creation" on page 6-6. |
|
|
An element used if the generated table names are not long enough to be unique. Values are restricted to In default mapping, each entity is mapped to one table. The only exception is in many-to-many mappings where there is one extra relation table involved in the source and target entities. When However, if the same entity is defined in multiple JAR files in an application, or across multiple applications, table-naming collision is inevitable. To address this problem, set If there is no The |