RE: Problems with Scaffolding ...

Rowan Hick
Wed, 02 Nov 2005 23:58:38 -0000

I’m getting the same problem using latest version of rails, even
uninstalled/reinstalled. No dice. Latest Beta no dice. Database exists with
table in it. Using XP Pro SP2, MySQL 5.0. I’m going to try out tonight on my
old Powerbook just to make sure it’s not a problem between Keyboard and
Chair.



Initially on a fresh rails install (brand new laptop) couldn’t connect used
set old_password query to update user, cool - rails connects, but now can’t
generate controller.



D:\minihaus.serv\testnerd>ruby script/generate scaffold people admin

      exists  app/controllers/

      exists  app/helpers/

      exists  app/views/admin

      exists  test/functional/

  dependency  model

      exists    app/models/

      exists    test/unit/

      exists    test/fixtures/

   identical    app/models/people.rb

   identical    test/unit/people_test.rb

   identical    test/fixtures/peoples.yml

       error  Before updating scaffolding from new DB schema, try creating a
tab

le for your model (People)





Kindest Regards,



Rowan





   _____

From: rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org
[mailto:rails-bounces-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org] On
Behalf Of Hendie Dijkman
Sent: Wednesday, October 26, 2005 8:26 AM
To: rails-1W37MKcQCpIf0INCOvqR/iCwEArCW2h5@public.gmane.org
Subject: Re: [Rails] Problems with Scaffolding ...



Thanks for the quick response Chris.

Yes, to all of your questions. I created the three databases, users, and the
products table in the database exactly as per the book. Rails does connect,
because if I change the username or password in the database.yml config
file, it complains about not being able to connect.

I delved into the rails code a little and it seems that error message comes
from a create_sandbox method in the scaffold_generator when a
ActiveRecord::StatementInvalid exception is thrown. Dunno, maybe that
triggers something with someone who has had similar problems?



--
No virus found in this incoming message.
Checked by AVG Free Edition.
Version: 7.1.362 / Virus Database: 267.12.6/152 - Release Date: 10/31/2005


--
No virus found in this outgoing message.
Checked by AVG Free Edition.
Version: 7.1.362 / Virus Database: 267.12.6/152 - Release Date: 10/31/2005