public function delete($Table = '', $Where = '', $Limit = false)
{
if ($Table == '') {
if (!isset($this->_Froms[0])) {
return false;
}
$Table = $this->_Froms[0];
} elseif (is_array($Table)) {
foreach ($Table as $t) {
$this->delete($t, $Where, $Limit, false);
}
return;
} else {
$Table = $this->escapeIdentifier($this->Database->DatabasePrefix . $Table);
}
if ($Where != '') {
$this->where($Where);
}
if ($Limit !== false) {
$this->limit($Limit);
}
if (count($this->_Wheres) == 0) {
return false;
}
$Sql = $this->getDelete($Table, $this->_Wheres, $this->_Limit);
return $this->query($Sql, 'delete');
}