Redis - Sort ID's based on Names in another Set -
i using multiple redis sets, hashes , sorted sets use-case. suppose having hash set stores id , corresponding object. (project id , content) have sets contain list of id's (list of projectids) have sorted sets sortby datetime fields , other integer scores. (sort deadline, created etc , project name). created sorted set use-case needs sort name (say project name). created project name sorted set (projectname:id value , 0 score). requirement need sort set (which contain id's) based on project name in desc or asc.
how achieve this??
read documentation sort
- should sort nameofzset nosort nameofhash->*
. better, learn how write lua scripts , execute them eval
.
Comments
Post a Comment