/** * Calls the underlying database to quote id * @param string $id * @return string */ public function quoteId($id) { return self::$db->quoteId($id); }
/** * Make a SQL delete statement from object variables * @param epDbObject $db the db connection * @param epObject the object for query * @param epClassMap the class map for the object * @return false|string */ public static function sqlDelete($db, $cm, $o) { // get all vars $vars = $o->epGetVars(); if (!$vars) { return false; } // delete row with the object id $sql = 'DELETE FROM ' . $db->quoteId($cm->getTable()) . ' WHERE ' . $db->quoteId($cm->getOidColumn()) . ' = ' . $o->epGetObjectId(); return $sql; }