I'm trying to use the :select option in the find method, but I guess it's not doing what I think it should be doing.
This gives me the error:Code:find_options = { :select => 'CONCAT(last_name, " ", ssn) AS last_name_ssn', :conditions => [ "LOWER(last_name) LIKE ?", '%text%' ], :order => "last_name_ssn ASC", :limit => 10 } @items = Person.find(find_options)
Couldn't find Person without an ID AND LOWER(last_name) LIKE '%text%'
Any ideas where I'm going wrong?
Perhaps I should just use find_by_sql?






Bookmarks