
- Redis Basics
- Redis - Home
- Redis - Overview
- Redis - Environment
- Redis - Configuration
- Redis - Data types
- Redis Commands
- Redis - Commands
- Redis - Keys
- Redis - Strings
- Redis - Hashes
- Redis - Lists
- Redis - Sets
- Redis - Sorted Sets
- Redis - HyperLogLog
- Redis - Publish Subscribe
- Redis - Transactions
- Redis - Scripting
- Redis - Connections
- Redis - Server
- Redis Advanced
- Redis - Backup
- Redis - Security
- Redis - Benchmarks
- Redis - Client Connection
- Redis - Pipelining
- Redis - Partitioning
- Redis - Java
- Redis - Php
- Redis Useful Resources
- Redis - Quick Guide
- Redis - Useful Resources
- Redis - Discussion
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
Redis - Sorted Set Zlexcount Command
When all the elements in a sorted set are inserted with the same score, in order to force lexicographical ordering, this command returns the number of elements in the sorted set at the key with a value between min and max.
Return Value
Integer reply, the number of elements in the specified score range.
Syntax
Following is the basic syntax of Redis ZLEXCOUNT command.
redis 127.0.0.1:6379> ZLEXCOUNT KEY MIN MAX
Example
redis 127.0.0.1:6379> ZADD myzset 0 a 0 b 0 c 0 d 0 e (integer) 5 redis 127.0.0.1:6379> ZADD myzset 0 f 0 g (integer) 2 redis 127.0.0.1:6379> ZLEXCOUNT myzset - + (integer) 7 redis 127.0.0.1:6379> ZLEXCOUNT myzset [b [f (integer) 5
redis_sorted_sets.htm
Advertisements