Welcome to Working With Rails

 

Discussion Forums

Discuss all things Ruby on Rails with perhaps the web's most vibrant group of Ruby on Rails enthusiasts.
2 Posts
ferrt search

i have the model named as Group Group.find_with_ferret 'annai',{:conditions =>["location in (?)", 'bangalore']}

i want to get the data annai and also location should be bangalore ...i need two conditions should be true...

here the o/p:

# @per_page=1>

can any pls help me to search with conditions....

Hi,

I don't have a ferret installation here but the API is quite clear: find_with_ferret(q, options = {}, find_options = {})

So for you it should be: Group.find_with_ferret ‘kali’, {}, {:conditions =>[“location in (?)”, ‘chennai’]}

2 Posts
Login to add your message