downloads | documentation | faq | getting help | mailing lists | licenses | wiki | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

MongoDB::__get> <MongoDB::execute
[edit] Last updated: Fri, 10 Feb 2012

view this page in

MongoDB::forceError

(PECL mongo >=0.9.5)

MongoDB::forceErrorCreates a database error

Description

public bool MongoDB::forceError ( void )

This method is not very useful for normal MongoDB use. It forces a database error to occur. This means that MongoDB::lastError() will return a generic database error after running this command.

This command is identical to running:

<?php

public function forceError() {
    return 
$this->command(array('forceerror' => 1));
}

?>

Parameters

This function has no parameters.

Return Values

Returns the database response.



add a note add a note User Contributed Notes MongoDB::forceError
There are no user contributed notes for this page.

 
show source | credits | stats | sitemap | contact | advertising | mirror sites