The following is a collection of my experience with the EAV system in Magento. It contains all the facts I needed early on in my Magento developer career. Being a reflection of a personal experience it may be incomplete, obscure, or overladen with details. Please comment if you have a suggestion on how to improve it. If you need a clarification on some part of the text below, please ask. If there is an error – point it out. Thank you!
The EAV system is one of the most complex part of Magento shop software. It is also the most controversial and often cited as a root of performance problems in shops that have to handle large and complex product databases. When developing Magento extensions these problems can be exacerbated by failure to properly use the EAV implemented in Magento, which often happens due to a great effort that is required to understand it. For me, as probably for many other Magento developers, it has been a lot of lessons learned hard.
Before diving into details of the Magento’s EAV, it is necessary to learn a bit about the origins of EAV and its general principles. EAV has quite a long history. Some of its earliest applications were storage systems for clinical data back in 1970s. As a storage method EAV borrows from early object-oriented languages. SIMULA 67 is cited as one such influence. Functional languages such as LISP are also known to have contributed to the development of EAV. They contain storage structures that record object information in attribute-value pairs – a principle fundamental to EAV.