OK, here is a simple abstraction of the problem:
2 variables(male_users and female_users) to store 2 groups of user i.e. male and female
If you have 1 million users, do you prefer (considering half of them is male, and half of the is female) :
I suppose you will answer saying you prefer to fetch only half the users ;-) And, depending on the condition, if more complex, it could be even less than this.
Basically, fetching less data means :
In general cases, we try to avoid fetching more data that necessary ; i.e. we place the filtering on the database side.
Of course, this means you'll have to think about the indexes you'll place on your database's tables : they'll have to fit the needs of the queries you'll be doing.