Is there a general term for a pairing of tables where one has header i开发者_开发知识库nformation and the other has detail lines?
For example, a pair of tables describing sales orders, or a pair storing bill of materials data.
One-To-Many describes the "numbers".
But one could prefer Parent-Child in some contexts, typically when the Child always has a Parent...
I think it is called a one-to-many relationship.
Also, Master-Detail.
Remember that it is a good practice to use consistent naming conventions in your database for these types of tables. Doesn't really matter what names, consistency is really the key. The goal is to have a general idea of what the table holds based on the name. Some I've seen:
(Assume the table holds Products)
Product -- ProductDetail
ProductHeader -- ProductDetail
Product -- ProductLines
For me, Parent-Child names imply a hierarchical relationship, which is a whole 'nother ball of wax.
精彩评论