Repopulate Bailey DB
1) Clear data out of database
these tables first to avoid foreign-key violation errors:
TRUNCATE crimes
TRUNCATE trial_files
TRUNCATE criminals
[or
TRUNCATE crimes; TRUNCATE trial_files; TRUNCATE criminals;
]
These tables are virtually always modified when you add a new record(s), so do them next:
TRUNCATE outcomes
TRUNCATE respites
TRUNCATE trials
[or
TRUNCATE outcomes; TRUNCATE respites; TRUNCATE trials;
]
These tables are occasionally modified:
TRUNCATE aliases
TRUNCATE judge_respites
TRUNCATE outcome_durations
TRUNCATE execution_specials
TRUNCATE mercy_appeals
[or
TRUNCATE aliases; TRUNCATE judge_respites; TRUNCATE outcome_durations; TRUNCATE execution_specials; TRUNCATE mercy_appeals;
]
2) Run the Importer.php file on each data file to upload it into db. Can take up to a minute. Dev and production instances both working.