ZSCORE

Since 1.1.0Sorted sets

Syntax

ZSCORE key member
  • Flags: fast, readonly
  • ACL categories: @fast, @read, @sortedset
  • Arity: 3

Returns the score of member in the sorted set at key.

Reply

  • The score, as a bulk string.
  • nil if the member or the key does not exist.

Examples

> ZADD z 7 a
(integer) 1
> ZSCORE z a
"7"
> ZSCORE z nope
(nil)