BEGIN TRANSACTION Update coSuper set isActive=0 where coSuperID=@tiCardID ... Update coSuper2 set isActive=0 where coSuperID=@tiCardID ... COMMIT TRANSACTIONYou may also consider using UPDATE trigger on coSuper that will update coSuper2 table's isActive field if it changes to 0 in coSuper table. This way your data will be consistent regardless how or from where isActive was changed to 0 in coSupe table.
>CREATE PROCEDURE ct_DelPrefCard >@tiCardID int > >as >SET NOCOUNT ON >begin >--Delete the actual card >Update coSuper set isActive=0 where coSuperID=@tiCardID > >--Delete the child records >Update coSuper2 set isActive=0 where coSuperID=@tiCardID > >--Delete our linked listed items in the coCardAssign table >--delete from coCardAssign where coSuperID = @tiCardID > >set nocount off > >end >>