I have this code. my problem is the strduedate field is in varchar type. How can I convert that field into datetime so I can perform the greater than query.
scenario.
Given the strduedate in my database is = '01/02/2016'
when I perform the query it says that strduedate is less than current date which is 09/18/2015.
$date_now = new DateTime();
$sql = "UPDATE jrf_tbl SET strifoverdue ='no' WHERE strduedate > '$date_now' ";
$OverDue->updatefields($sql);
STR_TO_DATE(str,format)-STR_TO_DATE(strduedate, '%m/%d/%Y')