In your external key constraint for the GlassesColor join GlassesColor enter on delete cascade . What this means is that when the entry associated with the primary key is deleted, the corresponding link string of the foreign key will also be deleted.
So, the GlassesColor table GlassesColor will look like this:
create table GlassesColor ( GlassesId int foreign key references Glasses(GlassesID) on delete cascade, ..... ) go
user596075
source share