mongodb\Migration insert()

insert() public method

Inserts new data into collection.

public \MongoDB\BSON\ObjectID insert ( $collection, $data, $options = [] )
$collection array|string

Collection name.

$data array|object

Data to be inserted.

$options array

List of options in format: optionName => optionValue.

return \MongoDB\BSON\ObjectID

New record id instance.

doc_Yii
2016-10-30 17:08:51
Comments
Leave a Comment

Please login to continue.