I think Nookie had originally intended to let Articles belong to more than one category, and each category could have more than one article. That's why HABTM relations exist.
-MI --------------------------------------------------------------------------- Remember, smart coders answer ten questions for every question they ask. So be smart, be cool, and share your knowledge. BAKE ON! blog: http://www.MarianoIglesias.com.ar -----Mensaje original----- De: [email protected] [mailto:[EMAIL PROTECTED] En nombre de Sergei Enviado el: Sábado, 24 de Febrero de 2007 10:07 p.m. Para: Cake PHP Asunto: Re: how to count articles in category ? Your problem is wrong designed DB. It should be like this: categories: - id - name articles - id - category_id - title - contnet There is no need in join table here. --~--~---------~--~----~------------~-------~--~----~ 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 -~----------~----~----~----~------~----~------~--~---
