Magento 1.9 - Mysql query to get all products images count in particular category

Mysql query to get all products images count in particular category

 
Below is mysql query to get all products images count in particular category
select count(*) from `catalog_product_entity_media_gallery` as t1 join `catalog_category_product` as t2 on t1.entity_id = t2.product_id
where t2.category_id = 3  and t1.attribute_id=88

No comments:

Post a Comment