MongoLink`
MongoLink`

MongoCollectionInsert

MongoCollectionInsert[MongoCollection[],doc]

inserts a document doc into the collection.

MongoCollectionInsert[MongoCollection[],{doc1,,docn}]

inserts n documents into the collection.

更多信息和选项

范例

基本范例  (1)

Connect to a client:

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

Create an data association to represent a document:

Insert one document into the collection:

Obtain a list of the primary keys of the inserted documents:

Create an data association to represent a series of documents:

Insert many documents into the collection:

Wolfram Research (2018),MongoCollectionInsert,Wolfram 语言函数,https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionInsert.html.

文本

Wolfram Research (2018),MongoCollectionInsert,Wolfram 语言函数,https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionInsert.html.

CMS

Wolfram 语言. 2018. "MongoCollectionInsert." Wolfram 语言与系统参考资料中心. Wolfram Research. https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionInsert.html.

APA

Wolfram 语言. (2018). MongoCollectionInsert. Wolfram 语言与系统参考资料中心. 追溯自 https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionInsert.html 年

BibTeX

@misc{reference.wolfram_2024_mongocollectioninsert, author="Wolfram Research", title="{MongoCollectionInsert}", year="2018", howpublished="\url{https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionInsert.html}", note=[Accessed: 25-November-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_mongocollectioninsert, organization={Wolfram Research}, title={MongoCollectionInsert}, year={2018}, url={https://reference.wolfram.com/language/MongoLink/ref/MongoCollectionInsert.html}, note=[Accessed: 25-November-2024 ]}