Skip Headers
Oracle® TimesTen In-Memory Database Reference
Release 11.2.1

Part Number E13069-10
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Index
Index
Go to Master Index
Master Index
Go to Feedback page
Contact Us

Go to previous page
Previous
Go to next page
Next
View PDF

1 Connection Attributes

The ODBC standard defines four connection attributes:

For a description of the ODBC definition of these attributes, see the appropriate ODBC manual for your platform:

This chapter describes all the attributes defined by TimesTen. To view the names and values of most attributes specified in the connection string, an application can use the ttConfiguration built-in procedure.

Note:

According to the ODBC standard, when an attribute occurs multiple times in a connection string, the first value specified is used, not the last value.

On UNIX, False means the attribute value is set to 0 and True means the attribute value is set to 1.

On Windows, False means the check box is unchecked and True means the check box is checked.

The following sections provide details on all TimesTen attributes, which are first listed in tables in "List of Attributes". Following the tables, each attribute is described in detail.

Required privileges for attributes

Only the instance administrator can change a first connection attribute to a value other than the one currently in effect. (No privileges are required to change AutoCreate and ForceConnect.)

List of Attributes

This section includes the tables:

Table 1-1 Data store attributes

Name Description Default

Data Source Name

A name that identifies the specific attributes of a connection to the database.

None

DataStore

Identifies the physical database.

None

DatabaseCharacterSet

Identifies the character set used by the database. This attribute is required at database creation time.

None

Description

A statement that identifies the use of the data source name.

None

LogDir

The directory where transaction log files are stored.

Database directory

Preallocate

Specifies that disk space for the database should be preallocated when creating the database.

0 (False)

ReplicationApplyOrdering

Begins parallel replication.

0 (Off)

ReplicationParallelism

Specifies the number of tracks available for parallel replication.

1 (Single-threaded replication)

Temporary

Specifies that the database is not saved to disk.

0 (False)

TypeMode

The type mode for the database.

0 (Oracle Type Mode)


Table 1-2 First connection attributes

Name Description Default

AutoCreate

Specifies that the first connection creates the database if it does not exist.

1 (True)

CkptFrequency

Controls the frequency in seconds that TimesTen performs a background checkpoint.

600

CkptLogVolume

Controls the amount of data in megabytes that collects in the log between background checkpoints.

0 (Off)

CkptRate

Controls the maximum rate at which data should be written to disk during a checkpoint operation.

0 (Unlimited rate)

Connections

Indicates the expected upper bound on the number of concurrent connections to the database.

64

ForceConnect

Specifies whether a connection is allowed to a failed database if it is not properly restored from the corresponding subscriber database.

0 (Connection disallowed)

LogAutoTruncate

Determines whether the first connection to a database should proceed if TimesTen recovery encounters a defective log record.

1 (Continues after log is truncated)

LogBufMB

The size of the internal log buffer in MB.

64

LogBufParallelism

The number of log buffer strands.

2

LogFileSize

The transaction log file size in MB.

64

LogFlushMethod

Controls the method used by TimesTen to write and sync log data to transaction log files.

1 (Write data to transaction log files using buffered writes. Use explicit sync operations as needed to sync log data to disk)

Logging

Specifies what type of logging should be performed for the database. Only logging to disk is supported.

1 (Logging to disk)

LogPurge

Specifies that unneeded transaction log files are deleted during a checkpoint operation.

1 (True)

MemoryLock

Allows applications that connect to a shared database to specify whether the real memory should be locked during database loading.

0 (Do not acquire a memory lock)

Overwrite

Specifies that the existing database should be overwritten with a new one when a connection is attempted.

0 (False)

PermSize

The size in MB for the permanent partition of the database.

32

ReceiverThreads

Controls the number of threads used to apply changes on the active master database to the standby master database in an active standby pair replication scheme.

1

RecoveryThreads

The number of threads used to rebuild indexes during recovery.

1

TempSize

The size in MB for the temporary partition of the database.

The default size is determined from the PermSize value.


Table 1-3 General connection attributes

Name Description Default

ConnectionName

Specifies whether there is a symbolic name for the data source.

The process name

DDLCommitBehavior

Controls transactional commit behavior in relation to DDL.

0 (Oracle behavior)

DDLReplicationAction

Determines whether a table is included in an active standby pair replication scheme at table creation time when the DDLReplicationLevel connection attribute is set to 2.

INCLUDE

DDLReplicationLevel

Enables replication of DDL (Data Definition Language) statements in an active standby replication scheme.

1 (Replication enabled)

Diagnostics

Specifies whether diagnostic messages are generated.

1 (Messages are generated)

DuplicateBindMode

Determines whether applications use TimesTen or Oracle parameter binding for duplicate occurrences of a parameter in a SQL statement.

0 (Oracle-style binding)

DurableCommits

Specifies that commit operations should write log records to disk.

0 (Records not written to disk)

Isolation

Specifies whether the isolation level is read committed or serializable.

1 (Read committed)

LockLevel

Specifies whether the connection should use row-level locking (value = 0) or database-level locking (value = 1).

0 (Row-level locking)

LockWait

Allows an application to configure the lock wait interval for the connection.

10 seconds

MatchLogOpts

Specifies that values used for the Logging and LogPurge attributes should match those of current connections.

0 (False)

PermWarnThreshold

The threshold at which TimesTen returns a warning and throws an SNMP trap when the permanent partition of the database is low in memory.

90%

PrivateCommands

Determines if commands are shared between connections.

0 (On)

PWD

See "UID and PWD".

Specify the password that corresponds with the specified UID. When caching Oracle data, PWD specifies the TimesTen password. You can specify the Oracle PWD in the connection string, if necessary.

None

PWDCrypt

The value of the encrypted user password.

None

QueryThreshold

Determines whether TimesTen returns an error message and throws an SNMP trap if a query times out before executing.

0 (No error is returned)

ReplicationTrack

Assigns a connection to a replication track.

None

SQLQueryTimeout

Specifies the time limit in seconds within which the database should execute SQL statements.

0 (No timeout)

TempWarnThreshold

The threshold at which TimesTen returns a warning and throws an SNMP trap when the temporary partition of the database is low in memory.

90%

UID

See "UID and PWD".

Specify a user name that is defined on the server. When caching Oracle data, the UID must match the UID on the Oracle database that is being cached in TimesTen.

None

WaitForConnect

Specifies that the connection attempt should wait if an immediate connection is not possible.

1


Table 1-4 NLS general connection attributes

Name Description Default

ConnectionCharacterSet

The character encoding for the connection, which may be different from the database character set.

US7ASCII unless the database character set is TIMESTEN8, then TIMESTEN8.

NLS_LENGTH_SEMANTICS

The default length semantics configuration.

BYTE

NLS_NCHAR_CONV_EXCP

Determines whether an error is reported when there is data loss during an implicit or explicit character type conversion between NCHAR/NVARCHAR data and CHAR/VARCHAR data.

0 (False)

NLS_SORT

The collating sequence to use for linguistic comparisons.

BINARY


Table 1-5 PL/SQL first connection attributes

Name Description Default

PLSQL

Determines whether PL/SQL is enabled.

1 (PL/SQL is enabled)

PLSQL_MEMORY_ADDRESS

The virtual address at which the shared memory segment is loaded into each process that uses the TimesTen direct drivers.

Platform specific

PLSQL_MEMORY_SIZE

The size in megabytes of the shared memory segment used by PL/SQL.

32 MB


Table 1-6 PL/SQL general connection attributes

Name Description Default

PLSCOPE_SETTINGS

Controls whether the PL/SQL compiler generates cross-reference information.

IDENTIFIERS: NONE

PLSQL_CCFLAGS

Controls conditional compilation of PL/SQL units.

NULL

PLSQL_CONN_MEM_LIMIT

Specifies the maximum amount of process heap memory in MB that PL/SQL can use for this connection.

100

PLSQL_OPTIMIZE_LEVEL

The optimization level that is used to compile PL/SQL library units.

2

PLSQL_TIMEOUT

The number of seconds a PL/SQL procedure can run before being automatically terminated.

30 seconds


Table 1-7 IMDB Cache first connection attributes

Name Description Default

CacheAWTMethod

Enables the AWT propagation method to be used on Oracle tables.

0 (sql)


Table 1-8 IMDB Cache database attributes

Name Description Default

CacheGridEnable

Enables cache grid.

On

CacheGridMsgWait

Sets the maximum message wait time.

60 seconds


Table 1-9 IMDB Cache general connection attributes

Name Description Default

DynamicLoadEnable

Enables or disables transparent load of Oracle data to dynamic cache groups.

1 (Dynamic cache group load is enabled)

DynamicLoadErrorMode

Determines if an error message is returned upon a transparent load failure.

0 (Errors are not returned)

OracleNetServiceName

The Oracle Service Name of the Oracle instance from which data is to be loaded into a TimesTen database. This attribute is only used by the cache agent. Set the OracleNetServiceName attribute to the Oracle Service Name.

None

OraclePWD

Identifies the password for the Oracle database that is being cached in TimesTen.

None

PassThrough

Specifies which SQL statements are executed locally in TimesTen and which SQL statements are passed through to Oracle for execution.

0

RACCallback

Specifies whether to enable or disable the installation of Application Failover (TAF) and Fast Application Notification (FAN) callbacks.

1 (Install the callbacks)


Table 1-10 Client connection attributes

Name Description Default

TCP_Port

The port number on which the server is listening.

None

TCP_Port2

The port number on which the server should listen if an automatic failover occurs.

None

TTC_FailoverPortRange

A range for the failover port numbers.

None

TTC_Server

Name of the computer where the TimesTen Server is running or a logical server name.

None

TTC_Server2

If an automatic failover occurs, the name of the computer where the TimesTen Server should be running or a logical server name.

None

TTC_Server_DSN

Server DSN corresponding to the TimesTen database.

None

TTC_Server_DSN2

Server DSN corresponding to the TimesTen database, if an automatic failover occurs.

None

TTC_Timeout

Optional. Timeout period, in seconds, for completion of a TimesTen client/server operation. The maximum timeout period is 99999 seconds.

60 seconds


Table 1-11 Server connection attributes

Name Description Default

MaxConnsPerServer

The maximum number of concurrent connections a child server process can handle.

1

ServersPerDSN

The desired number of server processes for the DSN.

1

ServerStackSize

The size in KB of the thread stack for each connection.

128 KB (32-bit systems)

256KB (64-bit systems)



Data store attributes

Data store attributes are set at data store creation time.The data store attributes are listed inTable 1-1, "Data store attributes" and described in detail in this section.

These attributes can be assigned values only during database creation by the instance administrator.


Data Source Name

The data source name uniquely identifies the attributes to a connection. It serves two purposes:

The database attributes can apply to either the data source name (connection to a database) or the Data Store Path Name (database).

On Windows, the data source name and all configuration information associated with the data source (including the database path name) are stored in the system registry. This information is used by the ODBC driver manager and by TimesTen.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set Data Source Name as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file DSN A name that describes the DSN.
Windows ODBC Data Source Administrator Data Source Name field A name that describes the DSN.


DataStore

The database path name uniquely identifies the physical database. It is the full path name of the database and the file name prefix, for example: C:\data\AdminData. This name is not a file name. The actual database file names have suffixes, such as .ds0 and .log0, for example C:\data\AdminData.ds0 and C:\data\AdminData.log0.

You can use environment variables in the specification of the database path and name.

Note:

You are required to specify the database path and name at database creation time. It cannot be altered after the database has been created.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set DataStore as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file DataStore Full path to the physical database that the data source name references.
Windows ODBC Data Source Administrator Data Store Path + Name field Full path to the physical database that the data source name references.


DatabaseCharacterSet

The database character set determines the character set in which data is stored.

Note:

You are required to specify the database character set at database creation time only. It cannot be altered after the database has been created. If you do not specify a value for this attribute when creating a database, TimesTen returns error message 12701.

Generally, your database character set should be chosen based on the data requirements. For example: Do you have data in Unicode or is your data in Japanese on UNIX (EUC) or Windows (SJIS)?

You should choose a connection character set that matches your terminal settings or data source. See "ConnectionCharacterSet".

When the database and connection character sets differ, TimesTen performs the data conversion internally based on the connection character set. If the connection and database character sets are the same, TimesTen does not need to convert or interpret the data set. Best performance occurs when connection and database character sets match, since no conversion is required.

To use this attribute you must specify a supported character set. For a list of character set names that can be used as a value for this attribute, see "Supported character sets" below.

There are several things to consider when choosing a character set for your database. For a discussion about these considerations, see "Choosing a database character set" in Oracle TimesTen In-Memory Database Operations Guide.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set DatabaseCharacterSet name as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file DatabaseCharacterSet Specify the preferred character set.
Windows ODBC Data Source Administrator Database Character Set list Select the preferred character set from the list provided in the ODBC Data Source Administrator.

Supported character sets

The tables in this section describe the character sets supported in TimesTen.

Asian character sets
Name Description
JA16EUC EUC 24-bit Japanese
JA16EUCTILDE The same as JA16EUC except for the way that the wave dash and the tilde are mapped to and from Unicode
JA16SJIS Shift-JIS 16-bit Japanese
JA16SJISTILDE The same as JA16SJIS except for the way that the wave dash and the tilde are mapped to and from Unicode
KO16KSC5601 KSC5601 16-bit Korean
KO16MSWIN949 Microsoft Windows Code Page 949 Korean
TH8TISASCII Thai Industrial Standard 620-2533 - ASCII 8-bit
VN8MSWIN1258 Microsoft Windows Code Page 1258 8-bit Vietnamese
ZHS16CGB231280 CGB2312-80 16-bit Simplified Chinese
ZHS16GBK GBK 16-bit Simplified Chinese
ZHS32GB18030 GB18030-2000
ZHT16BIG5 BIG5 16-bit Traditional Chinese
ZHT16HKSCS Microsoft Windows Code Page 950 with Hong Kong Supplementary Character Set HKSCS-2001. Character set conversion to and from Unicode is based on Unicode 3.0.
ZHT16MSWIN950 Microsoft Windows Code Page 950 Traditional Chinese
ZHT32EUC EUC 32-bit Traditional Chinese


European character sets
Name Description
BLT8CP921 Latvian Standard LVS8-92(1) Windows/UNIX 8-bit Baltic
BLT8ISO8859P13 ISO 8859-13 Baltic
BLT8MSWIN1257 Microsoft Windows Code Page 1257 8-bit Baltic
BLT8PC775 IBM-PC Code Page 775 8-bit Baltic
CEL8ISO8859P14 ISO 8859-13 Celtic
CL8ISO8859P5 ISO 8859-5 Latin/Cyrillic
CL8KOI8R RELCOM Internet Standard 8-bit Latin/Cyrillic
CL8KOI8U KOI8 Ukrainian Cyrillic
CL8MSWIN1251 Microsoft Windows Code Page 1251 8-bit Latin/Cyrillic
EE8ISO8859P2 ISO 8859-2 East European
EL8ISO8859P7 ISO 8859-7 Latin/Greek
ET8MSWIN923 Microsoft Windows Code Page 923 8-bit Estonian
EE8MSWIN1250 Microsoft Windows Code Page 1250 8-bit East European
EL8MSWIN1253 Microsoft Windows Code Page 1253 8-bit Latin/Greek
EL8PC737 IBM-PC Code Page 737 8-bit Greek/Latin
EE8PC852 IBM-PC Code Page 852 8-bit East European
LT8MSWIN921 Microsoft Windows Code Page 921 8-bit Lithuanian
NE8ISO8859P10 ISO 8859-10 North European
NEE8ISO8859P4 ISO 8859-4 North and North-East European
RU8PC866 IBM-PC Code Page 866 8-bit Latin/Cyrillic
SE8ISO8859P3 ISO 8859-3 South European
US7ASCII ASCII 7-bit American
US8PC437 IBM-PC Code Page 437 8-bit American
WE8ISO8859P1 ISO 8859-1 West European
WE8ISO8859P15 ISO 8859-15 West European
WE8MSWIN1252 Microsoft Windows Code Page 1252 8-bit West European
WE8PC850 IBM-PC Code Page 850 8-bit West European
WE8PC858 IBM-PC Code Page 858 8-bit West European


Middle Eastern character sets
Name Description
AR8ADOS720 Arabic MS-DOS 720 Server 8-bit Latin/Arabic
AR8ASMO8X ASMO Extended 708 8-bit Latin/Arabic
AR8ISO8859P6 ISO 8859-6 Latin/Arabic
AR8MSWIN1256 Microsoft Windows Code Page 1256 8-Bit Latin/Arabic
AZ8ISO8859P9E ISO 8859-9 Latin Azerbaijani
IW8ISO8859P8 ISO 8859-8 Latin/Hebrew
IW8MSWIN1255 Microsoft Windows Code Page 1255 8-bit Latin/Hebrew
TR8MSWIN1254 Microsoft Windows Code Page 1254 8-bit Turkish
TR8PC857 IBM-PC Code Page 857 8-bit Turkish
WE8ISO8859P9 ISO 8859-9 West European & Turkish


TimesTen character set
Name Description
TIMESTEN8 TimesTen legacy character semantics


Universal character sets
Name Description
AL16UTF16 Unicode 4.0 UTF-16 Universal character set. This is the implicit TimesTen national character set.
AL32UTF8 Unicode 4.0 UTF-8 Universal character set
UTF8 Unicode 3.0 UTF-8 Universal character set, CESU-8 compliant


See also

"ConnectionCharacterSet"


Description

Optionally, set this attribute to help you identify the Data Source Name (DSN) and its attributes.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set Description as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file Description Text description of the Data Source Name. This attribute is optional.
Windows ODBC Data Source Administrator Description field Text description of the Data Source Name. This attribute is optional.


LogDir

The LogDir attribute specifies the directory where database logs reside. Specifying this attribute allows you to place the transaction log files on a different I/O path from the database checkpoint files. This may improve throughput.

You can use environment variables in the specification of the transaction log file path name. For example, you can specify $HOME/AdminDS for the location of the database. See "Using environment variables in database path names" in Oracle TimesTen In-Memory Database Operations Guide for more information.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set LogDir as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file LogDir Specifies the directory where transaction log files reside.
Windows ODBC Data Source Administrator Transaction Log Directory field Specifies the directory where transaction log files reside.


Preallocate

The Preallocate attribute determines whether TimesTen preallocates file system space for the database when the database is created. Setting this attribute ensures that there is sufficient space for the database when the database is saved to the file system.

Using Preallocate=1 in combination with ttRestore or ttRepAdmin -duplicate and a value of PermSize that does not match the value of PermSize of the original database may result in two checkpoint files with different sizes. This has not been shown to have negative effects. However, the issue can be avoided completely either by using the same PermSize as the original database or by setting Preallocate=0.

When a duplicate operation is carried out, the duplicated store has behavior consistent with a Preallocate setting of 0, even if it is set to 1 on the original or duplicated database. The behavior is indicated by the size of the checkpoint files, which is the sum of the size of the data and size of the database header.

The checkpoint files are subsequently allowed to grow to the same size as checkpoint files on the master database (PermSize + database header), but the space is not preallocated. The checkpoint files increase in size as data is added.

The reason for this behavior is that PreAllocate is set at database creation time. It is not a first connection attribute. The duplicate operation is not a database creation operation, so the preallocate attribute is not honored.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set Preallocate as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file Preallocate 0 (default) - Does not preallocate file system space for database when creating the database.

1 - Preallocates file system space for the database.

Windows ODBC Data Source Administrator Preallocate check box unchecked (default) - Does not preallocate file system space for database when creating the database.

checked - Preallocates file system space for the database.


Note:

reallocating disk space for a large database is very time consuming.

ReplicationApplyOrdering

Starts user-specified parallel replication, when used with the ReplicationParallelism attribute. Set the value of this attribute to 1, to initiate parallel replication.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set ReplicationApplyOrdering as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file ReplicationApplyOrdering 0 (default) - Specifies single threaded replication.

1 - Specifies parallel replication.

Windows ODBC Data Source Administrator Replication Apply Ordering check box unchecked (default) - Specifies single threaded replication.

checked - Specifies parallel replication.



ReplicationParallelism

For user-specified parallel replication, this attribute specifies the number of tracks that are replicated in parallel.

You must also set ReplicationApplyOrdering to 1 to start parallel replication.

Use the ReplicationTrack attribute to assign a track to a connection.

For applications that have very predictable transactional dependencies and do not require that the commit order on the receiver is the same as that on the originating database, you can specify the number of transaction tracks and apply specific transactions to each track. All tracks are read, transmitted and applied in parallel.

The default value for this attribute is 1. If you set the value to be greater than 1, you cannot create a replication scheme using the CREATE ACTIVE STANDBY PAIR statement.

When parallel replication is enabled the Description column of the ttLogHolds built-in procedure displays one row per track per subscriber node.

Restrictions and things to consider when specifying parallel replication include:

To learn more about parallel replication, see Oracle TimesTen In-Memory Database TimesTen to TimesTen Replication Guide.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set ReplicationParallelism as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file ReplicationParallelism n - A value between 1 and 64, indicating the number of tracks to replicate in parallel. The default is 1, single-threaded replication.
Windows ODBC Data Source Administrator Parallel Replication field n - A value between 1 and 64, indicating the number of tracks to replicate in parallel. The default is 1, single-threaded replication.


Temporary

Set this attribute to create a temporary database. Temporary databases are not saved to the file system. They may, however, be shared and therefore require a data store path name. A temporary database is deleted when the last connection is closed. See "Database persistence" in Oracle TimesTen In-Memory Database Operations Guide for more information. You cannot assign the Temporary data store attribute to an existing permanent database.

Note:

You cannot back up or replicate a temporary database.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set Temporary as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file Temporary 0 (default) - Creates permanent database.

1 - Creates temporary database.

Windows ODBC Data Source Administrator Temporary check box unchecked (default) - Creates permanent database.

checked - Creates temporary database.



TypeMode

Specifies whether the names and semantics of the data types follow Oracle or TimesTen type rules. TimesTen supports both Oracle and TimesTen data types. The type mode determines what names are used to specify each data type. In some cases, a data type has both an alias name and a fixed type name. In such a situation, you can use either name. The TimesTen type mode is included for backward compatibility. We recommend that you use the default setting, which is Oracle type mode.

When caching Oracle data in TimesTen, TypeMode must be set to 0.

See "Type specifications" in Oracle TimesTen In-Memory Database SQL Reference for a list of data types and their fixed and alias names.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set TypeMode as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file TypeMode 0 (default) - Oracle type mode.

1 - TimesTen type mode.

If no value is specified, either the default type mode or the type mode assigned when the database was created is used.

Windows ODBC Data Source Administrator TypeMode dropdown list 0 (default) - Oracle type mode.

1 - TimesTen type mode.

If no value is specified, either the default type mode or the type mode assigned when the database was created is used.



First connection attributes

First connection attributes are set when a connection is made to an idle database (a database created by the instance administrator which currently has no connections) and persist for that connection and all subsequent connections until the last connection to this database is closed.

First connection attributes are listed in Table 1-2, "First connection attributes" and described in detail in this section.

If you try to connect to the database using attributes that are different from the first connection attribute settings, the new connection may be rejected or the attribute value may be ignored. However, for example, if existing connections have a LogFileSize of one size and a new connection specifies a LogFileSize of another size, TimesTen ignores the new value and returns a warning.

Note:

Only the instance administrator can change a first connection attribute to a value other than the one currently in effect. To change the value of a first connection attribute, you must first shut down the database and then connect with ADMIN privileges. (No privileges are required to change AutoCreate and ForceConnect.)

AutoCreate

If you connect to a database that has the AutoCreate attribute set and the database does not exist yet, the database is created automatically if you supplied a valid existing path. With AutoCreate set, TimesTen creates the database, but not the path to the database. If you attempt to connect to a database that does not exist and the AutoCreate attribute is not set, the connection fails.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set AutoCreate as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file AutoCreate 0 - Does not create new database if database does not exist.

1 (default) - Creates new database if the specified database does not exist.

Windows ODBC Data Source Administrator AutoCreate check box unchecked - Does not create new database if database does not exist.

checked (default) - Creates new database if database does not exist.



CkptFrequency

Controls the frequency in seconds that TimesTen performs a background checkpoint. The counter used for the checkpoint condition is reset at the beginning of each checkpoint.

If both CkptFrequency and CkptLogVolume attributes have a value greater than 0, a checkpoint is performed when either of the two conditions becomes true. The values set by the ttCkptConfig built-in procedure replace the values set by these attributes.

In the case that your application attempts to perform a checkpoint operation while a background checkpoint is in process, TimesTen waits until the background checkpoint finishes and then executes the application's checkpoint. To turn off background checkpointing, set CkptFrequency=0 and CkptLogVolume=0.

The value of this attribute is "sticky" as it persists across database loads and unloads unless it is explicitly changed. The default value is only used during database creation. Subsequent first connections default to using the existing value stored in the database. If left unspecified (or empty in the Windows ODBC Data Source Administrator), the stored setting is used. To turn the attribute off, you must explicitly specify a value of 0.

Regardless of the value of this attribute, if a checkpoint fails, TimesTen attempts a checkpoint only once every 10 minutes. If a checkpoint failure occurs due to a lack of file system space, we recommend that you attempt a manual checkpoint as soon as space is available. Once any successful checkpoint occurs, background checkpointing reverts to the configured schedule.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set CkptFrequency as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file CkptFrequency Enter a value in seconds for the frequency at which TimesTen should perform a background checkpoint. Default is 600 if Logging=1 is specified, otherwise it is 0. To specify the default or "existing" value, leave the value empty. A value of 0 means that checkpoint frequency is not considered when scheduling checkpoints.
Windows ODBC Data Source Administrator Ckpt Frequency (secs) field Enter a value in seconds for the frequency at which TimesTen should perform a background checkpoint. Default is 600 if Logging=1 is specified, otherwise it is 0. To specify the default or "existing" value, leave the field empty. A value of 0 means that checkpoint frequency is not considered when scheduling checkpoints.


CkptLogVolume

Controls the amount of data in megabytes that collects in the log between background checkpoints. The counter used for the checkpoint condition is reset at the beginning of each checkpoint.

If both CkptFrequency and CkptLogVolume attributes have a value greater than 0, a checkpoint is performed when either of the two conditions becomes true. The values set by the ttCkptConfig built-in procedure replace the values set by these attributes.

In the case that your application attempts to perform a checkpoint operation while a background checkpoint is in process, TimesTen waits until the background checkpoint finishes and then executes the application's checkpoint. To turn off background checkpointing, set CkptFrequency=0 and CkptLogVolume=0.

The value of this attribute is "sticky" as it persists across database loads and unloads unless it is explicitly changed. The default value is only used during database creation. Subsequent first connections default to using the existing value stored in the database. If left unspecified (or empty in the Windows ODBC Data Source Administrator), the stored setting is used. To turn the attribute off, you must explicitly specify a value of 0.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set CkptLogVolume as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file CkptLogVolume Specify the amount of data in megabytes that can accumulate in the transaction log file between background checkpoints. The default is 0. To specify the default or "existing" value, leave the value empty. A value of 0 means that log volume is not considered when scheduling checkpoints.
Windows ODBC Data Source Administrator Ckpt LogVolume field Specify the amount of data in megabytes that can accumulate in the transaction log file between background checkpoints. The default is 0. To specify the default or "existing" value, leave the field empty. A value of 0 means that log volume is not considered when scheduling checkpoints.


CkptRate

Controls the maximum rate at which data should be written to disk during a checkpoint operation. This may be useful when the writing of checkpoints to disk interferes with other applications.

This rate is used by all background checkpoints and by checkpoints initiated by the ttCkpt and ttCkptBlocking built-in procedures. Foreground checkpoints (checkpoints taken during first connect and last disconnect) do not use this rate. The rate is specified in MB per second.

A value of 0 disables rate limitation. This is the default. The value can also be specified using the ttCkptConfig built-in procedure. The value set by the ttCkptConfig built-in procedure replaces the value set by this attribute.

The value of this attribute is "sticky" as it persists across database loads and unloads unless it is explicitly changed. The default value is only used during database creation. Subsequent first connections default to using the existing value stored in the database. If left unspecified (or empty in the Windows ODBC Data Source Administrator), the stored setting is used. To turn the attribute off, you must explicitly specify a value of 0. For existing databases that are migrated to this release, the value is initialized to 0. To use the current or default value, the attribute value should be left unspecified.

For more details about the benefits of and issues when using CkptRate, see "Setting the checkpoint rate" in Oracle TimesTen In-Memory Database Operations Guide.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set CkptRate as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file CkptRate Specify the maximum rate in MB per second at which a checkpoint should be written to disk. A value of 0 indicates that the rate should not be limited. This is the default.
Windows ODBC Data Source Administrator CkptRate field Specify the maximum rate in MB per second at which a checkpoint should be written to disk. A value of 0 indicates that the rate should not be limited. This is the default.


Connections

Indicates the expected upper bound on the number of concurrent connections to the database. TimesTen allocates one semaphore for each expected connection. If the number of connections exceeds the value of this attribute, the system still operates but may perform suboptimally.

The number of current connections to a database can be determined by viewing the output from the ttStatus utility.

A Connections value of 0 or no value indicates that the default number of semaphores should be used. Some TimesTen processes use a database connection. If you receive an error indicating that the number of connections exceeds the value of this attribute, increase the value until you no longer receive this error.

Note:

The kernel must be configured with enough semaphores to handle all active databases. For details on setting semaphores for your system, see "Installation prerequisites" in Oracle TimesTen In-Memory Database Installation Guide.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set Connections as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file Connections no value - Indicates that the default value is used.

0 - Indicates that the default value is used.

64 - Default value.

An integer from 1 through 2047 -The value represents the expected maximum number of connections.

Windows ODBC Data Source Administrator Connections field no value - Indicates that the default value is used.

0 - Indicates that the default value is used.

64 - Default value.

An integer from 1 through 2047 -The value represents the expected maximum number of connections.



ForceConnect

When return receipt replication is used with the NONDURABLE TRANSMIT option, a failed master database is allowed to recover only by restoring its state from a subscriber database using the -duplicate option of the ttRepAdmin utility. In other words, the failed database cannot just come up and have replication bring it up to date because it may lose some transactions that were transmitted to the subscriber but not durably committed locally. The ForceConnect connection attribute overrides this restriction.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set ForceConnect as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file ForceConnect 0 (default) - Do not allow connection to failed database if it is not properly restored from the corresponding subscriber database.

1 - Allow connection to a failed database even if it is not properly restored from the corresponding subscriber database.

Windows ODBC Data Source Administrator ForceConnect check box unchecked (default) - Do not allow connection to failed database if it is not properly restored from the corresponding subscriber database.

checked - Allow connection to a failed database even if it is not properly restored from the corresponding subscriber database.



LogAutoTruncate

Determines whether the first connection to the database should proceed if TimesTen recovery encounters a defective log record.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set LogAutoTruncate as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file LogAutoTruncate 0 - If a defective log record is encountered, terminate recovery and return an error to the connecting application. Checkpoint and transaction log files remain unmodified.

1 (default) - If a defective log record is encountered, truncate the log at the defective record's location and continue with recovery. The original transaction log files are moved to a directory called savedLogFiles, which is created as a subdirectory of the log directory. The transaction log files are saved for diagnostic purposes.

Windows ODBC Data Source Administrator LogAutoTruncate box unchecked - If a defective log record is encountered, terminate recovery and return an error to the connecting application. Checkpoint and transaction log files remain unmodified.

checked (default) - If a defective log record is encountered, truncate the log at the defective record's location and continue with recovery. The original transaction log files are moved to a directory called savedLogFiles, which is created as a subdirectory of the log directory. The transaction log files are saved for diagnostic purposes.



LogBufMB

The LogBufMB attribute specifies the size of the internal transaction log buffer in megabytes. The default log buffer size is 64 megabytes.

If you change the value of LogBufMB, you also may need to change the value of LogBufParallelism to satisfy the constraint that LogBufMB/LogBufParallelism >=8.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set LogBufMB as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file LogBufMB n - Size of log buffer in megabytes.

If not set and the database exists, the existing value stored in the database is used.If not set and the database is being created, the default value of 64 is used.

Windows ODBC Data Source Administrator Log Buffer Size (MB) field Size of log buffer, in megabytes.

If not set and the database exists, the existing value stored in the database is used.If not set and the database is being created, the default value of 64 is used.



LogBufParallelism

The LogBufParallelism attribute specifies the number of transaction log buffer strands to which TimesTen writes log files before the log is written to disk, allowing for improved log performance. Each buffer has its own insertion latch. Records are inserted in any of the strands. The log flusher gathers records from all strands and writes them to the log files.

The maximum number of strands is 64. The default is 4.

If you change the value of LogBufParallelism, you also may need to change the value of LogBufMB to satisfy the constraint that LogBufMB/LogBufParallelism >=8.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set LogBufParallelism as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file LogBufParallelism An integer value between 1 and 64. Default is 4.
Windows ODBC Data Source Administrator LogBufParallelism field An integer value between 1 and 64. Default is 4.


LogFileSize

The LogFileSize attribute specifies the maximum size of transaction log files in megabytes. The minimum value is 8 MB. The default value is 64 MB. If you specify a size smaller than 8 MB, TimesTen returns an error message. Before TimesTen release 11.2.1.4, the minimum size was 1MB. If you created your database in a previous release of TimesTen and specified a log file size of less than 8 MB, you must increase the value assigned to this attribute to avoid an error.

Actual transaction log file sizes may be slightly smaller or larger than LogFileSize because log records cannot span transaction log files.

A value of zero indicates that either the default transaction log file size should be used if the database does not exist, or that the transaction log file size in effect for the most recent connection should be used if the database does exist.

It is best to set the value of LogFileSize to match or exceed LogBufMB, although it is possible that the LogBufMB value can be greater than the LogFileSize value. The log buffer cannot be larger than the LogFileSize value, so if the buffer is not sized to match LogFileSize, the buffer capacity may not be fully utilized.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set LogFileSize as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file LogFileSize n - Size of transaction log file in megabytes. Default is 64 when the database is created and 0 (current size in effect) on subsequent connections. The minimum size is 8 MB. The maximum value is 1024 MB.
Windows ODBC Data Source Administrator Log files Size (MB) field Size of transaction log file in megabytes. Default is 64 when the database is created and 0 (current size in effect) on subsequent connections. The minimum size is 8 MB. The maximum value is 1024 MB.


LogFlushMethod

Controls the method used by TimesTen to write and sync log data to transaction log files. The overall throughput of a system can be significantly affected by the value of this attribute, especially if the application chooses to commit most transactions durably.

As a general rule, use the value 2 if most of your transactions commit durably and use the value 1 otherwise.

For best results, however, experiment with both values using a typical workload for your application and platform. Although application performance may be affected by this attribute, transaction durability is not affected. Changing the value of this attribute does not affect transaction durability in any way.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set LogFlushMethod as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file LogFlushMethod 0 - Write data to the transaction log files using the previously used value.

1 (default) - Write data to transaction log files using buffered writes and use explicit sync operations as needed to sync log data to disk (for example with durable commits).

2 - Write data to transaction log files using synchronous writes such that explicit sync operations are not needed.

Windows ODBC Data Source Administrator Log Flush Method dropdown list 0 - Write data to the transaction log files using the previously used value.

1 (default) - Write data to transaction log files using buffered writes and use explicit sync operations as needed to sync log data to disk (for example with durable commits).

2 - Write data to transaction log files using synchronous writes such that explicit sync operations are not needed.


See also

DurableCommits


Logging

Logging to disk enables applications to roll back transactions. Logging to disk incurs a performance penalty due to both operations needed to maintain the log and delays incurred in writing the log to disk. Logging to disk enables applications to roll back unwanted transactions.

By default, transaction logging is enabled. This is the only mode currently available in TimesTen.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set Logging as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file Logging 1 - Logs modifications to the database to disk (only value currently allowed).
Windows ODBC Data Source Administrator Not available Not available


LogPurge

If the LogPurge attribute is set, TimesTen automatically removes transaction log files when they have been written to both checkpoint files and there are no transactions that still need the transaction log files' contents. The first time checkpoint is called, the contents of the transaction log files are written to one of the checkpoint files. When checkpoint is called the second time, TimesTen writes the contents of the transaction log files to the other checkpoint file.

TimesTen purges the transaction log files if all these conditions are met:

If this attribute is set to 0 or unchecked, unneeded transaction log files are appended with the.arch suffix. Applications can then delete the files.

This attribute is relevant only if Logging is set to 1. See also "MatchLogOpts".

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set LogPurge as follows:

Where to set the attributes How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file LogPurge 0 - Does not remove old transaction log files at connect and checkpoint.

1 (default) - Removes old transaction log files at connect and checkpoint.

Windows ODBC Data Source Administrator LogPurge check box unchecked - Does not remove old transaction log files at connect and checkpoint.

checked (default) - Removes old transaction log files at connect and checkpoint.



MemoryLock

On Solaris, Linux, Windows 64-bit and HP-UX 11 systems, TimesTen allows applications that connect to a shared database to specify whether the real memory should be locked while the database is being loaded into memory or while the store is in memory. If the physical memory used for the database is locked, the operating system's virtual memory sub-system cannot borrow that memory for other uses. No part of the database is ever paged out but this could lead to memory shortages in a system that is under configured with RAM. While memory locking can improve database load performance, it may impede other applications on the same computer.

On AIX the MemoryLock attribute is not implemented. The shared memory segment is locked when you use large pages, on AIX. You can lock the shared segment by using large pages. The Oracle TimesTen In-Memory Database Installation Guide contains more details about large pages.

The PL/SQL shared memory segment is not subject to MemoryLock.

Required privilege

Only the instance administrator can change the value of this attribute.

On Linux systems, set the groupname in the MemLock setting to be the same as the instance administrator in the /etc/security/limits.conf file. Set the value of MemLock to be at least as large as the TimesTen database shared memory segment.

On Solaris systems, the instance administrator must be root to set MemoryLock to 1 or 2. Setting MemoryLock to 3 or 4 enables use of Solaris "intimate shared memory".

On HP-UX systems, users need the MLOCK privilege, which is enabled with the setprivgrp command.

Setting

Set MemoryLock as follows.

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file MemoryLock 0 (default) - Does not lock memory.

1 - Tries to obtain a memory lock. If unable to lock, the connection succeeds. If a lock is obtained, it is released after the database is loaded into memory (recommended).

2 - A memory lock is required. If unable to lock, the connection fails. If a lock is obtained, the connection succeeds and the lock is released after the database is loaded into memory.

3 - Tries to obtain and keep a memory lock. If unable to lock, the connection succeeds. If a memory lock is obtained, the connection succeeds and the memory lock is held until the database is unloaded from memory.

4 - A memory lock is required and is held until the database is unloaded from memory. If unable to lock, the connection fails. If a lock is obtained, the connection succeeds and the memory lock is held until the database is unloaded from memory.

Windows ODBC Data Source Administrator Memory Lock field 0 (default) - Does not lock memory.

1 - Tries to obtain a memory lock. If unable to lock, the connection succeeds. If a lock is obtained, it is released after the database is loaded into memory (recommended).

2 - A memory lock is required. If unable to lock, the connection fails. If a lock is obtained, the connection succeeds and the lock is released after the database is loaded into memory.

3 - Tries to obtain and keep a memory lock. If unable to lock, the connection succeeds. If a memory lock is obtained, the connection succeeds and the memory lock is held until the database is unloaded from memory.

4 - A memory lock is required and is held until the database is unloaded from memory. If unable to lock, the connection fails. If a lock is obtained, the connection succeeds and the memory lock is held until the database is unloaded from memory.



Overwrite

If the Overwrite attribute is set and there is an existing database with the same database path name as the new database, TimesTen destroys the existing database and creates a new empty database, as long as the existing database is not in use. If the Overwrite attribute is set and there is not a database with the specified database path name, TimesTen only creates a new database if the AutoCreate attribute is also set (see "AutoCreate"). Overwrite is ignored if AutoCreate is set to 0. Applications should use caution when specifying the Overwrite =1 attribute.

Required privilege

Only the instance administrator can change the value of this attribute. If a user other than an instance administrator attempts to connect to a database with Overwrite=1, TimesTen returns an error.

Setting

Set Overwrite as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file Overwrite 0 (default) - Does not overwrite existing database with the same path name.

1 - Overwrites existing database with the same path name.

Windows ODBC Data Source Administrator Not available Not available


PermSize

Indicates the size in MB of the permanent memory region for the database. You may increase PermSize at first connect but not decrease it. TimesTen returns a warning if you attempt to decrease the permanent memory region size. If the database does not exist, a PermSize value of 0 or no value indicates that the default size should be used. Default size is 32 MB. For an existing database, a value of 0 or no value indicates that the existing size should not be changed.

Once you have created a database, you can make the permanent partition larger, but not smaller. See "Specifying the size of a database" in Oracle TimesTen In-Memory Database Operations Guide.

The ttMigrate and ttDestroy utilities can also be used to change the Permanent Data Size, when appropriate.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set PermSize as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PermSize n - Size of permanent partition of the database, in megabytes; default is 32 MB for both 32-bit systems and 64-bit systems. Minimum size is 32 MB.
Windows ODBC Data Source Administrator Permanent Data Size field n - Size of permanent partition of the database, in megabytes; default is 32 MB for both 32-bit systems and 64-bit systems. Minimum size is 32 MB.


ReceiverThreads

This attribute controls the number of threads used to apply changes on the active master database to the standby master database in an active standby pair replication scheme. The default is 1. You can also set this attribute on one or more read-only subscribers in an active standby pair replication scheme to increase replication throughput from the standby master database to the subscribers.

By default, a receiver thread in the replication agent applies the changes to the standby master database. When this attribute is set to 2, an additional thread applies the changes. Databases must be hosted on systems that are 2-way or larger to take advantage of setting this attribute to 2.

If you set this attribute to 2 on the standby master database, you should also set it to 2 on the active master database to maintain increased throughput if there is a failover.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set ReceiverThreads as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file ReceiverThreads n - The number of threads used to apply changes from the active master database to the standby master database. You can also set this attribute on one or more read-only subscribers in an active standby pair replication scheme to increase replication throughput from the standby master database to the subscribers.

The possible values are 1 and 2. Default is 1.

Windows ODBC Data Source Administrator ReceiverThreads field n - The number of threads used to apply changes from the active master database to the standby master database. You can also set this attribute on one or more read-only subscribers in an active standby pair replication scheme to increase replication throughput from the standby master database to the subscribers.

The possible values are 1 and 2. Default is 1.



RecoveryThreads

The RecoveryThreads attribute determines the number of threads used to rebuild indexes during recovery.

If RecoveryThreads=1, during recovery, indexes that must be rebuilt are done serially. If you have enough processors available to work on index rebuilds on your computer, setting this attribute to a number greater than 1 can improve recovery performance. The performance improvement occurs only if different processors can work on different indexes. There is no parallelism in index rebuild within the same index.

The value of RecoveryThreads can be any value up to the number of CPUs available on your system.

The default is 1 when the database is created. Upon subsequent connections, if the database must be recovered and RecoveryThreads is unspecified or has a value of 0, then TimesTen uses the previous setting for this attribute.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set RecoveryThreads as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file RecoveryThreads n - The number of threads to use when rebuilding indexes during recovery. Default is 1 when the database is created and 0 on subsequent connections.
Windows ODBC Data Source Administrator RecoveryThreads field n - The number of threads to use when rebuilding indexes during recovery. Default is 1 when the database is created and 0 on subsequent connections.

Notes

For a progress report on the recovery process, see the rebuild messages in the support log.

Set the number of threads low enough to leave sufficient resources on the server for other services/processes.


TempSize

TempSize indicates the total amount of memory in MB allocated to the temporary region.

TempSize has no predefined value. If left unspecified, its value is determined from PermSize as follows:

TimesTen rounds the value up to the nearest MB.

If specified, TimesTen always honors the TempSize value. Since the temporary data partition is recreated each time a database is loaded, the TempSize attribute may be increased or decreased each time a database is loaded. For an existing database, a value of 0 or no value indicates that the existing size should not be changed. The minimum TempSize is 32 MB.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set TempSize as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file TempSize n - Size of temporary partition of the database, in megabytes. Minimum size is 32 MB on all platforms.
Windows ODBC Data Source Administrator Temporary Data Size field n - Size of temporary partition of the database, in megabytes. Minimum size is 32 MB on all platforms.


General connection attributes

General connection attributes are set by each connection and persist for the duration of the connection. General connection attributes are listed in Table 1-3, "General connection attributes" and described in detail in this section.


ConnectionName

This attribute is also available as a Client connection attribute.

This attribute allows you to attach a symbolic name to any database connection. Connection names are unique within a process.

The symbolic name is used to help identify the connection in various TimesTen administrative utilities, such as ttIsql, ttXactAdmin and ttStatus. This can be particularly useful with processes that make multiple connections to the database, as is typical with multithreaded applications or in the identification of remote clients.

The value of this attribute is intended to be dynamically defined at connection time using the connection string. The default value is the connecting executable file name. It can also be defined statically in the DSN definition. Values used for ConnectionName should follow SQL identifier syntax rules.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set ConnectionName as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file ConnectionName Enter a string up to 30 characters that represents the name of the connection.If the specified or default connection name is in use, TimesTen assigns the name conn, where n is an integer greater than 0 to make the name unique.If not specified, the connecting process name.
Windows ODBC Data Source Administrator Connection field Enter a string up to 30 characters that represents the name of the connection.If the specified or default connection name is in use, TimesTen assigns the name conn, where n is an integer greater than 0 to make the name unique.If not specified, the connecting process name.


DDLCommitBehavior

This attribute controls transactional commit behavior in relation to DDL (Data Definition Language) statements

You can set it to the traditional TimesTen behavior or to the Oracle database behavior.

Note:

If PLSQL support is enabled, the DDLCommitBehavior must be the Oracle transactional commit behavior (value 0).

Do not use DDL statements in XA transactions.

DDL statements include:

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set DDLCommitBehavior as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file DDLCommitBehavior 0 (default) - Oracle database style behavior. An implicit transaction commit is done before the execution of the DDL statement and a durable commit is done after execution of DDL statements.

1 - Traditional TimesTen style behavior. Execution of DDL statements does not trigger implicit transaction commits.

Windows ODBC Data Source Administrator DDLCommitBehavior field 0 (default) - Oracle database style behavior. An implicit transaction commit is done before the execution of the DDL statement and a durable commit is done after execution of DDL statements.

1 - Traditional TimesTen style behavior. Execution of DDL statements does not trigger implicit transaction commits.


Examples

Example 1-1 TimesTen commit behavior

AUTOCOMMIT OFF;
CREATE TABLE t1 (c1 Varchar2(10));
COMMIT;

INSERT INTO t1 VALUES('some data');
1 row inserted.

CREATE TABLE t2 (c1 INTEGER);

ROLLBACK;

SELECT * FROM t1;
0 rows found.

SELECT * FROM t2;
2206: Table ttuser.t2 not found
The command failed.

INSERT INTO t1 VALUES('more data');
1 row inserted.

CREATE TABLE t1 (c1 VARCHAR2(10));
 2207: Table t1 already exists
The command failed.

ROLLBACK;

SELECT * FROM t1;
0 rows found.

Example 1-2 Oracle commit behavior

This example shows Oracle behavior (DDLCommitBehavior=0). In this example, the INSERTs and the creation of table t2 are committed. The second insert ('more data') is committed even though the DDL statement triggering the commit (duplicate create of table t1) fails:

-- implicit commit here

Command> CREATE TABLE t1 (c1 varchar2(10));
Table created.

-- implicit commit here

Command> COMMIT;
Commit complete.

Command> INSERT INTO t1 VALUES('some data');
1 row created.

-- implicit commit here
Command> CREATE TABLE t2 (c1 INTEGER);
Table created.

-- implicit commit here

SQL> ROLLBACK;
Rollback complete.

Command> SELECT * FROM t1;
C1
----------
some data

Command> SELECT * FROM t2;
no rows selected

Command> INSERT INTO t1 VALUES('more data');
1 row created.
-- implicit commit here

Command> CREATE TABLE t1 (c1 VARCHAR2(10));
CREATE TABLE t1 (c1 VARCHAR2(10))
             *
ERROR at line 1:
ORA-00955: name is already used by an existing object

-- implicit rollback

Command> ROLLBACK;
Rollback complete.

Command> SELECT * FROM t1;
C1
----------
some data
more data

DDLReplicationAction

Determines whether a table is included in an active standby pair replication scheme at table creation time when the DDLReplicationLevel connection attribute is set to 2.

The value may be modified by an ALTER SESSION statement, for example:

ALTER SESSION SET DDL_Replication_Action='EXCLUDE';

Values set by ALTER SESSION override the value set by this attribute.

Replication of DDL operations has these restrictions:

For examples of altering an active standby pair, see "Altering an Active Standby Pair" in the Oracle TimesTen In-Memory Database TimesTen to TimesTen Replication Guide.

When DDLCommitBehavior=0 (the default), DDL operations are automatically committed. When RETURN TWOSAFE has been specified, errors and timeouts may occur as described in "RETURN TWOSAFE" on in the Oracle TimesTen In-Memory Database TimesTen to TimesTen Replication Guide. If a RETURN TWOSAFE timeout occurs, the DDL transaction is committed locally regardless of the LOCAL COMMIT ACTION that has been specified.

To learn more about replicating DDL, see "Making DDL changes in an active standby pair" in the Oracle TimesTen In-Memory Database TimesTen to TimesTen Replication Guide.

Required privilege

ADMIN privilege is required if the value of this attribute is INCLUDE.

Setting

Set DDLReplicationAction as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file DDLReplicationAction INCLUDE (default) - When a table is created, it is automatically added to the active standby pair scheme.

EXCLUDE - When a table is created it is no automatically included in the active standby pair.

Windows ODBC Data Source Administrator DDLReplicationAction field INCLUDE (default) - When a table is created, it is automatically added to the active standby pair scheme.

EXCLUDE - When a table is created it is not automatically included in the active standby pair.



DDLReplicationLevel

Enables replication of the following DDL (Data Definition Language) statements in an active standby replication scheme:

DDL statements include:

The value of this attribute may be modified by an ALTER SESSION statement, for example:

ALTER SESSION SET DDL_Replication_Level=1;

Values set by ALTER SESSION override the value set by this attribute.

Replication of DDL operations has these restrictions:

For examples of altering an active standby pair, see "Altering an Active Standby Pair" in the Oracle TimesTen In-Memory Database TimesTen to TimesTen Replication Guide.

To learn more about replicating DDL, see "Making DDL changes in an active standby pair" in the Oracle TimesTen In-Memory Database TimesTen to TimesTen Replication Guide.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set DDLReplicationLevel as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file DDLReplicationLevel 1 (default) - Replicates ALTER TABLE ADD or DROP COLUMN to the standby database. Does not replicate CREATE and DROP operations for tables, indexes or synonyms to the standby database.

2 - Replicates creating and dropping of tables, indexes and synonyms.

Windows ODBC Data Source Administrator DDL Replication Level field 1 (default) - Replicates ALTER TABLE ADD or DROP COLUMN to the standby database. Does not replicate CREATE and DROP operations for tables, indexes or synonyms to the standby database.

2 - Replicates creating and dropping of tables, indexes and synonyms.



Diagnostics

Allows an application to configure the level of diagnostics information generated by TimesTen for the connection. TimesTen diagnostics messages are warnings whose numbers lie within the range 20000 through 29999. Diagnostics connection attribute values are integers.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set Diagnostics as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file Diagnostics 0 - No diagnostics messages are generated.

1 (default) - Base level diagnostics messages are generated.

Windows ODBC Data Source Administrator Diagnostics field 0 - No diagnostics messages are generated.

1 (default) - Base level diagnostics messages are generated.



DuplicateBindMode

This attribute determines whether applications use traditional TimesTen parameter binding for duplicate occurrences of a parameter in a SQL statement or Oracle-style parameter binding.

Traditionally, in TimesTen, multiple instances of the same parameter name in a SQL statement are considered to be multiple occurrences of the same parameter. When assigning parameter numbers to parameters, TimesTen assigns parameter numbers only to the first occurrence of each parameter name. The second and subsequent occurrences of a given name do not get their own parameter numbers. In this case, A TimesTen application binds a value for every unique parameter in a SQL statement. It cannot bind different values for different occurrences of the same parameter name nor can it leave any parameters or parameter occurrences unbound.In Oracle Database, multiple instances of the same parameter name in a SQL statement are considered to be different parameters. When assigning parameter numbers, Oracle assigns a number to each parameter occurrence without regard to name duplication. An Oracle application, at a minimum, binds a value for the first occurrence of each parameter name. For the subsequent occurrences of a given parameter, the application can either leave the parameter occurrence unbound or it can bind a different value for the occurrence.

For more details on parameter binding, see Oracle TimesTen In-Memory Database SQL Reference.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set DuplicateBindMode as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file DuplicateBindMode 0 (default) - Use the Oracle parameter binding model.

1 - Use the traditional TimesTen parameter binding model.

Windows ODBC Data Source Administrator Duplicate Bind Mode check box unchecked (default) - Use the Oracle parameter binding model.

checked - Use the traditional TimesTen parameter binding model.


Notes

When using Oracle Call Interface, DuplicateBindMode must be set to 0.

When PLSQL is set to 1 and DuplicateBindMode is set to 1, PL/SQL programs may not issue SQL statements containing duplicate parameter names.


DurableCommits

By default, DurableCommits is set to 0. This means that a log record is written to the file system when a transaction is committed, but the log record is not immediately written to disk. This reduces transaction execution time at the risk of losing some committed transactions if a failure occurs. When DurableCommits is set to 1, a log record is written to disk when the transaction is committed.

A connection can also call the ttDurableCommit built-in procedure to do durable commits explicitly on selected transactions. A call to ttDurableCommit flushes the log buffer to disk. The log buffer is shared among all connections and contains log records from transactions of all connections.

Log records are continually copied from the file system to disk. You can use LogFlushMethod to control when the file system is synchronized with the disk.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set DurableCommits as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file DurableCommits 0 (default) - Does not force log to disk on transaction commit.

1 - Forces log to disk on transaction commit.

Windows ODBC Data Source Administrator Durable Commits check box unchecked - Does not force log to disk on transaction commit.

checked - Forces log to disk on transaction commit


See also

LogFlushMethod


Isolation

By default, TimesTen uses read committed isolation. The Isolation attribute specifies the initial transaction isolation level for the connection. For a description of the isolation levels, see "Concurrency control through isolation and locking" in Oracle TimesTen In-Memory Database Operations Guide.

The value may be modified by an ALTER SESSION statement. For details, see Oracle TimesTen In-Memory Database SQL Reference.

If the passthrough or the propagate IMDB Cache feature is used, the TimesTen isolation level setting is inherited by the Oracle session. TimesTen serializable mode is mapped to Oracle's serializable mode. TimesTen read committed mode is mapped to Oracle's read committed mode. For more details on the passthrough attribute, see "PassThrough".

With PassThrough set to 3, you must use an ALTER SESSION statement to permanently modify the isolation level on the Oracle connection. For example on a connection to the DSN repdb1_1121:

  1. Call ttIsql and connect to the DSN with PassThrough level 3:

    % ttsisql;
    Command> connect "dsn=repdb1_1121;passtrhough=3";
    Connection successful:. . .PassThrough=3; TypeMode=0;
    <default setting Autocommit=1>
    
  2. Turn off AutoCommit:

    Command> autocommit=0;
    
  3. Temporarily change the PassThrough level to 0:

    Command> passthrough=0;
    
  4. Alter the isolation level to serializable:

    Command> prepare 1 ALTER SESSION SET ISOLATION_LEVEL=serializable;
    Command> commit;
    Command> exec=1;
    

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set Isolation as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file Isolation 0 - Connects to database in serializable isolation mode.

1 (default) - Connects to database in read committed mode.

Windows ODBC Data Source Administrator Isolation dropdown list 0 - Connects to database in serializable isolation mode.

1 (default) - Connects to database in read committed isolation mode.



LockLevel

By default, TimesTen enables row-level locking for maximum concurrency. With row-level locking, transactions usually obtain locks on the individual rows that they access, although a transaction may obtain a lock on an entire table if TimesTen determines that doing so would result in better performance. Row-level locking is the best choice for most applications, as it provides the finest granularity of concurrency control. To use row-level locking, applications must set the LockLevel connection attribute to 0 (the default value). To cache Oracle tables, you must set row-level locking. In order to CREATE, DROP, or ALTER a user, you can only use row-level locking and thus, the Locklevel must be set to 0 before you can perform any of these operations.

To give every transaction in this connection exclusive access to the database, you can enable database-level locking by setting the LockLevel attribute to 1. Doing so may improve performance for some applications.

A connection can change the desired lock level at any time by calling the ttLockLevel built-in procedure. Connections can also wait for unavailable locks by calling the ttLockWait built-in procedure. Different connections can coexist with different levels of locking, but the presence of even one connection doing database-level locking leads to loss of concurrency. To display a list of all locks on a particular database you can use the ttXactAdmin utility.

When using PL/SQL in your applications, set LockLevel=0 and selectively change to database level locking for specific transactions that require that level of locking by using the ttLockLevel built-in procedure.

Required privilege

ADMIN privilege is required if the value of this attribute is 1.

Setting

Set LockLevel as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file LockLevel 0 (default) - Transactions access database using row-level locking.

1 - Transactions access database by acquiring an exclusive lock on the entire database.

Windows ODBC Data Source Administrator DS-Level Locking check box unchecked (default) - Transactions access database using row-level locking.

checked - Transactions access database by acquiring an exclusive lock on the entire database.



LockWait

Allows an application to configure the lock wait interval for the connection. The lock wait interval is the number of seconds to wait for a lock when there is contention on it. Sub-second LockWait values significant to tenths of a second can be specified using decimal format for the number of seconds. For example:

LockWait = 0.1

results in a lock wait of one tenth of a second.

LockWait may be set to any value between 0 and 1,000,000 inclusive to a precision of tenths of a second. The default is 10 seconds:

LockWait = 10.0

Actual lock wait response time is imprecise and may be exceeded by up to one tenth of a second, due to the scheduling of the agent that detects timeouts. This imprecision does not apply to zero second timeouts, which are always reported immediately.

Cache grid uses message wait time with lock wait time. When using cache grid, lock wait times are approximately half the value you have specified. If your applications require the full lock wait time, specify twice the desired seconds.

A connection can change the lock wait interval at any time by calling the ttLockWait built-in procedure.

To display a list of all locks on a particular database you can use the TimesTen utility ttXactAdmin.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set LockWait as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file LockWait s - Seconds to wait for locking conflict resolution before timing out. Default is 10 seconds.
Windows ODBC Data Source Administrator LockWait field s - Seconds to wait for locking conflict resolution before timing out. Default is 10 seconds.


MatchLogOpts

The first connection to a database determines the type of logging that is performed and whether the transaction log files are purged. Any subsequent connection must specify the same values for the Logging and LogPurge attributes or TimesTen generates an error. If a connection does not know the current state of these attributes, MatchLogOpts can be set so that the logging attributes match.

Note:

If MatchLogOpts is set to True for the first connector, an error is generated and the connection fails. Because of this, use the attribute with caution.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set MatchLogOpts as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file MatchLogOpts 0 (default) - Values of Logging and LogPurge are used.

1 - Values of Logging and LogPurge are ignored. Instead, values match those of current connections.

Windows ODBC Data Source Administrator Match Log Opts check box unchecked (default) - Values of Logging and LogPurge are used.

checked - Values of Logging and LogPurge are ignored. Instead, values match those of current connections.



PermWarnThreshold

Indicates the threshold percentage at which TimesTen issues out-of-memory warnings for the permanent partition of the database's memory. The database is considered no longer out of permanent memory if it falls 10% below this threshold. An application must call the built-in procedure ttWarnOnLowMemory to receive out-of-memory warnings. The threshold also applies to SNMP warnings. See "ttWarnOnLowMemory". Also see "Diagnostics through SNMP Traps" in Oracle TimesTen In-Memory Database Error Messages and SNMP Traps.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set PermWarnThreshold as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PermWarnThreshold p - Percentage at which warning should be issued. Default is 90%
Windows ODBC Data Source Administrator Low Memory Warning Thresholds for Permanent Data field p - Percentage at which warning should be issued. Default is 90%.


PrivateCommands

When multiple connections execute the same command, they access common command structures controlled by a single command lock. To avoid sharing their commands and possibly placing contention on the lock, you can use PrivateCommands. This gives you better scaling at the cost of increased temporary space usage.

By default, the PrivateCommands is turned off and commands are shared.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set PrivateCommands as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PrivateCommands 0 (default) - Commands are shared with other connections.

1 - Commands are not shared with any other connection.

Windows ODBC Data Source Administrator Private Commands field 0 (default) - Commands are shared with other connections.

1 - Commands are not shared with any other connection.


Notes

If there are many copies of the same command, all of them are invalidated by a DDL or statistics change. This means that reprepare of these multiple copies takes longer when PrivateCommands = 1. With more commands DDL execution can take slightly longer.

When using the PrivateCommands attribute, memory consumption can increase considerably if the attribute is not used cautiously. For example, if PrivateCommands=1 for an application that has 100 connections with 100 commands, there are 10,000 commands in the system: one private command for each connection.


PWDCrypt

The PWDCrypt contains an encrypted version of the corresponding PWD value. The value for PWD is stored in clear text, which does not allow special characters, in the .odbc.ini file on UNIX and in the Windows Registry on Windows. Any users who have access to the .odbc.ini file or Windows Registry can view the value for this attribute. The PWDCrypt attribute allows special characters, is case sensitive and contains the value of the encrypted password.

For security reasons, the PWDCrypt attribute should only be placed in User DSNs or user private ODBCINI files. The presence of the PWDCrypt in System DSNs allows any user to use the PWDCrypt value to connect to TimesTen, even though they have no knowledge of the cleartext password.

To generate the value for this attribute, run the ttuser utility.

Required privilege

No privilege is required to change the value of this attribute.

Notes

If PWD and PWDCrypt are both supplied, the PWD value is used. See "UID and PWD".

The PWD is not stored anywhere in the TimesTen system.

Setting

Set PWDCrypt as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PWDCrypt Enter the value generated by the ttuser utility.
Windows ODBC Data Source Administrator PWDCrypt field Enter the value generated by the ttuser utility.


QueryThreshold

Use this attribute to write a warning to the support log and throw an SNMP trap when the execution time of a SQL statement exceeds the specified value. For queries executed by the replication agent, see Oracle TimesTen In-Memory Database TimesTen to TimesTen Replication Guide. You cannot set a query threshold for a SQL statement that is executed by the cache agent. The value of QueryThreshold applies to all connections. It applies to all SQL statements except those executed by the replication agent or the cache agent.

The value of this attribute can be any integer equal to or greater than 0. The default value is 0. A value of 0 indicates that no warning is issued. The unit is seconds.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set QueryThreshold as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file QueryThreshold A non-negative integer. Default is 0 and indicates that TimesTen does not return a warning.
Windows ODBC Data Source Administrator QueryThreshold (secs) field A non-negative integer. Default is 0 and indicates that TimesTen does not return a warning.


ReplicationTrack

Assigns a connection to a replication track. All transactions issued by the connection are assigned to this track, unless the track is altered.

To start user-specified parallel replication you must set a value for the ReplicationParallelism attribute, specifying the number of replication tracks to be applied in parallel. You must also set ReplicationApplyOrdering to 1.

The TTREP.REPPEERS system table Track_ID column shows the track associated with the connection.

You can use the ALTER SESSION SQL statement to assign or change the value of this attribute within a session.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set ReplicationTrack as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file ReplicationTrack n - An integer between 1 and 64 that specifies the replication track to be used by transactions issued by the connection.
Windows ODBC Data Source Administrator Replication Track field n - An integer between 1 and 64 that specifies the replication track to be used by transactions issued by the connection.


SQLQueryTimeout

Use this attribute to specify the time limit in seconds within which the database should execute SQL statements.

The value of this attribute can be any integer equal to or greater than 0. The default value is 0. A value of 0 indicates that the query does not time out.

This attribute does not stop IMDB Cache operations that are being processed on Oracle. This includes passthrough statements, flushing, manual loading, manual refreshing, synchronous writethrough, and propagating.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set SQLQueryTimeout as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file SQLQueryTimeout n - Time limit in seconds for which the database should execute SQL queries.
Windows ODBC Data Source Administrator QueryTimeout (secs) field n - Time limit in seconds for which the database should execute SQL queries.


TempWarnThreshold

Indicates the threshold percentage at which TimesTen issues out-of- memory warnings for the temporary partition of the database's memory. The database is considered no longer out of temporary memory if it falls 10% below this threshold. An application must call the built-in procedure ttWarnOnLowMemory to receive out-of-memory warnings. The threshold also applies to SNMP warnings. See "ttWarnOnLowMemory". Also see "Diagnostics through SNMP Traps" in Oracle TimesTen In-Memory Database Error Messages and SNMP Traps

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set TempWarnThreshold as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file TempWarnThreshold p - Percentage at which warning should be issued. Default is 90%.
Windows ODBC Data Source Administrator Low Memory Warning Thresholds for Temporary Data field p - Percentage at which warning should be issued. Default is 90%


UID and PWD

A user ID and password must be provided by a user who is identified internally to TimesTen. Alternatively, an encrypted password can be supplied using the PWDCrypt attribute. Some TimesTen operations prompt for the UID and PWD of the user performing the operation.

For client/server applications, specify UID and PWD either in the Client DSN configuration or in the connection string. The UID and PWD values specified in a connection string take precedence over the values specified in the Client DSN configuration.

When caching Oracle tables, PWD specifies the TimesTen password while OraclePWD specifies the Oracle password.

Required privilege

No privilege is required to change the values of these attributes.

Setting

Set UID and PWD as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file UID Character string specifying the user ID.
C or Java programs or UNIX ODBC.INI file PWD Character string specifying the password that corresponds to the user ID.
Windows ODBC Data Source Administrator User ID field Character string specifying the user ID.


WaitForConnect

When an application requests a connection to a TimesTen database and the connection is not possible (perhaps during concurrent loading/recovery of a database), TimesTen normally waits for completion of the conflicting connection. In some cases, it can take some time for an application to connect to a database. If the WaitForConnect attribute is off and the database is not immediately accessible, TimesTen returns immediately an error. For a description of the error, look for the error message number in "Warnings and Errors" in Oracle TimesTen In-Memory Database Error Messages and SNMP Traps.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set WaitForConnect as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file WaitForConnect 0 - Does not wait if connection to database fails.

1 (default) - Waits until connection to database is possible.

Windows ODBC Data Source Administrator Wait For Connect check box unchecked - Does not wait if connection to database fails.

checked (default) - Waits until connection to database is possible.



NLS general connection attributes

NLS connection attributes are set by each connection and persist for the duration of the connection. These attributes control the globalization behaviors of the database. NLS general connection attributes are listed Table 1-4, "NLS general connection attributes" and described in detail in this section.

You can use the ALTER SESSION statement to change NLS parameters to override the values that are assigned to these attributes at connection time.


ConnectionCharacterSet

This attribute is also available as a Client connection attribute.

This attribute specifies the character encoding for the connection, which may be different from the database character set. This can be useful when you have multiple connections to a database and one or more of those connections requires a character set that differs from that specified in the database.

The connection character set determines the character set in which data is displayed or presented.

Generally, you should choose a connection character set that matches your terminal settings or data source. Your database character set should be chosen based on the data requirements. For example: Do you have data in Unicode or is your data in Japanese on UNIX (EUC) or Windows (SJIS)?

When the database and connection character sets differ, TimesTen performs data conversion internally based on the connection character set. If the connection and database character sets are the same, TimesTen does not need to convert or interpret the data set. Best performance occurs when connection and database character sets match, since no conversion is required.

Parameters and SQL query text sent to the connect should be in the connection character set. Results and error messages returned by the connection are returned in the connection character set.

Character set conversions are not supported for the TIMESTEN8 character set. A ConnectionCharacterSet value of TIMESTEN8 results in an error if the value assigned to the DatabaseCharacterSet is not TIMESTEN8.

This attribute accepts the same values used for the DatabaseCharacterSet. For a list of character set names that can be used as a value for this attribute, see "Supported character sets".

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set ConnectionCharacterSet as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file ConnectionCharacterSet The default value for ConnectionCharacterSet is US7ASCII, except when the database character set is TIMESTEN8.
Windows ODBC Data Source Administrator Connection CharacterSet list The default value for ConnectionCharacterSet is US7ASCII, except when the database character set is TIMESTEN8.


NLS_LENGTH_SEMANTICS

The NLS_LENGTH_SEMANTICS attribute is used to set the default length semantics configuration. Length semantics determines how the length of a character string is determined. The length can be treated as a sequence of characters or a sequence of bytes.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set NLS_LENGTH_SEMANTICS as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file NLS_LENGTH_ SEMANTICS Specify either BYTE (default) or CHAR.
Windows ODBC Data Source Administrator NLS_LENGTH_ SEMANTICS list Select either BYTE (default) or CHAR.


NLS_NCHAR_CONV_EXCP

The NLS_NCHAR_CONV_EXCP attribute determines whether an error is reported when there is data loss during an implicit or explicit character type conversion between NCHAR/NVARCHAR2 data and CHAR/VARCHAR2 data. A replacement character is substituted for characters that cannot be converted.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set NLS_NCHAR_CONV_EXCP as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file NLS_NCHAR_CONV_EXCP 0 (default) - Errors are not reported when there is a data loss during character type conversion.

1 - Errors are reported when there is a data loss during character type conversion.

Windows ODBC Data Source Administrator NLS_NCHAR_ CONV_EXCP checkbox checked (default) - Error messages are not reported when there is a data loss during character type conversion.

unchecked - Error messages are reported when there is a data loss during character type conversion.



NLS_SORT

The NLS_SORT attribute indicates which collating sequence to use for linguistic comparisons. It accepts the values listed in "Supported Linguistic Sorts." All these values can be modified to do case-insensitive sorts by appending _CI to the value. To perform accent-insensitive and case-insensitive sorts, append _AI to the value.

For materialized views and cache groups, TimesTen recommends that you explicitly specify the collating sequence using the NLSSORT SQL function rather than using this attribute in the connection string or DSN definition.

NLS_SORT may affect many operations. The supported operations that are sensitive to collating sequence are:

Only BINARY sort is supported with the TIMESTEN8 character set.

NLS_SORT settings other than BINARY may have significant performance impact on character operations.

Note:

Primary key indexes are always based on the BINARY collating sequence. Use of non-BINARY NLS_SORT equality searches cannot use the primary key index

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set NLS_SORT as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file NLS_SORT Specify the linguistic sort sequence or BINARY (default).
Windows ODBC Data Source Administrator NLS_SORT dropdown list Specify the linguistic sort sequence or BINARY (default).

Supported linguistic sorts

The tables in this section list the supported values for the NLS_SORT general connection attribute and the NLS_SORT SQL function.

Monolingual linguistic sorts
Basic name Extended name
ARABIC -
ARABIC_MATCH -
ARABIC_ABJ_SORT -
ARABIC_ABJ_MATCH -
ASCII7 -
AZERBAIJANI XAZERBAIJANI
BENGALI -
BIG5 -
BINARY -
BULGARIAN -
CANADIAN FRENCH -
CATALAN XCATALAN
CROATIAN XCROATIAN
CZECH XCZECH
CZECH_PUNCTUATION XCZECH_PUNCTUATION
DANISH XDANISH
DUTCH XDUTCH
EBCDIC -
EEC_EURO -
EEC_EUROPA3 -
ESTONIAN -
FINNISH -
FRENCH XFRENCH
GERMAN XGERMAN
GERMAN_DIN XGERMAN_DIN
GBK -
GREEK -
HEBREW -
HKSCS -
HUNGARIAN XHUNGARIAN
ICELANDIC -
INDONESIAN -
ITALIAN -
LATIN -
LATVIAN -
LITHUANIAN -
MALAY -
NORWEGIAN -
POLISH -
PUNCTUATION XPUNCTUATION
ROMANIAN -
RUSSIAN -
SLOVAK XSLOVAK
SLOVENIAN XSLOVENIAN
SPANISH XSPANISH
SWEDISH -
SWISS XSWISS
THAI_DICTIONARY -
TURKISH XTURKISH
UKRAINIAN -
UNICODE_BINARY -
VIETNAMESE -
WEST_EUROPEAN XWEST_EUROPEAN


Multilingual linguistic sorts
Sort name Description
CANADIAN_M Canadian French sort supports reverse secondary, special expanding characters.
DANISH_M Danish sort supports sorting uppercase characters before lowercase characters.
FRENCH_M French sort supports reverse sort for secondary.
GENERIC_M Generic sorting order which is based on ISO14651 and Unicode canonical equivalence rules but excluding compatible equivalence rules.
JAPANESE_M Japanese sort supports SJIS character set order and EUC characters which are not included in SJIS.
KOREAN_M Korean sort Hangul characters are based on Unicode binary order. Hanja characters based on pronunciation order. All Hangul characters are before Hanja characters.
SPANISH_M Traditional Spanish sort supports special contracting characters.
THAI_M Thai sort supports swap characters for some vowels and consonants.
SCHINESE_RADICAL_M Simplified Chinese sort is based on radical as primary order and number of strokes order as secondary order.
SCHINESE_STROKE_M Simplified Chinese sort uses number of strokes as primary order and radical as secondary order.
SCHINESE_PINYIN_M Simplified Chinese Pinyin sorting order.
TCHINESE_RADICAL_M Traditional Chinese sort based on radical as primary order and number of strokes order as secondary order.
TCHINESE_STROKE_M Traditional Chinese sort uses number of strokes as primary order and radical as secondary order. It supports supplementary characters.



PL/SQL first connection attributes

PL/SQL connection attributes are set by each connection and persist for the duration of the connection. These attributes control the behaviors of the database. PL/SQL first connection attributes are listed Table 1-5, "PL/SQL first connection attributes" and described in detail in this section.


PLSQL

This attribute determines whether PL/SQL is configured for the database.

Specifying PLSQL=1 enables PL/SQL use in the database. Specifying PLSQL=0 disables PL/SQL use in the database.

On platforms where PL/SQL is supported, and in TimesTen installations where PL/SQL support was enabled at installation time, the default is PLSQL=1. In other environments the default is PLSQL=0.

PL/SQL may be enabled when the database is initially created, or at any first connect afterwards. However, once PL/SQL support is enabled in a database, you cannot disable it later.

Configuring PL/SQL support in a database results in the creation of several "built-in" PL/SQL packages and procedures that are defined in Oracle TimesTen In-Memory Database PL/SQL Developer's Guide.

Some things to be aware of when setting this attribute are:

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set PLSQL as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PLSQL 0 - Indicates that PL/SQL is not enabled for the database.

1 (default) - Enables PL/SQL for the database.

Windows ODBC Data Source Administrator PL/SQL Enabled checkbox checked - Enables PL/SQL for the database.

unchecked - Indicates that PL/SQL is not enabled for the database.



PLSQL_MEMORY_ADDRESS

This attribute determines the virtual address at which this shared memory segment is loaded into each process that uses the TimesTen "direct" drivers. This memory address must be identical in each process using TimesTen. You must specify the value as a hexadecimal address.

Use of PL/SQL requires a shared memory segment. This shared memory contains recently-executed PL/SQL code, shared package state, and metadata associated with the operation of PL/SQL. This shared memory segment is separate from the one containing the TimesTen database.

If PL/SQL use is enabled (PLSQL=1) and you have not specified a value for PLSQL_MEMORY_ADDRESS, TimesTen uses a platform-dependent default value.

The default values for each platform are designed to:

  1. Maximize the amount of virtual space for your TimesTen database and for your applications.

  2. Minimize the fragmentation of the virtual address space.

  3. Avoid conflicts with other uses of virtual address apace.

The platform specific default memory addresses are:

Operating system Address
32-bit Linux 10000000
64-bit Linux 0000007fa0000000
32-bit AIX c0000000
64-bit AIX 06ffffff00000000
32-bit Solaris 10000000
64-bit Solaris ffffff0000000000
32-bit Windows 5B8C0000
HP-UX systems Do not specify a value. The operating system automatically manages the address of the memory segment.

Some things to consider when setting this attribute are:

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set PLSQL_MEMORY_ADDRESS as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PLSQL_MEMORY_ADDRESS A hexidecimal value that indicates the memory address for PL/SQL process.
Windows ODBC Data Source Administrator PL/SQL Memory Address field A hexidecimal value that indicates the memory address for PL/SQL process.


PLSQL_MEMORY_SIZE

Use of PL/SQL requires a shared memory segment. This attribute determines the size in megabytes of the shared memory segment used by PL/SQL, which is shared by all connections.

This shared memory contains recently-executed PL/SQL code, the shared package state, and metadata associated with the operation of PL/SQL. This shared memory segment is separate from the one containing the TimesTen database.

Some things to consider when setting this attribute are:

For more information on how to calculate the size for PLSQL_MEMORY_SIZE, see "Calculate shared memory size for PL/SQL runtime" in Oracle TimesTen In-Memory Database Operations Guide.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set PLSQL_MEMORY_SIZE as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PLSQL_MEMORY_SIZE Specify a positive integer greater than 2 representing the size of the shared memory segment in megabytes. The default size is 32 MB.
Windows ODBC Data Source Administrator PL/SQL Memory Size field Specify a positive integer greater than 2 representing the size of the shared memory segment in megabytes. The default size is 23 MB.


PL/SQL general connection attributes

PL/SQL general connection attributes are set by each connection and persist for the duration of the connection. These attributes control the behaviors of the database. PL/SQL general connection attributes are listed in Table 1-6, "PL/SQL general connection attributes" and described in detail in this section.

You can use the ALTER SESSION statement to change PL/SQL parameters to override the values that are assigned to the PL/SQL general connection attributes at connection time. For details, see Oracle TimesTen In-Memory Database SQL Reference.


PLSCOPE_SETTINGS

PLSCOPE_SETTINGS controls whether the PL/SQL compiler generates cross-reference information. Either all or no cross-references are generated.

Some things to consider when setting this attribute are:

Note:

For more details on this attribute, see Oracle TimesTen In-Memory Database PL/SQL Developer's Guide.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set PLSCOPE_SETTINGS as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PLSCOPE_SETTINGS IDENTIFIERS:NONE (default)

IDENTIFIERS:ALL

Windows ODBC Data Source Administrator PLScope settings pulldown list IDENTIFIERS:NONE (default)

IDENTIFIERS:ALL



PLSQL_CCFLAGS

This attribute can be used to set directives to control conditional compilation of PL/SQL units, which allows you to customize the functionality of a PL/SQL program depending on conditions that are checked. This is especially useful when applications may be deployed to multiple database environments. Possible uses include activating debugging or tracing features, or basing functionality on the version of the database.

Use this format:

PLSQL_CCFLAGS = 'v1:c1,v2:c2,...,vn:cn'

vi has the form of an unquoted PL/SQL identifier. It is unrestricted and can be a reserved word or a keyword. The text is insensitive to case. Each one is known as a flag or flag name. Each vi can occur multiple times in the string, each occurrence can have a different flag value, and the flag values can be of different kinds.

ci is one of the following: a PL/SQL boolean literal, a PLS_INTEGER literal, or the literal NULL. The text is insensitive to case. Each one is known as a flag value and corresponds to a flag name.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set PLSQL_CCFLAGS as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PLSQL_CCFLAGS 'A string literal with this format:

'v1:c1,v2:c2,...,vn:cn'

Default: null

Windows ODBC Data Source Administrator PL/SQL CCFlags field 'A string literal with this format:

'v1:c1,v2:c2,...,vn:cn'

Default: null


You can use the ALTER SESSION SQL statement to change this attribute within a session.


PLSQL_CONN_MEM_LIMIT

This attribute specifies the maximum amount of process heap memory in megabytes that PL/SQL can use for the connection in which it is set.

Some things to consider when setting this attribute are:

See Oracle TimesTen In-Memory Database PL/SQL Developer's Guide for more information.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set PLSQL_CONN_MEM_LIMIT as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PLSQL_CONN_MEM_LIMIT An integer value in MB. Default value is 100MB.
Windows ODBC Data Source Administrator PL/SQL Connection Memory Limit field An integer value in MB. Default value is 100MB.


PLSQL_OPTIMIZE_LEVEL

This attribute specifies the optimization level to be used to compile PL/SQL library units. The higher the setting of this parameter, the more effort the compiler makes to optimize PL/SQL library units.

Some things to consider when setting this attribute are:

Note:

For more details on this attribute, see Oracle TimesTen In-Memory Database PL/SQL Developer's Guide.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set PLSQL_OPTIMIZE_LEVEL as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PLSQL_OPTIMIZE_LEVEL For details on the settings for this attribute, see Oracle TimesTen In-Memory Database PL/SQL Developer's Guide.

The default value is 2.

Windows ODBC Data Source Administrator PL/SQL Optimization Level pulldown list For details on the settings for this attribute, see Oracle TimesTen In-Memory Database PL/SQL Developer's Guide.

The default value is 2.



PLSQL_TIMEOUT

This attribute controls how long (in seconds) PL/SQL program units, including PL/SQL procedures, anonymous blocks and functions, are allowed to run before being automatically terminated.

This value may be modified with an ALTER SESSION statement. If this value is modified through ALTER SESSION, the new value impacts any PL/SQL program units that are currently running.

Note:

The frequency with which PL/SQL programs check execution time against this timeout value is variable. It is possible for programs to run significantly longer than the timeout value before being terminated.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set PLSQL_TIMEOUT as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PLSQL_TIMEOUT A positive integer representing the number of seconds for the timeout value.

A value of 0 means that there is no timeout limit.

The default value is 30 seconds.

Windows ODBC Data Source Administrator PL/SQL Timeout field A positive integer representing the number of seconds for the timeout value.

A value of 0 means that there is no timeout limit.

The default value is 30 seconds.



IMDB Cache first connection attributes

IMDB Cache first connection attributes are used only when you are using the IMDB Cache product. IMDB Cache first connection attributes are listed in Table 1-7, "IMDB Cache first connection attributes" and described in detail in this section.


CacheAWTMethod

Determines whether PL/SQL execution method or SQL array execution method is used for Asynchronous Writethrough propagation to apply changes to the Oracle server.

By default, Asynchronous Writethrough (AWT) uses SQL array execution to apply changes within TimesTen to the Oracle database. This method, CacheAWTMethod=0, works well when the same type of operation is repeated. For example, array execution is very efficient when a user does an update that affects several rows of the table. Updates are grouped together and sent to the Oracle server in one batch.

If you specify the PL/SQL execution method, CacheAWTMethod=1, AWT bundles all pending operations into a single PL/SQL collection that is sent to the Oracle server to be executed. This method can improve AWT throughput when there are mixed transactions and network latency between TimesTen and the Oracle server.

PL/SQL execution method transparently falls back to array execution mode temporarily when it encounters one of the following:

Specify the SQL execution method, CacheAWTMethod=0, if any AWT cache group contains a VARBINARY column.

The SYSTEMSTATS table contains information about the number of times the execution method temporarily falls back to SQL array execution.

Note:

Use the same AWT execution method on all TimesTen nodes in any active standby pair replication scheme.

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set CacheAWTMethod as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file CacheAWTMethod 0 (default) - Use SQL array execution method.

1 - Use PL/SQL collections and anonymous blocks (PL/SQL execution method).

Windows ODBC Data Source Administrator Cache AWT Method field 0 (default) - Use SQL array execution method.

1 - Use PL/SQL collections and anonymous blocks (PL/SQL execution method).



IMDB Cache database attributes

IMDB Cache connection attributes are used only when you are using the IMDB Cache product. IMDB Cache data store attributes are listed in and described in detail in this section.


CacheGridEnable

Determines whether cache grid is enabled or disabled. The TimesTen database must be a member of a cache grid before you can create cache groups. The default is 1 (enabled).

Required privilege

Only the instance administrator can change the value of this attribute.

Setting

Set CacheGridEnable as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file CacheGridEnable 0 - Cache groups can be defined outside of a cache grid.

1 (default) - All cache groups in the database must be defined as members of a cache grid.

Windows ODBC Data Source Administrator Cache Grid Enable check box unchecked - Cache groups can be defined outside of a cache grid.

checked (default) - All cache groups in the database must be defined as members of a cache grid.



CacheGridMsgWait

Specifies the number of seconds that an application waits for a message response from a remote member in a cache grid.

For more information on caching Oracle data in a TimesTen cache grid, see Oracle In-Memory Database Cache User's Guide.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set CacheGridMsgWait as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file CacheGridMsgWait Set to the number of seconds that TimesTen should wait for a cache grid message from a remote member. The default is 60 seconds.
Windows ODBC Data Source Administrator Cache Grid Message Wait field Set to the number of seconds that TimesTen should wait for a cache grid message from a remote member. The default is 60 seconds.


IMDB Cache general connection attributes

IMDB Cache general connection attributes are used only when you are using the IMDB Cache product. IMDB Cache general connection attributes are listed in Table 1-9, "IMDB Cache general connection attributes" and described in detail in this section.


DynamicLoadEnable

This attribute enables or disables dynamic load of Oracle data to a TimesTen dynamic cache group. By default, dynamic load of Oracle data is enabled.

To enable or disable dynamic load at the statement level and temporarily override the setting of this attribute, set the DynamicLoadEnable optimizer flag with the ttOptSetFlag built-in procedure.

Note:

The value of this attribute overrides the dynamic load behavior of all dynamic cache groups for the current connection to the database.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set DynamicLoadEnable as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file DynamicLoadEnable 0 - Disables dynamic load of Oracle data to TimesTen dynamic cache groups for the current connection.

1 (default) - Enables dynamic load of Oracle data to TimesTen dynamic cache groups for the current connection.

Windows ODBC Data Source Administrator Dynamic Load Enable field 0 - Disables dynamic load of Oracle data to TimesTen dynamic cache groups for the current connection.

1 (default) - Enables dynamic load of Oracle data to TimesTen dynamic cache groups for the current connection.



DynamicLoadErrorMode

This attribute controls what happens when an application executes a SQL operation against a dynamic cache group and the SQL operation cannot use dynamic load.

With a value of 0, the SQL operation executes against whatever data is in the TimesTen cache tables and returns a result based on that data with no error indicated.

With a value of 1, any statement that cannot use dynamic load (even if it does not need dynamic load) fails with an error indicating that it is not dynamic load-compliant.

For more information on caching Oracle data in a TimesTen cache group, see Oracle In-Memory Database Cache User's Guide.

Note:

To override the value of this attribute at the statement level, set the DynamicLoadErrorMode optimizer flag with the ttOptGetFlag built-in procedure.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set DynamicLoadErrorMode as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file DynamicLoadErrorMode 0 (default) - Statements execute against the cached data with no error.

1 - Statements use dynamic load or fail with an error.

Windows ODBC Data Source Administrator DynamicLoadErrorMode field 0 (default) - Statements execute against the cached data with no error.

1 - Statements use dynamic load or fail with an error.



OracleNetServiceName

The OracleNetServiceName attribute is used with the IMDB Cache.

This attribute identifies the Service Name for the Oracle instance

To cache Oracle tables and enable communication with Oracle, you must specify an Oracle Service Name.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set OracleNetServiceName as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file OracleNetServiceName Character string specifying the Oracle Service Name that is to be used as the Oracle ID.
Windows ODBC Data Source Administrator OracleNetServiceName field Character string specifying the Oracle Service Name that is to be used as the Oracle ID.


OraclePWD

This attribute is used with IMDB Cache. It identifies the password for the user specified by UID to connect to the Oracle database to perform cache operations.

Required privilege

No privilege is required to set the value of this attribute.

Setting

This attribute must be set in the connection string. On Linux, suppose you have defined the following odbc.ini file:

[myDSN]
Datastore=/data/myDSN
PermSize=128
DatabaseCharacterSet=AL32UTF8
ConnectionCharacterSet=AL32UTF8

Set OraclePWD for user ttuser by connecting to myDSN as follows:

% ttisql
 
Copyright (c) 1996-2009, Oracle.  All rights reserved.
Type ? or "help" for help, type "exit" to quit ttIsql.
 
 
Command> connect "dsn=myDSN;OraclePWD=mypwd";
Connection successful:
DSN=beta4;UID=ttuser;DataStore=/data/myDSN;DatabaseCharacterSet=AL32UTF8;
ConnectionCharacterSet=AL32UTF8;PermSize=128;TypeMode=0;
(Default setting AutoCommit=1)
Command> 

On Windows, set OraclePWD in the connection string in the same way that it is set on Linux.

See also

"UID and PWD"


PassThrough

This attribute is used with the IMDB Cache.

It specifies which SQL statements are executed only in the cache database and which SQL statements are passed through to the Oracle database. For more information about the IMDB Cache, see Oracle In-Memory Database Cache User's Guide and "CREATE CACHE GROUP" in Oracle TimesTen In-Memory Database SQL Reference.

The execution of a prepared PassThrough command assumes that the schema of dependent objects in the Oracle database has not changed since the prepare. If the schema has changed the PassThrough command may cause unexpected results from the Oracle database.

When passing SQL statements through to Oracle, use only TimesTen supported data types in column definitions. If the specified data type is not supported in TimesTen, the passthrough statement fails.

For information on changing the isolation level on the Oracle connection, when using this attribute, see "Isolation".

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set PassThrough as follows.

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file PassThrough 0 (default) - SQL statements are executed only on TimesTen.

1 - INSERT, UPDATE and DELETE statements are executed on TimesTen unless they reference one or more tables that are not in TimesTen. If they reference one or more tables not in TimesTen, they are passed through to the Oracle database. DDL statements are executed on TimesTen. Other statements are passed through to the Oracle database if they generate a syntax error in TimesTen or if one or more tables referenced within the statement are not in TimesTen.

2 - INSERT, UPDATE and DELETE statements performed on tables in read-only cache groups or user managed cache groups with the READONLY cache table attribute are passed through to the Oracle database. Passthrough behavior for other cache group types is the same as PassThrough=1.

3 - All statements are passed through to the Oracle database for execution, except that INSERT, UPDATE and DELETE statements issued on cache tables in a dynamic AWT global cache group result in a TimesTen error.

4 - SELECT statements issues on cache tables in a dynamic AWT global cache group that do not satisfy the criteria for a dynamic load query are passed through to the Oracle database for execution. Otherwise, statements are executed in the TimesTen database.

5 - SELECT statements issued on cache tables in a dynamic AWT global cache group that do not satisfy the criteria for a dynamic load query are passed through to the Oracle database for execution when all committed updates on cache tables in dynamic AWT global cache groups by previous transactions within the connection have been propagated to the Oracle database. Otherwise, statements are executed in the TimesTen database.

Windows ODBC Data Source Administrator PassThrough List 0 (default) - SQL statements are executed only on TimesTen.

1 - INSERT, UPDATE and DELETE statements are executed on TimesTen unless they reference one or more tables that are not in TimesTen. If they reference one or more tables not in TimesTen, they are passed through to the Oracle database. DDL statements are executed on TimesTen. Other statements are passed through to the Oracle database if they generate a syntax error in TimesTen or if one or more tables referenced within the statement are not in TimesTen.

2 - INSERT, UPDATE and DELETE statements performed on tables in read-only cache groups or user managed cache groups with the READONLY cache table attribute are passed through to the Oracle database. Passthrough behavior for other cache group types is the same as PassThrough=1.

3 - All statements are passed through to the Oracle database for execution, except that INSERT, UPDATE and DELETE statements issued on cache tables in a dynamic AWT global cache group result in a TimesTen error.

4 - SELECT statements issues on cache tables in a dynamic AWT global cache group that do not satisfy the criteria for a dynamic load query are passed through to the Oracle database for execution. Otherwise, statements are executed in the TimesTen database.

5 - SELECT statements issued on cache tables in a dynamic AWT global cache group that do not satisfy the criteria for a dynamic load query are passed through to the Oracle database for execution when all committed updates on cache tables in dynamic AWT global cache groups by previous transactions within the connection have been propagated to the Oracle database. Otherwise, statements are executed in the TimesTen database.


Restrictions

Certain restrictions must be considered when using the passthrough feature. They include:


RACCallback

This attribute allows you to enable or disable the installation of Transparent Application Failover (TAF) and Fast Application Notification (FAN) callbacks when using Oracle Real Application Clusters (Oracle RAC) with IMDB Cache.

For more information about IMDB Cache, see Oracle In-Memory Database Cache User's Guide and "CREATE CACHE GROUP" in Oracle TimesTen In-Memory Database SQL Reference.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set RACCallback as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file RACCallback 0 - Do not install TAF and FAN callbacks.

1 (default) - Install the TAF and FAN callbacks.

Windows ODBC Data Source Administrator RACCallback check box unchecked - Do not install TAF and FAN callbacks.

checked (default) - Install the TAF and FAN callbacks.



TimesTen Client connection attributes

TimesTen Client connection attributes are used only when you are connecting to a TimesTen server from a TimesTen client application. TimesTen Client connection attributes are listed in Table 1-10, "Client connection attributes" and described in detail in this section.

In addition to the attributes listed in this section, some database attributes and general connection attributes are also available for client connections or impact the behavior of the connection. These attributes are:


TCP_Port

When connecting to a TimesTen database using the TimesTen Client and Server, the TimesTen Client requires the network address and the TCP port number of the computer running the TimesTen Server. As a convenience, TimesTen allows you to define a logical server name that contains the network address and port number pair.

If you specify anything other than a logical server name for the TTC_Server attribute in the Client DSN definition, TimesTen Client assumes that the Server is running on the default TCP/IP port number. In such cases, if your Server is running on a port other than the default port, you must specify the port number in the ODBC connection string. For example:

"TTC_SERVER=server_host_name;TTC_SERVER_DSN=Server_DSN;TCP_PORT=server_port"

or

"DSN=Client_DSN;TCP_Port=server_port"

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set TCP_Port as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs TCP_Port Specify the port number where the Server is listening.
Windows ODBC Data Source Administrator and UNIX ODBC.INI file TimesTen does not support specifying this attribute directly in a UNIX ODBC.INI file or in the Windows ODBC Data Source Administrator. Alternatively, TCP_Port can be defined in the logical server name. N/A


TCP_Port2

This attribute is used to specify the port number to use if an automatic failover occurs. See the description of TCP_Port for details on setting the value of this attribute and associated attributes.

See Oracle TimesTen In-Memory Database Operations Guide for more information on automatic client failover.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set TCP_Port2 as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs TCP_Port2 Specify the failover port number where the Server should listen.
Windows ODBC Data Source Administrator and UNIX ODBC.INI file TimesTen does not support specifying this attribute directly in a UNIX ODBC.INI file or in the Windows ODBC Data Source Administrator. Alternatively, TCP_Port can be defined in the logical server name. N/A


TTC_FailoverPortRange

Specifies a port range for the port that the automatic client failover thread listens on for failover notifications in an active/standby replication configuration. The failover configuration allows a client application to connect to a new active node automatically if there is a failure on the current node.

Specifying a port range helps accommodate firewalls between the client and server systems. By default, TimesTen uses a port chosen by the operating system.

Note:

Client failover is only supported when the client is part of an active/standby pair replication configurations.

See Oracle TimesTen In-Memory Database Operations Guide for more information on automatic client failover.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set TTC_FailoverPortRange as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file TTC_FailoverPortRange Specify a lower value and an upper value for the port numbers in the format <lowervalue>-<upper value>.
Windows ODBC Data Source Administrator Failover Port Range field Specify a lower value and an upper value for the port numbers in the format <lowervalue>-<upper value>.


TTC_Server

When connecting to a TimesTen database using the TimesTen Client and Server, the TimesTen Client requires the specification of the network address and TCP port number of the computer running the TimesTen Server. As a convenience, TimesTen allows you to define a logical server name that contains the network address and port number pair. If you specify anything other than a logical server name for this attribute, TimesTen Client assumes that the Server is running on the default TCP/IP port number. In such cases, if your Server is running on a port other than the default port, you must specify the port number in the ODBC connection string. For example:

"TTC_SERVER=server_host_name;TTC_SERVER_DSN=Server_DSN;TCP_PORT=server_port"

or

"DSN=Client_DSN;TCP_Port=server_port"

Once the logical server name is defined, it can be used as the value for the TTC_Server attribute in a Client DSN. Therefore, multiple Client DSNs referencing the same computer that is running the TimesTen Server can use the same logical server name for the value of the TTC_Server attribute instead of having to specify repeatedly the same network address and port number within each of the Client DSNs.

Note:

TimesTen recommends that you specify a logical server name for the TTC_Server attribute. However, you can also specify a domain name server (DNS), host name or IP address for the TTC_Server attribute. If you do not use a logical server name and the TimesTen Server is listening on a non-default port number, you must provide the port number in the ODBC connection string. For example:
"TTC_SERVER=server_host_name;TTC_SERVER_DSN=Server_DSN;
TCP_PORT=server_port"

or

"DSN=Client_DSN;TCP_Port=server_port"

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set TTC_Server as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file TTC_Server Character string specifying the logical server.
Windows ODBC Data Source Administrator Server Name or Network Address field Character string specifying the logical server.


TTC_Server2

This attribute is used to specify the logical server name to use if an automatic failover occurs. See the description of TTC_Server for details on setting the value of this attribute and associated attributes.

The value of this attribute can be can be the same as the value specified for TTC_Server if it is a virtual IP address.

If the client has already failed over and has connected to TTC_Server2 and the connection fails, it connects to TTC_Server. It alternately attempts to connect to TTC_Server and TTC_Server2 until the TTC_TIMEOUT attribute expires.

Note:

Client failover is only supported when the client is part of an active/standby pair replication configurations.

See Oracle TimesTen In-Memory Database Operations Guide for more information on automatic client failover.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set TTC_Server2 as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file TTC_Server2 Character string specifying the logical server to be used if an automatic failover occurs.
Windows ODBC Data Source Administrator Server Name or Network Address 2 field Character string specifying the logical server to be used if an automatic failover occurs.


TTC_Server_DSN

The TTC_Server_DSN attribute specifies a Server DSN on the computer running the TimesTen Server.

On Windows, Server DSNs are the set of TimesTen System DSNs that use the TimesTen Data Manager driver. Use the ODBC Data Source Administrator to define Server DSNs.

On UNIX, Server DSNs are defined in the /var/TimesTen/ instance/sys.odbc.ini file. More details on this topic can be found in the platform-specific sections.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set TTC_Server_DSN as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file TTC_Server_DSN Character string specifying the DSN that resides on the Server.
Windows ODBC Data Source Administrator Server DSN field Character string specifying the DSN that resides on the Server.


TTC_Server_DSN2

This attribute is used to specify the Server DSN on the computer running the TimesTen Server. This is the Server DSN to be used if an automatic failover occurs. See the description of TTC_Server_DSN for details on setting the value of this attribute and associated attributes.

If a failover occurs, if the client cannot connect to TTC_Server_DSN or loses the connection to the DSN, it attempts to connect to TTC_Server_DSN2.

Note:

Client failover is only supported when the client is part of an active/standby pair replication configurations.

See Oracle TimesTen In-Memory Database Operations Guide for more information on automatic client failover.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set TTC_Server_DSN2 as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file TTC_Server_DSN2 Character string specifying the DSN that resides on the Server to be used if an automatic failover occurs.
Windows ODBC Data Source Administrator Server DSN2 field Character string specifying the DSN that resides on the Server to be used if an automatic failover occurs.


TTC_Timeout

The TTC_Timeout attribute sets a maximum time limit, in seconds, for a network operation that is completed by using the TimesTen Client and Server. The TTC_Timeout attribute also determines the maximum number of seconds a TimesTen Client application waits for the result from the corresponding TimesTen Server process before timing out.

The value of TTC_TIMEOUT is used in the OS select() call on the client side of a C/S connection. It is not used by SQLExecute() or OCIStmtExecute().

A value of 0 indicates that client/server operations should not timeout. Setting of this attribute is optional. If this attribute is not set, the default timeout period is 60 seconds. The maximum timeout period is 99,999 seconds. Upon timeout, the operation is interrupted, the Client application receives a timeout error and the connection is terminated. For example, if the Client application is running long queries, you may want to increase the timeout interval.

For certain queries, the client application may also set the SQL_QUERY_TIMEOUT ODBC statement option. The TimesTen Client ODBC Driver requires that SQL_QUERY_TIMEOUT must be less than TTC_TIMEOUT, unless the network timeout is set to 0. In that case, the network operation does not timeout.

The query timeout can be set using the SQLSetConnectOption ODBC call before a connection is established to the database using either the SQLConnect or SQLDriverConnect ODBC calls. Alternatively, the query timeout can be set by calling either the SQLSetConnectOption or SQLSetStmtOption ODBC calls after a connection is established to the database.

When the query timeout is set before establishing a connection to the database, the client driver does not know the network timeout value at that point. Hence, later, at connect time, the client driver silently sets the query timeout to a value slightly smaller than the network timeout value if the following are true:

When the query timeout is set after establishing a connection to the database, the client driver returns an error if the network timeout value is greater than 0, and the query timeout value greater than or equal to the network timeout value. The SQLState is set to S1000.

This attribute is not supported when shared memory is used for Client/Server inter-process communication. If set, TimesTen ignores the attribute.

Required privilege

No privilege is required to change the value of this attribute.

Setting

Set TTC_Timeout as follows.

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file TTC_Timeout A value between 0 and 99999 that represents the number of seconds that TimesTen Client waits for a connection before timing out. (The default value is 60.)
Windows ODBC Data Source Administrator Timeout Interval field A value between 0 and 99999 that represents the number of seconds that TimesTen Client waits for a connection before timing out. (The default value is 60.)


Server connection attributes

Server connection attributes are specified in the Server DSN only and are read at first connection. See "Defining Server DSNs" in Oracle TimesTen In-Memory Database Operations Guide. The attributes are used to set the number of connections to a TimesTen server, the number of servers for each DSN and the size of each connection to the server. These attributes allow you to specify multiple client connections to a single Server. By default, TimesTen creates only one connection to a Server per child process.

Note:

These attributes must be specified in the DSN. If these attributes are specified in a connection string, TimesTen ignores them and their values.

There are also TimesTen main daemon options that can be used to specify multiple Server connections. In the case that both the daemon options and these attributes have been specified, the value of the attributes takes precedence.

Server connection attributes are listed in Table 1-11, "Server connection attributes" and described in detail in this section.


MaxConnsPerServer

The MaxConnsPerServer attribute sets the maximum number of concurrent connections to the server which the DSN references.

If you want to support many connections to the Server, you must make sure that the per-process file descriptor limit for the UID that TimesTen is being run as is set to a value somewhat more than the number of concurrent child servers that are active. This is the number of anticipated concurrent client connections divided by MaxConnsPerServer.

The value of this attribute takes precedence over the setting of the value of the-maxConnsPerDSN option in the ttendaemon.options file. For details, see "Specifying multiple connections to the TimesTen Server" in Oracle TimesTen In-Memory Database Operations Guide.

For limits on the maximum number of connections to a TimesTen database, see the "System Limits" chapter in the Oracle TimesTen In-Memory Database System Tables and Limits Reference.

Required privilege

Only a user with operating system privileges on the system DSN in which this attribute is defined can change the value of this attribute to a value other than the one currently in effect.

Setting

Set MaxConnsPerServer as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file MaxConnsPerServer A value between 1 and 2047. The default is 1.
Windows ODBC Data Source Administrator Maximum Connections Per Server Process field A value between 1 and 2047. The default is 1.


ServersPerDSN

The ServersPerDSN attribute specifies the number of DSNs that can connect to a Server DSN at any given time.

The value of this attribute is only meaningful if the value of MaxConnsPerServer is greater than one. If there is only one connection per Server, the child server uses the process' main stack.

This value of this attribute takes precedence over the setting of the value of the -serversPerDSN option in the ttendaemon.options file. For details, see "Specifying multiple connections to the TimesTen Server" in Oracle TimesTen In-Memory Database Operations Guide.

Required privilege

Only a user with operating system privileges on the system DSN in which this attribute is defined can change the value of this attribute to a value other than the one currently in effect.

Setting

Set ServersPerDSN as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file ServersPerDSN A value between 1 and 2047. The default is 1.
Windows ODBC Data Source Administrator Server Processes Per DSN field A value between 1 and 2047. The default is 1.


ServerStackSize

The ServerStackSize attribute value determines the size of the stack on the Server for each connection. The value of this attribute is only meaningful if the value of MaxConnsPerServer is greater than one. If there is only one connection per Server, the child server uses the process' main stack. It is also platform-dependent, as defined in the setting below.

This value of this attribute takes precedence over the setting of the -serverStackSize option in the ttendaemon.options file. For details, see "Specifying multiple connections to the TimesTen Server" in Oracle TimesTen In-Memory Database Operations Guide.

Required privilege

Only a user with operating system privileges on the system DSN in which this attribute is defined can change the value of this attribute to a value other than the one currently in effect.

Setting

Set ServerStackSize as follows:

Where to set the attribute How the attribute is represented Setting
C or Java programs or UNIX ODBC.INI file ServerStackSize Valid values depend on the platform. The default is 128KB for 32-bit platforms and 256KB for 64-bit platforms.

If the sysconf call is available, the minimum is:

sysconf(_SC_THREAD_STACK_MIN)/ 1024

else 0

If the getrlimit call is available, the maximum value is:

getrlimit(RLIMIT_STACK, &r1);

r1.rlim_cur /1024

else 4096

The default is 128KB for 32-bit platforms and 256KB for 64-bit platforms.

Windows ODBC Data Source Administrator Server Stack Size field Valid values depend on the platform. The default is 128KB for 32-bit platforms and 256KB for 64-bit platforms.

If the sysconf call is available, the minimum is:

sysconf(_SC_THREAD_STACK_MIN)/ 1024

else 0

If the getrlimit call is available, the maximum value is:

getrlimit(RLIMIT_STACK, &r1);

r1.rlim_cur /1024

else 4096