Re: HABTM involving 3 tables

2006-06-21 Thread Chris Cassell
Write a method in your model that calls $this->query (), then you can call it from your controller $this->Model->method (). --~--~-~--~~~---~--~~ You received this message because you are subscribed to the Google Groups "Cake PHP" group. To post to this group, se

Re: HABTM involving 3 tables

2006-06-21 Thread AD7six
LetUsPrey, Half way through reading the sql I get lost. I-m assuming you have already created the associations etc? with the model associtions defenitions or a picture it might help. cheers, AD7six --~--~-~--~~~---~--~~ You received this message because you are

Re: HABTM involving 3 tables

2006-06-21 Thread bigdog
Sorry I don't have any ideas. Maybe someone else could jump in? --~--~-~--~~~---~--~~ 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 t

Re: HABTM involving 3 tables

2006-06-20 Thread LetUsPrey
Unless I'm misunderstanding that needs to be done each time I want to access the data, then. I was looking for a way to do the association so that it the data could then be accessed through the model, like you can with other associations. --~--~-~--~~~---~--~~ Yo

Re: HABTM involving 3 tables

2006-06-20 Thread bigdog
? $this->query('sql string'); --~--~-~--~~~---~--~~ 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 PRO

HABTM involving 3 tables

2006-06-20 Thread LetUsPrey
I have tables as below and want to use SQL statement "select groups.id as GroupID, groups.name as GroupName, views.id as ViewID, views.name as ViewName, subviews.id as SubViewID, subviews.name as SubViewName from groups,views,subviews,groups_views_subviews where groups.id = groups_views_subviews.g