mysql - Php Year Month Calculation -
friends, need data year='2015' , month='8' using & to. got empty results. please me out. here query.
select * me_fees year= '2015' && month = '8' && register_no= '9' && year between '2015' , '2015' && month between '6' , '12'
select * me_fees year= '2015' && month = '8' && register_no= '9' && year between '2015' , '2015' && month between '6' , '12'
that query uses mysql reserved words need escaped, month
, year
if field names escape them tick
`month`
then last 2 conditions useless. equivalent correct query be
select * me_fees `year`= 2015 , `month`= 8 , register_no= 9