Automating Database Switches - Development vs Production

EDIT: Moved this from a previous conversation as it was way off topic for that thread.

@QMcKay you mentioned once that you dont use Database Tools module, here is a use that you mind find useful… I use it extensively when developing.

I created a separate log in PIN that when entered it changes the database to a stock database then prompts me "Database Changed To Development Please Log In" I log in with admin password and I am on a stock database to develop features and test… I use naming thats unique for all my rules/actions and when I am happy with function I export to a .txt file using database tools and when I log out it automatically loads my production database back in so I simply just log back in with admin and import the settings.

For the Logout to work correctly everytime I load the default database I have to import a specific setup that has the User Logout rule that changes it back to production. Reason for this is I am deleting the database from Managment console so it does not have the Logout Rule/actions when it loads the next time.

I simply delete the database in Management console. This makes it back to default again next time I load it. If I want to develop on a system with some of the other functions built into it I simply just load up all the import settings I want in it then develop from that point on… Its working really well… its very efficient and a great way to organize my development without risk of messing up my main database and forgetting to backup at a specific point etc. It also allows me to help other people as I am looking from a viewpoint of a stock database.

I have also went a step further and enabled the Multiple Sessions in settings.txt file. So I can if need be have my production database and my development database open at same time in 2 different Samba Sessions on the same computer.

2 Likes