Skip to content

JSONPath filter with recursive descent or star from current element doesn't match as expected #963

@oshadmi

Description

@oshadmi

RedisJSON 2.4.6
With

json.set doc $ '[[{"code":1},{"code":3}],[{"mode":{"code":4}},{"code":2}],[{"code":0},{"code":2}]]'

The following should not return an empty result:

127.0.0.1:6379> json.get doc '$[?(@.*.code>2)].code'
"[]"
127.0.0.1:6379> json.get doc '$[?(@..code>2)].code'
"[]"

Should return corresponding results similar to:

127.0.0.1:6379> json.get doc '$.*[?(@.code>2)].code'
"[3]"
127.0.0.1:6379> json.get doc '$..[?(@.code>2)].code'
"[3,4]"

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions