/ Published in: Rails
URL: http://www.geekskillz.com/articles/11
Expand |
Embed | Plain Text
@distinctlist = Item.find.all.map{ |i| i.fieldname }.uniq
Comments
Subscribe to comments
You need to login to post a comment.

This is really bad solution to problem since database is far better at this job. Check
http://rors.org/2010/5/23/distinct-values-in-rails
hmm, your markdown support is not complete. another try: distinct values in rails