Results of 1 - 10 of about 18 for writeConcernError (0.001 sec.)
- The MongoDB\Driver\WriteConcernError class | PHP 8.3 13349
- The MongoDB\Driver\WriteConcernError class (mongodb >=1.0.0) はじめに The MongoDB\Driver\WriteConcernError class encapsulates information about a write concern error and may be returned by MongoDB\Driver\WriteResult::getWriteConcernError()
... . クラス概要 final class MongoDB\Driver\WriteConcernError { /* プロパティ */ public readonly string $ message ; public readonly int $ code ; public readonly ? object $ info ; /* メ ... r null if not available. 変更履歴 バージョン 説明 PECL mongodb 2.3.0 Added public readonly properties. 目次 MongoDB\Driver\WriteConcernError::getCode — Returns the WriteConcernError's error code MongoDB\Driver\WriteConcernError::getInfo — Returns metadata documen ... t for the WriteConcernError MongoDB\Driver\WriteConcernError::getMessage — Returns the WriteConcernError's error message 他のマニュアルの関連ページ Li ...
-
https://man.mtool.work/php/8.3/class.mongodb-driver-writeconcernerror.html
- MongoDB\Driver\WriteConcernError::getCode — Returns the WriteConcernError's err... 10861
- MongoDB\Driver\WriteConcernError::getCode (mongodb >=1.0.0) MongoDB\Driver\WriteConcernError::getCode — Returns the WriteConcernError's error code 説明 final public function MongoDB\Driver\WriteConcernError::getCode (): int パラメータ この関
... 数にはパラメータはありません。 戻り値 Returns the WriteConcernError's error code. エラー / 例外 Throws MongoDB\Driver\Exception\InvalidArgumentException on argument parsing errors. 例 例1 Mo ... ngoDB\Driver\WriteConcernError::getCode() example <?php $manager = new MongoDB\Driver\Manager ( "mongodb://rs1.example.com,rs2.example.com/?replicaSet=my ... ' => $writeConcern ]); } catch( MongoDB\Driver\Exception\BulkWriteException $e ) { var_dump ( $e -> getWriteResult ()-> getWriteConcernError ()-> getCode ()); } ?> 上の例の出力は、 たとえば以下のようになります。 int(64) 参考 » Write Concern reference ...
-
https://man.mtool.work/php/8.3/mongodb-driver-writeconcernerror.getcode.html
- MongoDB\Driver\WriteConcernError::getInfo — Returns metadata document for the W... 10689
- MongoDB\Driver\WriteConcernError::getInfo (mongodb >=1.0.0) MongoDB\Driver\WriteConcernError::getInfo — Returns metadata document for the WriteConcernError 説明 final public function MongoDB\Driver\WriteConcernError::getInfo (): ? object パ
... ラメータ この関数にはパラメータはありません。 戻り値 Returns the metadata document for the WriteConcernError, or null if no metadata is available. エラー / 例外 Throws MongoDB\Driver\Exception\InvalidArgumentException on argument p ... arsing errors. 例 例1 MongoDB\Driver\WriteConcernError::getInfo() example <?php $manager = new MongoDB\Driver\Manager ( "mongodb://rs1.example.com,rs2.example.com/?replicaSet=my ... ' => $writeConcern ]); } catch( MongoDB\Driver\Exception\BulkWriteException $e ) { var_dump ( $e -> getWriteResult ()-> getWriteConcernError ()-> getInfo ()); } ?> 上の例の出力は、 たとえば以下のようになります。 object(stdClass)#1 (1) { ["wtimeout"]=> bool(true) ...
-
https://man.mtool.work/php/8.3/mongodb-driver-writeconcernerror.getinfo.html
- MongoDB\Driver\WriteConcernError::getMessage — Returns the WriteConcernError's ... 10689
- MongoDB\Driver\WriteConcernError::getMessage (mongodb >=1.0.0) MongoDB\Driver\WriteConcernError::getMessage — Returns the WriteConcernError's error message 説明 final public function MongoDB\Driver\WriteConcernError::getMessage (): string パ
... ラメータ この関数にはパラメータはありません。 戻り値 Returns the WriteConcernError's error message. エラー / 例外 Throws MongoDB\Driver\Exception\InvalidArgumentException on argument parsing errors. 例 例1 ... MongoDB\Driver\WriteConcernError::getMessage() example <?php $manager = new MongoDB\Driver\Manager ( "mongodb://rs1.example.com,rs2.example.com/?replicaSet ... ' => $writeConcern ]); } catch( MongoDB\Driver\Exception\BulkWriteException $e ) { var_dump ( $e -> getWriteResult ()-> getWriteConcernError ()-> getMessage ()); } ?> 上の例の出力は、 たとえば以下のようになります。 string(33) "waiting for replication timed out" 参 ...
-
https://man.mtool.work/php/8.3/mongodb-driver-writeconcernerror.getmessage.html
- The MongoDB\Driver\WriteResult class | PHP 8.3 9111
- The MongoDB\Driver\WriteResult class (mongodb >=1.0.0) はじめに The MongoDB\Driver\WriteResult class encapsulates information about an executed MongoDB\Driver\BulkWrite and may be returned by MongoDB\Driver\Manager::executeBulkWrite() . クラ
... er $ server ; public readonly array $ upsertedIds ; public readonly array $ writeErrors ; public readonly ? MongoDB\Driver\WriteConcernError $ writeConcernError ; public readonly ? MongoDB\Driver\WriteConcern $ writeConcern ; public readonly array $ errorReplies ... ver final public function getUpsertedCount (): int final public function getUpsertedIds (): array final public function getWriteConcernError (): ? MongoDB\Driver\WriteConcernError final public function getWriteErrors (): array final public function isAcknowledged ... river\BulkWrite . writeErrors An array of MongoDB\Driver\WriteError s for any write errors that occurred during execution. writeConcernError The MongoDB\Driver\WriteConcernError that occurred, or null if no write concern error occurred. writeConcern The MongoDB\D ...
-
https://man.mtool.work/php/8.3/class.mongodb-driver-writeresult.html
- MongoDB\Driver\WriteResult::getWriteConcernError — Returns any write concern er... 8493
- MongoDB\Driver\WriteResult::getWriteConcernError (mongodb >=1.0.0) MongoDB\Driver\WriteResult::getWriteConcernError — Returns any write concern error that occurred 説明 final public function MongoDB\Driver\WriteResult::getWriteConcernError
... (): ? MongoDB\Driver\WriteConcernError パラメータ この関数にはパラメータはありません。 戻り値 Returns a MongoDB\Driver\WriteConcernError if a write concern error ... Throws MongoDB\Driver\Exception\InvalidArgumentException on argument parsing errors. 例 例1 MongoDB\Driver\WriteResult::getWriteConcernError() example <?php $manager = new MongoDB\Driver\Manager ( "mongodb://rs1.example.com,rs2.example.com/?replicaSet=myReplicaSe ... ' => $writeConcern ]); } catch( MongoDB\Driver\Exception\BulkWriteException $e ) { var_dump ( $e -> getWriteResult ()-> getWriteConcernError ()); } ?> 上の例の出力は、 たとえば以下のようになります。 object(MongoDB\Driver\WriteConcernError)#6 (3) { ["message"]=> s ...
-
https://man.mtool.work/php/8.3/mongodb-driver-writeresult.getwriteconcernerror.h...
- The MongoDB\Driver\BulkWrite class | PHP 8.3 8441
- The MongoDB\Driver\BulkWrite class (mongodb >=1.0.0) はじめに The MongoDB\Driver\BulkWrite collects one or more write operations that should be sent to the server. After adding any number of insert, update, and delete operations, the collec
... on\BulkWriteException $e ) { $result = $e -> getWriteResult (); // Check if the write concern could not be fulfilled if ( $writeConcernError = $result -> getWriteConcernError ()) { printf ( "%s (%d): %s\n" , $writeConcernError -> getMessage (), $writeConcernError ... -> getCode (), var_export ( $writeConcernError -> getInfo (), true ) ); } // Check if any write operations did not complete at all foreach ( $result -> getWriteErrors () ... t(s) 参考 MongoDB\Driver\Manager::executeBulkWrite() MongoDB\Driver\WriteResult MongoDB\Driver\WriteConcern MongoDB\Driver\WriteConcernError MongoDB\Driver\WriteError 目次 MongoDB\Driver\BulkWrite::__construct — Create a new BulkWrite MongoDB\Driver\BulkWrite::co ...
-
https://man.mtool.work/php/8.3/class.mongodb-driver-bulkwrite.html
- MongoDB\Driver\Exception\BulkWriteCommandException::getWriteConcernErrors — Ret... 8390
- MongoDB\Driver\Exception\BulkWriteCommandException::getWriteConcernErrors (mongodb >=2.1.0) MongoDB\Driver\Exception\BulkWriteCommandException::getWriteConcernErrors — Returns any write concern errors 説明 final public function MongoDB\Driv
... er\Exception\BulkWriteCommandException::getWriteConcernErrors (): array パラメータ この関数にはパラメータはありません。 戻り値 An array of any MongoDB\Driver\WriteConcernError s that ... n one server command was required to execute the bulk write. 例 例1 MongoDB\Driver\Exception\BulkWriteCommandException::getWriteConcernErrors() example <?php $manager = new MongoDB\Driver\Manager ; $bulk = new MongoDB\Driver\BulkWriteCommand ; $bulk -> insertOne ... writeConcern' => $writeConcern ]); } catch ( MongoDB\Driver\Exception\BulkWriteCommandException $e ) { var_dump ( $e -> getWriteConcernErrors ()); } ?> 上の例の出力は、 たとえば以下のようになります。 array(1) { [0]=> object(MongoDB\Driver\WriteConcernError)#6 (3) ...
-
https://man.mtool.work/php/8.3/mongodb-driver-bulkwritecommandexception.getwrite...
- MongoDB\Driver\BulkWrite::__construct — Create a new BulkWrite | PHP 8.3 8270
- MongoDB\Driver\BulkWrite::__construct (mongodb >=1.0.0) MongoDB\Driver\BulkWrite::__construct — Create a new BulkWrite 説明 public function MongoDB\Driver\BulkWrite::__construct ( ? array $options = null ) Constructs a new MongoDB\Driver\Bu
... on\BulkWriteException $e ) { $result = $e -> getWriteResult (); // Check if the write concern could not be fulfilled if ( $writeConcernError = $result -> getWriteConcernError ()) { printf ( "%s (%d): %s\n" , $writeConcernError -> getMessage (), $writeConcernError ... -> getCode (), var_export ( $writeConcernError -> getInfo (), true ) ); } // Check if any write operations did not complete at all foreach ( $result -> getWriteErrors () ...
-
https://man.mtool.work/php/8.3/mongodb-driver-bulkwrite.construct.html
- MongoDB\Driver\Manager::executeBulkWrite — Execute one or more write operations... 8047
- MongoDB\Driver\Manager::executeBulkWrite (mongodb >=1.0.0) MongoDB\Driver\Manager::executeBulkWrite — Execute one or more write operations 説明 final public function MongoDB\Driver\Manager::executeBulkWrite ( string $namespace , MongoDB\Dri
... $id ) { printf ( 'upsertedId[%d]: ' , $index ); var_dump ( $id ); } /* If the WriteConcern could not be fulfilled */ if ( $writeConcernError = $result -> getWriteConcernError ()) { printf ( "%s (%d): %s\n" , $writeConcernError -> getMessage (), $writeConcernError ... -> getCode (), var_export ( $writeConcernError -> getInfo (), true )); } /* If a write could not happen at all */ foreach ( $result -> getWriteErrors () as $writeError ) ...
-
https://man.mtool.work/php/8.3/mongodb-driver-manager.executebulkwrite.html