making and connecting the database