datapipe2 0.0.16 → 0.0.17

Sign up to get free protection for your applications and to get access to all the features.
Files changed (3) hide show
  1. checksums.yaml +4 -4
  2. data/lib/fns/db_to_pgsql.rb +2 -3
  3. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 10024db76a459c430fddb0758be465a747486c9a
4
- data.tar.gz: bdcdb5adc3b632782dd52f39c50cb906819ad37e
3
+ metadata.gz: b8c9b30c2a32bab0563c5b4e5b6b68099bbe1a12
4
+ data.tar.gz: d3af6443b1f092fe1cdb2e24cd8d03efbfb5fe47
5
5
  SHA512:
6
- metadata.gz: f14be6a3d780b659154be480d7da6e971a1b6fa75953ce7bcd4547e541a4168a6cd3eb78cd3d7692f8539d62e00607290afe3f9b9b7c4cb16b28cb22c9d78f03
7
- data.tar.gz: 7b1f4be2785cc3d245dba9c84fb42f3437004f75730b612c03db0edc68f4eafdddfd8678d8133adc95cc487425cba977d377a164662e5c74390deeb2e8061a78
6
+ metadata.gz: 3f10288f0f79471dd85dd0c1c37767bbd50d81c21ed199b679a17b68420d691641dd665492e246af6201defe9afc1cd3de4dda192fcc98a75f2286b0470e3de7
7
+ data.tar.gz: 7bc6f2355b31a8b7587115c751111415e92102c16b8f3e324bd2e264344c34d5d0da25b63c996ff9e168837697cff3643f30fe6175326e797a58daf3a86f602e
@@ -12,10 +12,9 @@ def db_to_pgsql(select_sql, table_name, columns)
12
12
  }
13
13
  d.connection.exec(copy_cmd)
14
14
 
15
- results = s.connection.execute(select_sql)
16
-
15
+ rst = s.queryForResultset(select_sql)
17
16
  count = 0
18
- results.each(as: :array, cache_rows: false) do |r|
17
+ rst.each do |r|
19
18
  count += 1
20
19
  print '.' if count % 100_000 == 0
21
20
  d.connection.put_copy_data "#{r.join('|')}\n"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: datapipe2
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.16
4
+ version: 0.0.17
5
5
  platform: ruby
6
6
  authors:
7
7
  - Guy Irvine