JSON.ARRINSERT
Since 1.1.0JSON
Syntax
JSON.ARRINSERT key path index value [value ...]Inserts values, each JSON text, before index in each array path matches. Negative indexes count from the end.
Reply
- The new lengths.
Examples
> JSON.SET d $ '{"tags":["math","code"]}'
OK
> JSON.ARRINSERT d $.tags 0 '"first"'
1) (integer) 3