What is the best way to enforce a 'subset' relationship with integrity constraints

前端 未结 12 1330
一个人的身影
一个人的身影 2020-12-10 18:11

For example, given 3 tables:

  • gastropod
  • snail
  • slug

and assuming we want to enforce that

  1. every row in \'gastropod\
12条回答
  •  南方客
    南方客 (楼主)
    2020-12-10 18:58

    Check out this thread: Maintaining subclass integrity in a relational database

    The thread provides multiple suggestions for SQL Server implementations, and I would be surprised if the ideas couldn't be applied to Oracle as well.

提交回复
热议问题