lua-resty-redis icon indicating copy to clipboard operation
lua-resty-redis copied to clipboard

hmget能否增加一个传入fied数组的方法?

Open andex1988 opened this issue 12 years ago • 4 comments
trafficstars

现在 red:hmget 传入的是可变参数,能否想hmset一样传入数组啊,或者安装redis 原生的命令 hmget hashname field1 field2?

andex1988 avatar Nov 20 '13 09:11 andex1988

@andex1988 This place is supposed to be English only. If you want to post in Chinese, please join the openresty (Chinese) mailing list and post there instead: https://groups.google.com/group/openresty

Below are some working examples using the hmget method:

-- HMGET myhash field1 field2 nofield
local res, err = red:hmget("myhash", "field1", "field2", "nofield")

-- HMGET myhash field1 field2 nofield
local fields = {"field1", "field2", "nofield"}
local res, err = red:hmget("myhash", unpack(fields))

agentzh avatar Nov 20 '13 19:11 agentzh

ok,thanks

andex1988 avatar Nov 21 '13 00:11 andex1988

问个问题,lua中的table数据集合太大了没办法返回数据是什么原因?

ThomasHaiKuan avatar Oct 17 '14 03:10 ThomasHaiKuan

@88069684 Please, do not use Chinese here because this place is considered English only (as mentioned above). You're recommended to post your Chinese questions to the openresty Chinese mailing list instead. See http://openresty.org/#Community

Thank you for your cooperation.

agentzh avatar Oct 17 '14 04:10 agentzh