apache.org > db > ddlutils |
Oracle
DdlUtils has support for the Oracle database for versions 8.1.7
and above.
Info about the datatypes and SQL elements supported in this version can be found in the
Oracle SQL Reference. You can access this documentation from the
Oracle Technology Network. Registration to this area is free.
DdlUtils provides different platforms for Oracle v8, v9, and v10. The v9 platform adds support for
the native TIMESTAMP type, and the v10 platform handles the recycle bin that was
introduced in version 10 of the Oracle database.
Note that DdlUtils currently does not automatically detect the database version, so it will always
choose the v8 version. If you want to make use of the additional features, then you have to
specify the platform identifier manually.
Platform identifiers:
- Oracle
- Oracle9
- Oracle10
Recognized JDBC drivers:
- oracle.jdbc.driver.OracleDriver
- oracle.jdbc.dnlddriver.OracleDriver
Recognized JDBC sub protocols:
- jdbc:oracle:thin
- jdbc:oracle:oci8
- jdbc:oracle:dnldthin
The database supports SQL comments | yes |
The database supports delimited identifiers | yes |
The database's maximum identifier length | 30 |
The database supports default values for LONG types | yes |
DdlUtils uses sequences for identity columns | yes |
The database supports non-primary key columns as identity columns | yes |
The database allows INSERT/UPDATE statements to set values for identity columns | yes |
DdlUtils can read back the auto-generated value of an identity column | yes |
The database supports non-unique indices | yes |
DdlUtils can create a database via JDBC | no |
DdlUtils can drop a database via JDBC | no |
JDBC Type | Database Type | Additional comments |
---|---|---|
ARRAY | BLOB | Will be read back as BLOB |
BIGINT | NUMBER(38) | |
BINARY | RAW | Oracle requires the specification of the size for RAW columns.
If no size was specified, then 254 is used. Will be read back as VARBINARY |
BIT | NUMBER(1) | Oracle has no native boolean type. |
BLOB | BLOB | |
BOOLEAN | NUMBER(1) | Oracle has no native boolean type. Will be read back as BIT |
CHAR | CHAR | |
CLOB | CLOB | |
DATALINK | BLOB | Will be read back as BLOB |
DATE | DATE | |
DECIMAL | NUMBER | |
DISTINCT | BLOB | Will be read back as BLOB |
DOUBLE | DOUBLE PRECISION | |
FLOAT | FLOAT | Will be read back as DOUBLE |
INTEGER | INTEGER | |
JAVA_OBJECT | BLOB | Will be read back as BLOB |
LONGVARBINARY | BLOB | Will be read back as BLOB |
LONGVARCHAR | CLOB | Will be read back as CLOB |
NULL | BLOB | Will be read back as BLOB |
NUMERIC | NUMBER | Will be read back as DECIMAL |
OTHER | BLOB | Will be read back as BLOB |
REAL | REAL | |
REF | BLOB | Will be read back as BLOB |
SMALLINT | NUMBER(5) | |
STRUCT | BLOB | Will be read back as BLOB |
TIME | DATE | Will be read back as TIMESTAMP |
TIMESTAMP | Oracle8 platform: DATE Oracle9/10 platforms: TIMESTAMP |
The TIMESTAMP native type is only supported in Oracle 9 and above. |
TINYINT | NUMBER(3) | |
VARBINARY | RAW | Oracle requires the specification of the size for RAW columns. If no size was specified, then 254 is used. |
VARCHAR | VARCHAR2 |