Closed rhnkyr closed 9 years ago
You should be able to do something like this:
$collection = $database->collection('articles');
$newName = 'Bryan';
$collection->update(function ($query) use ($newName) {
$query->set('creator.name', $newName)
->where('creator.mid', ...);
});
@bcrowe thank you m8.
How to update multiple docs at the same time.
For instance my doc :
i find docs by creator.mid and i want to set creator name every docs in collection.