This topic lists the available SQL and PL data types and indicates whether the data types are supported by OceanBase Connector/J.
SQL data types
| SQL data type | Supported by OceanBase Connector/J |
|---|---|
| BLOB | Yes |
| CHAR | Yes |
| CLOB | Yes |
| DATE | Yes |
| NCHAR | No |
| NCHAR VARYING | No |
| NUMBER | Yes |
| NVARCHAR2 | Yes |
| RAW | Yes |
| REF | Yes |
| ROWID | Yes |
| UROWID | No |
| VARCHAR2 | Yes |
Note
- OceanBase Connector/J supports the
NCHARtype only indirectly, without the correspondingjava.sql.Typestype, but it can access data of this type if the application calls theformOfUse(NCHAR)method. - OceanBase Connector/J directly supports the
NVARCHAR2type in Java Platform, Standard Edition (Java SE) 6, and indirectly supports theNVARCHAR2type in Java 2 Platform, Standard Edition (J2SE) 5.0, without the correspondingjava.sql.Typestype, but it can access data of this type if the application calls theformOfUse(NCHAR)method.
SQL data types supported by ANSI
| SQL data type supported by ANSI | Supported by OceanBase Connector/J |
|---|---|
| CHARACTER | Yes |
| DEC | Yes |
| DECIMAL | Yes |
| DOUBLE PRECISION | Yes |
| FLOAT | Yes |
| INT | Yes |
| INTEGER | Yes |
| NATIONAL CHARACTER | No |
| NATIONAL CHARACTER VARYING | No |
| NATIONAL CHAR | Yes |
| NATIONAL CHAR VARYING | No |
| NCHAR | Yes |
| NCHAR VARYING | No |
| NUMERIC | Yes |
| REAL | Yes |
| SMALLINT | Yes |
| VARCHAR | Yes |
User-defined SQL data types
| User-defined SQL data type | Supported by OceanBase Connector/J |
|---|---|
| OPAQUE | Yes |
| Reference types | Yes |
| Object types (JAVA_OBJECT) | Yes |
| Nested table and variable array | Yes |
PL data types
PL data types can be classified as follows:
Scalar types
Scalar character types, including
BOOLEANandDATEComposite types
Reference types
Large object (
LOB) types
| PL data type | Supported by OceanBase Connector/J |
|---|---|
| Scalar types: | |
| BINARY INTEGER | Yes |
| DEC | Yes |
| DECIMAL | Yes |
| DOUBLE PRECISION | Yes |
| FLOAT | Yes |
| INT | Yes |
| INTEGER | Yes |
| NATURAL | Yes |
| NATURAL n | No |
| NUMBER | Yes |
| NUMERIC | Yes |
| PLS_INTEGER | Yes |
| POSITIVE | Yes |
| POSITIVE n | No |
| REAL | Yes |
| SIGNTYPE | Yes |
| SMALLINT | Yes |
| Scalar character types: | |
| CHAR | Yes |
| CHARACTER | Yes |
| LONG | Yes |
| LONG RAW | Yes |
| NCHAR | No |
| NVARCHAR2 | No |
| RAW | Yes |
| ROWID | Yes |
| STRING | Yes |
| UROWID | No |
| VARCHAR | Yes |
| VARCHAR2 | Yes |
| BOOLEAN | Yes |
| DATE | Yes |
| Composite types: | |
| RECORD | No |
| TABLE | No |
| VARRAY | Yes |
| Reference types: | |
| REF CURSOR type | Yes |
| Object reference type | Yes |
| LOB types: | |
| BLOB | Yes |
| CLOB | Yes |
| NCLOB | Yes |
Note
NATURAL,NATURALn,POSITIVE,POSITIVEn, andSIGNTYPEare subtypes ofBINARY INTEGER.DEC,DECIMAL,DOUBLE PRECISION,FLOAT,INT,INTEGER,NUMERIC,REAL, andSMALLINTare subtypes ofNUMBER.- OceanBase Connector/J indirectly supports the
NCHARandNVARCHAR2types, without the correspondingjava.sql.Typestypes, but it can access data of these types if the application calls theformOfUse(NCHAR)method.