Click or drag to resize

AggregateFluentBase<TResult>.UnionWith<TWith> Method

Appends an $unionWith stage to the pipeline.

Namespace:  MongoDB.Driver
Assembly:  MongoDB.Driver (in MongoDB.Driver.dll) Version: 2.16.0+eeafbea0921243a5868b81984e1083a07c1f75bc
Syntax
public virtual IAggregateFluent<TResult> UnionWith<TWith>(
	IMongoCollection<TWith> withCollection,
	PipelineDefinition<TWith, TResult> withPipeline = null
)

Parameters

withCollection
Type: MongoDB.Driver.IMongoCollection<TWith>
The with collection.
withPipeline (Optional)
Type: MongoDB.Driver.PipelineDefinition<TWith, TResult>
The with pipeline.

Type Parameters

TWith
The type of the with collection documents.

Return Value

Type: IAggregateFluent<TResult>
The fluent aggregate interface.

Implements

IAggregateFluent<TResult>.UnionWith<TWith>(IMongoCollection<TWith>, PipelineDefinition<TWith, TResult>)
See Also