Snapshot Transactions¶
At this moment, Exasol supports only one transaction isolation level: SERIALIZABLE
.
This is good for data consistency, but it increases the probability of transactional conflicts. For more information, see:
The most common locking problem is related to metadata selects from system views (tables, column, object sizes, etc.). JDBC and ODBC drivers provide special non-blocking calls for common metadata requests: getTables(), getColumns(). But there are no such calls for WebSocket drivers.
The only way to access metadata in a non-blocking manner with PyExasol, is an internal feature called “Snapshot Transactions”. For information, see: * Transaction Management * Snapshot mode
Recommended Usage Pattern¶
If you want to read metadata without locks, and if strict transaction integrity is not an issue, please do the following:
Open new connection with option
snapshot_transactions=True
. Use this connection to read metadata from system views only.Open another connection in normal mode and use it for everything else.
Please see c08_snapshot_transactions.py
for a common locking scenario avoided by this feature.