/** * Fetchs records using the variable values specified in epObject * @param epObject $o * @param epClassMap */ public function update($cm, $o) { // check if class is abstract if ($cm->isAbstract()) { throw new epExceptionDbObject('Class [' . $cm->getName() . '] is abstract'); return false; } // preapre sql statement $sql = epObj2Sql::sqlUpdate($this, $cm, $o); if (!$sql) { // no need to update return true; } // execute sql return $r = $this->_execute($sql); }
/** * Fetchs records using the variable values specified in epObject * @param epObject $o * @param epClassMap */ public function update($cm, $o) { // preapre sql statement $sql = epObj2Sql::sqlUpdate($this, $cm, $o); if (!$sql) { // no need to update return true; } // execute sql return $r = $this->_execute($sql); }