Is there an official name for the many-to-many relationship table in a database schema?

岁酱吖の 提交于 2019-11-28 08:12:40

The most common name is "Join Table" in my opinion, but I have heard several others you have listed. So, I would say "no", there is no "official" name :-)

I call it a cross-reference table.

Some may not consider this an official term, but it's certainly a popular one. I mean, you'll find plenty of relevant results in Google if you search for it. The other thing I like is that it can be easily abbreviated "xref" and then used in your table naming scheme, e.g. "table1_xref_table2". That'll get everyone on your team calling it the same thing.

UPDATE:

Wikipedia calls it a junction table. It's strange that I've never heard that term but I suppose different circles call it different things. As we're finding out -- there is no single official answer.

This is HIGHLY unscientific, but I thought it would be interesting to see how many Google results were associated with the combination of common answers to this question and the term "many to many".

Based on this, it looks like "join table" is the most commonly used term for the...um...joining table in a many-to-many relationship.


The combined search terms

"join table" "many to many"

return around 13,700 results in Google.

"link table" "many to many"

returns around 4,700.

"junction table" "many to many"

returns around 3,500.

"association table" "many to many"

returns around 3,300.

"relationship table" "many to many"

returns around 3,200.

"intersection table" "many to many"

returns around 1,500.

"cross-reference table" "many to many"

brings back 1,000.

gerund "many to many"

only returns 450.

I've always called then intersection tables.

I call them link tables, but I've called them that for so long that I have no clue where I got the term from.

I think Relationship table is more at the mark. At least that is what we use. By the way if you ask for naming we always use it this way table1_table2 with no exceptions. That will serve you well in the long term.

There's a section in SQL for Smarties where Celko had an opportunity to name this kind of table:

Tables that represent many-to-many relationships should be named by their contents, and should be as minimal as possible. For example, Students are related to Classes by a third (relationship) table for their attendence. These tables might represent a pure relationship, or (etc)...

At the top of the section he talks about E-R (entity-relationship) diagrams.

I always just call them "many-to-many tables", or "many-to-many join tables". Seems the least likely to be misunderstood as something else. (I notice you used similar wording in the title of your question...)

Intersection table surely! I believe oracle also favor 'Intersection' tables.

http://download.oracle.com/docs/cd/B40099_02/books/ConfigApps/ConfigApps_TablesColumns7.html

I was told to call them 'link entities' when I first started work on relational databases (Dec Rdb almost 20 years ago). The 'entity' bit probably coming from the entity relationship diagrams the tables were in, although 'link tables' now sounds like a better fit from the same evolutionary tree.

Using @Noah's ground breaking research on Google this yields about 2000 references currently:

"link entity" "many to many"
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!