On the wiki it says to migrate your DB to production, you can run:
rake migrate RAILS_ENV=“production”
This is taken from:
Peak Obsession
My database is set up with correct MySQL permissions granted and the
database.yml is pointing at it. I get no errors when I run it, but
equally my production database does not change at all. When I run the
comment I just get this:
dave$ rake migrate RAILS_ENV=“production”
(in /Users/dave/Sites/sampleapp)
dave$
What am I doing wrong?
Try it the other way round:
RAILS_ENV=production rake migrate
-Jonathan.
Unfortunately that doesnt work either, same result.
I also found mention of an environment variable called RAILS_ENV so I
also tried the following:
$ set RAILS_ENV=production
$ rake migrate
Unfortunately, nothing new happened…
Jonathan V. wrote:
Try it the other way round:
RAILS_ENV=production rake migrate
-Jonathan.
export RAILS_ENV=production
rake migrate
Are you sure you haven’t manually set the value in environment.rb …
-Jonathan.
This worked, i’ll see if I can update the Wiki because I guess that
should contain the correct instructions 
Jonathan V. wrote:
export RAILS_ENV=production
rake migrate
Thanks for your help Jonathan
Unfortunately it didnt, I am using Mac OS X if that matters
Jonathan V. wrote:
Great.
Are you really sure that ‘RAILS_ENV=production rake migrate’ didn’t
work? That’s what I use all the time…
-Jonathan.
Great.
Are you really sure that ‘RAILS_ENV=production rake migrate’ didn’t
work? That’s what I use all the time…
-Jonathan.
Jonathan V. wrote:
export RAILS_ENV=production
rake migrate
Are you sure you haven’t manually set the value in environment.rb …
-Jonathan.
For the newbies out there like me:
In the environment.rb file the environment type has to be in quotes like
so:
RAILS_ENV=“production”
Was there a resolution to this issue? I’m having the same problem where
ruby script/console shows an error but RAILS_ENV shows production.
On Tue, Feb 1, 2011 at 12:19 PM, Anthony M. [email protected]
wrote:
Was there a resolution to this issue? I’m having the same problem where
ruby script/console shows an error but RAILS_ENV shows production.
Given that the original message was from 2006, picked up again by
someone in 2010 – maybe you should start a new thread with a clear
description of your problem (which doesn’t match that of the OP). 
–
Hassan S. ------------------------ [email protected]
twitter: @hassan
Try RAILS_ENV=production rake db:migrate
This is what im using all the time