Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Insert multiple records in one INSERT statement

branch: master

Fetching latest commit…

Octocat-spinner-32-eaf2f5

Cannot retrieve the latest commit at this time

Octocat-spinner-32 lib
Octocat-spinner-32 spec
Octocat-spinner-32 .gitignore
Octocat-spinner-32 MIT-LICENSE
Octocat-spinner-32 README.rdoc
Octocat-spinner-32 Rakefile
README.rdoc

MysqlMultiInsert

Insert multiple AR objects with one SQL INSERT statement.

Example

class MyClass < ActiveRecord::Base
  include MysqlMultiInsert
end

obj1 = MyClass.new
obj2 = MyClass.new

MyClass.multi_insert [obj1, obj2] #=> One insert statement

Copyright © 2009 Scott Taylor <scott@railsnewbie.com>, released under the MIT license

Something went wrong with that request. Please try again.