Introducing FOREIGN KEY constraint 'c_name' on table 't_name' may cause cycles or multiple cascade paths

前端 未结 2 1943
走了就别回头了
走了就别回头了 2020-12-22 11:07

I have a database table called Lesson:
columns: [LessonID, LessonNumber, Description] ...plus some other columns

I hav

2条回答
  •  慢半拍i
    慢半拍i (楼主)
    2020-12-22 11:52

    You can't have more than one cascading RI link to a single table in any given linked table. Microsoft explains this:

    You receive this error message because in SQL Server, a table cannot appear more than one time in a list of all the cascading referential actions that are started by either a DELETE or an UPDATE statement. For example, the tree of cascading referential actions must only have one path to a particular table on the cascading referential actions tree.

提交回复
热议问题