📣
TiDB Cloud Premium is now in public preview. Unlimited growth, instant elasticity, advanced security for enterprise workloads. Try it out →

IS_NULL_VALUE



Checks whether the input value is a JSON null. Please note that this function examines JSON null, not SQL NULL. To check if a value is SQL NULL, use IS_NULL.

{ "name": "John", "age": null }

Syntax

IS_NULL_VALUE( <expr> )

Return Type

Returns true if the input value is a JSON null, and false otherwise.

Examples

SELECT IS_NULL_VALUE(PARSE_JSON('{"name":"John", "age":null}') :age), --JSON null IS_NULL(NULL); --SQL NULL ┌──────────────────────────────────────────────────────────────────────────────┐ │ is_null_value(parse_json('{"name":"john", "age":null}'):age) │ is_null(null) │ ├──────────────────────────────────────────────────────────────┼───────────────┤ │ truetrue │ └──────────────────────────────────────────────────────────────────────────────┘

Was this page helpful?