added changeDatabase method