public function max($table, $join, $column = null, $where = null)
{
$query = $this->query($this->select_context($table, $join, $column, $where, 'MAX'));
if ($query) {
$max = $query->fetchColumn();
return is_numeric($max) ? $max + 0 : $max;
} else {
return false;
}
}
/** * @param $table * @param $column * @param null $where * @return int */ public function max($table, $column, $where = NULL) { if (empty($this->_reader)) { return $this->_writer->max($table, $column, $where); } else { return $this->_reader->max($table, $column, $where); } }