/** * Executes the current select object and returns the result * * @param integer $fetchMode * OPTIONAL * @param mixed $bind * An array of data to bind to the placeholders. * @return EhrlichAndreas_Pdo_Statement EhrlichAndreas_Db_Statement */ public function query($fetchMode = null, $bind = array()) { if (!empty($bind) && method_exists($this, 'bind')) { $this->bind($bind); } $stmt = $this->_adapter->query($this); if ($fetchMode == null) { $fetchMode = $this->_adapter->getFetchMode(); } $stmt->setFetchMode($fetchMode); return $stmt; }
/** * Get the fetch mode. * * @return int */ public function getFetchMode() { return $this->adapter->getFetchMode(); }