web server - Borland Technical Publications

web server - Borland Technical Publications web server - Borland Technical Publications

techpubs.borland.com
from techpubs.borland.com More from this publisher
12.11.2014 Views

Container-managed data access support By default, the Borland CMP engine does not automatically map cmp-field to LOBs. If you intend to use LOB data types, you must inform the CMP engine explicitely in the ejb-borland.xml deployment descriptor. You do this by setting the Column Property createColumnSql. For example: CLOB-column createColumnSql String> CLOB BLOB-column createColumnSql String> BLOB Container-created tables You can instruct the Borland EJB Container to automatically create tables for container-managed entities based on the entity's container-managed fields by enabling the create-tables property. Because table creation and data type mappings vary among vendors, you must specify the JDBC database dialect in the deployment descriptor to the Container. For all databases (except for JDataStore) if you specify the dialect, then the Container automatically creates tables for container-managed entities for you if the create-tables property is set to true. The Container will not create these tables unless you specify the dialect. The following table shows the names or values for the different dialects (case is ignored for these values): Database Name JDataStore Oracle Sybase MSSQLServer DB2 Interbase Informix Dialect Value jdatastore oracle sybase mssqlserver db2 interbase informix Chapter 17: EJB-QL and Data Access Support 161

162 BES Developer’s Guide

Container-managed data access support<br />

By default, the <strong>Borland</strong> CMP engine does not automatically map cmp-field to LOBs. If<br />

you intend to use LOB data types, you must inform the CMP engine explicitely in the<br />

ejb-borland.xml deployment descriptor. You do this by setting the Column Property<br />

createColumnSql. For example:<br />

<br />

CLOB-column<br />

<br />

createColumnSql<br />

String><br />

CLOB<br />

<br />

<br />

<br />

BLOB-column<br />

<br />

createColumnSql<br />

String><br />

BLOB<br />

<br />

<br />

Container-created tables<br />

You can instruct the <strong>Borland</strong> EJB Container to automatically create tables for<br />

container-managed entities based on the entity's container-managed fields by enabling<br />

the create-tables property. Because table creation and data type mappings vary<br />

among vendors, you must specify the JDBC database dialect in the deployment<br />

descriptor to the Container. For all databases (except for JDataStore) if you specify the<br />

dialect, then the Container automatically creates tables for container-managed entities<br />

for you if the create-tables property is set to true. The Container will not create these<br />

tables unless you specify the dialect.<br />

The following table shows the names or values for the different dialects (case is<br />

ignored for these values):<br />

Database Name<br />

JDataStore<br />

Oracle<br />

Sybase<br />

MSSQLServer<br />

DB2<br />

Interbase<br />

Informix<br />

Dialect Value<br />

jdatastore<br />

oracle<br />

sybase<br />

mssql<strong>server</strong><br />

db2<br />

interbase<br />

informix<br />

Chapter 17: EJB-QL and Data Access Support 161

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!