[DB MIGRATION REQ'D] Fix count history indexes
Fix bug where multi-column indexes caused inconsistent query results
Clean up tests, standardize milestone threshold to 20
Correct migration (remove rollback, fix type insertion)
Fix case in file paths