spring-data-mongodb icon indicating copy to clipboard operation
spring-data-mongodb copied to clipboard

Cannot add litteral array with SetUnion

Open npen opened this issue 1 year ago • 2 comments
trafficstars

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

npen avatar Oct 11 '24 16:10 npen

Thanks for getting in touch, but it feels like this is a question that would be better suited to Stack Overflow. We prefer to use GitHub issues only for bugs and enhancements. Feel free to update this issue with a link to the re-posted question (so that other people can find it) or add some more details if you feel this is a genuine bug.

christophstrobl avatar Oct 14 '24 05:10 christophstrobl

If you would like us to look at this issue, please provide the requested information. If the information is not provided within the next 7 days this issue will be closed.

spring-projects-issues avatar Oct 21 '24 05:10 spring-projects-issues

Closing due to lack of requested feedback. If you would like us to look at this issue, please provide the requested information and we will re-open the issue.

spring-projects-issues avatar Oct 28 '24 05:10 spring-projects-issues