The recently added json_path_exists behaves wrongly when json param is null.
For example:
SELECT json_path_exists(null, '$.a')
OUTPUT:
Failed to plan SQL: Error during planning: Error during planning: Coercion from [Null, Utf8] to the signature Exact([Binary, Utf8]) failed. and No function matches the given name and argument types 'json_path_exists(Null, Utf8)'. You might need to add explicit type casts.\n\tCandidate functions:\n\tjson_path_exists(Binary, Utf8)
What type of bug is this?
Incorrect result
What subsystems are affected?
Standalone mode, Frontend
Minimal reproduce step
The recently added
json_path_exists
behaves wrongly when json param is null. For example:What did you expect to see?
According to JSON_PATH_MATCH, the result should be null.
What did you see instead?
Error.
What operating system did you use?
macOS 15.0.1
What version of GreptimeDB did you use?
0.9.5
Relevant log output and stack trace
No response