On 30 mayo, 20:35, uolax [EMAIL PROTECTED] wrote:
Thanks so much for any time with this:
Forest-hasMany-Trees
trees-belongsTo-Forest
Do you really have 2 models named forest and tree? I hope not.
Try this approach:
bind a hasOne association for tree to your forest model, give it a
Thank you both for your response.
I know these aren't the real class names and whatnotjust trying to
put my code in the best hypothetical situation. It's not really forest
and treesit's courses (forest) and subjects these courses include
(trees). A course can have multiple subjects. i.e.
Oh and I meant bind IN a controllernot to.
--~--~-~--~~~---~--~~
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
Oh and I meant bind IN a controllernot to.
--~--~-~--~~~---~--~~
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
Oh and I meant bind IN a controllernot to.
--~--~-~--~~~---~--~~
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
Oh and I meant bind IN a controllernot to.
--~--~-~--~~~---~--~~
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
Okayhere's what I did.
Used AD7six's advise and did a quick unbind from a hasMany and bind a
hasOne and did a findAll. This gives me all of the ID's that have the
course that was searched for. I then put these ID's in an array and
set them as part of the conditions for the next findAll and
Thanks so much for any time with this:
Forest-hasMany-Trees
trees-belongsTo-Forest
I want to:
find the forests that only have trees that are brown, (each tree can
only belong to one forest)
list the other trees in those respective forest,
and don't list forests that have no brown trees all from