mermaid
mermaid copied to clipboard
Filter duplicate relationships in erDiagram
Description of Issue The ER diagram needs to filter out duplicate relationships when the relationship is defined in reverse. (ER diagram already filters out duplicate relationships in the same order.)
To Reproduce Define an ER diagram like this:
erDiagram
CUSTOMER }|..|{ DELIVERY-ADDRESS : has
CUSTOMER ||--o{ ORDER : places
CUSTOMER ||--o{ INVOICE : "liable for"
CUSTOMER ||--o{ INVOICE : "liable for"
INVOICE }o--|| CUSTOMER : "liable for"
CUSTOMER ||--o{ INVOICE : "liable for also"
Expected behavior Even though the "liable for" relationship (CUSTOMER -> INVOICE) is defined 3 times, it should be shown only once.
Desktop (please complete the following information):
- Browser: Chrome
- https://mermaid-js.github.io/mermaid-live-editor
Hi @sualeh - thanks for your submission.
I think you have identified an issue worth investigating. It's quite easy to avoid, of course, but it seems like a fair point to me.