Open nickkolok opened 5 years ago
Apps of a same project share a common database, so no, it's not possible.
However the tables in which everything is written are separate in the db, so there is no risk to erase anything from IPT2016
Well... I've seen database settings somewhere in the code, and db.mysqlite
was specified as default
(and the only) there. Moreover, I've notices smth about different databases in Django docs on createsuperuser
.
Yes you can switch from one database to another, but as far as I know you cannot have both databases active at the same time if you do not have an authentication system (see https://docs.djangoproject.com/en/1.11/topics/db/multi-db/#multiple-databases). It seems quite complicated to me to set up such a thing.
An alternative could be to create different project for each tournament instead of different apps. This way, the db are naturally separated, and you just need a bit of work to reroute the urls correctly. That will see multiple django projects running at the same time though, since we want the score from the previous year to always be available.
It looks like e.g.
IPT2016
database should be never more edited. So, it looks sane to store databases in separate files, each in the corresponding instance folder.Is this possible?