Replies: 1 comment
-
Do you have an idea of how composite keys would be represented? |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
As a developer I would love to have the possibility to create a visualisation of SQL schemas with mermaid. This would mainly mean to be able to create tables with the names of the columns and their data types as well as the column constraints to indicate primary and foreign keys etc. So actual what the ERD type is. But for a foreign key it would be very nice to have an arrow to the targeting primary key of the foreign table.
As an example let's say an article can be written by only one author. This is ho it looks like currently:
But the actual SQL database schema would be more accurately visualised if it would look like this, because cardinalities doesn't technically exists in an SQL database, only foreign keys exist.
As an alternative, the ERD could be made database independent and treated as something only semantically at which point a completely new type for SQL which has primary and foreign keys included and the arrow I mentioned above. Then mermaid would have one semantic diagram and one technical diagram for visualising entity relations.
Beta Was this translation helpful? Give feedback.
All reactions