search for: foo_cont

Displaying 1 result from an estimated 1 matches for "foo_cont".

Did you mean: foo_conf
2012 Feb 21
10
Search of multiple columns
I am currently writing a search method for my rails applications and at the moment it works fine. I have the following in my game.rb: def self.search(search) if search find(:all, :conditions => [''game_name LIKE ? OR genre LIKE ? OR console LIKE ?'', "%#{search}%", "#{search}", "#{search}"]) else find(:all) end end No that searches