RPUSH

Since 1.1.0Lists

Syntax

RPUSH key value [value ...]
  • Flags: fast, write
  • ACL categories: @fast, @list, @write
  • Arity: -3

Adds values to the tail (right) of the list at key, in the order given. A missing key is created.

Reply

  • The length of the list afterwards.
  • A WRONGTYPE error if the key is not a list.

Examples

> RPUSH l a b c
(integer) 3
> LRANGE l 0 -1
1) "a"
2) "b"
3) "c"