SismemberCommand: Contents
  SISMEMBER _key_ _member_
    Return value
    See also

SismemberCommand

SISMEMBER _key_ _member_

Time complexity O(1)
Return 1 if member is a member of the set stored at key, otherwise0 is returned. On error a negative value is returned. Client librariesshould raise an error when a negative value is returned instead to passthe value to the caller.

Return value

Integer reply, specifically:

1 if the element is a member of the set
0 if the element is not a member of the set OR if the key does not exist
-2 if the key does not hold a set value

See also