Db/Statement/Pdo/Ibm.php

Show: PublicProtectedPrivateinherited
Table of Contents
Zend Framework

LICENSE

This source file is subject to the new BSD license that is bundled with this package in the file LICENSE.txt. It is also available through the world-wide-web at this URL: http://framework.zend.com/license/new-bsd If you did not receive a copy of the license and are unable to obtain it through the world-wide-web, please send an email to license@zend.com so we can send you a copy immediately.

Category
Zend  
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  
Package
Zend_Db  
Subpackage
Statement  
Version
$Id: Ibm.php 24593 2012-01-05 20:35:02Z matthew $  

\Zend_Db_Statement_Pdo_Ibm

Package: Zend\Db\Statement
Proxy class to wrap a PDOStatement object for IBM Databases.

Matches the interface of PDOStatement. All methods simply proxy to the matching method in PDOStatement. PDOExceptions thrown by PDOStatement are re-thrown as Zend_Db_Statement_Exception.

Parent(s)
\Zend_Db_Statement_Pdo < \Zend_Db_Statement
Category
Zend  
Copyright
Copyright (c) 2005-2012 Zend Technologies USA Inc. (http://www.zend.com)  
License
New BSD License  

Properties

>VPropertyprotected\Zend_Db_Adapter_Abstract $_adapter = null
Default valuenullDetails
Type
\Zend_Db_Adapter_Abstract
Inherited_from
\Zend_Db_Statement::$$_adapter  
Inherited_from
\Zend_Db_Statement_Pdo::$$_adapter  
>VPropertyprotectedarray $_attribute = array()
Default valuearray()Details
Type
array
Inherited_from
\Zend_Db_Statement::$$_attribute  
Inherited_from
\Zend_Db_Statement_Pdo::$$_attribute  
>VPropertyprotectedarray $_bindColumn = array()
inherited
Column result bindings.
Inherited from: \Zend_Db_Statement::$$_bindColumn\Zend_Db_Statement_Pdo::$$_bindColumn
Default valuearray()Details
Type
array
Inherited_from
\Zend_Db_Statement::$$_bindColumn  
Inherited_from
\Zend_Db_Statement_Pdo::$$_bindColumn  
>VPropertyprotectedarray $_bindParam = array()
inherited
Query parameter bindings; covers bindParam() and bindValue().
Inherited from: \Zend_Db_Statement::$$_bindParam\Zend_Db_Statement_Pdo::$$_bindParam
Default valuearray()Details
Type
array
Inherited_from
\Zend_Db_Statement::$$_bindParam  
Inherited_from
\Zend_Db_Statement_Pdo::$$_bindParam  
>VPropertyprotectedint $_fetchMode = \PDO::FETCH_ASSOC
inherited
The current fetch mode.
Inherited from: \Zend_Db_Statement_Pdo::$$_fetchMode
Default value\PDO::FETCH_ASSOCDetails
Type
int
Inherited_from
\Zend_Db_Statement_Pdo::$$_fetchMode  
>VPropertyprotected\Zend_Db_Profiler_Query $_queryId = null
Default valuenullDetails
Type
\Zend_Db_Profiler_Query
Inherited_from
\Zend_Db_Statement::$$_queryId  
Inherited_from
\Zend_Db_Statement_Pdo::$$_queryId  
>VPropertyprotectedarray $_sqlParam = array()
inherited
Parameter placeholders in the SQL string by position in the split array.
Inherited from: \Zend_Db_Statement::$$_sqlParam\Zend_Db_Statement_Pdo::$$_sqlParam
Default valuearray()Details
Type
array
Inherited_from
\Zend_Db_Statement::$$_sqlParam  
Inherited_from
\Zend_Db_Statement_Pdo::$$_sqlParam  
>VPropertyprotectedarray $_sqlSplit = array()
inherited
SQL string split into an array at placeholders.
Inherited from: \Zend_Db_Statement::$$_sqlSplit\Zend_Db_Statement_Pdo::$$_sqlSplit
Default valuearray()Details
Type
array
Inherited_from
\Zend_Db_Statement::$$_sqlSplit  
Inherited_from
\Zend_Db_Statement_Pdo::$$_sqlSplit  
>VPropertyprotectedresource|object $_stmt = null
inherited

The driver level statement object/resource

Inherited from: \Zend_Db_Statement::$$_stmt\Zend_Db_Statement_Pdo::$$_stmt
Default valuenullDetails
Type
resource | object
Inherited_from
\Zend_Db_Statement::$$_stmt  
Inherited_from
\Zend_Db_Statement_Pdo::$$_stmt  

Methods

methodpublic__construct(\Zend_Db_Adapter_Abstract $adapter, mixed $sql) : void
inherited

Constructor for a statement.

Inherited from: \Zend_Db_Statement::__construct()\Zend_Db_Statement_Pdo::__construct()
Parameters
NameTypeDescription
$adapter\Zend_Db_Adapter_Abstract
$sqlmixed

Either a string or Zend_Db_Select.

methodpublic_bindParam(mixed $parameter, mixed $variable, mixed $type = null, mixed $length = null, mixed $options = null) : bool

Binds a parameter to the specified variable name.

Parameters
NameTypeDescription
$parametermixed

Name the parameter, either integer or string.

$variablemixed

Reference to PHP variable containing the value.

$typemixed

OPTIONAL Datatype of SQL parameter.

$lengthmixed

OPTIONAL Length of SQL parameter.

$optionsmixed

OPTIONAL Other options.

Returns
TypeDescription
bool
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublic_execute(array $params = null) : bool
inherited

Executes a prepared statement.

Inherited from: \Zend_Db_Statement_Pdo::_execute()
Parameters
NameTypeDescription
$paramsarray

OPTIONAL Values to bind to parameter placeholders.

Returns
TypeDescription
bool
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublic_fetchBound(array $row) : bool
inherited

Helper function to map retrieved row to bound column variables

Inherited from: \Zend_Db_Statement::_fetchBound()\Zend_Db_Statement_Pdo::_fetchBound()
Parameters
NameTypeDescription
$rowarray
Returns
TypeDescription
boolTrue
methodprotected_parseParameters(string $sql) : void
Parameters
NameTypeDescription
$sqlstring
methodprotected_prepare(string $sql) : void
inherited

Prepare a string SQL statement and create a statement object.

Inherited from: \Zend_Db_Statement_Pdo::_prepare()
Parameters
NameTypeDescription
$sqlstring
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodprotected_stripQuoted(string $sql) : string
inherited

Remove parts of a SQL string that contain quoted strings of values or identifiers.

Inherited from: \Zend_Db_Statement::_stripQuoted()\Zend_Db_Statement_Pdo::_stripQuoted()
Parameters
NameTypeDescription
$sqlstring
Returns
TypeDescription
string
methodpublicbindColumn(string $column, mixed $param, mixed $type = null) : bool
inherited

Bind a column of the statement result set to a PHP variable.

Inherited from: \Zend_Db_Statement_Pdo::bindColumn()
Parameters
NameTypeDescription
$columnstring

Name the column in the result set, either by position or by name.

$parammixed

Reference to the PHP variable containing the value.

$typemixed

OPTIONAL

Returns
TypeDescription
bool
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicbindParam(mixed $parameter, mixed $variable, mixed $type = null, mixed $length = null, mixed $options = null) : bool
inherited

Binds a parameter to the specified variable name.

Inherited from: \Zend_Db_Statement::bindParam()\Zend_Db_Statement_Pdo::bindParam()
Parameters
NameTypeDescription
$parametermixed

Name the parameter, either integer or string.

$variablemixed

Reference to PHP variable containing the value.

$typemixed

OPTIONAL Datatype of SQL parameter.

$lengthmixed

OPTIONAL Length of SQL parameter.

$optionsmixed

OPTIONAL Other options.

Returns
TypeDescription
bool
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicbindValue(mixed $parameter, mixed $value, mixed $type = null) : bool
inherited

Binds a value to a parameter.

Inherited from: \Zend_Db_Statement_Pdo::bindValue()
Parameters
NameTypeDescription
$parametermixed

Name the parameter, either integer or string.

$valuemixed

Scalar value to bind to the parameter.

$typemixed

OPTIONAL Datatype of the parameter.

Returns
TypeDescription
bool
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpubliccloseCursor() : bool
inherited

Closes the cursor, allowing the statement to be executed again.

Inherited from: \Zend_Db_Statement_Pdo::closeCursor()
Returns
TypeDescription
bool
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpubliccolumnCount() : int
inherited

Returns the number of columns in the result set.

Inherited from: \Zend_Db_Statement_Pdo::columnCount()

Returns null if the statement has no result set metadata.

Returns
TypeDescription
intThe number of columns.
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicerrorCode() : string
inherited

Retrieves the error code, if any, associated with the last operation on the statement handle.

Inherited from: \Zend_Db_Statement_Pdo::errorCode()
Returns
TypeDescription
stringerror code.
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicerrorInfo() : array
inherited

Retrieves an array of error information, if any, associated with the last operation on the statement handle.

Inherited from: \Zend_Db_Statement_Pdo::errorInfo()
Returns
TypeDescription
array
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicexecute(array $params = null) : bool
inherited

Executes a prepared statement.

Inherited from: \Zend_Db_Statement::execute()\Zend_Db_Statement_Pdo::execute()
Parameters
NameTypeDescription
$paramsarray

OPTIONAL Values to bind to parameter placeholders.

Returns
TypeDescription
bool
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicfetch(int $style = null, int $cursor = null, int $offset = null) : mixed
inherited

Fetches a row from the result set.

Inherited from: \Zend_Db_Statement_Pdo::fetch()
Parameters
NameTypeDescription
$styleint

OPTIONAL Fetch mode for this fetch operation.

$cursorint

OPTIONAL Absolute, relative, or other.

$offsetint

OPTIONAL Number for absolute or relative cursors.

Returns
TypeDescription
mixedArray, object, or scalar depending on fetch mode.
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicfetchAll(int $style = null, int $col = null) : array

Returns an array containing all of the result set rows.

Behaves like parent, but if limit() is used, the final result removes the extra column 'zend_db_rownum'

Parameters
NameTypeDescription
$styleint

OPTIONAL Fetch mode.

$colint

OPTIONAL Column number, if fetch mode is by column.

Returns
TypeDescription
arrayCollection of rows, each in a format by the fetch mode.
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicfetchColumn(int $col = 0) : string
inherited

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

Inherited from: \Zend_Db_Statement_Pdo::fetchColumn()
Parameters
NameTypeDescription
$colint

OPTIONAL Position of the column to fetch.

Returns
TypeDescription
string
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicfetchObject(string $class = 'stdClass', array $config = array()) : mixed
inherited

Fetches the next row and returns it as an object.

Inherited from: \Zend_Db_Statement_Pdo::fetchObject()
Parameters
NameTypeDescription
$classstring

OPTIONAL Name of the class to create.

$configarray

OPTIONAL Constructor arguments for the class.

Returns
TypeDescription
mixedOne object instance of the specified class.
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicgetAdapter() : \Zend_Db_Adapter_Abstract
inherited

Gets the Zend_Db_Adapter_Abstract for this particular Zend_Db_Statement object.

Inherited from: \Zend_Db_Statement::getAdapter()\Zend_Db_Statement_Pdo::getAdapter()
Returns
TypeDescription
\Zend_Db_Adapter_Abstract
methodpublicgetAttribute(integer $key) : mixed
inherited

Retrieve a statement attribute.

Inherited from: \Zend_Db_Statement_Pdo::getAttribute()
Parameters
NameTypeDescription
$keyinteger

Attribute name.

Returns
TypeDescription
mixedAttribute value.
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicgetColumnMeta(int $column) : mixed
inherited

Returns metadata for a column in a result set.

Inherited from: \Zend_Db_Statement_Pdo::getColumnMeta()
Parameters
NameTypeDescription
$columnint
Returns
TypeDescription
mixed
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicgetDriverStatement() : \unknown_type
inherited

Gets the resource or object setup by the _parse

Inherited from: \Zend_Db_Statement::getDriverStatement()\Zend_Db_Statement_Pdo::getDriverStatement()
Returns
TypeDescription
\unknown_type
methodpublicgetIterator() : \IteratorIterator
inherited

Required by IteratorAggregate interface

Inherited from: \Zend_Db_Statement_Pdo::getIterator()
Returns
TypeDescription
\IteratorIterator
methodpublicnextRowset() : bool
inherited

Retrieves the next rowset (result set) for a SQL statement that has multiple result sets.

Inherited from: \Zend_Db_Statement_Pdo::nextRowset()

An example is a stored procedure that returns the results of multiple queries.

Returns
TypeDescription
bool
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicrowCount() : int
inherited

Returns the number of rows affected by the execution of the last INSERT, DELETE, or UPDATE statement executed by this statement object.

Inherited from: \Zend_Db_Statement_Pdo::rowCount()
Returns
TypeDescription
intThe number of rows affected.
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicsetAttribute(string $key, mixed $val) : bool
inherited

Set a statement attribute.

Inherited from: \Zend_Db_Statement_Pdo::setAttribute()
Parameters
NameTypeDescription
$keystring

Attribute name.

$valmixed

Attribute value.

Returns
TypeDescription
bool
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
methodpublicsetFetchMode(int $mode) : bool
inherited

Set the default fetch mode for this statement.

Inherited from: \Zend_Db_Statement_Pdo::setFetchMode()
Parameters
NameTypeDescription
$modeint

The fetch mode.

Returns
TypeDescription
bool
Throws
ExceptionDescription
\Zend_Db_Statement_Exception
Documentation was generated by phpDocumentor 2.0.0a12.