Overarching goal: Data that has been uploaded should be augmented with enough database data that it can be added as a row to the database
Things to keep in mind:
- Any errors produced in this story will be shown on the frontend so errors shouldn't be made in such a way that they couldn't be listed in the frontend
Data flow steps:
Negative cases
Note, the following tables are deliberately excluded from database updating because they use a data source whose transformation hasn't been implemented yet:
- data_policeunit - Describes police units as a unit, but the 060 foia responses return information about individual officers
- data_officerbadgenumber - This data is synthesized based on existing database data, it should have a special upload step that verifies the numbers we receive due to high potential for conflict
- data_officer - should be updated through a
roster foia response in order to ensure we get the best data
- data_allegationcategory - This is used to classify the type of allegation, and should thus not be updated from foia responses except to insert new rows. This will receive its own story
Overarching goal: Data that has been uploaded should be augmented with enough database data that it can be added as a row to the database
Things to keep in mind:
Data flow steps:
Augment transformed data - The transformed allegation data is augmented with existing database data so that each row of transformed data has enough information to be a valid row in the database
Check augmented data - Check if the data to load already exists in the database
Load non conflicting augmented data
-Cpd-witness will not have all of the columns of the officer row, missing columns don't need to match.
Negative cases
When an augmented transformed row matches an existing database row:
When a transformed row cannot be augmented:
Note, the following tables are deliberately excluded from database updating because they use a data source whose transformation hasn't been implemented yet:
rosterfoia response in order to ensure we get the best data