One of the questions in my homework in databases:
"In which countries do you speak Swedish but not Finnish? The answer should consist of countrynames."
This is my piece of code:
Select Name from Country
left outer join CountryLanguage
on CountryLanguage.Countrycode = Country.Code
where (CountryLanguage.Language = 'Swedish') and (CountryLanguage.Language not in ('Finnish'))
I don't know how to actually use the function "NOT IN". As output I would like to get Denmark, Normay and Sweden. Finland should not be in the output since they do speak Swedish in Finland but also Finnish, and the question was "where they ONLY speak Finnish".