small medium large xlarge

31 Jul 2008, 23:22
Ciaran Bradley (2 posts)


Just a note, (from a total noob, this is my 3rd day learning RoR). I’m on a Mac 10.4.11 running the MySQL database. I was getting an “unknown database” error, after setting up database.yml and by running the db:migrate. However, I (out of curiosity) tried db:create instead, and all went through correctly. (I hit the same type of issue when doing the Hello World).

Just thought I’d share, although I’ve just had the book a few hours, (I’ll probably get to the bit where you’ve put it in the appendix later :) )

01 Aug 2008, 02:39
Sam Ruby (633 posts)

I don’t believe that is currently covered in the book (it was introduced in Rails 2.0) – I’ll see to it that it is added.

01 Aug 2008, 10:34
Ciaran Bradley (2 posts)


Thanks Sam, I was convinced that I’d missed something. I’m really enjoying it so far :)

07 Aug 2008, 04:50
Mikhail V. Shokhirev (a.k.a. Mike Shock) (19 posts)

Ciaran, when you tried to run “rake db:migrate” you got the “unknown database” error because the DB, described in config/database.yml, didn’t exist. And the “db:create” task created the needed database. Before “db:create” was added to the Rails tasks, you had to create the databases manually by the DB-specific tools.

You must be logged in to comment