WOLFRAM

MongoLink`
MongoLink`

MongoCollectionCount

[Experimental]

MongoCollectionCount[MongoCollection[]]

counts the number of documents in MongoCollection.

MongoCollectionCount[MongoCollection[], query]

counts the number of documents in MongoCollection matching the query query.

Details and Options

Examples

Basic Examples  (1)Summary of the most common use cases

Connect to a client:

Out[1]=1

Connect to a the "WolframTestCollection" collection in the "WolframTestDB" database:

Out[1]=1

Count the number of documents in the collection:

Out[1]=1

Count the number of documents in the collection that match the query <|"sex""female"|>:

Out[1]=1
Wolfram Research (2018), MongoCollectionCount, Wolfram Language function, https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html.
Wolfram Research (2018), MongoCollectionCount, Wolfram Language function, https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html.

Text

Wolfram Research (2018), MongoCollectionCount, Wolfram Language function, https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html.

Wolfram Research (2018), MongoCollectionCount, Wolfram Language function, https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html.

CMS

Wolfram Language. 2018. "MongoCollectionCount." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html.

Wolfram Language. 2018. "MongoCollectionCount." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html.

APA

Wolfram Language. (2018). MongoCollectionCount. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html

Wolfram Language. (2018). MongoCollectionCount. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html

BibTeX

@misc{reference.wolfram_2025_mongocollectioncount, author="Wolfram Research", title="{MongoCollectionCount}", year="2018", howpublished="\url{https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html}", note=[Accessed: 05-June-2025 ]}

@misc{reference.wolfram_2025_mongocollectioncount, author="Wolfram Research", title="{MongoCollectionCount}", year="2018", howpublished="\url{https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html}", note=[Accessed: 05-June-2025 ]}

BibLaTeX

@online{reference.wolfram_2025_mongocollectioncount, organization={Wolfram Research}, title={MongoCollectionCount}, year={2018}, url={https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html}, note=[Accessed: 05-June-2025 ]}

@online{reference.wolfram_2025_mongocollectioncount, organization={Wolfram Research}, title={MongoCollectionCount}, year={2018}, url={https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionCount.html}, note=[Accessed: 05-June-2025 ]}