Synopsis: Entity-Attribute-Value
Learn to identify the Entity-Attribute-Value antipattern challenges, including its impact on data integrity and querying. Understand when its use may be justified and explore alternative modeling strategies to handle variable attributes more effectively in relational databases.
We'll cover the following...
“How do we count the number of rows by date?” This is an example of a simple task for a database programmer. It involves basic SQL syntax:
However, the simple solution assumes two things:
-
Values are stored in the same column, as in
Bugs.date_reported. -
Values can be compared to one another so that
GROUP BYcan accurately group dates with equal values together.
What if we can’t rely on those assumptions? What if the date is stored in the date_reported or report_date column, or in any other column that’s different on ...