{"id":14998,"date":"2018-01-30T15:52:44","date_gmt":"2018-01-30T12:52:44","guid":{"rendered":"https:\/\/belvg.com\/blog\/?p=14998"},"modified":"2023-12-05T19:52:17","modified_gmt":"2023-12-05T17:52:17","slug":"eav-in-magento-2","status":"publish","type":"post","link":"https:\/\/belvg.com\/blog\/eav-in-magento-2.html","title":{"rendered":"EAV in Magento 2"},"content":{"rendered":"\n<p>The Entity-Attribute-Value model is a data model intended for describing entities where the number of attributes is expected to be enormous, but in fact, the number of attributes to be used in the entity is small.<!--more--><\/p>\n<p><strong>Entity<\/strong> stores information about the type of the data being stored. In the case of Magento, this is customer product, category, and etc.<br>\n<strong>Attribute<\/strong> is the individual property of each entity (name, weight, email address).<br>\n<strong>Value<\/strong> is the value of a given entity and attribute.<br>\n\n<\/p><div class=\"request__platform\">\n    <picture>\n        <source srcset=\"https:\/\/belvg.com\/wp-content\/uploads\/2019\/06\/pixel.png\" data-srcset=\"https:\/\/belvg.com\/blog\/wp-content\/uploads\/2020\/07\/small-devices-sales.jpg\" media=\"(max-width: 640px)\" class=\"lazy\"><\/source>\n        <source srcset=\"https:\/\/belvg.com\/wp-content\/uploads\/2019\/06\/pixel.png\" data-srcset=\"https:\/\/belvg.com\/blog\/wp-content\/uploads\/2023\/12\/bg_request_prestashop.png\" media=\"(min-width: 641px)\" class=\"lazy\"><\/source>\n        <img decoding=\"async\" src=\"https:\/\/belvg.com\/wp-content\/uploads\/2019\/06\/pixel.png\" data-src=\"https:\/\/belvg.com\/blog\/wp-content\/uploads\/2023\/12\/bg_request_prestashop.png\" class=\"lazy\" width=\"787\" height=\"300\" loading=\"lazy\" alt=\"bg request prestashop\" title=\"Request block (Platform)\">\n    <\/picture>\n    <div class=\"content_part\">\n        <span class=\"title h3\"> Lorem ipsum dolor sit amet consectetur <\/span>\n        <span class=\"sales_after_content_text\">Lorem ipsum dolor sit amet consectetur<\/span>\n        <a href=\"https:\/\/belvg.belvgdev.com\/com\/work\/ekstralys\" data-link class=\"contact_with_sales call-to-action\" target=\"_blank\">\n            TEST LINK CTA        <\/a>\n    <\/div>\n<\/div>\n\n<style>.request__platform { position: relative; } .request__platform .content_part { position: absolute; top: 50%; left: 0; margin: 0 calc(var(--belvg-space__base) * 3); max-width: 50%; transform: translateY(-50%); } .request__platform img { width: 100%; object-fit: cover; } @media screen and (max-width: 640px) { .request__platform img { min-height: 250px; } .request__platform .content_part { color: var(--belvg-color__white); text-align: center; left: 50%; transform: translate(-50%, -50%); width: 100%; max-width: unset; padding: 0 var(--belvg-space__md); } } <\/style>\n<br>\nThe benefits the EAV model brings are following:\n<ul>\n<li>Flexible versatile data structure (it&rsquo;s possible to change the number of properties without having to change the database schema).<\/li>\n<li>When adding a new attribute for a given entity, we have a possibility to use it in other entities.<\/li>\n<li>Quick to implement.<\/li>\n<\/ul>\n<p><strong>Database schema for EAV entities:<\/strong><\/p>\n<ul>\n<li>eav_entity &ndash; (E) The Entity table.<\/li>\n<li>eav_entity_attribute (A) The Attrubute table<\/li>\n<li>eav_entity_{type} (V) &ndash; The Value table. {type} &ndash; datetime, decimals, int, text and varchar.<\/li>\n<\/ul>\n<p><strong>Diagram with eav_* tables:<\/strong><\/p>\n<p><a href=\"https:\/\/belvg.com\/blog\/wp-content\/uploads\/2018\/01\/EAV-in-Magento-2.png\"><img decoding=\"async\" loading=\"lazy\" class=\"lazy alignnone size-full wp-image-15001\" src=\"https:\/\/belvg.com\/wp-content\/uploads\/2019\/06\/pixel.png\" data-src=\"https:\/\/belvg.com\/blog\/wp-content\/uploads\/2018\/01\/EAV-in-Magento-2.png\" alt=\"EAV in Magento 2\" width=\"1600\" height=\"1356\" title=\"Request block (Platform)\"><\/a><\/p>\n<p><strong>Which EAV entities are there in Magento 2:<\/strong><\/p>\n<p>The list of entities can be found in the eav_entity_type table:<\/p>\n<ul>\n<li>customer<\/li>\n<li>customer_address<\/li>\n<li>catalog_category<\/li>\n<li>catalog_product<\/li>\n<\/ul>\n<p><strong>Which EAV entity types are there in Magento 2:<\/strong><\/p>\n<ul>\n<li>eav_entity_int<\/li>\n<li>eav_entity_varchar<\/li>\n<li>eav_entity_text<\/li>\n<li>eav_entity_decimal<\/li>\n<li>eav_entity_datetime<\/li>\n<\/ul>\n\n<h2><strong>Entities catalog_product in Magento 2<\/strong><\/h2>\n<p>In order to understand the EAV model in Magento 2, let&rsquo;s consider&nbsp; &ldquo;catalog_product&rdquo; example, the type of tables used to create attributes, the functions of attributes in the attribute set and attribute group. Besides, we have a closer look at the tables used to assign the product with an attribute. At every step, there&rsquo;s SQL code being generated by Magento.<\/p>\n<ol>\n<li>Create an attribute for each type with default data.<\/li>\n<li>Create attribute set with new attributes.<\/li>\n<li>Add new attribute group in the attribute set.<\/li>\n<li>Consider the tables used to assign the product with an attribute.<\/li>\n<\/ol>\n<p><strong>1. First off, we create an attribute for each type with default data. You can perform it in the admin panel: Stores &ndash; Attributes &ndash; Product Attributes &ndash; Add New Attribute<\/strong><\/p>\n<ul>\n<li>Text Field<\/li>\n<li>Text Area<\/li>\n<li>Date<\/li>\n<li>Yes\/No<\/li>\n<li>Multiple Select<\/li>\n<li>Dropdown<\/li>\n<li>Price<\/li>\n<li>Media Image<\/li>\n<li>Fixed Product Tax<\/li>\n<li>Visual Swatch<\/li>\n<li>Text Swatch<\/li>\n<\/ul>\n<p><strong>1.1 Create product attribute with text field type<\/strong><\/p>\n<pre class=\"lang:mysql decode:true \">INSERT INTO `eav_attribute` (`entity_type_id`, `attribute_code`, `backend_model`, `backend_type`, `frontend_input`, `frontend_label`, `frontend_class`, `source_model`, `is_required`, `is_user_defined`, `default_value`, `is_unique`)\r\nVALUES (4, 'text_field', NULL, 'varchar', 'text', 'Text Field', NULL, NULL, 0, 1, NULL, 0)\r\n\r\nDELETE FROM `eav_attribute_label` WHERE (attribute_id ='159')<\/pre>\n<p>If we forgot to assign the label for attribute, there would be a line added:<\/p>\n<pre class=\"lang:mysql decode:true\">INSERT INTO `eav_attribute_label` (`attribute_id`, `store_id`, `value`) VALUES ('159', 1, 'Label Name') \r\nINSERT INTO `catalog_eav_attribute` (`attribute_id`, `is_global`, `is_searchable`, `is_filterable`, `is_comparable`, `is_visible_on_front`, `is_html_allowed_on_front`, `is_filterable_in_search`, `used_in_product_listing`, `used_for_sort_by`, `apply_to`, `is_visible_in_advanced_search`, `is_used_for_promo_rules`, `is_used_in_grid`, `is_visible_in_grid`, `is_filterable_in_grid`) VALUES (159, 0, 0, 0, 0, 0, 1, 0, 0, 0, NULL, 0, 0, 1, 1, 1)<\/pre>\n<p><strong>&nbsp;<\/strong><strong>1.2. Create product attribute with text area type<\/strong><\/p>\n<pre class=\"lang:mysql decode:true\">INSERT INTO `eav_attribute` (`entity_type_id`, `attribute_code`, `backend_model`, `backend_type`, `frontend_input`, `frontend_label`, `source_model`, `is_required`, `is_user_defined`, `default_value`, `is_unique`) VALUES (4, 'text_area', NULL, 'text', 'textarea', 'Text Area', NULL, 0, 1, NULL, 0)\r\nDELETE FROM `eav_attribute_label` WHERE (attribute_id ='160')\r\nINSERT INTO `catalog_eav_attribute` (`attribute_id`, `is_global`, `is_searchable`, `is_filterable`, `is_comparable`, `is_visible_on_front`, `is_html_allowed_on_front`, `is_filterable_in_search`, `used_in_product_listing`, `apply_to`, `is_visible_in_advanced_search`, `is_wysiwyg_enabled`, `is_used_for_promo_rules`, `is_used_in_grid`, `is_visible_in_grid`, `is_filterable_in_grid`) VALUES (160, 0, 0, 0, 0, 0, 1, 0, 0, NULL, 0, 0, 0, 1, 1, 1)<\/pre>\n<p><strong>&nbsp;<\/strong><strong>1.3. Create product attribute with date type<\/strong><\/p>\n<pre class=\"lang:mysql decode:true\">INSERT INTO `eav_attribute` (`entity_type_id`, `attribute_code`, `backend_model`, `backend_type`, `frontend_model`, `frontend_input`, `frontend_label`, `source_model`, `is_required`, `is_user_defined`, `default_value`, `is_unique`) VALUES (4, 'date', 'Magento\\\\Eav\\\\Model\\\\Entity\\\\Attribute\\\\Backend\\\\Datetime', 'datetime', 'Magento\\\\Eav\\\\Model\\\\Entity\\\\Attribute\\\\Frontend\\\\Datetime', 'date', 'Date', NULL, 0, 1, NULL, 0)\r\nDELETE FROM `eav_attribute_label` WHERE (attribute_id ='161')\r\nINSERT INTO `catalog_eav_attribute` (`attribute_id`, `is_global`, `is_searchable`, `is_filterable`, `is_comparable`, `is_visible_on_front`, `is_html_allowed_on_front`, `is_filterable_in_search`, `used_in_product_listing`, `used_for_sort_by`, `apply_to`, `is_visible_in_advanced_search`, `is_used_for_promo_rules`, `is_used_in_grid`, `is_visible_in_grid`, `is_filterable_in_grid`) VALUES (161, 0, 0, 0, 0, 0, 1, 0, 0, 0, NULL, 0, 0, 1, 1, 1)<\/pre>\n<p><strong>1.4. Create product attribute with yes\/no type<\/strong><\/p>\n<pre class=\"lang:mysql decode:true\">INSERT INTO `eav_attribute` (`entity_type_id`, `attribute_code`, `backend_model`, `backend_type`, `frontend_input`, `frontend_label`, `source_model`, `is_required`, `is_user_defined`, `default_value`, `is_unique`) VALUES (4, 'yes_no', NULL, 'int', 'boolean', 'Yes No', 'Magento\\\\Eav\\\\Model\\\\Entity\\\\Attribute\\\\Source\\\\Boolean', 0, 1, '0', 0)\r\nDELETE FROM `eav_attribute_label` WHERE (attribute_id ='162')\r\nINSERT INTO `catalog_eav_attribute` (`attribute_id`, `is_global`, `is_searchable`, `is_filterable`, `is_comparable`, `is_visible_on_front`, `is_html_allowed_on_front`, `is_filterable_in_search`, `used_in_product_listing`, `used_for_sort_by`, `apply_to`, `is_visible_in_advanced_search`, `is_used_for_promo_rules`, `is_used_in_grid`, `is_visible_in_grid`, `is_filterable_in_grid`) VALUES (162, 0, 0, 0, 0, 0, 1, 0, 0, 0, NULL, 0, 0, 1, 1, 1)<\/pre>\n<p><strong>1.5. Create product attribute with multiple select type<\/strong><\/p>\n<pre class=\"lang:mysql decode:true \">INSERT INTO `eav_attribute` (`entity_type_id`, `attribute_code`, `backend_model`, `backend_type`, `frontend_input`, `frontend_label`, `source_model`, `is_required`, `is_user_defined`, `is_unique`) VALUES (4, 'multiple_select', 'Magento\\\\Eav\\\\Model\\\\Entity\\\\Attribute\\\\Backend\\\\ArrayBackend', 'varchar', 'multiselect', 'Multiple Select', NULL, 0, 1, 0)\r\n\r\nDELETE FROM `eav_attribute_label` WHERE (attribute_id ='163')\r\n\r\nINSERT INTO `catalog_eav_attribute` (`attribute_id`, `is_global`, `is_searchable`, `is_filterable`, `is_comparable`, `is_visible_on_front`, `is_html_allowed_on_front`, `is_filterable_in_search`, `used_in_product_listing`, `apply_to`, `is_visible_in_advanced_search`, `is_used_for_promo_rules`, `is_used_in_grid`, `is_visible_in_grid`, `is_filterable_in_grid`) VALUES (163, 0, 0, 0, 0, 0, 1, 0, 0, NULL, 0, 0, 1, 1, 1)\r\n\r\nINSERT INTO `eav_attribute_option` (`attribute_id`, `sort_order`) VALUES ('163', '1')\r\nDELETE FROM `eav_attribute_option_value` WHERE (option_id = '213')\r\nINSERT INTO `eav_attribute_option_value` (`option_id`, `store_id`, `value`) VALUES ('213', '0', 'Option one')\r\n\r\nINSERT INTO `eav_attribute_option` (`attribute_id`, `sort_order`) VALUES ('163', '2')\r\nDELETE FROM `eav_attribute_option_value` WHERE (option_id = '214')\r\nINSERT INTO `eav_attribute_option_value` (`option_id`, `store_id`, `value`) VALUES ('214', '0', 'Option two')\r\n\r\nUPDATE `eav_attribute` SET `default_value` = '' WHERE (attribute_id = '163')<\/pre>\n<p><strong>&nbsp;<\/strong><strong>1.6. Create product attribute with dropdown type<\/strong><\/p>\n<pre class=\"lang:mysql decode:true \">INSERT INTO `eav_attribute` (`entity_type_id`, `attribute_code`, `backend_model`, `backend_type`, `frontend_input`, `frontend_label`, `source_model`, `is_required`, `is_user_defined`, `is_unique`) VALUES (4, &nbsp;'dropdown', &nbsp;NULL, 'int', 'select', 'Dropdown', 'Magento\\\\Eav\\\\Model\\\\Entity\\\\Attribute\\\\Source\\\\Table', 0, &nbsp;1, &nbsp;0)\r\n\r\nDELETE FROM `eav_attribute_label` WHERE (attribute_id ='164')\r\n\r\nINSERT INTO `catalog_eav_attribute` (`attribute_id`, `is_global`, `is_searchable`, `is_filterable`, `is_comparable`, `is_visible_on_front`, `is_html_allowed_on_front`, `is_filterable_in_search`, `used_in_product_listing`, `used_for_sort_by`, `apply_to`, `is_visible_in_advanced_search`, `is_used_for_promo_rules`, `is_used_in_grid`, `is_visible_in_grid`, `is_filterable_in_grid`) VALUES (164, 0, 0, 0, 0, 0, 1, 0, 0, 0, NULL, 0, 0, 1, 1, 1)\r\n\r\nINSERT INTO `eav_attribute_option` (`attribute_id`, `sort_order`) VALUES ('164', 1)\r\nDELETE FROM `eav_attribute_option_value` WHERE (option_id = '215')\r\nINSERT INTO `eav_attribute_option_value` (`option_id`, `store_id`, `value`) VALUES ('215', '0', 'Option one')\r\n\r\nINSERT INTO `eav_attribute_option` (`attribute_id`, `sort_order`) VALUES ('164', '2')\r\nDELETE FROM `eav_attribute_option_value` WHERE (option_id = '216')\r\nINSERT INTO `eav_attribute_option_value` (`option_id`, `store_id`, `value`) VALUES ('216', '0', 'Option two')\r\n\r\nUPDATE `eav_attribute` SET `default_value` = '' WHERE (attribute_id = '164')<\/pre>\n<p><strong>&nbsp;<\/strong><strong>1.7. Create product attribute with price type<\/strong><\/p>\n<pre class=\"lang:mysql decode:true \">INSERT INTO `eav_attribute` (`entity_type_id`, `attribute_code`, `backend_model`, `backend_type`, `frontend_input`, `frontend_label`, `source_model`, `is_required`, `is_user_defined`, `default_value`, `is_unique`) VALUES (4, 'price_example', &nbsp;'Magento\\\\Catalog\\\\Model\\\\Product\\\\Attribute\\\\Backend\\\\Price', &nbsp;'decimal', &nbsp;'price', 'Price Example', NULL, 0, 1, NULL, &nbsp;0)\r\n\r\nDELETE FROM `eav_attribute_label` WHERE (attribute_id ='165')\r\n\r\nINSERT INTO `catalog_eav_attribute` (`attribute_id`, `is_global`, `is_searchable`, `is_filterable`, `is_comparable`, `is_visible_on_front`, `is_html_allowed_on_front`, `is_filterable_in_search`, `used_in_product_listing`, `used_for_sort_by`, `apply_to`, `is_visible_in_advanced_search`, `is_used_for_promo_rules`, `is_used_in_grid`, `is_visible_in_grid`, `is_filterable_in_grid`) VALUES (165, 0, 0, 0, 0, 0, 1, 0, 0, 0, NULL, 0, 0, 1, 1, 1)<\/pre>\n<p><b>1.8. Create product attribute with media image type<\/b><\/p>\n<pre class=\"lang:mysql decode:true \">INSERT INTO `eav_attribute` (`entity_type_id`, `attribute_code`, `backend_model`, `backend_type`, `frontend_input`, `frontend_label`, `source_model`, `is_required`, `is_user_defined`, `is_unique`) VALUES (4, 'media_image', NULL, 'varchar', 'media_image', 'Media image', NULL, 0, 1, 0)\r\n\r\nDELETE FROM `eav_attribute_label` WHERE (attribute_id ='166')\r\n\r\nINSERT INTO `catalog_eav_attribute` (`attribute_id`, `is_global`, `is_searchable`, `is_filterable`, `is_comparable`, `is_visible_on_front`, `is_html_allowed_on_front`, `is_filterable_in_search`, `used_in_product_listing`, `used_for_sort_by`, `apply_to`, `is_visible_in_advanced_search`, `is_used_for_promo_rules`, `is_used_in_grid`, `is_visible_in_grid`, `is_filterable_in_grid`) VALUES (166, 0, 0, 0, 0, 0, 1, 0, 0, 0, NULL, 0, 0, &nbsp;1, 1, 1)<\/pre>\n<p><b>1.9. Create product attribute with Fixed Product Tax type<\/b><\/p>\n<pre class=\"lang:mysql decode:true \">INSERT INTO `eav_attribute` (`entity_type_id`, `attribute_code`, `backend_model`, `frontend_input`, `frontend_label`, `source_model`, `is_required`, `is_user_defined`, `is_unique`) VALUES (4, 'fixed_product_tax', 'Magento\\\\Weee\\\\Model\\\\Attribute\\\\Backend\\\\Weee\\\\Tax', 'weee', 'Fixed Product Tax', NULL, 0, 1, 0)\r\n\r\nDELETE FROM `eav_attribute_label` WHERE (attribute_id ='167')\r\n\r\nINSERT INTO `catalog_eav_attribute` (`attribute_id`, `is_global`, `is_searchable`, `is_filterable`, `is_comparable`, `is_visible_on_front`, `is_html_allowed_on_front`, `is_filterable_in_search`, `used_in_product_listing`, `used_for_sort_by`, `apply_to`, `is_visible_in_advanced_search`, `is_used_for_promo_rules`, `is_used_in_grid`, `is_visible_in_grid`, `is_filterable_in_grid`) VALUES (167, 0, 0, 0, 0, 0, 1, 0, 0, 0, 'simple,virtual,bundle,downloadable,configurable', 0, 0, 1, 1, 1)<\/pre>\n<p><span style=\"font-weight: 400;\">The second part of the article is to be published soon. Stay tuned!<\/span><\/p>\n\n\n<div class=\"after_content__request\" style=\"background-color:\">\n    <div class=\"content_part\">\n        <span class=\"title h3\">\n                    <\/span>\n        <span class=\"sales_after_content_text\">\n                    <\/span>\n        <a href=\"https:\/\/belvg.com\/contact?utm_source=blog&amp;utm_campaign=request_&amp;utm_content=bottom%20\" data-link class=\"contact_with_sales call-to-action\" target=\"_blank\">\n             Get started <\/a>\n    <\/div>\n<\/div>\n\n<style>.after_content__request .title { margin-bottom: var(--belvg-space__md); } .after_content__request .content_part { margin: 0; padding: var(--belvg-space__2xl) clamp(var(--belvg-space__md), 10vw, 100px); justify-content: center; text-align: center; } <\/style>\n\n\n","protected":false},"excerpt":{"rendered":"Developer Certification Exam","protected":false},"author":82,"featured_media":15008,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"image","meta":{"_acf_changed":false,"footnotes":""},"categories":[35,14,389,471,473,472],"tags":[],"class_list":["post-14998","post","type-post","status-publish","format-image","has-post-thumbnail","hentry","category-certification","category-magento","category-magento2-development","category-magento-developer","category-magento-front-end-developer","category-magento-solution-specialist","post_format-post-format-image"],"acf":[],"aioseo_notices":[],"aioseo_head":"\n\t\t<!-- All in One SEO 5.0.4 - aioseo.com -->\n\t<meta name=\"robots\" content=\"max-image-preview:large\" \/>\n\t<link rel=\"canonical\" href=\"https:\/\/belvg.com\/blog\/?custom_blocks=request-block-platform\" \/>\n\t\t<meta name=\"generator\" content=\"All in One SEO (AIOSEO) 5.0.4\" \/>\n\t\t<script type=\"application\/ld+json\" class=\"aioseo-schema\">\n\t\t\t{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/?custom_blocks=request-block-platform#breadcrumblist\",\"itemListElement\":[{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#listItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/belvg.com\\\/blog\\\/\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/magento#listItem\",\"name\":\"Magento\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/magento#listItem\",\"position\":2,\"name\":\"Magento\",\"item\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/magento\",\"nextItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/eav-in-magento-2.html#listItem\",\"name\":\"EAV in Magento 2\"},\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#listItem\",\"name\":\"Home\"}},{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/eav-in-magento-2.html#listItem\",\"position\":3,\"name\":\"EAV in Magento 2\",\"previousItem\":{\"@type\":\"ListItem\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/category\\\/magento#listItem\",\"name\":\"Magento\"}}]},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#organization\",\"name\":\"BelVG Blog\",\"description\":\"Magento and Prestashop articles\",\"url\":\"https:\\\/\\\/belvg.com\\\/blog\\\/\"},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/?custom_blocks=request-block-platform#webpage\",\"url\":\"https:\\\/\\\/belvg.com\\\/blog\\\/?custom_blocks=request-block-platform\",\"name\":\"Request block (Platform) | BelVG Blog\",\"inLanguage\":\"en-US\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#website\"},\"breadcrumb\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/?custom_blocks=request-block-platform#breadcrumblist\"},\"datePublished\":\"2023-12-01T17:48:24+02:00\",\"dateModified\":\"2023-12-04T19:12:57+02:00\"},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/belvg.com\\\/blog\\\/\",\"name\":\"BelVG Blog\",\"description\":\"Magento and Prestashop articles\",\"inLanguage\":\"en-US\",\"publisher\":{\"@id\":\"https:\\\/\\\/belvg.com\\\/blog\\\/#organization\"}}]}\n\t\t<\/script>\n\t\t<!-- All in One SEO -->\n\n","aioseo_head_json":{"title":"Request block (Platform) | BelVG Blog","description":"","canonical_url":"https:\/\/belvg.com\/blog\/?custom_blocks=request-block-platform","robots":"max-image-preview:large","keywords":"","webmasterTools":{"miscellaneous":""},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"BreadcrumbList","@id":"https:\/\/belvg.com\/blog\/?custom_blocks=request-block-platform#breadcrumblist","itemListElement":[{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/#listItem","position":1,"name":"Home","item":"https:\/\/belvg.com\/blog\/","nextItem":{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/category\/magento#listItem","name":"Magento"}},{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/category\/magento#listItem","position":2,"name":"Magento","item":"https:\/\/belvg.com\/blog\/category\/magento","nextItem":{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/eav-in-magento-2.html#listItem","name":"EAV in Magento 2"},"previousItem":{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/#listItem","name":"Home"}},{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/eav-in-magento-2.html#listItem","position":3,"name":"EAV in Magento 2","previousItem":{"@type":"ListItem","@id":"https:\/\/belvg.com\/blog\/category\/magento#listItem","name":"Magento"}}]},{"@type":"Organization","@id":"https:\/\/belvg.com\/blog\/#organization","name":"BelVG Blog","description":"Magento and Prestashop articles","url":"https:\/\/belvg.com\/blog\/"},{"@type":"WebPage","@id":"https:\/\/belvg.com\/blog\/?custom_blocks=request-block-platform#webpage","url":"https:\/\/belvg.com\/blog\/?custom_blocks=request-block-platform","name":"Request block (Platform) | BelVG Blog","inLanguage":"en-US","isPartOf":{"@id":"https:\/\/belvg.com\/blog\/#website"},"breadcrumb":{"@id":"https:\/\/belvg.com\/blog\/?custom_blocks=request-block-platform#breadcrumblist"},"datePublished":"2023-12-01T17:48:24+02:00","dateModified":"2023-12-04T19:12:57+02:00"},{"@type":"WebSite","@id":"https:\/\/belvg.com\/blog\/#website","url":"https:\/\/belvg.com\/blog\/","name":"BelVG Blog","description":"Magento and Prestashop articles","inLanguage":"en-US","publisher":{"@id":"https:\/\/belvg.com\/blog\/#organization"}}]}},"aioseo_meta_data":{"post_id":"14998","title":"Why use EAV in Magento 2? | #site_title","description":"Discover the benefits of Entity Attribute Value model in Magento 2 and find out how it can work for your online store.","keywords":null,"keyphrases":null,"focus_keyword":null,"additional_keywords":null,"truseo_locale":null,"primary_term":null,"canonical_url":null,"og_title":null,"og_description":null,"og_object_type":"default","og_image_type":"default","og_image_custom_url":null,"og_image_custom_fields":null,"og_image_url":null,"og_image_width":null,"og_image_height":null,"og_video":null,"og_custom_url":null,"og_article_section":null,"og_article_tags":null,"twitter_use_og":false,"twitter_card":"default","twitter_image_type":"default","twitter_image_custom_url":null,"twitter_image_custom_fields":null,"twitter_image_url":null,"twitter_title":null,"twitter_description":null,"schema_type":"default","schema_type_options":null,"schema":{"blockGraphs":[],"customGraphs":[],"default":{"data":{"Article":[],"Course":[],"Dataset":[],"FAQPage":[],"Movie":[],"Person":[],"Product":[],"ProductReview":[],"Car":[],"Recipe":[],"Service":[],"SoftwareApplication":[],"WebPage":[]},"graphName":"","isEnabled":true},"graphs":[]},"pillar_content":false,"robots_default":true,"robots_noindex":false,"robots_noarchive":false,"robots_nosnippet":false,"robots_nofollow":false,"robots_noimageindex":false,"robots_noodp":false,"robots_notranslate":false,"robots_max_snippet":null,"robots_max_videopreview":null,"robots_max_imagepreview":"large","priority":null,"frequency":null,"local_seo":null,"limit_modified_date":false,"ai":null,"breadcrumb_settings":null,"seo_analyzer_scan_date":null,"created":"2026-11-03 18:37:12","updated":"2026-11-03 18:37:12"},"aioseo_breadcrumb":"<div class=\"aioseo-breadcrumbs\"><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/belvg.com\/blog\/\" title=\"Home\">Home<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">\u00bb<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\t<a href=\"https:\/\/belvg.com\/blog\/category\/magento\" title=\"Magento\">Magento<\/a>\n\t\t<\/span><span class=\"aioseo-breadcrumb-separator\">\u00bb<\/span><span class=\"aioseo-breadcrumb\">\n\t\t\tEAV in Magento 2\n\t\t<\/span><\/div>","aioseo_breadcrumb_json":[{"label":"Home","link":"https:\/\/belvg.com\/blog\/"},{"label":"Magento","link":"https:\/\/belvg.com\/blog\/category\/magento"},{"label":"EAV in Magento 2","link":"https:\/\/belvg.com\/blog\/eav-in-magento-2.html"}],"post_mailing_queue_ids":[],"_links":{"self":[{"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/posts\/14998","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/users\/82"}],"replies":[{"embeddable":true,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/comments?post=14998"}],"version-history":[{"count":37,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/posts\/14998\/revisions"}],"predecessor-version":[{"id":27894,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/posts\/14998\/revisions\/27894"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/media\/15008"}],"wp:attachment":[{"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/media?parent=14998"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/categories?post=14998"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/belvg.com\/blog\/wp-json\/wp\/v2\/tags?post=14998"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}