How can I update a document using the "_id" field? I can do it using another field, but not the "_id". I understand this field is an ObjectId, but how do I create a filter for it? Some code is below. Thanks for any help!
mongocxx::instance inst{};
mongocxx::client conn{};
auto db = conn["todos"];
builder::stream::document filter;
builder::stream::document update;
//bsoncxx::oid myoid("55f32a05c330964d296e6a11");
//THIS WORKS USING THE CATCHUP FIELD
filter << "catchup" << false;
// THIS DOES NOT WORK
//filter << "_id" << "55f32a05c330964d296e6a11";
// THIS DOES NOT WORK
//filter << "_id" << myoid;
update << "$set" << bsoncxx::builder::stream::open_document
<< "minhand" << 44 << bsoncxx::builder::stream::close_document;
db["clockdials"].update_one(filter, update);