How do I delete data that is not in the view, the view is made up of 8 different tables using intersect they all have 'country' column in them and I want to delete country that is not in the view (vw_Countries).
I tried this two ways and I get this error message.
Msg 207, Level 16, State 1, Line 24
Invalid column name 'vw_Countries'.
Delete from [WorldFoodProduction].[dbo].[CO2_Data]
where country not in( vw_Countries).
Delete [WorldFoodProduction].[dbo].[CO2_Data]
where country not in( vw_Countries).