View on GitHub

JODA - JSON On Demand Analysis

Efficient data wrangling for semi-structured JSON documents

LISTATTRIBUTES - Object

Returns a list of all member names in the given object

Input parameters

Name Type Optional Description
obj Object False  

Output

Array[String]:

Usage

LISTATTRIBUTES(<obj>)

Examples

Example 1

Input Document

{"a":1, "b":{"c": true}}

Query

LOAD tmp
AS ('': LISTATTRIBUTES(''))

Result

["a","b"]

Example 2

Input Document

{"a":1, "b":{"c": true}}

Query

LOAD tmp
AS ('': LISTATTRIBUTES('/b'))

Result

["c"]