sqlconv 0.9.1 → 0.9.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (4) hide show
  1. checksums.yaml +4 -4
  2. data/bin/sqlconv +2 -2
  3. data/sqlconv.gemspec +1 -1
  4. metadata +1 -1
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: c5e7b92b5dc45bdff66046a2a632acf9b6e33a5e324365633cae0f51e016122e
4
- data.tar.gz: de89675de412523cb91e6822ba66d4284c932dc934b22c35be7c0d6cdd15e181
3
+ metadata.gz: 8f5a4cff886763224e9216e3f42be20d97ecb9dd96a9bcb23be71d2cc5553276
4
+ data.tar.gz: df12b1041887989c6782ed1e2a64ce4f47f09b31f40130cc1cb8833e1bd8b95f
5
5
  SHA512:
6
- metadata.gz: 88f8d0b4303c6a49d5e824fda39f8f82daa875f41baba03d47e2038c8fd16443f1e8dbcddbece53320402c1a59e2be0ef6cd300b481d59d98636bc9033637dab
7
- data.tar.gz: d8b34edce1ea7c65f6e2b3f6ee8a1fe28eab74c1f904b168fa69e893472a763c5ac39de379c1ce0790fcf3216a8c28f6fd1396329cc846fc0b157e3c972f45ea
6
+ metadata.gz: 36e69fad7422741a99aeb03b28541eec399875c45993d1c7b86ca6bdccf27ad9d04d5aa751cde238c0e8f9fb303e1fbd009e8d82c0915116f568f25eff0ea290
7
+ data.tar.gz: 4c49fa603ecb629a4fc6c3c0bcb366ca9ac45bbb87d515ed866550e03dc9e4cf79d3d52cc82f115c2ec664e30db5d742e5a848bd2966818dd98453b88babb56c
data/bin/sqlconv CHANGED
@@ -141,7 +141,7 @@ def conv(tab1, map1, tab2, map2, mode, dump)
141
141
  defined?(item.func) == "method" or die "undefined function '#{item.func}'"
142
142
  ours.push *(send item.func, *Array[cols[item.from-1]])
143
143
  end
144
- when item.text# literal
144
+ when item.text # literal
145
145
  ours.push(item.text)
146
146
  when item.zero # zero
147
147
  ours.push(0)
@@ -173,7 +173,7 @@ def conv(tab1, map1, tab2, map2, mode, dump)
173
173
 
174
174
  # output insert statement
175
175
  if mode == "pipes"
176
- ours.map! {|item| item == "NULL" ? '' : item.gsub("|","~").gsub("''", "'")[1..-2]}
176
+ ours.map! {|e| e == 'NULL' ? '' : e !~ /\A['"]/ ? e : e[1..-2].gsub("|","~").gsub("''", "'")}
177
177
  puts ours * "|"
178
178
  else
179
179
  puts [pref, ours * ",", ");"].join
data/sqlconv.gemspec CHANGED
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = "sqlconv"
5
- s.version = "0.9.1"
5
+ s.version = "0.9.2"
6
6
  s.author = "Steve Shreeve"
7
7
  s.email = "steve.shreeve@gmail.com"
8
8
  s.summary = "Handy utility to massage MySQL dump files"
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sqlconv
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.9.1
4
+ version: 0.9.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Steve Shreeve