DISCARD

Since 1.1.0Transactions

Syntax

DISCARD
  • Flags: fast
  • ACL categories: @fast, @transaction
  • Arity: 1

Drops the commands queued since MULTI, ends the transaction, and stops watching keys.

Reply

  • OK.
  • ERR DISCARD without MULTI outside a transaction.

Examples

> MULTI
OK
> SET z 1
QUEUED
> DISCARD
OK
> EXISTS z
(integer) 0