activerecord-import-vertica 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/activerecord-import/active_record/adapters/vertica5_adapter.rb +10 -0
- data/lib/activerecord-import/active_record/adapters/vertica6_adapter.rb +10 -0
- data/lib/activerecord-import/active_record/adapters/vertica7_adapter.rb +10 -0
- data/lib/activerecord/import/vertica.rb +0 -19
- data/lib/activerecord/import/vertica/version.rb +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 276cbe6449ad2d1fc8fb367831d919201339afe7
|
4
|
+
data.tar.gz: a8146edcc7e3abd1c70ddce2b0ed629f54123b94
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: ca75775eac4609cb5e38dda2038ed5eb63d33d4986fe388926e8f333402a7e51aa2156d38dfcc397983a65e2f01b49c8e29957ee65e004251e52aebd2b896789
|
7
|
+
data.tar.gz: 2a2679d64dd060fb2223d5a4685a2029f50a0af1db03496d8a442eab9961ab04493df85f581dc4aa9c398a634cf5be5313216711756db9c0aff6c038f445187c
|
@@ -3,3 +3,13 @@ require "activerecord-import/adapters/vertica5_adapter"
|
|
3
3
|
class ActiveRecord::ConnectionAdapters::VerticaAdapter
|
4
4
|
include ActiveRecord::Import::Vertica5Adapter
|
5
5
|
end
|
6
|
+
|
7
|
+
class ActiveRecord::Base
|
8
|
+
def self.import(*args)
|
9
|
+
if args.flatten.first.is_a?(::ActiveRecord::Base)
|
10
|
+
bulk_insert_records(*args)
|
11
|
+
else
|
12
|
+
bulk_insert(*args)
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
@@ -3,3 +3,13 @@ require "activerecord-import/adapters/vertica6_adapter"
|
|
3
3
|
class ActiveRecord::ConnectionAdapters::VerticaAdapter
|
4
4
|
include ActiveRecord::Import::Vertica6Adapter
|
5
5
|
end
|
6
|
+
|
7
|
+
class ActiveRecord::Base
|
8
|
+
def self.import(*args)
|
9
|
+
if args.flatten.first.is_a?(::ActiveRecord::Base)
|
10
|
+
bulk_insert_records(*args)
|
11
|
+
else
|
12
|
+
bulk_insert(*args)
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
@@ -3,3 +3,13 @@ require "activerecord-import/adapters/vertica7_adapter"
|
|
3
3
|
class ActiveRecord::ConnectionAdapters::VerticaAdapter
|
4
4
|
include ActiveRecord::Import::Vertica7Adapter
|
5
5
|
end
|
6
|
+
|
7
|
+
class ActiveRecord::Base
|
8
|
+
def self.import(*args)
|
9
|
+
if args.flatten.first.is_a?(::ActiveRecord::Base)
|
10
|
+
bulk_insert_records(*args)
|
11
|
+
else
|
12
|
+
bulk_insert(*args)
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
@@ -8,22 +8,3 @@ module Activerecord
|
|
8
8
|
end
|
9
9
|
end
|
10
10
|
end
|
11
|
-
|
12
|
-
# AR import loads itself inside of an activesupport load hook,
|
13
|
-
# so we have to force load the code now so that we can patch the
|
14
|
-
# import method.
|
15
|
-
module ActiveRecord
|
16
|
-
module Import
|
17
|
-
end
|
18
|
-
end
|
19
|
-
require "activerecord-import/import"
|
20
|
-
|
21
|
-
class ActiveRecord::Base
|
22
|
-
def self.import(*args)
|
23
|
-
if args.flatten.first.is_a?(::ActiveRecord::Base)
|
24
|
-
bulk_insert_records(*args)
|
25
|
-
else
|
26
|
-
bulk_insert(*args)
|
27
|
-
end
|
28
|
-
end
|
29
|
-
end
|