Amazon Redshift
Database Developer Guide (API Version 2012-12-01)


Displays information to identify and resolve lock conflicts with database tables.

A lock conflict can occur when two or more users are loading, inserting, deleting, or updating data rows in the same table at the same time. Every time a lock conflict occurs, Amazon Redshift writes a data row to the STL_TR_CONFLICT system table.

This table is visible only to superusers. For more information, see Visibility of Data in System Tables and Views.

Table Columns

Column Name Data Type Description
xact_id bigint Transaction ID for the rolled back transaction.
process_id bigint Process associated with the lock.
xact_start_ts timestamp Timestamp for the transaction start.
abort_time timestamp Time that the transaction was aborted.
table_id bigint Table ID for the table where the conflict occurred.

Sample Query

For examples of lock conflicts, see Managing Concurrent Write Operations. To return information about conflicts that involved a particular table, run a query that specifies the table ID:

select * from stl_tr_conflict where table_id=100234 order by xact_start_ts; xact_id|process_| xact_start_ts | abort_time |table_ |id | | |id -------+--------+--------------------------+--------------------------+------ 1876 | 8551 |2010-03-30 09:19:15.852326|2010-03-30 09:20:17.582499|100234 1928 | 15034 |2010-03-30 13:20:00.636045|2010-03-30 13:20:47.766817|100234 1991 | 23753 |2010-04-01 13:05:01.220059|2010-04-01 13:06:06.94098 |100234 2002 | 23679 |2010-04-01 13:17:05.173473|2010-04-01 13:18:27.898655|100234 (4 rows)

You can get the table ID from the DETAIL section of the error message for serializability violations (error 1023).