
- 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 Zrem Command
Redis ZREM command removes the specified members from the sorted set stored at the key. Non-existing members are ignored. An error is returned when the key exists and does not hold a sorted set.
Return Value
Integer, number of members removed from the sorted set, not including non-existing members.
Syntax
Following is the basic syntax of Redis ZREM command.
redis 127.0.0.1:6379> ZREM key member [member ...]
Example
redis 127.0.0.1:6379> ZADD myzset 0 a 1 b 2 c 3 d 4 e (integer) 5 redis 127.0.0.1:6379> ZREM myzset b (integer) 1 redis 127.0.0.1:6379> ZRANGE myzset 0 -1 WITHSCORES 1) "a" 2) "0" 3) "c" 4) "2" 5) "d" 6) "3" 7) "e" 8) "4"
redis_sorted_sets.htm
Advertisements