TimesTen Pro*C/C++ Precompiler Options

This section discusses the use of Pro*C/C++ Precompiler options in TimesTen.

Precompiler Option Support

There are supported precompiler options in TimesTen.

SeeTable 4-2.

Note:

TimesTen does not support the following features or related options: Advanced Queueing, database optimization, user-defined objects. Also, TimesTen supports only CPOOL=NO and does not support related options.

Table 4-2 TimesTen Pro*C/C++ Precompiler Option Support

Option Notes

AUTO_CONNECT

Supported value: NO (default)

CHAR_MAP

No notes

CLOSE_ON_COMMIT

Supported value: YES

The Oracle Database default value of NO is overridden by TimesTen.

CODE

No notes

COMP_CHARSET

No notes

CONFIG

No notes

CPOOL

Supported value: NO (default)

CPP_SUFFIX

No notes

DB2_ARRAY

No notes

DBMS

Supported value: NATIVE (default)

DEF_SQLCODE

No notes

DEFINE

No notes

DYNAMIC

No notes

ERRORS

No notes

FIPS

No notes

HEADER

No notes

HOLD_CURSOR

No notes

IMPLICIT_SVPT

Supported value: NO (default)

INAME

No notes

INCLUDE

No notes

INTYPE

No notes

LINES

No notes

LNAME

No notes

LTYPE

No notes

MAX_ROW_INSERT

No notes

MAXLITERAL

No notes

MAXOPENCURSORS

No notes

MODE

No notes

NATIVE_TYPES

No notes

NLS_CHAR

No notes

NLS_LOCAL

Supported value: NO (default)

ONAME

No notes

ORACA

No notes

PAGELEN

No notes

PARSE

No notes

PREFETCH

No notes

RELEASE_CURSOR

No notes

SELECT_ERROR

No notes

SQLCHECK

Not applicable

Any of the SQLCHECK settings is allowed, but TimesTen does not support semantic checking during precompilation.

Whenever a Pro*C/C++ application uses PL/SQL, Pro*C/C++ acts as though the SQLCHECK setting is SEMANTICS.

Important: A setting of SEMANTICS (or FULL, which is synonymous) always results in a connection to the database, even though precompilation semantic checking is not performed.

See Semantic Checking Restrictions.

STMT_CACHE

No notes

SYS_INCLUDE

No notes

THREADS

No notes

TYPE_CODE

No notes

UNSAFE_NULL

No notes

USERID

No notes

UTF16_CHARSET

Supported value: NCHAR_CHARSET

VARCHAR

No notes

Note:

TimesTen does not support the default value for CLOSE_ON_COMMIT. TimesTen supports only CLOSE_ON_COMMIT=YES.

Setting Precompiler Options

You can set precompiler options in one of several ways.

  • At compile time, either in the configuration file pcscfg.cfg or on the Pro*C/C++ command line

    A command line setting takes precedence over a setting in the configuration file.

  • At runtime through the EXEC ORACLE OPTION command

    A runtime setting takes precedence over a compile-time setting.

For example, the following shows portions of the configuration file that ships with TimesTen.

ltype=short
parse=full
close_on_commit=yes
...

The following command line would override the ltype=short setting from the configuration file:

% proc ltype=long ... iname=sample.pc

The following runtime command would override the ltype=long setting from the command line:

EXEC ORACLE OPTION LTYPE=NONE;