Select where not in another table
Posted on 2013-01-31
I have 2 tables
dbo.WideCityList and dbo.PostalCodes.
I want to find all widecitylist.City, WideCityList.State that does not exist in postalCodes.Cityname, PostalCodes.ProvinceAbbr
All cities in WideCityList have a dash "-" where there should be a space.
So in WideCity list it is "Los-Angeles" and in PostalCodes it is "Los Angeles"
So a city+state in WideCityList that does not exist in PostalCodes will need to have a replace function for any dashes into spaces. Hope that makes sense!