Thanks,
I'm now using the counter cache.
I tried the INNER join version as well and I got good looking result
arrays, but it seems using GROUP BY in pagination messes pagination
up.
$this-paginate = array(
'Blog' = array(
'joins' = array(
array(
The easiest way would be to Use countercache and then just add
post_count 0 to conditions... if you cant zdf countercache for some
reason you could also inner join the posts Table, which would leave
all blogs that have no assocciated post...
On 1 Nov., 18:29, Max D max.doerf...@googlemail.com
Hi,
i use cake 1.3 and I have a Blog hasMany Post association and now I
want to find all the Blogs, which have at least one Post. I use the
Containable Behavior.
I understand, that I could do a Blog-find('all', array('contain' =
array('Post'))) and simply filter the results for the Blogs, where