0
오브젝트 ID로 업데이트 문서를 보려고했지만 결과를 얻지 못했습니다. 여기 내 코드는 제발 도와주세요java에서 _id를 사용하여 mongodb에서 문서를 업데이트 할 수 있습니까?
DBCollection patients= db.getCollection("Patients");
BasicDBObject doc = new BasicDBObject();
doc.put("name","seshu");
DBObject update=`new` BasicDBObject().append("_id",ObjectId("534e1c8e40a8af540cd01ff4"));
patients`enter code here`.update(update, doc);