Redis Zrangebylex 命令

Redis 教程 · 2019-03-07 21:44:50

Redis Zrangebylex 通过字典区间返回有序集合的成员。

语法

redis Zrange 命令基本语法如下:

redis 127.0.0.1:6379> ZRANGEBYLEX key min max [LIMIT offset count]

可用版本

>= 2.8.9

返回值

指定区间内的元素列表。

实例

redis 127.0.0.1:6379> ZADD myzset 0 a 0 b 0 c 0 d 0 e 0 f 0 g
(integer) 7
redis 127.0.0.1:6379> ZRANGEBYLEX myzset - [c
1) "a"
2) "b"
3) "c"
redis 127.0.0.1:6379> ZRANGEBYLEX myzset - (c
1) "a"
2) "b"
redis 127.0.0.1:6379> ZRANGEBYLEX myzset [aaa (g
1) "b"
2) "c"
3) "d"
4) "e"
5) "f"
redis> 

点击查看所有 Redis 教程 文章: https://codercto.com/courses/l/33.html

查看所有标签

The Haskell School of Expression

The Haskell School of Expression

Paul Hudak / Cambridge University Press / 2000-01 / USD 95.00

Functional programming is a style of programming that emphasizes the use of functions (in contrast to object-oriented programming, which emphasizes the use of objects). It has become popular in recen......一起来看看 《The Haskell School of Expression》 这本书的介绍吧!

JS 压缩/解压工具
JS 压缩/解压工具

在线压缩/解压 JS 代码

图片转BASE64编码
图片转BASE64编码

在线图片转Base64编码工具

URL 编码/解码
URL 编码/解码

URL 编码/解码