Set databases properly