Currently my product belong to many Categories, I want to get Category Name, from which product was ordered.
Magento 1.9 – Get Category Name from Ordered Product
categorymagento-1.9productsales-ordersql
categorymagento-1.9productsales-ordersql
Currently my product belong to many Categories, I want to get Category Name, from which product was ordered.
Best Answer
Abdul Ghaffar,magento does not save category details at sales model.So it not possible to get Category Name, from which product was ordered.
Magento save order only product id,sku at sales module.
If you want to then you need do customization,first you need to add a field to at sales_quote_item & sales_flat_order_item.
During cart,you need to add category id to sales_quote_item table.
During order place, convert that field value to sales_flat_order_table