TXID function in Amazon QLDB - Amazon Quantum Ledger Database (Amazon QLDB)

TXID function in Amazon QLDB

Important

End of support notice: Existing customers will be able to use Amazon QLDB until end of support on 07/31/2025. For more details, see Migrate an Amazon QLDB Ledger to Amazon Aurora PostgreSQL.

In Amazon QLDB, use the TXID function to return the unique transaction ID of the current statement that you're running. This is the value that is assigned to a document's txId metadata field when the current transaction is committed to the journal.

Syntax

TXID()

Arguments

None

Return type

string

Examples

SELECT TXID() FROM << 0 >> -- "L7S9iJqcn9W2M4qOEn27ay" SELECT TXID() FROM Person WHERE GovId = 'LEWISR261LL' -- "BKeMb48PNyvHWJGZHkaodG"