Greetings,
I have a stored procedure that does an update to T_SOLICITATION that involves the old solicitor field.
the first part involves getting data into a work table and out of T_CONTRIBUTIONS, the solicitor field there is now called worker_customer_no. when the work table is finally assembled, there is an update to T_SOLICITATIONS. The update statement is below:
Update a
Set cpg_sol = ISNULL(b.solicitor, '(none)')
From #work1 a,
t_solicitation b (NOLOCK)
Where a.customer_no = b.customer_no and
a.campaign_no = b.campaign_no and
IsNull(a.cont_designation, 0) = IsNull(b.cont_designation, 0)
Any ideas? thanks.
Maybe I Jumped the gun. I modified it to look like the following:
Set cpg_sol = ISNULL(d.display_name_tiny, '(none)')
From t_step b
join t_plan p on b.plan_no = p.plan_no
join #work1 a on p.campaign_no = a.campaign_no and p.customer_no = a.customer_no
and IsNull(p.cont_designation, 0) = IsNull(a.cont_designation, 0)
JOIN FT_CONSTITUENT_DISPLAY_NAME() d ON b.worker_customer_no = d.customer_no
Look right?