From: Anderson Leite Date: 2010-06-06T07:30:41+09:00 Subject: Re: comparing objects The first solution sent by Marcin Wolski works for normal ruby classes, but I got something wrong when using with an ActiveRecord class. I am not sure about the problem know. So I tried Robert Klemme's solution, using: in_both = obj_from_db.select do |u1| obj_from_xml.any? do |u2| u1.email == u2.email && u1.age == u2.age end end That's working know. I have to study a little more of your suggestions since this aproach still looks like slowly yet.... To figure the problem, I am using this algorithm at http://www.dobbyme.com That's a birthday reminder. The idea implemented here is: I got your gmail contacts (useim gdata gem) and lokk at dobbyme's database to match if you have some contact already registered. I think now the actual aproach is fine, but with a lot of users I will start to have some troubles...am I right ? Opnions ? -- Posted via http://www.ruby-forum.com/.