I am trying to get products name(value) and when i see my db table catalog_product_entity_varchar but in which in the column of value all base images are given so please tell accurate table or any method to get products name or value
-
do you want to get the product details by Id???– Asad KhanMay 15, 2019 at 5:55
-
are you trying to get it directly in the database, I mean using phpmyadmin etc?– fmsthirdMay 15, 2019 at 5:55
-
no i just need products name that save in db with value named– Shan HaiderMay 15, 2019 at 5:56
-
you need the table that stores the product name?– fmsthirdMay 15, 2019 at 6:18
-
yes @magefms i have already explore table like catalog_product_entity_varchar– Shan HaiderMay 15, 2019 at 6:23
1 Answer
Magento uses an EAV table structure for products. Names are stored in catalog_product_entity_varchar. If you have the product ID X, you can query this table directly:
SELECT entity_id, value, store_id FROM catalog_product_entity_varchar
WHERE entity_id = X AND attribute_id = (
SELECT attribute_id FROM eav_attribute
WHERE entity_type_id=4 AND attribute_code='name'
)
The subquery determines the attribute id for "name", entity_type_id 4 is always the type ID for products.
-
i have found base images path except value in catalog_product_entity_varchar May 15, 2019 at 6:04
-
-