Use the eclipselink.target-database
property to specify the database to use, controlling custom operations and SQL generation for the specified database.
Table 5-89 describes this persistence property's values.
Table 5-89 Valid Values for target-database
Value | Description |
---|---|
Defined in the |
Specify your database:
|
If eclipselink.validation-only
= true
, you must cannot use an Auto
class name or short name.
Example 5-93 shows how to use this property in the persistence.xml
file.
Example 5-93 Using target-database in persistence.xml
<property name="eclipselink.target-database" value="Oracle"/>
or
<property name="eclipselink.target-database" value="org.eclipse.persistence.platform.database.HSQLPlatform"/>
Example 5-94 shows how to use this property in the persistence.xml
file.
Example 5-94 Using target-database in a Property Map
import org.eclipse.persistence.config.TargetDatabase; import org.eclipse.persistence.config.PersistenceUnitProperties; propertiesMap.put(PersistenceUnitProperties.TARGET_DATABASE, TargetDatabase.Oracle);
For more information, see:
"Introduction to Data Access" and "TopLink Database and Application Server Support" in Understanding Oracle TopLink
Solutions Guide for Oracle TopLink