[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