0

I am locked with how to fill the following code

$criteria->addSearchCondition('esdate', 'now()-interval \'1 day\'', false, 'AND', '>');

if I use 'now()' alone it could work but as soon as I add the interval function I cannot get it done. I guess the escaped quote may not be accepted, but was unable to find any correct syntax.

Any help more than appreciated...

1 Answer 1

1
$criteria->addCondition( "esdate > NOW() - INTERVAL 1 DAY" );
1
  • great ! But still need the quote... $criteria->addCondition( "esdate > now() - interval '1 day'" );
    – CedSha
    Jun 15, 2012 at 14:42

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.