array ( 0 => 'index.php', 1 => 'PHP Manual', ), 'head' => array ( 0 => 'UTF-8', 1 => 'ja', ), 'this' => array ( 0 => 'mysql-xdevapi-rowresult.construct.php', 1 => 'RowResult::__construct', ), 'up' => array ( 0 => 'class.mysql-xdevapi-rowresult.php', 1 => 'mysql_xdevapi\\RowResult', ), 'prev' => array ( 0 => 'class.mysql-xdevapi-rowresult.php', 1 => 'mysql_xdevapi\\RowResult', ), 'next' => array ( 0 => 'mysql-xdevapi-rowresult.fetchall.php', 1 => 'RowResult::fetchAll', ), 'alternatives' => array ( ), 'source' => array ( 'lang' => 'ja', 'path' => 'reference/mysql_xdevapi/mysql_xdevapi/rowresult/construct.xml', ), ); $setup["toc"] = $TOC; $setup["toc_deprecated"] = $TOC_DEPRECATED; $setup["parents"] = $PARENTS; manual_setup($setup); ?>
(No version information available, might only be in Git)
RowResult::__construct — RowResult のコンストラクタ
データベースへの問い合わせから得られる結果セットを表現します。
この関数にはパラメータはありません。
例1 mysql_xdevapi\RowResult::__construct() の例
<?php
$session = mysql_xdevapi\getSession("mysqlx://user:password@localhost");
$schema = $session->getSchema("addressbook");
$table = $schema->getTable("names");
$row = $table->select('name', 'age')->where('age > 18')->execute()->fetchAll();
print_r($row);
上の例の出力は、 たとえば以下のようになります。
Array ( [0] => Array ( [name] => John [age] => 42 ) [1] => Array ( [name] => Sam [age] => 33 ) )