Entity-attribute-value model - Wikipedia, the free encyclopedia - 0 views
-
Entity–attribute–value model
-
Entity–attribute–value model (EAV) is a data model to describe entities where the number of attributes (properties, parameters) that can be used to describe them is potentially vast, but the number that will actually apply to a given entity is relatively modest
- ...21 more annotations...
-
In an EAV data model, each attribute-value pair is a fact describing an entity, and a row in an EAV table stores a single fact
-
EAV tables are often described as "long and skinny": "long" refers to the number of rows, "skinny" to the few columns
-
Data is recorded as three columns: The entity: the item being described. The attribute or parameter: a foreign key into a table of attribute definitions. At the very least, the attribute definitions table would contain the following columns: an attribute ID, attribute name, description, Data type, and columns assisting input validation
-
Row modeling, where facts about something (in this case, a sales transaction) are recorded as multiple rows rather than multiple columns
-
differences between row modeling and EAV (which may be considered a generalization of row-modeling) are:
-
The data type of the value column/s in a row-modeled table is pre-determined by the nature of the facts it records. By contrast, in an EAV table, the conceptual data type of a value in a particular row depend on the attribute in that row
-
In the EAV table itself, this is just an attribute ID, a foreign key into an Attribute Definitions table
-
larger systems use separate EAV tables for each data type (including binary large objects, "BLOBS"), with the metadata for a given attribute identifying the EAV table in which its data will be stored
-
Where an EAV system is implemented through RDF, the RDF Schema language may conveniently be used to express such metadata
-
access to metadata must be restricted, and an audit trail of accesses and changes put into place to deal with situations where multiple individuals have metadata access
-
quality of the annotation and documentation within the metadata (i.e., the narrative/explanatory text in the descriptive columns of the metadata sub-schema) must be much higher, in order to facilitate understanding by various members of the development team.
-
Validation metadata include data type, range of permissible values or membership in a set of values, regular expression match, default value, and whether the value is permitted to be null
-
Grouping metadata: Attributes are typically presented as part of a higher-order group, e.g., a specialty-specific form. Grouping metadata includes information such as the order in which attributes are presented