On Wed, Feb 8, 2012 at 2:19 AM, Hassan Schroeder <hassan.schroe...@gmail.com
> wrote:

> On Tue, Feb 7, 2012 at 4:36 PM, Don <don.leat...@gmail.com> wrote:
>
> >  However, you will want to make sure you research, in detail, the
> database
> > situation.  Heroku is now forcing the use of Postgres for "production"
> > deployment, in certain situations.  Since your app is probably using
> SQLite,
> > you will want to try to deploy to Heroku on an older stack - one that
> allows
> > the use of SQLite.
>
> Has Heroku ever used anything but PostgreSQL? Have you ever
> had a DB-related issue deploying an app to Heroku that was being
> developed with a non-PG database?  (Other than with DB-proprietary
> SQL, of course)
>
> Just curious, I've never had (or heard of) such a problem; wondering
> if I've just been lucky  :-)
>

At my current project, the other developer prefers mysql and uses only that,
I prefer postgresql and use it mostly (but sometimes I test on mysql).
Already
on 2 occasions, I had tests fail, (on postgresql) that passed on mysql.

1) we had an issue where a schema.db was incorrectly processed by
mysql upon rake test:prepare (this worked correctly in postgresql).
We switched to RAKE_ENV=test rake db:create/migrate/seed for
that reason

2) postgresql checks more rigorously on certain cases of uniqueness
of the primary key (I think that was writing a rake db:seed with a fixed
low value id (16 actually) that was saved later on by the regular create
tests ... mysql happily created a second a row with that id? postgresql
complained)

And this is just a fairly "simple" project smaller than 1 person year ...
When you get to more complex projects, the number of issues will
certainly increase. What I generally do, is also test on mysql. In
general, I find keeping up multi-platform compatibility a good
measure to see if I keep to "standard/future proof" implementations
(unless I really need a specialized feature of postgresql).

So yes, I think it _is_ relevant to do some regular development/testing
runs with exactly the same database version as in production (and
even within postgresql, versions can matter since certain not really
valid constructs get more rigorously tested and may throw an
exception with newer versions).

HTH,

Peter

-- 
*** Available for a new project ***

Peter Vandenabeele
http://twitter.com/peter_v
http://rails.vandenabeele.com
http://coderwall.com/peter_v

-- 
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-talk@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.

Reply via email to