Arguments
str
required
The key of the json entry.
str
required
The path of the array.
int
required
The start index of the range.
int
required
The stop index of the range.
Response
The length of the array after the trimming.
Documentation Index
Fetch the complete documentation index at: /llms.txt
Use this file to discover all available pages before exploring further.
length = redis.json.arrtrim("key", "$.path.to.array", 2, 10)
Trim an array so that it contains only the specified inclusive range of elements.
length = redis.json.arrtrim("key", "$.path.to.array", 2, 10)
Was this page helpful?