HSET
Adds or updates fields in a hash.
Hashes · Example verified
Syntax covered here
HSET key field value [field value ...]Updating one existing field while adding another counts only the new field; fields are merged rather than replacing the entire hash.
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
> HSET user name Ada
1
# connection: default
> HSET user name Bob city Paris
1