search

Home  >  Q&A  >  body text

phpredis - redis zadd bug

调用phpredis的zadd命令,score值大于999时会出现bug。
比如score值为245970,再调用zScore时获取的值就是245,好像是只能保留最高三位。
但是在另一台服务器上就正常,哪位大神有遇到类似的情况?

伊谢尔伦伊谢尔伦2796 days ago914

reply all(1)I'll reply

  • 黄舟

    黄舟2017-04-24 09:11:58

    Okay, I found the answer by searching on the Internet, asking and answering it myself.
    The first solution, https://github.com/phpredis/phpredis/commit/83f3440b889c79291d369d83ce..., modify the source code and then compile and install.
    The second option is git clone -b php-numencode https://github.com/nicolasff/phpredis.git. Re-download the fixed version of phpredis installation.

    reply
    0
  • Cancelreply