EXEC
- Usage:
-
EXEC [ IFEQ key value | IFNE key value | NX nonexisting-key | XX existing-key ] [ [ IFEQ key value | IFNE key value | NX nonexisting-key | XX existing-key ] ... ]
- Complexity:
- O(N) for N conditions, plus the complexity of commands in the transaction
- Since:
- 1.2.0
- ACL Categories:
- @slow, @transaction
Executes all previously queued commands in a transaction and restores the connection state to normal.
When using WATCH, EXEC will execute commands only if the watched keys were
not modified, allowing for a check-and-set mechanism.
Reply#
One of the following:
- Array: each element being the reply to each of the commands in the atomic transaction.
- Null: the transaction was aborted because a
WATCHed key was touched.
History#
| Version | Change |
|---|---|
| 9.2.0 | Added the |