Using Django 1.4 is it possible to have 2 apps within the same project use two different databases?
If so, will each app have there own settings.py?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
Have a look at the django documentation on how to define multiple databases in your settings.
To use a different database for each app you can use one of to approaches:
You can manually select a database on each database call. This will probably not be possible if you used third party apps.
You can define a database router which is probably more suitable if you do not want to modify an app. There is an example in the documentation which explains how to route reads/writes to another database.