Writing a query to add multiple values to a key in REDIS Hashes?

前端 未结 3 654
伪装坚强ぢ
伪装坚强ぢ 2020-12-31 16:49

I went through the command list on REDIS Hashes.Is it possible to assign multiple values to a hash key in REDIS? For instance,I am trying to represent the following table in

3条回答
  •  悲哀的现实
    2020-12-31 17:31

    I think you're misunderstanding how hashes work. You can't have two identical fields with different values. Your second HMSET command is overwriting the values from the first command. You will either need to use unique fields or a different key.

提交回复
热议问题