mongodb\Migration save()

save() public method

Update the existing database data, otherwise insert this data

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

Collection name.

$data array|object

Data to be updated/inserted.

$options array

List of options in format: optionName => optionValue.

return \MongoDB\BSON\ObjectID

Updated/new record id instance.

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

Please login to continue.