db.yourcollection.update({
"需要删除的字段": {
"$exists": true
}
}, {
"$unset": {
"需要删除的字段":null
}
}, {
multi: true
});
mongodb清空某个字段
猜你喜欢
转载自blog.csdn.net/fall_hat/article/details/104531245
今日推荐
周排行