在sql数据库中匹配月份和年份

i am currently using code below to get results. but it some times give wrong result because it tries to match with today's date. while i want that it should try to match only current month and year only. it should not match the current day(date).

$this->db->select('*')
               ->where('u_id',$user)
               ->where('month','CURDATE()',FALSE)
               ->from('basepointsbymonth');
               $que=$this->db->get();

please provide any solution.

This should do it:

where MONTH(date) = MONTH(CURDATE()) AND YEAR(date) = YEAR(CURDATE())

楼上代码么的问题