My model
public function get_payscale() { $this->db->from(\'payscale P\')->join(\'employee E\',\'E.employee_id = P.employee_id \'); $this-&g
Use like this :
$this->db->where('EXTRACT(YEAR_MONTH FROM P.payscale_date)',date('Ym'));
This query will extract the Year and month from the date given column like 201605 (2016-05-21)