Consider offering syntax like PlantUML for ER diagrams
See original GitHub issueI just added the capability to render entity relationship diagrams to mermaid, and made up a simple syntax, e.g. PERSON !-?< ACCOUNT : holds
is interpreted as a person holds zero or more accounts and an account must be held by one and only one person.
PlantUML has a similar-but-different syntax which is also pretty intuitive (and of course already in use). For example PERSON ||..o{ ACCOUNT
means the same thing (although the relationship label holds
is missing). An additional nuance of PlantUML appears to be that using either dots or dashes in the relationship one can distinguish between identifying and non-identifying relationships.
@Dunning-Kruger has suggested use of PlantUML syntax - seems like a good idea. What do others think?
- Should we just ditch my syntax in favour of PlantUML style (I have no issue with this at all)
- Should we offer two alternative styles? (Given that ER diagrams are not live yet, I’m not sure it’s worth it)
- Any other thoughts? As @knsv pointed out in the original trail of issue #117 it’s important to spend time now getting this right, as it will be hard to change later, without screwing existing users
- Ofc I could extend the PlantUML syntax to include the relationship label as this is a useful (and pretty standard in my experience - in fact it’s regarded as mandatory by some)
Comments greatly appreciated. Thx.
Issue Analytics
- State:
- Created 4 years ago
- Comments:6 (5 by maintainers)
Top GitHub Comments
No problem - I should’ve thought of it myself - at least you did! I’ll do some work on it and post here when appropriate.
Thank you for looking into this.