MIOLO20
Carregando...
Procurando...
Nenhuma entrada encontrada
Referência à classe Statement
Diagrama de heranças da classe Statement
Statement

Membros públicos

 __construct ($sql, Connection $conn)
 
 bindValue ($name, $value, $type=null)
 
 bindParam ($name, &$var, $type=PDO::PARAM_STR)
 
 execute ($params=null)
 
 closeCursor ()
 
 columnCount ()
 
 errorCode ()
 
 errorInfo ()
 
 fetch ($fetchStyle=PDO::FETCH_BOTH)
 
 fetchAll ($fetchStyle=PDO::FETCH_BOTH, $columnIndex=0)
 
 fetchColumn ($columnIndex=0)
 
 rowCount ()
 
 getWrappedStatement ()
 
- Membros públicos herdados de Statement
 fetchAll ($fetchStyle=PDO::FETCH_BOTH)
 

Descrição detalhada

A thin wrapper around a Doctrine\DBAL\Driver\Statement that adds support for logging, DBAL mapping types, etc.

Autor
Roman Borschel roman.nosp@m.@cod.nosp@m.e-fac.nosp@m.tory.nosp@m..org
Desde
2.0

Definido na linha 35 do ficheiro Statement.php.

Documentação dos Construtores & Destrutor

◆ __construct()

__construct ( $sql,
Connection $conn )

Creates a new Statement for the given SQL and Connection.

Parâmetros
string$sqlThe SQL of the statement.
Doctrine

DBAL\Connection The connection on which the statement should be executed.

Definido na linha 64 do ficheiro Statement.php.

Documentação das funções

◆ bindParam()

bindParam ( $name,
& $var,
$type = PDO::PARAM_STR )

Binds a parameter to a value by reference.

Binding a parameter by reference does not support DBAL mapping types.

Parâmetros
string$nameThe name or position of the parameter.
mixed$valueThe reference to the variable to bind
integer$typeThe PDO binding type.
Retorna
boolean TRUE on success, FALSE on failure.

Implementa Statement.

Definido na linha 114 do ficheiro Statement.php.

◆ bindValue()

bindValue ( $name,
$value,
$type = null )

Binds a parameter value to the statement.

The value can optionally be bound with a PDO binding type or a DBAL mapping type. If bound with a DBAL mapping type, the binding type is derived from the mapping type and the value undergoes the conversion routines of the mapping type before being bound.

Parâmetros
$nameThe name or position of the parameter.
$valueThe value of the parameter.
mixed$typeEither a PDO binding type or a DBAL mapping type name or instance.
Retorna
boolean TRUE on success, FALSE on failure.

Implementa Statement.

Definido na linha 85 do ficheiro Statement.php.

◆ closeCursor()

closeCursor ( )

Closes the cursor, freeing the database resources used by this statement.

Retorna
boolean TRUE on success, FALSE on failure.

Implementa Statement.

Definido na linha 145 do ficheiro Statement.php.

◆ columnCount()

columnCount ( )

Returns the number of columns in the result set.

Retorna
integer

Implementa Statement.

Definido na linha 155 do ficheiro Statement.php.

◆ errorCode()

errorCode ( )

Fetches the SQLSTATE associated with the last operation on the statement.

Retorna
string

Implementa Statement.

Definido na linha 165 do ficheiro Statement.php.

◆ errorInfo()

errorInfo ( )

Fetches extended error information associated with the last operation on the statement.

Retorna
array

Implementa Statement.

Definido na linha 175 do ficheiro Statement.php.

◆ execute()

execute ( $params = null)

Executes the statement with the currently bound parameters.

Retorna
boolean TRUE on success, FALSE on failure.

Implementa Statement.

Definido na linha 124 do ficheiro Statement.php.

◆ fetch()

fetch ( $fetchStyle = PDO::FETCH_BOTH)

Fetches the next row from a result set.

Parâmetros
integer$fetchStyle
Retorna
mixed The return value of this function on success depends on the fetch type. In all cases, FALSE is returned on failure.

Implementa Statement.

Definido na linha 187 do ficheiro Statement.php.

◆ fetchAll()

fetchAll ( $fetchStyle = PDO::FETCH_BOTH,
$columnIndex = 0 )

Returns an array containing all of the result set rows.

Parâmetros
integer$fetchStyle
integer$columnIndex
Retorna
array An array containing all of the remaining rows in the result set.

Definido na linha 199 do ficheiro Statement.php.

◆ fetchColumn()

fetchColumn ( $columnIndex = 0)

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

Parâmetros
integer$columnIndex
Retorna
mixed A single column from the next row of a result set or FALSE if there are no more rows.

Implementa Statement.

Definido na linha 213 do ficheiro Statement.php.

◆ getWrappedStatement()

getWrappedStatement ( )

Gets the wrapped driver statement.

Retorna
Doctrine\DBAL\Driver\Statement

Definido na linha 233 do ficheiro Statement.php.

◆ rowCount()

rowCount ( )

Returns the number of rows affected by the last execution of this statement.

Retorna
integer The number of affected rows.

Implementa Statement.

Definido na linha 223 do ficheiro Statement.php.


A documentação para esta classe foi gerada a partir do seguinte ficheiro: