setting up datatbase