Changed creation of db