Scaffold didn't work

i am using rails -v 3.0.7.when i tried “rails generate scaffold try
name:string number:decimal” , it gave following error message
invoke active_record
/usr/lib/ruby/1.8/yaml.rb:133:in load': syntax error on line 7, col 2: pool: 5’ (ArgumentError)
from /usr/lib/ruby/1.8/yaml.rb:133:in load' from /usr/lib/ruby/gems/1.8/gems/railties-3.0.7/lib/rails/ application/configuration.rb:88:indatabase_configuration’
from /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.7/lib/
active_record/railtie.rb:58
from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/
active_support/lazy_load_hooks.rb:36:in instance_eval' from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/ active_support/lazy_load_hooks.rb:36:inexecute_hook’
from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/
active_support/lazy_load_hooks.rb:43:in run_load_hooks' from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/ active_support/lazy_load_hooks.rb:42:ineach’
from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/
active_support/lazy_load_hooks.rb:42:in run_load_hooks' from /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.7/lib/ active_record/base.rb:1904 from /usr/lib/ruby/gems/1.8/gems/railties-3.0.7/lib/rails/ generators/named_base.rb:97:inpluralize_table_names?’
from /usr/lib/ruby/gems/1.8/gems/railties-3.0.7/lib/rails/
generators/named_base.rb:44:in table_name' from /usr/lib/ruby/gems/1.8/gems/activerecord-3.0.7/lib/rails/ generators/active_record/model/model_generator.rb:16:increate_migration_file’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/task.rb:
22:in send' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/task.rb: 22:inrun’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/
invocation.rb:118:in invoke_task' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/ invocation.rb:124:ininvoke_all’
from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/
active_support/dependencies.rb:239:in map' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/core_ext/ ordered_hash.rb:75:ineach’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/
invocation.rb:124:in map' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/ invocation.rb:124:ininvoke_all’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/group.rb:
226:in dispatch' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/ invocation.rb:109:insend’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/
invocation.rb:109:in invoke' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/group.rb: 269:in_invoke_for_class_method’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/shell.rb:
74:in with_padding' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/group.rb: 258:in_invoke_for_class_method’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/group.rb:
134:in _invoke_from_option_orm' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/task.rb: 22:insend’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/task.rb:
22:in run' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/ invocation.rb:118:ininvoke_task’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/
invocation.rb:124:in invoke_all' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/shell.rb: 14:inmap’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/core_ext/
ordered_hash.rb:75:in each' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/ invocation.rb:124:inmap’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/
invocation.rb:124:in invoke_all' from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/group.rb: 226:indispatch’
from /usr/lib/ruby/gems/1.8/gems/thor-0.14.6/lib/thor/base.rb:
389:in start' from /usr/lib/ruby/gems/1.8/gems/railties-3.0.7/lib/rails/ generators.rb:163:ininvoke’
from /usr/lib/ruby/gems/1.8/gems/railties-3.0.7/lib/rails/commands/
generate.rb:10
from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/
active_support/dependencies.rb:239:in require' from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/ active_support/dependencies.rb:239:inrequire’
from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/
active_support/dependencies.rb:225:in load_dependency' from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/ active_support/dependencies.rb:596:innew_constants_in’
from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/
active_support/dependencies.rb:225:in load_dependency' from /usr/lib/ruby/gems/1.8/gems/activesupport-3.0.7/lib/ active_support/dependencies.rb:239:inrequire’
from /usr/lib/ruby/gems/1.8/gems/railties-3.0.7/lib/rails/
commands.rb:17
from script/rails:6:in `require’
from script/rails:6

Please somebody help
Thanks

On 6 May 2011, at 17:38, amrit pal pathak [email protected]
wrote:

i am using rails -v 3.0.7.when i tried “rails generate scaffold try
name:string number:decimal” , it gave following error message
invoke active_record
/usr/lib/ruby/1.8/yaml.rb:133:in load': syntax error on line 7, col 2: pool: 5’ (ArgumentError)

You have a syntax error in your database.yml file, probably on line 7 or
thereabouts.

Fred

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs