I’m presented with a case where I must connect a single environment to different databases. The idea is that each new database created is a company, that company will be associated with a user and that user will have their respective accesses.
I have thought of creating a view where the user is configured or typed to the respective company, once logged in then he asks him which company he wants to work in and at that moment the system changes the path to the database.
I do not know if this is possible, just to think about it I have several questions that maybe you can help me solve, for example:
Would it be possible to have in a database all the users and permissions, without having to replicate them in each one of the bases subsequently created?
Is it possible to switch to the hot database?
What do I think if it is correct ?, or would it be easier and feasible to have all the companies inside a same store and filter by the code of them once the user enters? If a good solution would perform well?
The truth is I’m open to listen to ideas and suggestions from all of you and apply the one that best suits and works with CUBA.