Sequel :: AdapterNotFound: LoadError: cannot load such file - win32ole

I can successfully connect to the database MySQLand Postgresusing 'sequel'.

I want to connect to a SQL Server database from Ubuntu 12.04 to Windows. Using tiny-tds, we can do this, but I want to use "continue" to connect

Mounted Pearls

gem 'dbi'
gem 'tiny_tds'
gem 'sequel'
gem "win32ole-pp"
gem "rubysl-win32ole"
gem 'activerecord-sqlserver-adapter'

I get the following error.

1.9.3p448 :007 >   require 'win32ole-pp'
LoadError: cannot load such file -- win32ole-pp

1.9.3p448 :008 > require 'rubysl-win32ole'
 => false 

1.9.3p448 :001 > DB = Sequel.ado(:database => 'test_database', :host => 'xxx.xxx.xxx.xxx', :user => 'username', :password => 'password', :provider => 'SQLNCLI10')
    Sequel::AdapterNotFound: LoadError: cannot load such file -- win32ole

Sequel provides an adapter for tiny tds. How can i use this adapter? Please tell me how can I do this with the continuation of gem?

I don’t understand how to use tiny tds with a continuation, since the continuation provides an adapter for tiny_tds.

Thanks...

+4
1

, MSSQL ubuntu 12.04 . Sequel tiny_tds SQL-. xxx.xxx.xxx.xxx - IP- . win32ole

Sequel MySQL2, Postgres, SQL Server Tiny tds.

Gem

gem 'tiny_tds' #For SQlServer
gem 'mysql2' #For MySQL
gem 'sequel'

MySQL2

DB = Sequel.connect(:adapter => 'mysql2', :user => 'username', :password => "passw0rd", :host => "xxx.xxx.xxx.xxx" , :database => "test_database")

SQL Server

DB = Sequel.connect(:adapter => 'tinytds', :user => 'username', :password => "passw0rd", :host => "xxx.xxx.xxx.xxx" , :database => "test_database")

post = DB.from(:test_table)

post.all
+11

All Articles