How to build a beautiful database schema in yEd Graph Editor

I want to show you how, with the help of the now popular yEd application, which is designed to build various diagrams and schemes, you can make a complete (with all the notation) database schema.

So, for starters, we have a standard container with elements for building an ERD (entity relationship diagram). Their designations are shown in the figure.

image

A small digression, if you need to insert just text on the diagram, i.e. without any block, then the following simple steps from a comment from jaiprakash quickly solve this problem. “Select any link -> add label -> enter text -> convert to node.”

So, we pose the conditional task of constructing the following scheme.

image

Create a framework of basic elements.

image

In order to add the notation of primary and foreign keys you have to contrive a little. Selecting the desired element, add a new label to it, which we will call KEY. Because It will be located under the main unit, then select it using the clamped Ctr.

image

image

Set its Placment (placement) by selecting Internal: top left (inside, top left), color as desired, Distance (distance from the edges) to zero, Insets (insertion in pixels) to 20 2 0 0 so that it is opposite the attribute field with a small distance, Font Family (font) set Segoe UI Symbol, because It accurately supports the necessary characters.

image

Symbols for copying can be found, for example, in the Windows symbol table.

image

image

Do the same with the arrows.

image

In order to combine several tables into a block, you can use Grouping.

image

The final version of the example is as follows. Everything is clear and beautiful :)

image

I hope this short article will help some of the novice database designers. Thank you for your attention, I will be glad to comment.

Also popular now: