Skip to content

add @ operator to blues jsonata #12

@tbal999

Description

@tbal999

Firstly - excellent work porting jsonata to Golang. Impressive. I have a request:

In original JSONATA they have # and @ operators which enable JOIN like operations on data (a simplification on top of usage of map and filter) i.e

$$.new.additionalfeatures @ $T1.$$.old.items @ $T2[$T1.id = $T2.id].{
    "id": $T1.id,
    "color": $T1.colour,
    "name": $T2.name
}

and currently you'd need to do something like

$$.old.items.{
    "id": $.id,
    "name": $.name,
    "color": ($filter($$.new.additionalfeatures, function($i){$i.id = $.id})).colour
}

It would be useful to have at least the @ operator added to the Go port of jsonata.

I appreciate this would be a fiddly bit of work - so it's a 'nice to have'.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions