How are you checking to see if the row was updated or not? By the 
updated_at timestamp, or something else?

I'm not sure if you're asking for help coming up with a way to determine 
whether or not a row should be deleted, or just how to delete it.

The how to delete is simple enough, I guess. Just loop through the 
records and call destroy on the object if it doesn't meet your criteria 
with something like this:

@records.each { |record| record.destroy if/unless # insert your logic 
here }

-- Josh
http://iammrjoshua.com


Me wrote:
> I have a table of data that I update with a file.  I would like to
> delete all data that does not get updated.

-- 
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 rubyonrails-talk@googlegroups.com
To unsubscribe from this group, send email to 
rubyonrails-talk+unsubscr...@googlegroups.com
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-talk?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to