I would appreciate any tips/clues/advice very much.
I have started using ruby on rails and when the MS SQL Server database is on
a different box than my dev box (where the RoR app is located) I can connect
fine. However when I try to connect to a MS SQL Server database on the same
box as my RoR app I get an error. I have tried to use the IP address of the
dev box as the value of "host" as well as "localhost" but
nothing works. I
am using Windows 2000, SQL Server 7, and RoR v 1.0. Here is my
configuration.yml file and a copy of the error :
development:
adapter: sqlserver
database: cookbook_development
host: 127.0.0.1
username: sa
password: password
DBI::DatabaseError in Recipe#index
Open
OLE error code:80004005 in Microsoft OLE DB Provider for SQL Server
Cannot open database requested in login
''cookbook_development''.
Login fails.
HRESULT error code:0x80020009
Exception occurred.
RAILS_ROOT: ./script/../config/..
Application Trace | Framework Trace | Full Trace
c:/ruby/lib/ruby/site_ruby/1.8/DBD/ADO/ADO.rb:57:in `connect''
c:/ruby/lib/ruby/site_ruby/1.8/dbi/dbi.rb:584:in `connect''
c:/ruby/lib/ruby/site_ruby/1.8/dbi/dbi.rb:384:in `connect''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/sqlserver_adapter.rb:40:in
`sqlserver_connection''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:145:in
`send''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:145:in
`connection_without_query_cache=''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/query_c
ache.rb:54:in
`connection=''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:106:in
`retrieve_connection''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:20:in
`connection''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/base.rb
:518:in
`count_by_sql''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/base.rb
:511:in
`count''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/pagin
ation.rb:167:in
`count_collection_for_pagination''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/pagin
ation.rb:188:in
`paginator_and_collection_for''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/pagin
ation.rb:124:in
`paginate''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/scaff
olding.rb:101:in
`list''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/scaff
olding.rb:94:in
`index''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:853:in
`send''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:853:in
`perform_action_without_filters''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/filte
rs.rb:332:in
`perform_action_without_benchmark''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/bench
marking.rb:69:in
`perform_action_without_rescue''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/bench
marking.rb:69:in
`measure''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/bench
marking.rb:69:in
`perform_action_without_rescue''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/rescu
e.rb:82:in
`perform_action''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:369:in
`send''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:369:in
`process_without_session_management_support''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/sessi
on_management.rb:116:in
`process''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/dispatcher.rb:38:in
`dispatch''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/webrick_server.rb:117:in
`handle_dispatch''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/webrick_server.rb:83:in
`service''
c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:104:in `service''
c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:65:in `run''
c:/ruby/lib/ruby/1.8/webrick/server.rb:155:in `start_thread''
c:/ruby/lib/ruby/1.8/webrick/server.rb:144:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:144:in `start_thread''
c:/ruby/lib/ruby/1.8/webrick/server.rb:94:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:89:in `each''
c:/ruby/lib/ruby/1.8/webrick/server.rb:89:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:79:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:79:in `start''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/webrick_server.rb:69:in
`dispatch''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/commands/servers/webrick.rb:5
9
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require__''
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require''
c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.2.5/lib/active_support/depend
encies.rb:214:in
`require''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/commands/server.rb:28
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require__''
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require''
c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.2.5/lib/active_support/depend
encies.rb:214:in
`require''
script/server:3
c:/ruby/lib/ruby/site_ruby/1.8/DBD/ADO/ADO.rb:57:in `connect''
c:/ruby/lib/ruby/site_ruby/1.8/dbi/dbi.rb:584:in `connect''
c:/ruby/lib/ruby/site_ruby/1.8/dbi/dbi.rb:384:in `connect''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/sqlserver_adapter.rb:40:in
`sqlserver_connection''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:145:in
`send''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:145:in
`connection_without_query_cache=''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/query_c
ache.rb:54:in
`connection=''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:106:in
`retrieve_connection''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:20:in
`connection''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/base.rb
:518:in
`count_by_sql''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/base.rb
:511:in
`count''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/pagin
ation.rb:167:in
`count_collection_for_pagination''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/pagin
ation.rb:188:in
`paginator_and_collection_for''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/pagin
ation.rb:124:in
`paginate''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/scaff
olding.rb:101:in
`list''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/scaff
olding.rb:94:in
`index''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:853:in
`send''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:853:in
`perform_action_without_filters''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/filte
rs.rb:332:in
`perform_action_without_benchmark''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/bench
marking.rb:69:in
`perform_action_without_rescue''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/bench
marking.rb:69:in
`measure''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/bench
marking.rb:69:in
`perform_action_without_rescue''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/rescu
e.rb:82:in
`perform_action''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:369:in
`send''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:369:in
`process_without_session_management_support''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/sessi
on_management.rb:116:in
`process''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/dispatcher.rb:38:in
`dispatch''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/webrick_server.rb:117:in
`handle_dispatch''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/webrick_server.rb:83:in
`service''
c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:104:in `service''
c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:65:in `run''
c:/ruby/lib/ruby/1.8/webrick/server.rb:155:in `start_thread''
c:/ruby/lib/ruby/1.8/webrick/server.rb:144:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:144:in `start_thread''
c:/ruby/lib/ruby/1.8/webrick/server.rb:94:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:89:in `each''
c:/ruby/lib/ruby/1.8/webrick/server.rb:89:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:79:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:79:in `start''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/webrick_server.rb:69:in
`dispatch''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/commands/servers/webrick.rb:5
9
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require__''
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require''
c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.2.5/lib/active_support/depend
encies.rb:214:in
`require''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/commands/server.rb:28
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require__''
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require''
c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.2.5/lib/active_support/depend
encies.rb:214:in
`require''
script/server:3
c:/ruby/lib/ruby/site_ruby/1.8/DBD/ADO/ADO.rb:57:in `connect''
c:/ruby/lib/ruby/site_ruby/1.8/dbi/dbi.rb:584:in `connect''
c:/ruby/lib/ruby/site_ruby/1.8/dbi/dbi.rb:384:in `connect''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/sqlserver_adapter.rb:40:in
`sqlserver_connection''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:145:in
`send''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:145:in
`connection_without_query_cache=''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/query_c
ache.rb:54:in
`connection=''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:106:in
`retrieve_connection''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/connect
ion_adapters/abstract/connection_specification.rb:20:in
`connection''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/base.rb
:518:in
`count_by_sql''
c:/ruby/lib/ruby/gems/1.8/gems/activerecord-1.13.2/lib/active_record/base.rb
:511:in
`count''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/pagin
ation.rb:167:in
`count_collection_for_pagination''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/pagin
ation.rb:188:in
`paginator_and_collection_for''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/pagin
ation.rb:124:in
`paginate''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/scaff
olding.rb:101:in
`list''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/scaff
olding.rb:94:in
`index''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:853:in
`send''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:853:in
`perform_action_without_filters''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/filte
rs.rb:332:in
`perform_action_without_benchmark''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/bench
marking.rb:69:in
`perform_action_without_rescue''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/bench
marking.rb:69:in
`measure''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/bench
marking.rb:69:in
`perform_action_without_rescue''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/rescu
e.rb:82:in
`perform_action''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:369:in
`send''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/base.
rb:369:in
`process_without_session_management_support''
c:/ruby/lib/ruby/gems/1.8/gems/actionpack-1.11.2/lib/action_controller/sessi
on_management.rb:116:in
`process''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/dispatcher.rb:38:in
`dispatch''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/webrick_server.rb:117:in
`handle_dispatch''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/webrick_server.rb:83:in
`service''
c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:104:in `service''
c:/ruby/lib/ruby/1.8/webrick/httpserver.rb:65:in `run''
c:/ruby/lib/ruby/1.8/webrick/server.rb:155:in `start_thread''
c:/ruby/lib/ruby/1.8/webrick/server.rb:144:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:144:in `start_thread''
c:/ruby/lib/ruby/1.8/webrick/server.rb:94:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:89:in `each''
c:/ruby/lib/ruby/1.8/webrick/server.rb:89:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:79:in `start''
c:/ruby/lib/ruby/1.8/webrick/server.rb:79:in `start''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/webrick_server.rb:69:in
`dispatch''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/commands/servers/webrick.rb:5
9
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require__''
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require''
c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.2.5/lib/active_support/depend
encies.rb:214:in
`require''
c:/ruby/lib/ruby/gems/1.8/gems/rails-1.0.0/lib/commands/server.rb:28
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require__''
c:/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:18:in
`require''
c:/ruby/lib/ruby/gems/1.8/gems/activesupport-1.2.5/lib/active_support/depend
encies.rb:214:in
`require''
script/server:3
Request
Parameters: None
Show session dump
---
flash: !ruby/hash:ActionController::Flash::FlashHash {}
Response
Headers: {"cookie"=>[],
"Cache-Control"=>"no-cache"}
On 12/18/05, Greg <runman-RmF8UnMRvhsnvi+hAk537w@public.gmane.org> wrote:> > I would appreciate any tips/clues/advice very much. > > I have started using ruby on rails and when the MS SQL Server database is > on > a different box than my dev box (where the RoR app is located) I can > connect > fine. However when I try to connect to a MS SQL Server database on the > same > box as my RoR app I get an error. I have tried to use the IP address of > the > dev box as the value of "host" as well as "localhost" but nothing > works. I > am using Windows 2000, SQL Server 7, and RoR v 1.0. Here is my > configuration.yml file and a copy of the error : > [...]HI Greg, I have success using the local hostname as the host. "local" is supposed to work too. Can you contact your SQL instance via SQL Query Analyzer? Also, are you using SQL 2000 Standard/Developer/Enterprise ? If you''re using MSDE the rules are different (I think). Did that work ? -- ------------------------------ Joyeux Noël ------------------------------ Peter Fitzgibbons _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
-----Original Message----- From: rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org [mailto:rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org] On Behalf Of Peter Fitzgibbons Sent: Monday, December 19, 2005 9:52 AM To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org Subject: Re: [Rails] using a local MS SQL Server On 12/18/05, Greg <runman-RmF8UnMRvhsnvi+hAk537w@public.gmane.org> wrote: I would appreciate any tips/clues/advice very much. I have started using ruby on rails and when the MS SQL Server database is on a different box than my dev box (where the RoR app is located) I can connect fine. However when I try to connect to a MS SQL Server database on the same box as my RoR app I get an error. I have tried to use the IP address of the dev box as the value of "host" as well as "localhost" but nothing works. I am using Windows 2000, SQL Server 7, and RoR v 1.0. Here is my configuration.yml file and a copy of the error : [...] HI Greg, I have success using the local hostname as the host. "local" is supposed to work too. Can you contact your SQL instance via SQL Query Analyzer? Also, are you using SQL 2000 Standard/Developer/Enterprise ? If you''re using MSDE the rules are different (I think). Did that work ? -- ------------------------------ Joyeux Noël ------------------------------ Peter Fitzgibbons Unfortunately it did not. I can use ASP, VB, SQL Query Analyzer and such with "localhost", "local", "127.0.0.1", or the IP address but for some reason my Ruby on Rails doesn''t like it. I am using SQL Server 7 in the client mode (since I work on MS 2000 Pro) so perhaps if I upgrade to the MSDE version it might help. As it is, I just added the other box''s sqlserver instance to the MMC from where I develop on and I administer it remotely. I can live with it for now (everything worked better when I was using PostgreSQL !). Thanks for the ideas, Merry Christmas Greg Canter
Greg, try "(local)" On 12/19/05, Greg <runman-RmF8UnMRvhsnvi+hAk537w@public.gmane.org> wrote:> > > -----Original Message----- > From: rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > [mailto:rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org] On Behalf Of Peter Fitzgibbons > Sent: Monday, December 19, 2005 9:52 AM > To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > Subject: Re: [Rails] using a local MS SQL Server > > > > On 12/18/05, Greg <runman-RmF8UnMRvhsnvi+hAk537w@public.gmane.org> wrote: > > I would appreciate any tips/clues/advice very much. > > I have started using ruby on rails and when the MS SQL Server > database is on > a different box than my dev box (where the RoR app is located) I can > connect > fine. However when I try to connect to a MS SQL Server database on > the same > box as my RoR app I get an error. I have tried to use the IP > address of the > dev box as the value of "host" as well as "localhost" but nothing > works. I > am using Windows 2000, SQL Server 7, and RoR v 1.0. Here is my > configuration.yml file and a copy of the error : > [...] > > > HI Greg, > > I have success using the local hostname as the host. "local" is supposed to > work too. > Can you contact your SQL instance via SQL Query Analyzer? > Also, are you using SQL 2000 Standard/Developer/Enterprise ? If you''re > using MSDE the rules are different (I think). > > Did that work ? > -- > ------------------------------ > Joyeux Noël > ------------------------------ > Peter Fitzgibbons > > > Unfortunately it did not. I can use ASP, VB, SQL Query Analyzer and such > with "localhost", "local", "127.0.0.1", or the IP address but for some > reason my Ruby on Rails doesn''t like it. I am using SQL Server 7 in the > client mode (since I work on MS 2000 Pro) so perhaps if I upgrade to the > MSDE version it might help. As it is, I just added the other box''s > sqlserver instance to the MMC from where I develop on and I administer it > remotely. I can live with it for now (everything worked better when I was > using PostgreSQL !). > > Thanks for the ideas, > Merry Christmas > > Greg Canter > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >
Or the computer name when SQL Server was installed... This will be the server name of the SQL Server instance. On 12/19/05, Ed C. <defeated2k4-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> > Greg, try "(local)" > > On 12/19/05, Greg <runman-RmF8UnMRvhsnvi+hAk537w@public.gmane.org> wrote: > > > > > > -----Original Message----- > > From: rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > > [mailto:rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org] On Behalf Of Peter > Fitzgibbons > > Sent: Monday, December 19, 2005 9:52 AM > > To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > > Subject: Re: [Rails] using a local MS SQL Server > > > > > > > > On 12/18/05, Greg <runman-RmF8UnMRvhsnvi+hAk537w@public.gmane.org> wrote: > > > > I would appreciate any tips/clues/advice very much. > > > > I have started using ruby on rails and when the MS SQL Server > > database is on > > a different box than my dev box (where the RoR app is located) I > can > > connect > > fine. However when I try to connect to a MS SQL Server database > on > > the same > > box as my RoR app I get an error. I have tried to use the IP > > address of the > > dev box as the value of "host" as well as "localhost" but > nothing > > works. I > > am using Windows 2000, SQL Server 7, and RoR v 1.0. Here is my > > configuration.yml file and a copy of the error : > > [...] > > > > > > HI Greg, > > > > I have success using the local hostname as the host. "local" is > supposed to > > work too. > > Can you contact your SQL instance via SQL Query Analyzer? > > Also, are you using SQL 2000 Standard/Developer/Enterprise ? If you''re > > using MSDE the rules are different (I think). > > > > Did that work ? > > -- > > ------------------------------ > > Joyeux Noël > > ------------------------------ > > Peter Fitzgibbons > > > > > > Unfortunately it did not. I can use ASP, VB, SQL Query Analyzer and > such > > with "localhost", "local", "127.0.0.1", or the IP address but for some > > reason my Ruby on Rails doesn''t like it. I am using SQL Server 7 in the > > client mode (since I work on MS 2000 Pro) so perhaps if I upgrade to the > > MSDE version it might help. As it is, I just added the other box''s > > sqlserver instance to the MMC from where I develop on and I administer > it > > remotely. I can live with it for now (everything worked better when I > was > > using PostgreSQL !). > > > > Thanks for the ideas, > > Merry Christmas > > > > Greg Canter > > > > _______________________________________________ > > Rails mailing list > > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > > http://lists.rubyonrails.org/mailman/listinfo/rails > > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >_______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails
Well ... obviously subscribing to this list and the fountain of helpful wisdom in the Ruby on Rails community was A Good Thing (tm). Thanks Ed C. !! the correct answer was putting "local" in parenthesis. Merry Christmas to all !!! Greg -----Original Message----- From: rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org [mailto:rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org] On Behalf Of Ed C. Sent: Monday, December 19, 2005 8:04 PM To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org Subject: Re: [Rails] using a local MS SQL Server Greg, try "(local)" On 12/19/05, Greg <runman-RmF8UnMRvhsnvi+hAk537w@public.gmane.org> wrote:> > > -----Original Message----- > From: rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > [mailto:rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org] On Behalf Of Peter > Fitzgibbons > Sent: Monday, December 19, 2005 9:52 AM > To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > Subject: Re: [Rails] using a local MS SQL Server > > > > On 12/18/05, Greg <runman-RmF8UnMRvhsnvi+hAk537w@public.gmane.org> wrote: > > I would appreciate any tips/clues/advice very much. > > I have started using ruby on rails and when the MS SQL Server > database is on > a different box than my dev box (where the RoR app is located) > I can connect > fine. However when I try to connect to a MS SQL Server > database on the same > box as my RoR app I get an error. I have tried to use the IP > address of the > dev box as the value of "host" as well as "localhost" but > nothing works. I > am using Windows 2000, SQL Server 7, and RoR v 1.0. Here is my > configuration.yml file and a copy of the error : > [...] > > > HI Greg, > > I have success using the local hostname as the host. "local" is > supposed to work too. > Can you contact your SQL instance via SQL Query Analyzer? > Also, are you using SQL 2000 Standard/Developer/Enterprise ? If > you''re using MSDE the rules are different (I think). > > Did that work ? > -- > ------------------------------ > Joyeux Noël > ------------------------------ > Peter Fitzgibbons > > > Unfortunately it did not. I can use ASP, VB, SQL Query Analyzer and > such with "localhost", "local", "127.0.0.1", or the IP address but for > some reason my Ruby on Rails doesn''t like it. I am using SQL Server 7 > in the client mode (since I work on MS 2000 Pro) so perhaps if I > upgrade to the MSDE version it might help. As it is, I just added the > other box''s sqlserver instance to the MMC from where I develop on and > I administer it remotely. I can live with it for now (everything > worked better when I was using PostgreSQL !). > > Thanks for the ideas, > Merry Christmas > > Greg Canter > > _______________________________________________ > Rails mailing list > Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org > http://lists.rubyonrails.org/mailman/listinfo/rails >_______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org http://lists.rubyonrails.org/mailman/listinfo/rails