How to write filter on the controller in Ruby on Rails, that is eqvivalent to this SQL code
select * from persons where persons.category = 'developers'
Use this:
before_filter :nerds_only
private
def nerds_only
@people = Person.where(:category => 'developers')
end