Skip to content

Cannot add litteral array with SetUnion #4809

@npen

Description

@npen

Hello,

Using SetOperators.SetUnion:

SetOperators.arrayAsSet("aField").union("anotherField")

How can I reproduce this expression that works fine in Mongo, when one field is a single value and needs to be wrapped in square brackets:

$setUnion: [ "$arrayOfStringField", [ "$stringField" ] ]

Thanks

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