Hai,

I have one question with join of two tables.

1.Project
{
   id,                       primary key
   project_name;
   manager              foreign key
}
2.Manager
{
   id,                  primary key
   name
}

Association is Manager has many projects and project has one Manager.

code for model is,

class Manager extends AppModel
{

var $name Manager
 var $hasMany =  'Project' ;
}

class Project extends AppModel
{
    var $name ='Project';
    var $belongsTo = 'Manager';
}

But when i use $this->Project->findall(); i won't get any records. Is
there any problem with
models. Can any one help to solve this problem.

Thanks,
Vidya


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Cake 
PHP" 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
-~----------~----~----~----~------~----~------~--~---

Reply via email to