Creating a database in MS SQL Server using rake db:create throws an error: The driver encountered an error: com.microsoft.sqlserver.jdbc.SQLServerException -----------------------------------------------------------------------------------------------------------------------------------------------------------
Key: JRUBY-3246 URL: http://jira.codehaus.org/browse/JRUBY-3246 Project: JRuby Issue Type: Bug Components: ActiveRecord-JDBC Environment: Windows XP/JRuby 1.1.3/AR-0.9/SQLServer (9.0.3073) Express Reporter: George Secillano The complete error message is: The driver encountered an error: com.microsoft.sqlserver.jdbc.SQLServerException: The TCP/IP connection to the host has failed. java.net.ConnectException: Connection refused: connect The entry in database.yml: development: adapter: jdbc encoding: utf8 database: whohar_development username: sa password: url: jdbc:sqlserver://localhost:1388 driver: com.microsoft.sqlserver.jdbc.SQLServerDriver The cause seems be coming from lines 27-29 in jdbc.rake. The actual url used to connect becomes jdbc:sqlserver://. I guess the driver would use default values for host and port (localhost:1433) and the database is actually listening on 1388. Commenting out the said lines seems to fix the problem. Maybe someone can give light on the relevance of these lines. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira --------------------------------------------------------------------- To unsubscribe from this list, please visit: http://xircles.codehaus.org/manage_email