Forum: Ruby on Rails Multiple Inserts

Announcement (2017-05-07): www.ruby-forum.com is now read-only since I unfortunately do not have the time to support and maintain the forum any more. Please see rubyonrails.org/community and ruby-lang.org/en/community for other Rails- und Ruby-related community platforms.
Matt W. (Guest)
on 2007-07-04 01:37
(Received via mailing list)
Hello,

I am trying to optimize my Rails code for database inserts. I often
have to insert/update several thousand records after web crawls. Once
I have all the data to insert/update, what are some good ways to
optimize this? I've looked into doing multiple inserts using object-
level transactions. However, the Rails API states that this
functionality is deprecated (http://api.rubyonrails.org/classes/
ActiveRecord/Transactions/ClassMethods.html#M000681). What is the
preferred method? Thanks!
This topic is locked and can not be replied to.