BEGIN TRAN create table Test (ID varchar(1), Name varchar(10), FollowID varchar(1) null) insert into Test values ('a','First','b'), ('a', 'Second', 'e'), ('b', 'Third', 'e'), ('c','4th','e'), ('d','d','e'), ('e','e',null) go create trigger tr_Test_Update on Test for update as begin update T set FollowID = I.ID from Test T inner join Deleted Del on T.FollowID =Del.ID cross join Inserted I end go select * from Test update Test set ID = 'f' where ID = 'e' select * from Test ROLLBACKThe main thing was figuring that we need to use a cross join with Inserted since there is no actual link anymore...
>>create trigger tr_TableA_Update ON TableA for UPDATE >>AS >> BEGIN >> update TableA set FollowID = Inserted.ID from TableA >>inner join Inserted on ID = Inserted.ID inner join Deleted on TableA.FollowID = Deleted.ID >> END