Wydaje się, że użycie podzapytania działa - z tą małą sztuczką:
$options = array(
'fields' => array('MAX(SubBlog.created)'),
'conditions' => array('SubBlog.user_id = Blog.user_id')
);
$subquery = $this->subquery('all', $options);
$options = array(
'order'=>array($this->alias.'.published' => 'DESC'),
'conditions' => array(
'User.active' => 1,
'Blog.status' => self::STATUS_ACTIVE,
'Blog.published = ' . $subquery
),
'contain' => array('User.username'),
'fields' => array(
'User.id', 'User.username',
'Blog.id', 'Blog.headline', 'Blog.published'
),
'limit' => $limit,
);
return $this->find('all', $options);
subquery() to metoda AppModel:https://github .com/dereuromark/tools/blob/2.0/Lib/MyModel.php#L405