Kode Anda harus serupa dengan ini, dengan asumsi Buku e Proyek berada dalam hubungan (Book
milik Project
)
$this->Book->find
(
'all',
array
(
'fields' => array('Book.value', 'Project.name'),
'conditions' => array
(
'Book.created IN (SELECT MAX(Book.created) FROM books Book WHERE Book.user_id = 1)',
'Book.user_id' => 1
),
'group' => 'Project.name'
)
);