Understanding Why COUNT(*) Can Be Slow in PostgreSQL.