interface Merge {
    $merge: {
        into: string | {
            coll: string;
            db: string;
        };
        let?: Record<string, any>;
        on?: string | string[];
        whenMatched?: "replace" | "merge" | "keepExisting" | "fail" | (AddFields | mongoose.PipelineStage.Project | ReplaceRoot | ReplaceWith | Set | Unset)[];
        whenNotMatched?: "fail" | "insert" | "discard";
    };
}

Properties

Properties

$merge: {
    into: string | {
        coll: string;
        db: string;
    };
    let?: Record<string, any>;
    on?: string | string[];
    whenMatched?: "replace" | "merge" | "keepExisting" | "fail" | (AddFields | mongoose.PipelineStage.Project | ReplaceRoot | ReplaceWith | Set | Unset)[];
    whenNotMatched?: "fail" | "insert" | "discard";
}

Type declaration

  • into: string | {
        coll: string;
        db: string;
    }
  • Optional let?: Record<string, any>
  • Optional on?: string | string[]
  • Optional whenMatched?: "replace" | "merge" | "keepExisting" | "fail" | (AddFields | mongoose.PipelineStage.Project | ReplaceRoot | ReplaceWith | Set | Unset)[]
  • Optional whenNotMatched?: "fail" | "insert" | "discard"