MySQL “关联表”的正确名称是什么(多对多关系)

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/3045034/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-08-31 16:20:29  来源:igfitidea点击:

What's the correct name for an "association table" (a many-to-many relationship)

sqlmysqlsql-serveroraclerdbms

提问by Imran

What's the correct or most popular name for an "association table"?

“关联表”的正确名称或最受欢迎的名称是什么?

I've heard lookup, associative, resolving, mapping and junction table.

我听说过查找、关联、解析、映射和连接表。

采纳答案by Raj Kaimal

Cross reference table. CustomerProductXRef.

交叉参考表。客户产品XRef.

回答by Dijkgraaf

There is no "correct" name, but the academic name would be an "Associative Table" (see See the Wikipedia article Associative Entity). Other common names are (in alphabetical order):

没有“正确”名称,但学术名称将是“关联表”(请参阅​​维基百科文章关联实体)。其他常见名称是(按字母顺序):

  • Association table
  • Bridge table
  • Cross-reference table
  • Crosswalk
  • Intermediary table
  • Intersection table
  • Join table
  • Junction table
  • Link table
  • Linking table
  • Many-to-many resolver
  • Map table
  • Mapping table
  • Pivot Table
  • Pairing table
  • Relationship table
  • Transition table
  • 关联表
  • 桥台
  • 对照表
  • 人行横道
  • 中介表
  • 交点表
  • 连接表
  • 接线台
  • 链接表
  • 链接表
  • 多对多解析器
  • 地图表
  • 映射表
  • 数据透视表
  • 配对桌
  • 关系表
  • 过渡表

Note: This is contents original created by Derek Greer but that was posted as an edit to an accepted answer that totaly changed the answer.

注意:这是德里克·格里尔(Derek Greer)原创的内容,但作为对已接受答案的编辑发布,完全改变了答案。

回答by DCookie

"Correct" depends on the modeling methodology in use. I am familiar with Chen, in which this table is the physical implementation of an Associative Entity. I suppose most popular would be directly related to most popular modeling methodology.

“正确”取决于使用的建模方法。我对陈很熟悉,其中这张表是一个关联实体的物理实现。我想最流行的将与最流行的建模方法直接相关。

Wikipedialists several names for this type of table.

维基百科为这种类型的表格列出了几个名称。

回答by Paul Sasik

I was taught and use the term "Join Table"

我被教导并使用术语“连接表

回答by Kate Gregory

Do you call your customer table CustomerTable or Customer or Customers? I generally use a "business object" name (eg Orders for information about which customers have ordered which products, not CustomerProduct) but a table that really just tracks the relationship, like SalesRepCustomer, I give the name of the two tables involved and don't add a suffix. As others say, be consistent.

你称你的客户表为 CustomerTable 还是 Customer 或 Customers?我通常使用“业务对象”名称(例如,有关哪些客户订购了哪些产品的信息的订单,而不是 CustomerProduct),但实际上只是跟踪关系的表,如 SalesRepCustomer,我给出了涉及的两个表的名称,但不t 添加后缀。正如其他人所说,保持一致。

I reserve the name lookup (in conversation, not in the table name) for things like "what is the name of Country 11", not for "which sales rep looks after Country 11".

我保留名称查找(在对话中,而不是在表名称中)用于“国家 11 的名称是什么”,而不是“哪个销售代表负责国家 11”。

回答by onedaywhen

Relationship table.

关系表。

"One of the basic tricks in SQL is representing a many-to-many relationship. You create a third table that references the two (or more) tables involved by their primary keys. This third table has quite a few popular names, such as 'junction table' or 'join table,' but I know that it is a relationship."

“SQL 中的一个基本技巧是表示多对多关系。您创建第三个表,该表引用主键所涉及的两个(或多个)表。第三个表有很多流行的名称,例如'连接表'或'连接表',但我知道这是一种关系。”

Hollywood Couples by Joe Celko

乔塞尔科的好莱坞情侣

回答by Alex Larzelere

Depends on whom you ask. They're all correct, use the term that makes the most sense to who you're talking to.

取决于你问谁。他们都是正确的,请使用对您的谈话对象最有意义的术语。

回答by wergeld

We call these Crosswalk tables where I work. Naming is based on Table1XTable2 where the contents are the PKs of the 2 tables.

我们在我工作的地方称这些人行横道桌。命名基于 Table1XTable2,其中内容是 2 个表的 PK。