It looks like the GROUP BY in the left join statement is causing the problem. The following query works and returns the results I want, but doesn't use Cake magic to make it work.
SELECT `Project`.`id`, count(`Task`.`project_id`) FROM `projects` AS `Project` LEFT JOIN `tasks` AS `Task` ON (`Project`.`company_id`= `3` AND `Task`.`project_id` = `Project`.`id`) WHERE `Project`.`company_id`= `3` GROUP BY `Task`.`project_id` --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, send email to cake-php@googlegroups.com To unsubscribe from this group, send email to [EMAIL PROTECTED] For more options, visit this group at http://groups.google.com/group/cake-php?hl=en -~----------~----~----~----~------~----~------~--~---