Using redigo, I'm trying to use HMGET. I'm passing a string slice as param in field. It is not working, returning empty result.
func HMGET(c redis.Conn, field []string)(){
if err := c.Send("HMGET", HashName, field); err != nil {
return nil, err
}
if err := c.Flush(); err != nil {
return nil, err
}
rval, err := c.Receive()
if err != nil {
return nil, err
}
return rval, nil
}
This is working
c.Send("HMGET", r.HashName, "1", "2", "3")
Any suggestions why field when passed as param is not working?