Setting up Rails to work with sqlserver

后端 未结 6 1631
孤城傲影
孤城傲影 2020-12-31 08:15

Ok I followed the steps for setting up ruby and rails on my Vista machine and I am having a problem connecting to the database.

Contents of database.yml

6条回答
  •  执笔经年
    2020-12-31 08:40

    I too had faced this problem. There is another work around. You can create a DSN for the app db from control panel->admin tools->Odbc. Database.yml file should look like below:

    adapter: sqlserver
    mode: odbc
    dsn: DSN_NAME
    host: localhost
    database: App_development
    username: uname
    password: password
    

    I tried using the deprecated gem, wasn't of much use. I had tried installing an ADO adaptor too which rendered useless.

提交回复
热议问题