Created
October 25, 2010 11:57
-
-
Save JGaudette/644835 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/ruby | |
require 'dbi' | |
require 'odbc' | |
dbh = DBI.connect('DBI:ODBC:prod', 'username', 'password') | |
query = "select getdate()" | |
row = dbh.select_one(query) | |
puts "got a value of: " + row[0].to_s | |
dbh.disconnect if dbh |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment