Skip to content

Instantly share code, notes, and snippets.

@jamiejackson
Created February 11, 2015 18:09
Show Gist options
  • Save jamiejackson/00449f3dc418cdf1b408 to your computer and use it in GitHub Desktop.
Save jamiejackson/00449f3dc418cdf1b408 to your computer and use it in GitHub Desktop.
require 'rubygems'
require 'roo'
require 'iconv'
require 'mysql'
require 'deep_merge'
require "cwo_import/version"
module CwoImport
def self.pull(start_year, end_year, table, excel, measures, states, exceptions, conn, data_dir)
puts 1.alph
end
Alph = ("A".."Z").to_a
def self.alph
s, q = "", self
(q, r = (q - 1).divmod(26)) && s.prepend(Alph[r]) until q.zero?
s
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment