JSON.MGET

Since 1.1.0JSON

Syntax

JSON.MGET key [key ...] path
  • Flags: readonly
  • ACL categories: @json, @read, @slow
  • Arity: -2

Evaluates path in the JSON documents at several keys.

Reply

  • An array with one element per key: the JSON text the path gives, or nil for a key that does not exist or is not a JSON document.

Examples

> JSON.MSET a $ 1 b $ 2
OK
> JSON.MGET a b missing $
1) "[1]"
2) "[2]"
3) (nil)