I have a database schema with categories and products that are joined
with categories_products table. This makes it so a product can be
assigned to multiple categories.
I would like to find all of the products that belong to a category.
I've tried:
$this->Product->findAll(array("CategoriesProduct.category_id='$id'"),
$fields, null, 10, $page, 1);
but I get an unknown column "CategoriesProduct.category_id" error.
Is there anyway that I can do this besides writing my own query?
--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---