Bug with switching to other databases