# SET ISOLATION statement

The SET ISOLATION statement allows a user to change the isolation level for the user's connection. Valid levels are SERIALIZABLE, REPEATABLE READ, READ COMMITTED, and READ UNCOMMITTED.

Issuing this statement always commits the current transaction. The JDBC java.sql.Connection.setTransactionIsolation method behaves almost identically to this command, with one exception: if you are using the embedded driver, and if the call to java.sql.Connection.setTransactionIsolation does not actually change the isolation level (that is, if it sets the isolation level to its current value), the current transaction is not committed.

For information about isolation levels, see "Locking, concurrency, and isolation" in the Java DB Developer's Guide. For information about the JDBC java.sql.Connection.setTransactionIsolation method, see java.sql.Connection.setTransactionIsolation method.

#### Syntax

    SET [ CURRENT ] ISOLATION [ = ]
    {
    UR | DIRTY READ | READ UNCOMMITTED
    CS | READ COMMITTED | CURSOR STABILITY
    RS |
    RR | REPEATABLE READ | SERIALIZABLE
    RESET
    }

    set isolation serializable;

Parent topic: SET statements
Related reference
SET ROLE statement
SET SCHEMA statement