Well, more informations would make easier to help you :
=================
when i comment the $hasOne im getting a set of array values but if i
removed the
comment for the $hasOne im getting a null value.
=================
When you do what ? I mean the code shown above is not going to bring
back anything, so are you querying the UserDetails ?
Have also a look in the name of the PrimaryKey if you did not follow
the cake standard (ie : user_id => userdetails_id)..
On Dec 6, 6:35 am, "[EMAIL PROTECTED]" <[EMAIL PROTECTED]>
wrote:
> can anyone tells me why the $hasOne is nothing working properly?
>
> class UserDetail extends AppModel
> {
> var $name = 'UserDetail';
> var $hasOne = array('BasicInfo' =>
> array('className' => 'BasicInfo',
> 'conditions' => '',
> 'order' => '',
> 'dependent' => false,
> 'foreignKey' => 'user_id'));
>
> }class BasicInfo extends AppModel
> {
> var $name = 'BasicInfo';
>
> }when i comment the $hasOne im getting a set of array values but if i
> removed the
> comment for the $hasOne im getting a null value.
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---