I have an account model that should join to a terminology model. Below is the account model code:
class Account extends AppModel { var $name = 'Account'; var $useTable = 'G_ACCOUNT'; var $hasMany = array('Term' => array('className' => 'Term', 'conditions' => '', 'order' => 'Term.value DESC', 'limit' => '', 'foreignKey' => 'account_id', 'dependent' => true, 'exclusive' => false, 'finderSql' => '' ) ); } The debug shows that the sql ran: SELECT Term.ID, Term.ACCOUNT_ID, Term.KEY, Term.VALUE FROM RH_INTAKE_CUSTOM_TERM Term WHERE Term.account_id=NULL ORDER BY Term.value DESC but the where clause is 'WHERE Term.account_id=NULL'. Why is it NULL? Shouldn't it be an id from the account table? --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---