Skip to content

transactions:get

Terminal window
rai transactions:get [OPTIONS]

Gets details for a specified transaction processed by a RelationalAI (RAI) engine. Requires the eng_user application role.

OptionTypeDescription
--idIntegerThe ID of the transaction to get details for. If missing, you are prompted to enter the ID interactively.

Transactions can have the following states:

StateDescription
CREATEDThe transaction has been accepted but is not yet in the engine queue. If it remains in this state, the engine’s resources are at capacity. Consider increasing the engine size or cancelling the transaction and running it on a different engine.
QUEUEDThe transaction is in the engine’s queue. If it remains in this state, the engine’s concurrency limit has been reached. Wait for the transaction to leave the queue or cancel it and rerun on a different engine.
RUNNINGThe transaction is being processed by the engine.
CANCELINGThe transaction is being cancelled.
COMPLETEDThe transaction has been successfully processed.
ABORTEDThe transaction was cancelled or aborted due to an error. Check the ABORT_REASON field for more details.

Use the transactions:get command to get details for a specific transaction by ID:

Terminal window
rai transactions:get --id 01b439b2-0002-6941-0051-c0070498679a
---------------------------------------------------
▰▰▰▰ Transaction fetched
Field Value
─────────────────────────────────────────────────────
id 01b439b2-0002-6941-0051-c0070498679a
database myModel
state COMPLETED
abort_reason N/A
read_only True
created_by user@company.com
created_on 2024-05-09 19:26:09
finished_at 2024-05-09 19:26:09
duration 0.2s
---------------------------------------------------

Transaction IDs can be found using the transactions:list command. IDs are also reported by the RAI debugger.

If you do not provide the --id option, you are prompted to enter the ID interactively:

Terminal window
rai transactions:get
---------------------------------------------------
? Transaction id: 01b439b2-0002-6941-0051-c0070498679a
▰▰▰▰ Transaction fetched
Field Value
─────────────────────────────────────────────────────
id 01b439b2-0002-6941-0051-c0070498679a
database myModel
state COMPLETED
abort_reason N/A
read_only True
created_by jane.doe@relational.ai
created_on 2024-05-09 19:26:09
finished_at 2024-05-09 19:26:09
duration 0.2s
---------------------------------------------------

See Compute Resources for more information on RAI engines and engine management.