Prior to version 1.5.0 of the driver it was possible to use MongoCollection::batchInsert(),
however, as of 1.5.0 that method is now discouraged.
You can use Collection::createBatchInsert()
public batchInsert ( array $rows, $validate = true ) : |
||
$rows | array | list of documents to insert, defined as arrays |
return |