Returns the score of a member in a sorted set.
ZSCORE key member
Returns the score of member in the sorted set at
key.
If member does not exist in the sorted set, or
key does not exist, nil is returned.
One of the following:
Bulk string reply: the score of the member (a double-precision floating point number), represented as a string.
Nil reply: if member does not exist in the sorted set, or the key does not exist.
One of the following:
Double reply: the score of the member (a double-precision floating point number).
Null reply: if member does not exist in the sorted set, or the key does not exist.
O(1)
@fast @read @sortedset
127.0.0.1:6379> ZADD myzset 1 "one"
(integer) 1
127.0.0.1:6379> ZSCORE myzset "one"
"1"
BZMPOP, BZPOPMAX, BZPOPMIN, ZADD, ZCARD, ZCOUNT, ZDIFF, ZDIFFSTORE, ZINCRBY, ZINTER, ZINTERCARD, ZINTERSTORE, ZLEXCOUNT, ZMPOP, ZMSCORE, ZPOPMAX, ZPOPMIN, ZRANDMEMBER, ZRANGE, ZRANGEBYLEX, ZRANGEBYSCORE, ZRANGESTORE, ZRANK, ZREM, ZREMRANGEBYLEX, ZREMRANGEBYRANK, ZREMRANGEBYSCORE, ZREVRANGE, ZREVRANGEBYLEX, ZREVRANGEBYSCORE, ZREVRANK, ZSCAN, ZUNION, ZUNIONSTORE.