Constructor for a statement.
Bind a column of the statement result set to a PHP variable.
bool
bindColumn
(string $column, &$param, [mixed $type = null], mixed $param)
-
string
$column: Name the column in the result set, either by position or by name.
-
mixed
$param: Reference to the PHP variable containing the value.
-
mixed
$type: OPTIONAL
-
&$param
Implementation of:
- Zend_Db_Statement_Interface::bindColumn()
- Bind a column of the statement result set to a PHP variable.
Binds a parameter to the specified variable name.
bool
bindParam
(mixed $parameter, &$variable, [mixed $type = null], [mixed $length = null], [mixed $options = null], mixed $variable)
-
mixed
$parameter: Name the parameter, either integer or string.
-
mixed
$variable: Reference to PHP variable containing the value.
-
mixed
$type: OPTIONAL Datatype of SQL parameter.
-
mixed
$length: OPTIONAL Length of SQL parameter.
-
mixed
$options: OPTIONAL Other options.
-
&$variable
Implementation of:
- Zend_Db_Statement_Interface::bindParam()
- Binds a parameter to the specified variable name.
Binds a value to a parameter.
bool
bindValue
(mixed $parameter, mixed $value, [mixed $type = null])
-
mixed
$parameter: Name the parameter, either integer or string.
-
mixed
$value: Scalar value to bind to the parameter.
-
mixed
$type: OPTIONAL Datatype of the parameter.
Implementation of:
- Zend_Db_Statement_Interface::bindValue()
- Binds a value to a parameter.
Returns the number of columns in the result set.
Returns null if the statement has no result set metadata.
int
columnCount
()
Implementation of:
- Zend_Db_Statement_Interface::columnCount()
- Returns the number of columns in the result set.
Retrieves the error code, if any, associated with the last operation on the statement handle.
string
errorCode
()
Implementation of:
- Zend_Db_Statement_Interface::errorCode()
- Retrieves the error code, if any, associated with the last operation on the statement handle.
Retrieves an array of error information, if any, associated with the last operation on the statement handle.
array
errorInfo
()
Implementation of:
- Zend_Db_Statement_Interface::errorInfo()
- Retrieves an array of error information, if any, associated with the last operation on the statement handle.
Executes a prepared statement.
bool
execute
([ $params = array()])
-
array
$params: OPTIONAL Values to bind to parameter placeholders.
Implementation of:
- Zend_Db_Statement_Interface::execute()
- Executes a prepared statement.
Fetches a row from the result set.
mixed
fetch
([int $style = null], [int $cursor = null], [int $offset = null])
-
int
$style: OPTIONAL Fetch mode for this fetch operation.
-
int
$cursor: OPTIONAL Absolute, relative, or other.
-
int
$offset: OPTIONAL Number for absolute or relative cursors.
Implementation of:
- Zend_Db_Statement_Interface::fetch()
- Fetches a row from the result set.
Returns an array containing all of the result set rows.
array
fetchAll
([int $style = null], [int $col = null])
-
int
$style: OPTIONAL Fetch mode.
-
int
$col: OPTIONAL Column number, if fetch mode is by column.
Implementation of:
- Zend_Db_Statement_Interface::fetchAll()
- Returns an array containing all of the result set rows.
Returns a single column from the next row of a result set.
string
fetchColumn
([int $col = 0])
-
int
$col: OPTIONAL Position of the column to fetch.
Implementation of:
- Zend_Db_Statement_Interface::fetchColumn()
- Returns a single column from the next row of a result set.
Fetches the next row and returns it as an object.
mixed
fetchObject
([string $class = 'stdClass'], [ $config = array()])
-
string
$class: OPTIONAL Name of the class to create.
-
array
$config: OPTIONAL Constructor arguments for the class.
Implementation of:
- Zend_Db_Statement_Interface::fetchObject()
- Fetches the next row and returns it as an object.
Returns metadata for a column in a result set.
mixed
getColumnMeta
(int $column)
Retrieves the next rowset (result set) for a SQL statement that has multiple result sets. An example is a stored procedure that returns the results of multiple queries.
bool
nextRowset
()
Implementation of:
- Zend_Db_Statement_Interface::nextRowset()
- Retrieves the next rowset (result set) for a SQL statement that has multiple result sets. An example is a stored procedure that returns the results of multiple queries.
Returns the number of rows affected by the execution of the last INSERT, DELETE, or UPDATE statement executed by this statement object.
int
rowCount
()
Implementation of:
- Zend_Db_Statement_Interface::rowCount()
- Returns the number of rows affected by the execution of the last INSERT, DELETE, or UPDATE statement executed by this statement object.
Set a statement attribute.
bool
setAttribute
(string $key, mixed $val)
-
string
$key: Attribute name.
-
mixed
$val: Attribute value.
Implementation of:
- Zend_Db_Statement_Interface::setAttribute()
- Set a statement attribute.
Prepare a string SQL statement and create a statement object.
void
_prepSql
(string $sql)