📜  cakephp 按计数分组 - PHP 代码示例

📅  最后修改于: 2022-03-11 14:53:57.290000             🧑  作者: Mango

代码示例1
$query = $articles->find();
$query->select([
    'count' => $query->func()->count('view_count'),
    'published_date' => 'DATE(created)'
])
->group('published_date')
->having(['count >' => 3]);