i have Linux fedora installed on machine and also i am working with rails project and i have SQL server 2012 on another machine .... i want to connect rails with SQL server 2012 remotely. How can i do this ??
Use the following gems for connecting sql server :
gem 'tiny_tds'
gem 'activerecord-sqlserver-adapter'
And the database.yml
should look like this:
development:
mode: dblib
adapter: sqlserver
host: <host or ip>
database: <DBNAME>
username: uname
password: password
timeout: 0
you can check gems documentation for further usage.
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.