https://embed.notionlytics.com/wt/ZXlKd1lXZGxTV1FpT2lKaFlUZG1PR014WkRVd1ltWTBORGd5T1RVd05qZzBNekF4WTJJd1kyRTJPU0lzSW5kdmNtdHpjR0ZqWlZSeVlXTnJaWEpKWkNJNklrbGpiM1pzV2pOcU1VUnBRM1ZUUm1WNFRtdHlJbjA9

Magento implements the Entity-Attribute-Value (EAV) model, which gives it a powerful and flexible way to store entity data. This design allows Magento to support different types of entities - like products, categories, customers - each with potentially hundreds of unique and dynamic attributes, without needing to change the database structure for every new attribute.

A Beginner-Friendly Analogy

Imagine your high school is a Magento store, and each student is like a product in that store. The school needs to keep track of many details about each student, such as their name, age, grade, favorite subjects, etc.

In a traditional database, you might have a table where each column represents a specific detail (attribute) about the student. This can be limiting because every student needs to have the same set of details, and adding new details means changing the structure of the entire table.

EAV Model Explained:

Magento uses a different method called the Entity-Attribute-Value (EAV) model, which is more flexible.

  1. Entities (Students): An entity is something we want to store information about. In this case, it's the students.
  2. Attributes (Details): Attributes are the types of data we want to store - like name, age, grade, and favorite subjects.
  3. Values: These are the actual data entries for each attribute of each student.

EAV Tables Structure:

What are Magento 2 entities?

As an eCommerce platform responsible for most processes of online retail business, Magento has to manage multiple entities. Here is their schema:

Untitled