Adding some indexes to speed up the queries