简体   繁体   中英

Many-to-many relationship on the same entity without additional join table columns

I have an entity that has many-to-many association to itself.

If I needed some additional properties (like asked here ) the answer would be to use a new intermediate entity. But without them is it bad practice to use direct many-to-many association to the entity itself?

使用映射表是N对N关系的最佳方法,而无需在映射表中自行创建新列。

Aleksey,

If you have additional columns, you need a new intermediate Entity .

But without them is it bad practice to use direct many-to-many association to the entity itself ?

No, you can if you want since you do not have additional columns on The joined Table

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM