View on GitHub

JODA - JSON On Demand Analysis

Efficient data wrangling for semi-structured JSON documents

EXISTS - Type

Checks if the given attribute exists.

Input parameters

Name Type Optional Description
x Any False The attribute to check for existence

Output

Bool: True if it exists, false otherwise

Usage

EXISTS(<x>)

Examples

Example 1

Input Document

{"doc": 1}

Query

LOAD tmp
AS ('': EXISTS('/doc'))

Result

true

Example 2

Input Document

{"doc": 1}

Query

LOAD tmp
AS ('': EXISTS('/array'))

Result

false