This is for all SQL developers over here, this would be easy but thought to post. I have a table which has all country names in world. I have another table which has a sentence which would have more than one country name in it. How to extract the country names and place them in a separate row like below
Country_Universe_Table
America
India
Bhutan
Nepal
Iran
dataid Comments
1 America and India has signed a deal
2 UK, Nepal and Bhutan see cold weather
The output shall come as
dataid Country
1 America
1 India
2 UK
2 Nepal
2 Bhutan