On 16 April 2010 14:22, Hemant Bhargava <[email protected]> wrote:
> Guyz, tell me one thing that if i have an array of object of type ABC..
> then how to find the objects from that array which are uniq in id.. I
> mean unique by ABC.id..

If you have two with the same id how do you know which one you want?

If you just mean that you want to strip out duplicate entries then
look at then just use abc.uniq  (Have a look at the docs for the Array
class).

Colin

>
> May be a newbie question..
> --
> 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.
>
>

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