在数据库设计中说出父子表不是错吗? [英] Isn't it wrong to say Parent-Child tables in database design?

查看:75
本文介绍了在数据库设计中说出父子表不是错吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在学习数据库设计,并且熟悉诸如 ER图实体之间的关系等的基本术语.

I am learning database designing and got acquainted with basic terminologies like ER diagrams, relationships between Entities etc.

我遇到了像 Parent,子表这样的术语.这些术语使我无法理解.我确实搜索过SO早期提出的类似问题,但我仍不清楚.

I came across terms like Parent , child tables. It is these terminologies where I am not able to understand; I did search similar questions asked earlier in SO, but I am not still clear.

Parent-Child 术语是有意义的,在这里,我们实际上是 parent-child classes ;在"RDBMS"中这有什么意义?

Parent - Child terminologies makes sense in Object oriented programming, where we literally have parent - child classes; how does this make sense in `RDBMS'?

有人可以帮助我了解 RDBMS 中表之间的 parent-child table 关系吗?

Can anyone help me understand parent - child table relationship between tables in RDBMS?

推荐答案

这些术语是如此笼统,以至于您必须从上下文中找出含义.有父母关系(船)/协会描述树/层次结构/网络时为子级.这仅表示在某种关系的某种图形表示中,从一个节点到另一个节点存在一条边.这包括具有概念上有方向性的线的图.通常,这些术语在关系或信息建模上下文中用于所引用的&内容.引用父表被"子表引用"的表的元关系/关联表中的表,这意味着从子表到父表都有外键(FK).这与FK被错误地称为关系"有关.但是/关系表示关系数据库中与值(可能是标识实体)的业务/应用程序关系(船)/关联.因此,"关系模型"和实体-关系模型".

The terms are so general that you have to figure out what is meant from context. There are parents & children when a relation(ship)/association describes a tree/hierarchy/network. It just means there is an edge from one node to another in some graph representation of some relationship. That includes diagrams with conceptually directed lines. Often the terms are used in a relational or information modeling context for the referenced & referencing tables in the meta-relation(ship)/association on tables that a parent table "is referenced by" a child table meaning there is a foreign key (FK) from the child to the parent. This is related to FKs wrongly being called "relationships". But tables/relations represent business/application relation(ship)s/associations on values (possibly identifying entities) in relational databases. Hence the "Relational Model" and the "Entity-Relationship Model".

这篇关于在数据库设计中说出父子表不是错吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆