Permalink
Browse files

Add support for ar-extensions' insert_many connection method

  • Loading branch information...
1 parent 651b8b1 commit 2a9edd1fd952d857097a9cd0145f228234e5d602 @mperham mperham committed Oct 9, 2008
Showing with 3 additions and 1 deletion.
  1. +3 −1 lib/data_fabric.rb
View
@@ -141,7 +141,9 @@ def initialize(model_class, options)
delegate :insert, :update, :delete, :create_table, :rename_table, :drop_table, :add_column, :remove_column,
:change_column, :change_column_default, :rename_column, :add_index, :remove_index, :initialize_schema_information,
:dump_schema_information, :execute, :to => :master
-
+
+ delegate :insert_many, :to => :master # ar-extensions bulk load method
+
def transaction(start_db_transaction = true, &block)
with_master { raw_connection.transaction(start_db_transaction, &block) }
end

0 comments on commit 2a9edd1

Please sign in to comment.