Hello
i was trying to create a short php code to delete certain data in one of my db table(all the raw older then the actual date). Searching in other post i finally created these few lines
$db = JFactory::getDbo();
$query = $db->getQuery(true);
$now = JFactory::getDate();
$query
->delete('fab_trips')
->where(`datetime`) < $now ;
$db->setQuery($query);
$db->execute();
But still isn't working.
Can anyone give me some advice?
Thanks everybody
i was trying to create a short php code to delete certain data in one of my db table(all the raw older then the actual date). Searching in other post i finally created these few lines
$db = JFactory::getDbo();
$query = $db->getQuery(true);
$now = JFactory::getDate();
$query
->delete('fab_trips')
->where(`datetime`) < $now ;
$db->setQuery($query);
$db->execute();
But still isn't working.
Can anyone give me some advice?
Thanks everybody