02. Foundations - Data Models
Data models have to be thought thoroughly when they are first created.
Bad data models can create:
- inconvenience
- inconsistencies
- life threatening scenarios
- systematic abuse
Examples:
- the dutch postal codes allow you to Uniquely identify any door based on
- postal code
- house number
- the German codes don't even represent a continuous geographical region, they contain multiple cities/towns
- There can be the same street with the same number in the same postal codes, so then you need the city as well, and the number of course
- For Queue, for some reason people abuse it for oral exams as it wasn't intended for that.
- A hospital should not use an BSN number as an identifier, INTERNATIONALS might NOT HAVE IT! -> deadly
- smart buildings can be really dumb, so people end up
- cutting cables
- hardwiring
- hacking
- breaking sensors
Conclusion
Attention
Always work with the user in mind, your models should create intuitive relationships between all of the entities, and also intuitive entities themselves! Choices have cascading effects down the line. Some edge cases are very important!