MySQL大于当前日期时间问题

时间:2012-12-17 10:15:59

标签: php mysql phpmyadmin

check deal_time field value in phpmyadmin is less than or greater than current datetime stamp.
deal_time value stored in database in format('y/m/d h:m:s') 2012-12-17 11:05:28;

条件 - >

  $WhereBy = $this->db->dbprefix("product").".`Active` = 'Y' and ".$this->db->dbprefix("product"). ".`Deal_Time` <= NOW()"   ;

但它返回错误的结果。请告诉我们有什么问题。在此先感谢。

2 个答案:

答案 0 :(得分:3)

我认为是h:我:不是h:m:s因为你会得到几个月的分钟

答案 1 :(得分:0)

尝试 date(Deal_Time)&lt; = NOW()