Wouldn't you want to use an OR between the conditions here?  Otherwise
you're going to only find stuff where the title, url and description
are all the same.  What are the odds of that?

On Jul 20, 11:36 pm, Rails List <[email protected]>
wrote:
> Controller:
>
> def search
>   t = params[:search][:query]
>   @q = Model.find(:all, :conditions=>["title like ? AND url like ? AND
> description like ?", t,t,t"])
> end

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Talk" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to 
[email protected]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to