\Query\DriversPDOStatementInterface

Interface created from official PHP Documentation

Summary

Methods
Constants
bindColumn()
bindParam()
bindValue()
closeCursor()
columnCount()
debugDumpParams()
errorCode()
errorInfo()
execute()
fetch()
fetchColumn()
fetchObject()
getAttribute()
nextRowset()
rowCount()
setAttribute()
setFetchMode()
No constants found
No protected methods found
N/A
No private methods found
N/A

Methods

bindColumn()

bindColumn(mixed  $column, mixed  $param, integer  $type, integer  $maxlen, mixed  $driverdata) : boolean

Bind a column to a PHP variable

Parameters

mixed $column

Number or name of the column in the result set

mixed $param

Name of the PHP variable to which the column will be bound

integer $type

Data type of the parameter, specified by the PDO::PARAM_* constants

integer $maxlen

A hint for pre-allocation

mixed $driverdata

Optional parameter(s) for the driver

Returns

boolean

bindParam()

bindParam(mixed  $parameter, mixed  $variable, integer  $dataType = \PDO::PARAM_STR, integer  $length, mixed  $driverOptions) : boolean

Binds a parameter to the specified variable name

Parameters

mixed $parameter

Parameter identifier. For a prepared statement using named placeholders, this will be a parameter name of the form :name. For a prepared statement using question mark placeholders, this will be the 1-indexed position of the parameter.

mixed $variable

Name of the PHP variable to bind to the SQL statement parameter.

integer $dataType

Explicit data type for the parameter using the PDO::PARAM_* constants. To return an INOUT parameter from a stored procedure, use the bitwise OR operator to set the PDO::PARAM_INPUT_OUTPUT bits for the data_type parameter.

integer $length

Length of the data type. To indicate that a parameter is an OUT parameter from a stored procedure, you must explicitly set the length.

mixed $driverOptions

Returns

boolean

bindValue()

bindValue(mixed  $parameter, mixed  $value, integer  $dataType = \PDO::PARAM_STR) : boolean

Binds a value to a corresponding named or question mark placeholder in the SQL statement that was used to prepare the statement

Parameters

mixed $parameter

Parameter identifier. For a prepared statement using named placeholders, this will be a parameter name of the form :name. For a prepared statement using question mark placeholders, this will be the 1-indexed position of the parameter.

mixed $value

The value to bind to the parameter

integer $dataType

Explicit data type for the parameter using the PDO::PARAM_* constants.

Returns

boolean

closeCursor()

closeCursor() : boolean

Frees up the connection to the server so that other SQL statements may be issued, but leaves the statement in a state that enables it to be executed again

Returns

boolean

columnCount()

columnCount() : integer

Returns the number of columns in the result set

Returns

integer

debugDumpParams()

debugDumpParams() : void

Dumps the information contained by a prepared statement directly on the output

errorCode()

errorCode() : string

Fetch the SQLSTATE associated with the last operation on the statement handle

Returns

string

errorInfo()

errorInfo() : array

Fetch extended error information associated with the last operation on the statement handle

Returns

array

execute()

execute(array  $boundInputParams = NULL) : boolean

Run a prepared statement query

Parameters

array $boundInputParams

Returns

boolean

fetch()

fetch(integer  $how = \PDO::ATTR_DEFAULT_FETCH_MODE, integer  $orientation = \PDO::FETCH_ORI_NEXT, integer  $offset) : mixed

Fetches the next row from a result set

Parameters

integer $how
integer $orientation
integer $offset

Returns

mixed

fetchColumn()

fetchColumn(integer  $columnNumber) : mixed

Returns a single column from the next row of a result set

Parameters

integer $columnNumber

Returns

mixed

fetchObject()

fetchObject(string  $className = "stdClass", array  $ctorArgs = NULL) : mixed

Fetches the next row and returns it as an object

Parameters

string $className
array $ctorArgs

Returns

mixed

getAttribute()

getAttribute(integer  $attribute) : mixed

Retrieve a statement attribute

Parameters

integer $attribute

Returns

mixed

nextRowset()

nextRowset() : boolean

Advances to the next rowset in a multi-rowset statement handle

Returns

boolean

rowCount()

rowCount() : integer

Returns the number of rows affected by the last SQL statement

Returns

integer

setAttribute()

setAttribute(integer  $attribute, mixed  $value) : boolean

Set a statement attribute

Parameters

integer $attribute
mixed $value

Returns

boolean

setFetchMode()

setFetchMode(integer  $mode) : boolean

Set the default fetch mode for this statement

Parameters

integer $mode

Returns

boolean