如何使用Spring Mongo向所有现有文档添加新字段

时间:2020-05-10 08:51:22

标签: spring mongodb spring-mongodb spring-mongo

有什么方法可以使用Spring mongo向所有现有文档中添加新字段。

寻找类似于

db.collection.update({“ all_document”},

ckeditor5-ui

1 个答案:

答案 0 :(得分:0)

有两种方法可以实现此目的。您可以使用updateupdateMany更新所有现有文档命令。

cd solr/bin
solr create -c yourCore
solr start -p 8983

Example