checks if the DB exists