Quantcast
Channel: How do I find the index of the first occurrence of a score in a sorted Redis set? - Stack Overflow
Browsing latest articles
Browse All 2 View Live

Answer by sazzad for How do I find the index of the first occurrence of a...

You can use ZCOUNT from negative infinity to your specific score to find the index. For example, in following sorted set: > ZADD dewey 1 first 3 second 8 third 21 fourth 55 fifth (integer) 5 To find...

View Article


How do I find the index of the first occurrence of a score in a sorted Redis...

I'm writing a search engine using Dewey Decimal call numbers to categorize information. The scheme is as follows: 123.45 2 is a sub-category of 1. 3 is a sub-category of 2. 4 a sub-category of 3. Etc....

View Article

Browsing latest articles
Browse All 2 View Live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>