I am creating an attribute for product called supplier(Select).
Question 1
in which table the values of the supplier attribute are saving While adding the product?

Question 2
i want to retrieve the orders product according to supplier attribute.is their any possibilities to filter order according to this supplier selection.


Answer 1

eav_attribute is the table where attribute is stored and options against attribute is stored in eav_attribute_option table. And the product table where you'll find both the attribute and value is catalog_product_entity_int

Answer 2

$collection = Mage::getModel('sales/order_item')
->addAttributeToFilter('supplier', array('like' => '%A%'));  //'%A%' will be your search criteria

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.