Questions tagged [eav]

Questions about Magento's Entity Attribute Value (EAV) implementation

Filter by
Sorted by
Tagged with
3
votes
1answer
33 views

What is the difference between the customer attribute properties user_defined and system and what are they used for?

How to create a customer attribute is explained in various answers such as this or this. What they all have in common, is that when creating the attribute its properties user_defined and system are ...
1
vote
2answers
4k views

Set default value for attribute in Setup Script in Magento 2

I have created install script to add an attribute to category. Default value has to be set, thus 'default' => '1', is used. InstallData.php file: public function install(...
1
vote
1answer
6k views

Where the actual data of custom attribute is stored in magento 2?

I have added a custom attribute in existing table catalog_category. The following code i have write in InstallData.php. namespace BelVG\AdditionalImageTemplate\Setup; use Magento\Framework\Setup\...
3
votes
2answers
2k views

Magento 2 attribute backend_type static vs varchar

Is Magento attribute value saved in database table static and varchar identical? when and why to use static backend_type instead of varchar?
6
votes
6answers
13k views

Magento 2 - Add custom attribute in customer registration form

I want to add a custom attribute in customer registration form. I write a module with the following InstallData.php <?php namespace vendor\TestModule\Setup; use Magento\Customer\Model\Customer; ...
25
votes
0answers
981 views

Magento Profiling - Why so many EAV: Magento\Eav\Model\Config::getAttribute?

I'm just reviewing the speed of a store and just wondering if anyone knows more about why I have over 100 EAV: Magento\Eav\Model\Config::getAttribute 0.006978 rows within my profiler. It's just I do ...
0
votes
0answers
19 views

EAV - Static and Varchar Entity - What is the common between both?

I need a help on one of the following question : Q - EAV - Static and varchar entity type what is the similar in between this ? Both values can be identical for single sites Both values can be ...
0
votes
1answer
935 views

Should I disable flat catalog?

My Magento store has around 60,000 products. We use flat tables. We are in the process of separating them into different attribute sets, and are adding lots of new attributes to assist with filtering ...
0
votes
0answers
29 views

Magento 2 - How to hide/remove custom attribute from backend Account Information tab in customer page?

I have a custom attribute showing in the account information tab page. how can I remove them? Right now I can see the following
0
votes
0answers
30 views

Using EAV attribute as foreign key?

What would be the best way to link products and customers. I want that all products are assigned to customers. So customers can create their own products. As I am new to Magento I can think of 2 ways:...
0
votes
0answers
30 views

EavSetupFactory doesn't exist?

Trying to add a attribute to categories. Setting up install script following this guide: https://devdocs.magento.com/guides/v2.3/ui_comp_guide/howto/add_category_attribute.html and https://www....
4
votes
1answer
2k views

How to get custom attributes from customer via SOAP API?

I have a few custom attributes to extend the customer with bank account information. The attributes are stored in mage_eav_attribute table. How can I get them via the SOAP API?
1
vote
1answer
485 views

Error with Magento\Eav\Model\Entity\Attribute how to fix?

I have this error, 1 exception(s): Exception #0 (Exception): Item (Magento\Eav\Model\Entity\Attribute) with the same ID "87" already exists. it seems to me that there must be a duplicate row ? But ...
1
vote
1answer
66 views

How to add 'switcherConfig' to a Modifier pool on Magento2

I have custom eav table whose attributes. I'm getting dynamically on my modifier pool. But I want to add switcherConfig, as one of my fieldset display is dependent on a selected field value. Can ...
1
vote
2answers
2k views

Magento 2: addAttributeToFilter not returning any results

When I use addAttributeToFilter on Magento\Catalog\Model\ResourceModel\Product\CollectionFactory, with a custom attribute, I always get 0 results. use Magento\Catalog\Model\ResourceModel\Product\...
1
vote
2answers
898 views

What is the difference between eav/attribute and eav/entity_attribute?

Looking at eav_setup file and trying to understand the difference between the eav/attribute and eav/entity_attribute table. If I have to guess, eav/attribute is the entity that represents the ...
1
vote
0answers
68 views

Magento2.3.3 Facing Error during Data migration

I am trying to migartion from Magneto1.9.3.10 to Magento2.3.3 but I am facing error during [Eav Step] data migration like: SQLSTATE[HY093]: Invalid parameter number: number of bound variables does ...
2
votes
3answers
1k views

Invalid method Magento\Eav\Model\Entity\Attribute::isAllowedForRuleCondition

I am getting an issue on Magento 2.2 when trying to create promotion rule. This error occurs sometimes and the error disappears if run Magento upgrade command. But it comes again sometime.
2
votes
2answers
645 views

Mage_Eav_Model_Attribute_Data::factory() must be an instance of Mage_Eav_Model_Attribute

I'm facing this message in system.log when I open an oreder from the admin panel: MESSAGE: Recoverable Error: Argument 1 passed to Mage_Eav_Model_Attribute_Data::factory() must be an instance of ...
3
votes
1answer
885 views

Magento 2 : How to create an EAV entity module?

I want to create EAV entity module. I refer these below links. I want to do the same in Magento 2. How to create an EAV entity? How to do it in Magento 2? Please help me. Thanks. UPDATE: I can ...
2
votes
1answer
470 views

row_id vs entity_id in magento 2.3 EE

In Magento 2.3 EE, entity_id is missing in EAV tables, instead row_id is available Please explain the difference between row_id and entity_id and the removal of entity_id in EAV tables
1
vote
1answer
45 views

How to make product specific multiselect attributes on Magento 2.3?

We have a table that has data linked to products. MyCustomDataTable { id, product_id, text_value } We want to be able to search for products using the MyCustomDataTable.text_value value. ...
3
votes
1answer
984 views

Magento 2: Join EAV attribute from product attribute set on a custom flat table

Hi fellow programmers, I would like to know how to do a join on my custom flat table (i.e. discountrules), I've implemented a generic Repository based on the Pestle archive, which implements the ...
4
votes
0answers
41 views

magento 2: create custom frontend input type

I need a custom frontend input type which I would call "table": The issue at hand is that I have a customer that has a lot of different attribute sets with even more attributes. And he is in a ...
19
votes
3answers
5k views

Magento 2: Are Flat Tables Still a Thing?

Are flat tables still a thing we need to worry about in Magento 2? I know there's UI where we can turn the flat tables on, but I'm unsure how well they've been tested, and if they're even needed ...
5
votes
3answers
3k views

How do I add additional options to customer gender?

I have a client who would like to add the option 'Transgender' in addition to Male and Female in the gender field. Can I do this directly in the database? Would I need to update anything beyond the ...
0
votes
1answer
50 views

EAV indexer optimization: cannot find option

There is a section in the Magento 2.3 documentation that is titled EAV indexer optimization. It says that you should basically disable the EAV indexer, if you are not using a MySQL based search ...
2
votes
1answer
382 views

Magento 2 : Invalid method Magento\Eav\Model\Entity\Attribute::isScopeStore

I am getting an issue on Magento 2.2.6 when trying to save my module record. This error occurs sometimes and the error disappears if run Magento upgrade command. But it comes again sometime. system....
11
votes
3answers
3k views

Right way to implement getExtensionAttributes()

I was wondering, what's the right way to implement an extensible EAV model. I see that in Magento\Catalog\Model\Product, the method getExtensionAttributes() is implemented like this: public function ...
3
votes
2answers
1k views

Customer EAV Attribute not Showing in Admin

Before upgrading to Magento 2.2.1, I was using version 2.1.10 and made a custom uuid attribute for customers. The attribute was added to the customer form in the admin panel and saved correctly. ...
4
votes
0answers
160 views

How to use modifier in product_action_attribute Form?

I have created an eav attribute and modified the field inside edit product form, that was easy. But in products mass action (Update attributes) page, the field I have created, by eav Attribute and ...
0
votes
1answer
67 views

How to list unused attributes options by sql query

I would like to list all attributes options that our products don't uses. I prefer to use SQL to do that to learn how to work with. Right now i use this query to get the ID of my attributs select * ...
3
votes
2answers
4k views

Magento 2 How to add custom attribute to customer address and how to insert value in that attribute?

I want to add a new custom attribute to "customer_address" that I did with an attribute installer script, now I am able to see that field in "eav_attribute" table. I have created a module and I have ...
1
vote
2answers
32 views

Magento 2 - read and write new customer attribute

I added a new customer attribute n2gEmails: app/code/Fekete/Newsletter2Go/etc/extension_attributes.xml: <?xml version="1.0" ?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" ...
0
votes
0answers
17 views

Unable to define customer flat columns using source entity

I'm trying to create a customer EAV which is always either 0 or 1, never null. The main issue I'm having is forcing the column in the customer_grid_flat table to be not nullable. $customerSetup->...
0
votes
1answer
63 views

Magento 2: EAV Attribute is not showing on catalog page

I've made an EAV attribute using an external script but the attribute is not showing on catalogue page. The database has created. I tried to put value in EAV Database but nothing works. Ext_Script in ...
0
votes
1answer
600 views

How to create a custom tab with custom attributes in Customer admin

I am a beginner in Magento (version 2.3). I am looking for a solution to create a form with custom attributes, which would be displayed by clicking on a custom tab in Customer admin. I have ...
0
votes
1answer
43 views

Magento 2: Call to a member function getEntityType() on null

I'm trying to create a new Eav Entity after this instruction post. Then i got this issue: Call to a member function getEntityType() on null I'm still new with Eav Entity, so can some one help me ...
18
votes
6answers
43k views

Magento 2 - How to get attribute options value of eav entity?

How can I get the attribute options values of eav entity? I found solution only for magento 1.x but M2 I don't know. M1: $attr = Mage::getResourceModel('eav/entity_attribute_collection')->...
0
votes
0answers
11 views

getAdditionalAttributeTable returning empty string

In the /vendor/magento/module-eav/Model/ResourceModel/Attribute/Collection.php file, the call below is simply returning an empty string, any ideas as to where this might be, or even where this ...
3
votes
1answer
1k views

How to create text swatch programmatically?

How to create text swatch programmatically? If, I follow method from saving controller in the product-attribute module (admin) then, I got first and the third field saved but not actual text swatch.
0
votes
2answers
174 views

Magento 2 : Need to perform clean cache programmatically after records save

In admin side, I want to clean "eav" cache type on records save. I added code in afterSave() function and function also call after save records. But, I think it's not working because, parent afterSave(...
6
votes
4answers
5k views

Magento 2 - Get attribute options and sort order

I need to get the label and sort order (as defined in backend) of all the options of a custom attribute, programmatically. I'm using this interface: Magento\Eav\Api\AttributeRepositoryInterface This ...
0
votes
0answers
35 views

How to add extra fields on ccsave payment method?

I need to create two additional fields for the ccsave checkout form. I created in the tables sales_flat_quote_payment and sales_flat_order_payment two fields called cc_parcelas and cc_csc. In html, ...
2
votes
2answers
4k views

Where is the newsletter 'general subscription' field stored in the database

I'm working on a customer database export, but can't find where the 'general subscription' newsletter subscription field is stored in the database. I imagine it is some EAV value, but in what table ...
2
votes
2answers
685 views

Custom Customer attribute not saving Magento 2.3.1

I have the following code to create a custom customer attribute. <?php namespace Vendor\MyModule\Setup\Patch\Data; use Magento\Customer\Model\Customer; use Magento\Customer\Setup\...
1
vote
1answer
38 views

How is a product name retrieved if the query does not return it in the result set?

I'm trying to get data from catalog_product EAV tables with the following code: $productCollection = Mage::getModel('catalog/product')->getCollection() ->addAttributeToFilter('...
0
votes
0answers
34 views

Magento 2 - join using EAV attribute

I created an EAV attribute on product entity, this attribute named user_id and has the ID of the user who's added the product. After works, I crashed on this point, I need to join tables to get ...
0
votes
0answers
24 views

Customer Custom Attribute missing in order

I have create custom customer attribute using EAV, While registering customer from Admin-panel Checkout the customer attribute not setting default values.
1
vote
1answer
47 views

Needed short explanation

I have read many blogs to understand some of the topics in Magento 2 but still not clear about them. They are as follows EAV Dependency Injection Could anyone please explain them shortly? Thanks ...

1
2 3 4 5
8