# Development to Production

**URL:** <https://www.ruby-forum.com/t/development-to-production/134433>\
**Category:** Rails\
**Created:** [April 10, 2008, 7:26pm UTC](https://www.ruby-forum.com/t/development-to-production/134433 "2008-04-10T19:26:55Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![pete](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/p/3ab097/32.png) [@pete](https://www.ruby-forum.com/u/pete)\
**Post date:** [April 10, 2008, 7:26pm UTC](https://www.ruby-forum.com/t/development-to-production/134433/1 "2008-04-10T19:26:55Z")

</div>

Hi-

Does rake db:create accept a parameter to specify the environment to  
create? I have a \_development DB and would like to create the  
\_production DB to match the schema, and migrate the data.

I can’t seem to find the documentation to do this. Can someone point  
me in the right direction? Or do you have the command to do this?

Thanks!

---

<div class="post-metadata">

**Author:** ![pete](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/p/3ab097/32.png) [@pete](https://www.ruby-forum.com/u/pete)\
**Post date:** [April 11, 2008, 4:41pm UTC](https://www.ruby-forum.com/t/development-to-production/134433/2 "2008-04-11T16:41:33Z")

</div>

RAILS\_ENV= rake db:create

(assuming a \*nix environment)

So, for production you’d do:

RAILS\_ENV=production rake db:create

In windows, I’m sure there is a similar way to set the rails env, but  
as I don’t code on windows (anymore), I’m not sure what that way is.

-Danimal
