Return the keys in the object that's referenced by path
key
is key to parse. Returns null
for nonexistent keys.
path
is JSONPath to specify. Default is root $
. Returns null
for nonexistant path.
JSON.OBJKEYS returns an array of array replies for each path, an array of the key names in the object as a bulk string reply, or nil
if the matching JSON value is not an object.
For more information about replies, see Redis serialization protocol specification.
{{< highlight bash >}} redis> JSON.SET doc $ '{"a":[3], "nested": {"a": {"b":2, "c": 1}}}' OK redis> JSON.OBJKEYS doc $..a
- (nil)
-
- "b"
- "c" {{< / highlight >}}
JSON.ARRINDEX
| JSON.ARRINSERT