How to get disabled products id's and products price in magento 2 by using SQL Query?
-
14-04-2021 - |
سؤال
I want to get disabled products id's and products price in magento 2 by using SQL Query ?
By using this i'm getting disabled product but how to get price for that products.
SELECT entity_id FROM `catalog_product_entity_int`
WHERE attribute_id = (
SELECT attribute_id FROM `eav_attribute`
WHERE `attribute_code` LIKE 'status'
) AND `catalog_product_entity_int`.value = 2
المحلول
Try this:
SELECT entity_id, value as price from catalog_product_entity_decimal
WHERE entity_id IN (SELECT entity_id FROM `catalog_product_entity_int`
WHERE attribute_id = (
SELECT attribute_id FROM `eav_attribute`
WHERE `attribute_code` LIKE 'status'
) AND `catalog_product_entity_int`.value = 2) AND attribute_id = 77;
لا تنتمي إلى magento.stackexchange