SINTERSTORE
Since 1.1.0Sets
Syntax
SINTERSTORE destination key [key ...]Stores the intersection of the given sets, as SINTER computes it, at destination, replacing whatever was there, and its expiry. An empty result leaves no key at destination.
Reply
- The number of members stored.
Examples
> SADD x a b c d
(integer) 4
> SADD y c d e
(integer) 3
> SET old v EX 100
OK
> SINTERSTORE old x y
(integer) 2
> TTL old
(integer) -1