In my table, email recipients list is stored as a single column comma separated value. And I have another table with email addresses to be blocked as a single column value. Now I want to remove blocked emails from the first table and update only allowed emails in the first table column value.
I already have function to return comma separated table value. Is there any default function or easiest way to achieve this?
EX:
Select EmailAddress From TableA
'[email protected],[email protected],[email protected],[email protected],[email protected]'
Select EmailAddress From TableB
'abc@gmail,mno@gmail'
Expected result after update:
Select EmailAddress From TableA
'[email protected],[email protected],[email protected]'