From c058a773b89b1bf4103f9bd4910743f60f238792 Mon Sep 17 00:00:00 2001 From: Oscar Del Ben Date: Fri, 4 May 2012 08:36:30 +0200 Subject: [PATCH] mention database mapping in getting started guide --- guides/source/getting_started.textile | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/guides/source/getting_started.textile b/guides/source/getting_started.textile index 31eb332c89..947abd7ba0 100644 --- a/guides/source/getting_started.textile +++ b/guides/source/getting_started.textile @@ -404,7 +404,10 @@ $ rails generate model Post title:string text:text With that command we told Rails that we want a +Post+ model, which in turn should have a title attribute of type string, and a text attribute -of type text. Rails in turn responded by creating a bunch of files. For +of type text. Those attributes are automatically added to the +posts+ +table in the database and mapped to the +Post+ model. + +Rails in turn responded by creating a bunch of files. For now, we're only interested in +app/models/post.rb+ and +db/migrate/20120419084633_create_posts.rb+. The latter is responsible for creating the database structure, which is what we'll look at next.