- What is the difference between new and create for a model?
After using "new" to make a new model, one must call "save" to save it into the database.
For "create", new and save is done automatically and the model is saved into the database without calling "save".
- What command combined with new will emulate the same behavior as create?
The "save" command
- What is the column that exists on every table but we did NOT define?
"id" is the column that exists on every table but we did NOT define. Same with "created_at" and "updated_at".
- What single line of ruby code can insert a cat with the name "hat" in the database?
Cat.create name:"hat"
- What was the most confusing part over the last few weeks?
Differentiating which files do what in the ruby project folder!
- How did you like this homework in comparison with the others?
Fun! Finally get to use database and integrate it with view.