ZINCRBY

Adds an increment to a sorted-set member's score.

Sorted sets · Example verified

Syntax covered here

ZINCRBY key increment member

The case updates an existing member and returns its resulting score.

Tested example & replies

Requests below run in order against an empty database. Each connection authenticates with the fixture password first. Quoted values are strings; null is a nil reply; arrays preserve RESP order.

# connection: default
> ZADD scores 1 a 2 b
2
# connection: default
> ZINCRBY scores 2 a
"3"