欢迎访问 生活随笔!

生活随笔

当前位置: 首页 >

(error) ERR wrong number of arguments for 'hmget' command

发布时间:2023/12/31 45 豆豆
生活随笔 收集整理的这篇文章主要介绍了 (error) ERR wrong number of arguments for 'hmget' command 小编觉得挺不错的,现在分享给大家,帮大家做个参考.

首先不存在hmgetall这样的命令,

localhost:6379> hgetall people_info

  • “\xe5\xbc\xa0\xe5\xb0\x8f\xe4\xba\x8c”
  • “{“age”: 17, “salary”: 100, “address”: “\u5317\u4eac”}”
  • “\xe7\x8e\x8b\xe5\xb0\x8f\xe4\xb8\x89”
  • “{“age”: 20, “salary”: 9999, “address”: “\u56db\u5ddd”}”
  • “\xe5\xbc\xa0\xe5\xb0\x8f\xe5\x9b\x9b”
  • “{“age”: 30, “salary”: 0, “address”: “\u5c71\u4e1c”}”
  • “\xe5\x88\x98\xe5\xb0\x8f\xe4\xba\x94”
  • “{“age”: 24, “salary”: 24, “address”: “\u6cb3\u5317”}”
  • “\xe5\x91\xa8\xe5\xb0\x8f\xe5\x85\xad”
  • “{“age”: 56, “salary”: 87, “address”: “\u9999\u6e2f”}”
  • 正确用法如下:
    localhost:6379> hmget people_info "\xe5\xbc\xa0\xe5\xb0\x8f\xe4\xba\x8c"

  • “{“age”: 17, “salary”: 100, “address”: “\u5317\u4eac”}”
  • 或者:
    localhost:6379> hmget people_info "张小二"

  • “{“age”: 17, “salary”: 100, “address”: “\u5317\u4eac”}”
  • 上面加粗的地方是命令

    总结

    以上是生活随笔为你收集整理的(error) ERR wrong number of arguments for 'hmget' command的全部内容,希望文章能够帮你解决所遇到的问题。

    如果觉得生活随笔网站内容还不错,欢迎将生活随笔推荐给好友。