On Jul 31, 2015, at 11:35 AM, nilayyyy1...@gmail.com wrote: > > Hi Urubatan My find_by_sql query works perfect but when I am using it as > active relation case and when and then is not working properly it is only > giving me one result .
In one case, your case when is in the select clause, which makes sense, in the other it is in the where clause, which does not make sense. -- Scott Ribe scott_r...@elevated-dev.com http://www.elevated-dev.com/ https://www.linkedin.com/in/scottribe/ (303) 722-0567 voice -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscr...@googlegroups.com. To post to this group, send email to rubyonrails-talk@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/7E817078-7CA8-4B6E-8E45-A3CDB4BDEA40%40elevated-dev.com. For more options, visit https://groups.google.com/d/optout.