Created
June 20, 2011 01:07
-
-
Save maxhodak/1034976 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
>> fd = User.new | |
=> #<User id: nil, created_at: nil, updated_at: nil> | |
>> fd.save | |
SQL (0.4ms) BEGIN | |
SQL (10.6ms) INSERT INTO `users` (`created_at`, `updated_at`) VALUES (?, ?) [["created_at", Mon, 20 Jun 2011 01:01:40 UTC +00:00], ["updated_at", Mon, 20 Jun 2011 01:01:40 UTC +00:00]] | |
(1.6ms) COMMIT | |
=> true | |
>> fd | |
=> #<User id: 0, created_at: "2011-06-20 01:01:40", updated_at: "2011-06-20 01:01:40"> | |
>> User.find 1 | |
User Load (2.5ms) SELECT `users`.* FROM `users` WHERE `users`.`id` = ? LIMIT 1 [["id", 1]] | |
=> #<User id: 1, created_at: "2011-06-20 01:01:40", updated_at: "2011-06-20 01:01:40"> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
This is on a dummy app with no modifications: just created and
rails g scaffold User; rake db:migrate