PDOStatement 类

(PHP 5 >= 5.1.0, PHP 7, PECL pdo >= 1.0.0)

简介

代表一条预处理语句,并在该语句被执行后代表一个相关的结果集。

类摘要

PDOStatement implements Traversable {
/* 属性 */
readonly string $queryString;
/* 方法 */
bindColumn ( mixed $column , mixed &$param [, int $type [, int $maxlen [, mixed $driverdata ]]] ) : bool
bindParam ( mixed $parameter , mixed &$variable [, int $data_type = PDO::PARAM_STR [, int $length [, mixed $driver_options ]]] ) : bool
bindValue ( mixed $parameter , mixed $value [, int $data_type = PDO::PARAM_STR ] ) : bool
closeCursor ( ) : bool
columnCount ( ) : int
debugDumpParams ( ) : bool
errorCode ( ) : string
errorInfo ( ) : array
execute ([ array $input_parameters ] ) : bool
fetch ([ int $fetch_style [, int $cursor_orientation = PDO::FETCH_ORI_NEXT [, int $cursor_offset = 0 ]]] ) : mixed
fetchAll ([ int $fetch_style [, mixed $fetch_argument [, array $ctor_args = array() ]]] ) : array
fetchColumn ([ int $column_number = 0 ] ) : string
fetchObject ([ string $class_name = "stdClass" [, array $ctor_args ]] ) : mixed
getAttribute ( int $attribute ) : mixed
getColumnMeta ( int $column ) : array
nextRowset ( ) : bool
rowCount ( ) : int
setAttribute ( int $attribute , mixed $value ) : bool
setFetchMode ( int $mode ) : bool
}

属性

queryString

所用的查询字符串

Table of Contents