SCAN result not processed correctly
I've tried to get the SCAN command to work, but ran into a problem that the redis reply is not processed correctly.
According to the Redis documentation:
SCAN, SSCAN, HSCAN and ZSCAN return a two elements multi-bulk reply, where the first element is a string representing an unsigned 64 bit number (the cursor), and the second element is a multi-bulk with an array of elements.
When using redox, the only result I get back is the first element (cursor). While debugging, I noticed that the reader in the redis context does have the entire result (including the 2nd part), so this doesn't seem to be a hiredis issue.
Show some code! Are you templating on redisReply*?
No, I was using std::vectorstd::string for the result type. When it turns out that using redisReply for the result type works, I'll close this issue.
Thanks!
Ok. I believe it should, since that is the direct hiredis reply. The SCAN reply doesn't fit the form of any others of the current templates On Jun 8, 2015 12:17 AM, "bveldhoen" [email protected] wrote:
No, I was using std::vectorstd::string for the result type. When it turns out that using redisReply for the result type works, I'll close this issue.
Thanks!
— Reply to this email directly or view it on GitHub https://github.com/hmartiro/redox/issues/16#issuecomment-109889430.