Support for multiple database connections

PR for #65 issue