sergio-SZhfuDltjDxEfCMKe0UOsQC/G2K4zDHf@public.gmane.org
2005-Oct-16 03:12 UTC
Dynamic database selection
I am looking to implement a solution where the database is dynamically selected based on the authentication parameters. Basically there is master database that has an "accounts" table, which, among other things, has a "name" column. The "name" column is the name of the database. Users will authenticate against the "accounts" table in the master database and the Rails application will establish a connection to selected database for the duration of the session. I was wondering if someone has any ideas or has implemented a similar solution? Serge.