Database Improvements

Ongoing work to replace all of TheyWorkForYou's raw queries with nice shiny PDO prepared statements.
`fatal_error()` is reinstated and called at https://github.com/mysociety/theyworkforyou/commit/b706f774902b26ec040c45da68040ee2b91f891a#diff-77c35f7a822c865eb2574ccaa7c398cbR270