Support setting a "default" database
|Reported by:||Kyle Fuller||Owned by:||nobody|
|Component:||Database layer (models, ORM)||Version:||1.1|
|Has patch:||yes||Needs documentation:||no|
|Needs tests:||no||Patch needs improvement:||no|
I have wrote two patches which allow you to select a "default" database, one is for a settings variable, another is a environmental variable. While I was playing around with multidb I found it annoying that I couldn't set a default db, I wanted to be able to use the same settings.py on my site for development and my production site.
os.environ['DJANGO_DEFAULT_DB'] = "development"
This could be set in your wsgi file.
DEFAULT_DB_ALIAS = "development"
This would go into settings.py