fetching to db and saving working