Skip to content

is it possible to filter NULLs? #9

@arenas-guerrero-julian

Description

@arenas-guerrero-julian

Hi,

I have the following JSON:

[{
    "author": [
        {
            "fullname": "some fullname",
            "rank": 3
        },
        {
            "fullname": "other fullname",
            "pid": {
                "id": {
                    "scheme": "orcid",
                    "value": "0000-0000-0000-0000"
                },
                "provenance": {
                    "provenance": "Harvested",
                    "trust": "0.91"
                }
            },
            "rank": 4
        }
    ]
}]

and the following jsonpath expression:
$.*.author[*].(fullname,pid.id.value,pid.id.scheme)

I am getting the following result:
[{'fullname': 'some fullname', 'pid.id.value': None, 'pid.id.scheme': None}, {'fullname': 'other fullname', 'pid.id.value': '0000-0000-0000-0000', 'pid.id.scheme': 'orcid'}]

I am getting None values, is there a way to filter them?

Thank you in advance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions