Instead of COUNT(*), COUNT(1) is more effecient. I'm
not sure if this is compatible with all of the DBMSes
but I know it works with MSSQL and Postgresql.
This is because the database engine/server does not
need to pull back all of the database fields.