I'm having 2 tables with old and new project numbers, If project number in Table A matches with Project Number in Table B, Then i need to update the Table A project number with its equivalent New project number located in Table B.
For that i;ve written the below query which worked fine, But now my requirement has been changed to:
I need to iterate through all the rows in Table A and Table B, If match found i need to INSERT a record in a new table which should store Project number(Varchar), IsProjNumConverted (Bit (0,1))
How can i do this using CASE statement>?
dbo.Incident_Info .Proj_ID = x.INVC_PROJ_ID
left outer join Repository.dbo.PROJ_ID_XREF x on x.PROJ_ID=i.Proj_ID