Minimizing find_by query for a single repeated attribute