开发者

Need Help with a Trigger for preventing a circular reference on a table

We currently have a table that looks like this:

ChildId    |  ParentID
------------------
1          | NULL
2          | NULL
3          | 1
4          | 3

Can anyone help me come up with a constraint/trigger that would开发者_运维问答 prevent a circular reference from being inserted or updated into the table?

Thanks


You will need to create a trigger.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜