hi,

<% @sp_references.each do |sp_ref| %>
 <% sp_ref.all_references.each_with_index do |tax_ref, i| %>
  <%if (tax_ref.reference.uniq) && (tax_ref.reference !~ /emend$/i) %>
   <%= tax_ref.reference %>
  <%end%>
 <%end%>
<%end%>

This 'uniq' option to get distinct elements in tax_ref.reference is not
working. It shows "undefined method `uniq' for #<String:". Kindly help me
this regard to get the distinct elements from array using each in rails.

--
With Regards,
Palani

-- 
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