I am creating an application in Symfony2 where each user gets their own database, that is, all users have their own set of credentials for the database. The user does not know these credentials, they are stored in the application.
Depending on which user is logged in, the application retrieves the user credentials and stores the data in a specific user database.
I use Propel as an ORM, and I know that I can configure multiple connections. But all the solutions that I encountered require knowing the details of the connection in advance, but I do not know that the user will register and log in.
So my question is: how can I initiate a proper database connection?
source share