Re: multiple database users for rails app?

check for the existence of this session variable and act accordingly.
That’s easy enough to do, but how do I “act accordingly”? How do I tell
my controller that, based on the presence of this session property,
connect to the database using these credentials instead of those?

  • donald

Sounds to me like you want two DB connections, one for each user. Use
the session variable to choose which connection to use. Multiple
connections to one db should be equivalent to connecting to multiple
databases: rails multiple databases - Google Search