TimesTen OCI Support Reference

This is a reference section for TimesTen support of OCI features.

Supported OCI Calls

There is TimesTen support for OCI calls.

Table 3-2 lists TimesTen support for OCI calls that are documented for Oracle Database 19c releases.

Some groups of calls are represented with an asterisk in the name. For example, the calls related to Advanced Queuing, which TimesTen does not support, have names that start with OCIAQ and are represented in the table as OCIAQ*(). OCI date functions, which TimesTen does support, are designated by OCIDate*().

Note:

TimesTen does not support the following features or related calls: Advanced Queueing, Any Data, collections, Data Cartridge, Direct Path Loading, user-defined objects, XML DB.

Table 3-2 TimesTen OCI Supported Calls

OCI Call Notes

OCIAppCtxClearAll()

No notes

OCIAppCtxSet()

No notes

OCIArrayDescriptorAlloc()

No notes

OCIArrayDescriptorFree()

No notes

OCIAttrGet()

See Supported Handles and Attributes.

TimesTen support includes special usage with cache groups. See Using Cache Operations With TimesTen OCI.

OCIAttrSet()

See Supported Handles and Attributes.

OCIBindArrayOfStruct()

This is supported for SQL statements but not PL/SQL.

OCIBindByName()

The following is an unsupported value for the mode parameter:

  • OCI_IOV

OCIBindByPos()

The following is an unsupported value for the mode parameter:

  • OCI_IOV

OCIBindDynamic()

No notes

OCICharSetConversionIsReplacementUsed()

No notes

OCICharSetToUnicode()

No notes

OCIClientVersion()

No notes

OCIDate*()

See Table 3-4.

OCIDefineArrayOfStruct()

This is supported for SQL statements but not PL/SQL.

OCIDefineByPos()

The following is an unsupported value for the mode parameter:

  • OCI_IOV

OCIDefineDynamic()

No notes

OCIDescribeAny()

PL/SQL objects are not supported.

Describing objects is supported only by name.

See Supported Parameter Attributes.

The following are unsupported values for the objptr_typ parameter:

  • OCI_OTYPE_REF

  • OCI_OTYPE_PTR

The following are unsupported values for the objtyp parameter:

  • OCI_PTYPE_PKG

  • OCI_PTYPE_FUNC

  • OCI_PTYPE_PROC

  • OCI_PTYPE_SYN

  • OCI_PTYPE_TYPE

When you use the setting OCI_PTYPE_DATABASE for the objtyp parameter, use the predetermined name $TT_DB_NAME$ as the database name for the *objptr parameter.

OCIDescriptorAlloc()

No notes

OCIDescriptorFree()

No notes

OCIDurationBegin()

Supported for LOBs. Regardless of the duration setting, the duration cannot exceed the lifetime of the transaction.

OCIDurationEnd()

Supported for LOBs. Regardless of the duration setting, the duration cannot exceed the lifetime of the transaction.

OCIEnvCreate()

The following are unsupported values for the mode parameter:

  • OCI_EVENTS

  • OCI_NEW_LENGTH_SEMANTICS

  • OCI_NCHAR_LITERAL_REPLACE_ON

  • OCI_NCHAR_LITERAL_REPLACE_OFF

  • OCI_NO_MUTEX (Instead use OCI_ENV_NO_MUTEX.)

OCIEnvInit()

The following are unsupported values for the mode parameter:

  • OCI_NO_MUTEX

  • OCI_ENV_NO_MUTEX

Note: Use OCIEnvCreate() instead of OCIEnvInit(). OCIEnvInit() is supported for backward compatibility.

OCIEnvNlsCreate()

The following are unsupported values for the mode parameter:

  • OCI_EVENTS

  • OCI_NCHAR_LITERAL_REPLACE_ON

  • OCI_NCHAR_LITERAL_REPLACE_OFF

  • OCI_NO_MUTEX (Instead use OCI_ENV_NO_MUTEX.)

OCIErrorGet()

No notes

OCIHandleAlloc()

No notes

OCIHandleFree()

No notes

OCIInitialize()

The following are unsupported values for the mode parameter:

  • OCI_NO_MUTEX

  • OCI_ENV_NO_MUTEX

Note: Use OCIEnvCreate() instead of OCIInitialize(). OCIInitialize() is supported for backward compatibility.

OCIInterval*()

See Table 3-4.

OCILob*()

TimesTen supports OCILob*() functions other than the following:

  • Functions specifically intended for array reads and writes

  • Functions specifically intended for BFILEs

  • Functions specifically intended for SecureFiles

Notes:

OCILogoff()

No notes

OCILogon()

No notes

OCILogon2()

OCI_DEFAULT is the only supported value for the mode parameter.

OCIMultiByte*()

No notes

OCINls*()

No notes

OCINumber*()

No notes

OCIParamGet()

No notes

OCIParamSet()

No notes

OCIPing()

No notes

OCIRaw*()

No notes

OCIRowidToChar()

No notes

OCIServer*()

OCI_DEFAULT is the only supported value for the mode parameter of OCIServerAttach.

OCISessionBegin()

OCI_CRED_RDBMS is the only supported value for the credt parameter.

OCI_DEFAULT is the only supported value for the mode parameter.

OCISessionEnd()

No notes

OCISessionGet()

TimesTen does not support switching between sessions.

OCISessionRelease()

No notes

OCIStmtExecute()

The following are unsupported values for the mode parameter:

  • OCI_BATCH_ERRORS

  • OCI_STMT_SCROLLABLE_READONLY

Note: Using OCI_COMMIT_ON_SUCCESS results in improved performance, avoiding an extra round trip to the server to commit a transaction.

OCIStmtFetch()

No notes

OCIStmtFetch2()

The only supported values for the orientation parameter are OCI_DEFAULT and OCI_FETCH_NEXT.

OCIStmtGetBindInfo()

No notes

OCIStmtPrepare()

The only supported value for the language parameter is OCI_NTV_SYNTAX.

OCIStmtPrepare2()

The only supported value for the mode parameter is OCI_DEFAULT.

For statement caching, TimesTen supports the key argument to tag a statement for future calls to OCIStmtPrepare2() or OCIStmtRelease().

OCIStmtRelease()

The only supported value for the mode parameter is OCI_DEFAULT.

For statement caching, TimesTen supports the key argument to tag a statement. This can be the key from OCIStmtPrepare2().

OCIString*()

No notes

OCIThread*()

No notes

OCITransCommit()

The only supported value for the mode parameter is OCI_DEFAULT.

OCITransRollback()

No notes

OCIUnicodeToCharSet()

No notes

OCIUserCallbackGet()

No notes

OCIUserCallbackRegister()

No notes

OCIWideChar*()

No notes

Supported Handles and Attributes

There are handles and attributes that TimesTen OCI supports for OCIAttrGet() and OCIAttrSet() calls.

Table 3-3 lists the handles and attributes that TimesTen OCI supports for OCIAttrGet() and OCIAttrSet() calls.

See Handle and Descriptor Attributes in Oracle Call Interface Programmer's Guide.

Table 3-3 TimesTen OCI Supported Handles and Attributes

Handle C Object Supported Attributes

Environment

OCIEnv

OCI_ATTR_ENV_CHARSET_ID

OCI_ATTR_ENV_NCHARSET_ID

OCI_ATTR_ENV_UTF16

OCI_ATTR_OBJECT

Error

OCIError

OCI_ATTR_DML_ROW_OFFSET

Service context

OCISvcCtx

OCI_ATTR_ENV

OCI_ATTR_IN_V8_MODE

OCI_ATTR_SERVER

OCI_ATTR_SESSION

OCI_ATTR_TRANS

Statement

OCIStmt

OCI_ATTR_BIND_COUNT

OCI_ATTR_CURRENT_POSITION

OCI_ATTR_ENV

OCI_ATTR_FETCH_ROWID

OCI_ATTR_NUM_DML_ERRORS

OCI_ATTR_PARAM_COUNT

OCI_ATTR_PREFETCH_MEMORY (Refer to Configuring the Result Set Buffer Size in Client/Server Using OCI)

OCI_ATTR_PREFETCH_ROWS (Refer to Configuring the Result Set Buffer Size in Client/Server Using OCI)

OCI_ATTR_ROW_COUNT

OCI_ATTR_ROWID

OCI_ATTR_ROWS_FETCHED

OCI_ATTR_SQLFNCODE

OCI_ATTR_STATEMENT

OCI_ATTR_STMT_TYPE

Bind

OCIBind

OCI_ATTR_CHARSET_FORM

OCI_ATTR_CHARSET_ID

OCI_ATTR_MAXCHAR_SIZE

OCI_ATTR_MAXDATA_SIZE

Define

OCIDefine

OCI_ATTR_CHARSET_FORM

OCI_ATTR_CHARSET_ID

OCI_ATTR_MAXCHAR_SIZE

Describe

OCIDescribe

OCI_ATTR_PARAM

OCI_ATTR_PARAM_COUNT

Server

OCIServer

OCI_ATTR_ENV

OCI_ATTR_IN_V8_MODE

OCI_ATTR_SERVER_GROUP

OCI_ATTR_SERVER_STATUS

User session

OCISession

OCI_ATTR_ACTION

OCI_ATTR_CLIENT_IDENTIFIER

OCI_ATTR_CLIENT_INFO

OCI_ATTR_CURRENT_SCHEMA

OCI_ATTR_DRIVER_NAME

OCI_ATTR_INITIAL_CLIENT_ROLES

OCI_ATTR_MODULE

OCI_ATTR_PROXY_CREDENTIALS

OCI_ATTR_USERNAME

Authentication

OCIAuthInfo

Same as for user session handle

Transaction

OCITrans

OCI_ATTR_TRANS_NAME

OCI_ATTR_TRANS_TIMEOUT

Thread

OCIThreadHandle

N/A

Supported Descriptors

There are descriptors that TimesTen OCI supports.

Table 3-4 lists the descriptors that TimesTen OCI supports.

Table 3-4 TimesTen OCI Supported Descriptors

Descriptor C Object

Parameter (read-only)

OCIParam

ROWID

OCIRowid

ANSI DATE

OCIDateTime

TIMESTAMP

OCIDateTime

TIMESTAMP WITH TIME ZONE

OCIDateTime

TIMESTAMP WITH LOCAL TIME ZONE

OCIDateTime

INTERVAL YEAR TO MONTH

OCIInterval

INTERVAL DAY TO SECOND

OCIInterval

User callback

OCIUcb

Supported OCI-Defined Constants

There are OCI-defined constants that TimesTen OCI supports as well as mappings to TimesTen SQL types.

Table 3-5 lists the OCI-defined constants that TimesTen OCI supports and the mappings to TimesTen SQL types.

Table 3-5 TimesTen OCI Supported OCI-Defined Constants

OCI-defined Constant TimesTen SQL Type Notes

SQLT_AFC

CHAR

No notes

SQLT_AVC

CHAR

No notes

SQLT_BDOUBLE

BINARY_DOUBLE

No notes

SQLT_BFLOAT

BINARY_FLOAT

No notes

SQLT_BIN

VARBINARY

No notes

SQLT_BLOB

BLOB

No notes

SQLT_CHR

VARCHAR2

No notes

SQLT_CLOB

CLOB

To write to or read from an NCLOB, set the character set form (csfrm) parameter to SQLCS_NCHAR for applicable function calls.

SQLT_DAT

DATE

No notes

SQLT_DATE

DATE

No notes

SQLT_FLT

NUMBER, BINARY_FLOAT

No notes

SQLT_IBDOUBLE

BINARY_DOUBLE

No notes

SQLT_IBFLOAT

BINARY_FLOAT

No notes

SQLT_INT

NUMBER, TT_INTEGER, TT_BIGINT, TT_SMALLINT, TT_TINYINT

No notes

SQLT_INTERVAL_DS

N/A

Not stored in TimesTen.

SQLT_INTERVAL_YM

N/A

Not stored in TimesTen.

SQLT_LBI

VARBINARY

No notes

SQLT_LNG

VARCHAR2

No notes

SQLT_LVB

VARBINARY

Truncated at 4 MB when stored in TimesTen.

SQLT_LVC

VARCHAR2

Truncated at 4 MB when stored in TimesTen.

SQLT_NUM

NUMBER

No notes

SQLT_ODT

DATE

No notes

SQLT_RDD

ROWID

Rowids are returned in Oracle Database format.

SQLT_RSET

N/A

Only one result set parameter is allowed for each statement.

Not stored in TimesTen

SQLT_STR

VARCHAR2

Null-terminated.

SQLT_TIMESTAMP

TIMESTAMP

No notes

SQLT_TIMESTAMP_LTZ

TIMESTAMP

Time zone ignored when stored in TimesTen.

SQLT_TIMESTAMP_TZ

TIMESTAMP

Time zone ignored when stored in TimesTen.

SQLT_UIN

NUMBER, TT_INTEGER, TT_BIGINT, TT_SMALLINT, TT_TINYINT

No notes

SQLT_VBI

VARBINARY

No notes

SQLT_VCS

VARCHAR2

No notes

SQLT_VNU

NUMBER

First byte indicates length of number (length of succeeding bytes).

SQLT_VST

CHAR, VARCHAR2

No notes

Supported Parameter Attributes

There are supported parameter attributes for OCIDescribeAny() calls.

Table 3-6 that follows lists supported parameter attributes for OCIDescribeAny() calls.

See Describing Schema Metadata in Oracle Call Interface Programmer's Guide for information about supported attributes.

Table 3-6 TimesTen OCI Supported Parameter Attributes

Parameter Supported Attributes

All parameters

OCI_ATTR_NUM_PARAMS

OCI_ATTR_OBJ_NAME

OCI_ATTR_OBJ_SCHEMA

OCI_ATTR_PTYPE

Table and view parameters

OCI_ATTR_NUM_COLS

OCI_ATTR_LIST_COLUMNS

PL/SQL procedure and function parameters

OCI_ATTR_LIST_ARGUMENTS

PL/SQL package subprogram parameters

OCI_ATTR_LIST_ARGUMENTS

OCI_ATTR_NAME

PL/SQL package parameters

OCI_ATTR_LIST_SUBPROGRAMS

Sequence parameters

OCI_ATTR_OBJID

OCI_ATTR_MIN

OCI_ATTR_MAX

OCI_ATTR_INCR

OCI_ATTR_CACHE

OCI_ATTR_ORDER

OCI_ATTR_HW_MARK

Column parameters

OCI_ATTR_CHAR_USED

OCI_ATTR_CHAR_SIZE

OCI_ATTR_DATA_SIZE

OCI_ATTR_DATA_TYPE

OCI_ATTR_NAME

OCI_ATTR_PRECISION

OCI_ATTR_SCALE

OCI_ATTR_IS_NULL

OCI_ATTR_TYPE_NAME

OCI_ATTR_SCHEMA_NAME

OCI_ATTR_CHARSET_ID

OCI_ATTR_CHARSET_FORM

Argument and result parameters

OCI_ATTR_NAME

OCI_ATTR_POSITION

OCI_ATTR_DATA_TYPE

OCI_ATTR_DATA_SIZE

OCI_ATTR_PRECISION

OCI_ATTR_SCALE

OCI_ATTR_LEVEL

OCI_ATTR_IS_NULL

OCI_ATTR_CHARSET_ID

OCI_ATTR_CHARSET_FORM

List parameters

OCI_LTYPE_COLUMN

OCI_LTYPE_SCH_OBJ

OCI_LTYPE_DB_SCH

Database parameters

OCI_ATTR_VERSION

OCI_ATTR_CHARSET_ID

OCI_ATTR_NCHARSET_ID

OCI_ATTR_LIST_SCHEMAS

OCI_ATTR_MAX_PROC_LEN

OCI_ATTR_MAX_COLUMN_LEN

OCI_ATTR_CURSOR_COMMIT_BEHAVIOR

OCI_ATTR_MAX_CATALOG_NAMELEN

OCI_ATTR_CATALOG_LOCATION

OCI_ATTR_SAVEPOINT_SUPPORT

OCI_ATTR_NOWAIT_SUPPORT

OCI_ATTR_AUTOCOMMIT_DDL

OCI_ATTR_LOCKING_MODE