On 27 November 2010 12:45, Michael Pavling <pavl...@gmail.com> wrote: > On 27 November 2010 03:14, daze <dmonopol...@gmail.com> wrote: >> Is it okay to have, for example, sqlite3 for development and testing, >> and mysql2 for production? Is that doable/common/not too hard to >> configure? > > It's perfectly doable, and perfectly okay, and apparently quite > common; just complete the appropriate sections of the database.yml > file for each of your environments.
I am a bit confused Michael, see below. Here you are saying it is ok to have different db types. > >> Should the types of databases for development, testing, and production >> all be the same? > > "Should"? No... *don't* do it! Even though it is undoubtedly possible, > and lots of people do :-) Now you are saying that that they must _not_ be the same. Methinks you mistyped? > You will be making a total nightmare for yourself when code that > "works" in development "doesn't pass tests", or worse, code that > "passes tests" doesn't "run in production". There are too many > differences across dbs; reserved words, db contraints (like index name > sizes), and general SQL implementation [1]. Make your development > environment as close as possible to your production, and ideally have > your test environment be *identical* to production. Here you say they should be the same I think (which I agree with generally), yet right at the start you said it was ok for them to be different. Colin -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-t...@googlegroups.com. To unsubscribe from this group, send email to rubyonrails-talk+unsubscr...@googlegroups.com. For more options, visit this group at http://groups.google.com/group/rubyonrails-talk?hl=en.