Table of Contents

Method UnionWith

Namespace
MongoDB.Driver
Assembly
MongoDB.Driver.dll

UnionWith<TWith>(IMongoCollection<TWith>, PipelineDefinition<TWith, TResult>)

Appends an $unionWith stage to the pipeline.

public virtual IAggregateFluent<TResult> UnionWith<TWith>(IMongoCollection<TWith> withCollection, PipelineDefinition<TWith, TResult> withPipeline = null)

Parameters

withCollection IMongoCollection<TWith>

The with collection.

withPipeline PipelineDefinition<TWith, TResult>

The with pipeline.

Returns

IAggregateFluent<TResult>

The fluent aggregate interface.

Type Parameters

TWith

The type of the with collection documents.