Skip to content

MongoCursor ​

Class

constructor ​

db ​

single ​

exec ​

typescript
public exec(): Promise<any>
public exec(): Promise<any>

limit ​

typescript
public limit(n: Parameter): Promise<any>
public limit(n: Parameter): Promise<any>

populate ​

typescript
public populate(fields: Parameter): Promise<any>
public populate(fields: Parameter): Promise<any>

Populate a field with data from another collection. When a string is used, the value will be populated from the collection with same name. When an object is used, the value will be populated from the collection with the name specified in the collection property.

Population is a complex operation and less performant with nested fields.

select ​

typescript
public select(fields: Parameter): Promise<any>
public select(fields: Parameter): Promise<any>

skip ​

typescript
public skip(n: Parameter): Promise<any>
public skip(n: Parameter): Promise<any>

sort ​

typescript
public sort(config: Parameter): Promise<any>
public sort(config: Parameter): Promise<any>