hi, is there a way to create the database (say development and or production) specified in database.yml with rake? thanks, Enrico -- "The only thing necessary for the triumph of evil is for good men to do nothing" Edmund Burke
on 2006-05-04 17:37
on 2006-05-04 17:43
A production database usually is much more than just the create statement. For testing and development I use sqlite, where no db creation is necessary, when you first start to use it it gets created automatically.
on 2006-05-04 17:46
Have you looked at the rake migrate utilities. ~A
on 2006-05-04 17:59
Isn't migrations assuming the DB is already there? I'm aware of the migrating functionality on tables and data, there's an execute method able to execute the query you pass but still... isn't it assuming the DB is alredy in place? I know it's just a matter of typing few words, I was just wondering about a rake way to do it. thanks -- "The only thing necessary for the triumph of evil is for good men to do nothing" Edmund Burke
on 2006-05-04 19:24
you can initially import your schema with: rake db_schema_import but i'm not sure about the actual creation of DB. -tak.
on 2006-05-08 21:30
Takashi Okamoto a écrit : > you can initially import your schema with: > > rake db_schema_import > > but i'm not sure about the actual creation of DB. > > -tak. > IMHO, db_schema_import task does work only for SQLite. For MySQL I always have to create "manually" the empty schemas needed (dev, test, prod). What about other DBMS ? I don't know, a try costs nothing ... Didier