Database Reference
In-Depth Information
Store only the origin-
al state
(Type 0)
Store only the most cur-
rent state
(Type 1)
Store full
history
(Type 2)
Store some
history
(Type 3)
Organization
✓
SurveyCreation
✓
Survey
✓
CompletedSurvey
✓
CompletedSurveyResponse
✓
SurveyQuestion
✓
SurveyQuestionPossibleAnswer
✓
The only collection we learned that needs full history is
Survey
. Most collections are Type
1, meaning only the most current.
CompletedSurvey
and
CompletedSurveyResponse
are
Type 0 (as many transactions are), meaning we are just storing the original state as the
transaction should never change.
Using effective dates to implement a Type 2, here is our updated physical data model: