I have some code that runs in SQL Server that I need to translate into DB2
Code:
update dbo.stg_joc_tbl
set office = s.office
from dbo.stg_joc_tbl j, dbo.REF_NA_SALES_XREF_TBL s
where j.district = s.district_code
I have done this once but I have lost the script. And I have also forgoten what I did. I know I did a nested select statment something like
Code:
update dbo.stg_joc_tbl
set office = s.office
from dbo.stg_joc_tbl j
where j.district in (select distinct district_code from REF_NA_SALES_XREF_TBL)
If anyone can look at this and help me remember it would be greatly apreciated.
Jim