Re: New rails user - Trying to understand why console wont run save command

After you have to save the orm records to database by .save! Comand .
Ex:- subject.save! Comand


Sent from my Nokia phone

------Original message------
From: Steve Mr. [email protected]
To: [email protected]
Date: Saturday, November 26, 2011 8:09:41 PM GMT+0100
Subject: [Rails] New rails user - Trying to understand why console wont
run save command

Hi Everyone,

I just found this forum today and I’m having trouble with a rails
tutorial I’m working on. On all other rails console commands it runs
when I hit enter such as:

“>> subject.new_record?
=> true”

However when I try to save a record using:

subject = Subject.new(:name => “First Subject”, :position => 1", :visible =>
true)

Nothing happens. I tried create as well. When I hit enter it just puts
an enter and doesn’t run the command which returns. Any clue what I’m
doing wrong?


Posted via http://www.ruby-forum.com/.


You received this message because you are subscribed to the Google
Groups “Ruby on Rails: Talk” group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/rubyonrails-talk?hl=en.

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