Isolation

Description

Sets the isolation level to use when connecting to the database.

In multiuser databases, transactions initiated by different users can overlap. If these transactions access common data in the database, they can overwrite each other or collide.

To prevent concurrent transactions from interfering with each other and compromising the integrity of your database, you can set the isolation level when you connect to the database. Isolation levels are used by .NET Framework data providers when performing a transaction.

PowerBuilder uses the Isolation database parameter to allow you to set various database lock options. Each value corresponds to an isolation level defined in the .NET Framework.

NoteWhen to specify the Isolation value You must set the Isolation value before you connect to the database. The Isolation value takes effect only when the database connection occurs. Changes made to the Isolation value after the connection occurs have no effect on the current connection.

Applies to

Syntax

Isolation='value'

Parameter

Description

value

A string specifying the isolation level. Values correspond to members of the .NET Framework IsolationLevel enumeration:

  • TC – Chaos

  • None specified – The default isolation level for the DBMS (Default)

  • RC – Read Committed

  • RU – Read Uncommitted

  • RR – Repeatable Read

  • TS – Serializable Transactions

Default

The default lock value depends on how your database is configured. For information, see your DBMS documentation.

Examples

Example 1

Example 1 To set the Isolation value to RC (Read Committed):

NoteUsing the example in code If you specify Isolation Level in your database profile, the syntax displays on the Preview page in the Database Profile Setup dialog box. You can copy the syntax from the Preview page into your code.