changed the query of provider_id