/** * Returns the formatted standard error message of SQL * * @deprecated 2.0 * * @param boolean $showSQL If TRUE, displays the last SQL statement sent to the database * @return string A standised error message */ public function stderr($showSQL = false) { return $this->_db->stderr($showSQL); }
public function getRows($class = null) { // get the subset (based on limits) of records $query = 'SELECT *' . ' FROM #__acctexp_' . $this->table . $this->getConstraints() . $this->getOrdering() . $this->getLimit(); $this->db->setQuery($query); $rows = $this->db->loadObjectList(); if ($this->db->getErrorNum()) { echo $this->db->stderr(); return false; } if ($class) { foreach ($rows as $k => $obj) { $rows[$k] = new $class(); $rows[$k]->load($obj->id); } } return $rows; }