I have the following Models
Referral
belongsTo => array('Client')
Client
belongsTo => array('Person')
Person
hasOne => array('Client')
I can pull out paginated data using the following
$this->paginate['Referral'] = array('recursive'=>2);
$this->data['Referrals'] = $this->paginate('Referral');
My problem is this seems to automatically contain the Client and
Person models to get that data rather than joining the three tables
and running one query. This means that I cannot sort data by
Person.first_name or Person.last_name.
Is it possible to force paginate to apply deep recursion using one
query with multiple joins rather than multiple queries per fetched row?
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"CakePHP" group.
To post to this group, send email to [email protected]
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
-~----------~----~----~----~------~----~------~--~---