Thanks Dude .. Worked .. Brijesh Shah wrote: > Hemant Bhargava wrote: >> I am having Bangalore in an variable. I mean lets suppose selected_city. >> Then i tried this:- >> City.find(:all, :conditions => [ "name != selected_city" ] >> >> Nopes this is not working .. >> >> >> > Then try with this... > > City.find(:all, :conditions => [ "name != ?",selected_city ] > > selected_city must be variable. > > Thanks > Brijesh Shah
-- Posted via http://www.ruby-forum.com/. -- 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.

