|
PHP5中文手册
PDOStatement->fetch()(PHP 5 >= 5.1.0, PECL pdo:0.1-1.0.3) PDOStatement->fetch() — Fetches the next row from a result set 说明PDOStatement
mixed fetch
([ int $fetch_style
[, int $cursor_orientation
[, int $cursor_offset
]]] )
Fetches a row from a result set associated with a PDOStatement object. The fetch_style parameter determines how PDO returns the row. 参数
返回值The return value of this function on success depends on the fetch type. In all cases, FALSE is returned on failure. 范例
Example#1 Fetching rows using different fetch styles
<?php 上例将输出:
Example#2 Fetching rows with a scrollable cursor
<?php 上例将输出:
|