The command SET TRANSACTION {READ ONLY | READ WRITE | WRITE} is based on ANSI SQL. It allows the user to specify whether the transaction is allowed to make any changes to data.
The transaction level read-write level setting can be used with dynamic load balancing in HotStandby configuration. If the assigned workload server is Secondary, it can be changed programmatically to the Primary for the time of one transaction. At the transaction level, the following statement changes the workload connection server to Primary for the time of one transaction: SET TRANSACTION WRITE (nonstandard)
The affected transaction is the one that is started with the statement. After the transaction has been executed at the Primary, the workload connection server is reverted to the session default.