Fix historical dates to be in y-m-d h:i:s format

Using y-m-d formatted datetimes makes date math a lot easier in SQLite