Hello, I''m having trouble with scaffold $ ./script/generate scaffold Event dependency model exists app/models/ exists test/unit/ exists test/fixtures/ skip app/models/event.rb skip test/unit/event_test.rb skip test/fixtures/events.yml exists app/controllers/ exists app/helpers/ exists app/views/events exists test/functional/ create app/controllers/events_controller.rb create test/functional/events_controller_test.rb create app/helpers/events_helper.rb create app/views/layouts/events.rhtml create public/stylesheets/scaffold.css create app/views/events/list.rhtml create app/views/events/show.rhtml create app/views/events/new.rhtml create app/views/events/edit.rhtml ORA-12514: TNS:listener could not resolve SERVICE_NAME given in connect descriptor The config/database.yml contains the correct adapter ( oci ) and username,password,host and database. I''m connection to real data so I can''t give out this information. The database is running Oracle 9i. I''m connecting to this database on a different machine. However, I don''t encounter a problem using sqlplus to connect to this database. Has anyone else had this problem? Any suggestions? Thanks, -- ==================================================| Steven Knight skk-Y5xk1i+vvAw3uPMLIKxrzw@public.gmane.org | | UNH Research Computing Center 603-862-3042 | ===================================================
Hello, You should set both the host and the database fields in database.yml to the TNS entry corresponding to your DB instead of the real host/database. Julien Faissolle -----Original Message----- From: rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org [mailto:rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org] On Behalf Of Steven Knight Sent: Monday, April 18, 2005 3:47 PM To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org Subject: [Rails] scaffold and an oracle error Hello, I''m having trouble with scaffold $ ./script/generate scaffold Event dependency model exists app/models/ exists test/unit/ exists test/fixtures/ skip app/models/event.rb skip test/unit/event_test.rb skip test/fixtures/events.yml exists app/controllers/ exists app/helpers/ exists app/views/events exists test/functional/ create app/controllers/events_controller.rb create test/functional/events_controller_test.rb create app/helpers/events_helper.rb create app/views/layouts/events.rhtml create public/stylesheets/scaffold.css create app/views/events/list.rhtml create app/views/events/show.rhtml create app/views/events/new.rhtml create app/views/events/edit.rhtml ORA-12514: TNS:listener could not resolve SERVICE_NAME given in connect descriptor The config/database.yml contains the correct adapter ( oci ) and username,password,host and database. I''m connection to real data so I can''t give out this information. The database is running Oracle 9i. I''m connecting to this database on a different machine. However, I don''t encounter a problem using sqlplus to connect to this database. Has anyone else had this problem? Any suggestions? Thanks, -- ==================================================| Steven Knight skk-Y5xk1i+vvAw3uPMLIKxrzw@public.gmane.org | | UNH Research Computing Center 603-862-3042 | ================================================== _______________________________________________ Rails mailing list Rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org lists.rubyonrails.org/mailman/listinfo/rails
On Mon, 2005-04-18 at 16:13 +0200, Faissolle, Julien wrote:> Hello, > > You should set both the host and the database fields in database.yml to > the TNS entry corresponding to your DB instead of the real > host/database. > > Julien Faissolle >Thanks Julien, that fixed my oracle problem. Which brings my to this problem: $ ./script/generate scaffold Event dependency model exists app/models/ exists test/unit/ exists test/fixtures/ skip app/models/event.rb skip test/unit/event_test.rb skip test/fixtures/events.yml exists app/controllers/ exists app/helpers/ exists app/views/events exists test/functional/ create app/controllers/events_controller.rb create test/functional/events_controller_test.rb create app/helpers/events_helper.rb create app/views/layouts/events.rhtml create public/stylesheets/scaffold.css create app/views/events/list.rhtml create app/views/events/show.rhtml create app/views/events/new.rhtml create app/views/events/edit.rhtml undefined method `free'' for 1:Fixnum Any thoughts? I''m running ruby 1.8.2 (2004-12-25) [i686-linux] Thanks, -- ==================================================| Steven Knight skk-Y5xk1i+vvAw3uPMLIKxrzw@public.gmane.org | | UNH Research Computing Center 603-862-3042 | ===================================================