LINDEX
Note
Official reference: LINDEX.
Read one element by index.
Syntax
LINDEX key index
Indices start at zero; negative indices count from the end, with -1 denoting the last element.
Results
| Return | Rows | Content |
|---|---|---|
| ResultSet | 1 | ELEMENT field, STRING type |
Example
RPUSH demo:queue first second
LINDEX demo:queue 0