ave data in DWH with only one row for one of the ID but when I am using the update statement for the COLUMN_1 like
UPDATE [T_TABLE] SET COLUMN_1=case when ([Partner] = 'SAP' and ((Technology = 'SAP S/4HANA Cloud' or Technology = 'SAP S/4HANA Hosted' or Technology = 'SAP Cloud Platform' or Technology = 'SAP Business Technology Platform' ) and (Segment = 'Automotive'))) then 'SAP Auto Cloud' when ([Partner] = 'SAP' and ([Technology] = 'SAP S/4HANA ONPREM' or [Technology] = 'SAP S/4HANA Cloud'or [Technology] = 'SAP S/4HANA Hosted'or [Technology] = 'SAP Digital Manufacturing/Supply Chain' or [Technology] = 'SAP Integrated Business Planning (IBP)' or [Technology] = 'SAP Ariba' or [Technology] = 'SAP Concur' or [Technology] = 'SAP Fieldglass' or [Technology] = 'SAP SuccessFactors' or [Technology] = 'SAP Qualtrics')) then 'SAP Intelligent Suite & Industry Cloud' end
So for Partner as 'SAP' and Technology as 'SAP S/4HANA Hosted' I want two rows for the single ID one will show me COLUMN_1 as 'SAP Intelligent Suite & Industry Cloud' and other row will show as 'SAP Auto Cloud'. Right now it is not happening because when first condition satisfies it keeps the COLUMN_1 as 'SAP Auto Cloud' and then moves to the end. So is there any other alternative of when condition that I can use here?
UPDATE [T_TABLE] SET COLUMN_1=case when ([Partner] = 'SAP' and ((Technology = 'SAP S/4HANA Cloud' or Technology = 'SAP S/4HANA Hosted' or Technology = 'SAP Cloud Platform' or Technology = 'SAP Business Technology Platform' ) and (Segment = 'Automotive'))) then 'SAP Auto Cloud' when ([Partner] = 'SAP' and ([Technology] = 'SAP S/4HANA ONPREM' or [Technology] = 'SAP S/4HANA Cloud'or [Technology] = 'SAP S/4HANA Hosted'or [Technology] = 'SAP Digital Manufacturing/Supply Chain' or [Technology] = 'SAP Integrated Business Planning (IBP)' or [Technology] = 'SAP Ariba' or [Technology] = 'SAP Concur' or [Technology] = 'SAP Fieldglass' or [Technology] = 'SAP SuccessFactors' or [Technology] = 'SAP Qualtrics')) then 'SAP Intelligent Suite & Industry Cloud' end
So for Partner as 'SAP' and Technology as 'SAP S/4HANA Hosted' I want two rows for the single ID one will show me COLUMN_1 as 'SAP Intelligent Suite & Industry Cloud' and other row will show as 'SAP Auto Cloud'. Right now it is not happening because when first condition satisfies it keeps the COLUMN_1 as 'SAP Auto Cloud' and then moves to the end. So is there any other alternative of when condition that I can use here?