Package dev.morphia.aggregation.stages
Class UnionWith
java.lang.Object
dev.morphia.aggregation.stages.Stage
dev.morphia.aggregation.stages.UnionWith
Performs a union of two collections; i.e. $unionWith combines pipeline results from two collections into a single result set. The
stage outputs the combined result set (including duplicates) to the next stage.
- Since:
- 2.1
-
Method Details
-
unionWith
Performs a union of two collections; i.e. $unionWith combines pipeline results from two collections into a single result set. The stage outputs the combined result set (including duplicates) to the next stage.- Parameters:
stages
- the pipeline stages- Returns:
- the new Stage
- Since:
- 3.0
- MongoDB documentation
- Aggregration Pipeline Stage: $unionWith
- Since server release
- 4.4
-
unionWith
Performs a union of two collections; i.e. $unionWith combines pipeline results from two collections into a single result set. The stage outputs the combined result set (including duplicates) to the next stage.- Parameters:
type
- the type to perform the pipeline againststages
- the pipeline stages- Returns:
- the new Stage
- MongoDB documentation
- Aggregration Pipeline Stage: $unionWith
- Since server release
- 4.4
-
unionWith
Performs a union of two collections; i.e. $unionWith combines pipeline results from two collections into a single result set. The stage outputs the combined result set (including duplicates) to the next stage.- Parameters:
collection
- the collection to perform the pipeline againststages
- the pipeline stages- Returns:
- the new stage
- MongoDB documentation
- Aggregration Pipeline Stage: $unionWith
- Since server release
- 4.4
-