Added multiple-database support.