I am not been able to insert row into DB from the rails console.
Post.create(:title =>"t1",:content =>"c1")
(0.2ms) begin transaction
SQL (0.4ms) INSERT INTO "posts" ("created_at", "updated_at") VALUES
(?, ?) [["created_at", "2015-04-06 19:21:40.219007"], ["updated_at",
(204.6ms) commit transaction
=> #<Post id: 13, title: nil, content: nil, created_at: "2015-04-06
19:21:40", updated_at: "2015-04-06 19:21:40">
title and content column are not populates.
create_posts.rb file :
class CreatePosts < ActiveRecord::Migration
create_table :posts do |t|
t.timestamps null: false
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 unsubscribe from this group and stop receiving emails from it, send an email to firstname.lastname@example.org.
To post to this group, send email to email@example.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/17ceeb0b4066ce4f668d5991a68d821d%40ruby-forum.com.
For more options, visit https://groups.google.com/d/optout.