user manual

146 BES Developers Guide
Setting Properties
However, the Container can detect the dialect from the URL for the
JDataStore database. Thus, for JDataStore, the Container will create these
tables regardless of whether you explicitly specify the dialect.
The following table shows the names or values for the different dialects (case
is ignored for these values):
Mapping Java types to SQL types
When you develop an enterprise bean for an existing database, you must map
the SQL data types specified in the database schema to Java programming
language data types.
The Borland EJB Container follows the JDBC rules for mapping Java
programming language types to SQL types. JDBC defines a set of generic
SQL type identifiers that represent the most commonly used SQL types. You
must use these default JDBC mapping rules when you develop an enterprise
bean to model an existing database table. (These types are defined in the
class java.sql.Types.)
The following table shows the default SQL to Java type mapping as defined by
the JDBC specification.
Database Name Dialect Value
JDataStore jdatastore
Oracle oracle
Sybase sybase
MSSQLServer mssqlserver
DB2 db2
Interbase interbase
Informix informix
No database none
Java type JDBC SQL type
boolean/Boolean BIT
byte/Byte TINYINT
char/Character CHAR(1)
double/Double DOUBLE
float/Float REAL
int/Integer INTEGER
long/Long BIGINT
short/Short SMALLINT
String VARCHAR
java.math.BigDecimal NUMERIC
byte[] VARBINARY
java.sql.Date DATE
java.sql.Time TIME