Database Reference
In-Depth Information
Figure 5-5. In this updated version of the diagram the Invoice Payments join entity has been added.
Now you have only one-to-many relationships—perfect. You're ready to move on to the next step.
The Entity-Relationship Diagram
Now that you have a list of entities and their relationships, you're ready to assemble your
master plan: the entity relationship (ER) diagram. An ER diagram is a picture that shows all
the entities in your database and the relationships between them. Unlike the diagram you've
already drawn, each entity appears only once in an ER diagram.
Drawing the ER diagram has two purposes: first, to help you find relationships you missed,
or relationships that don't belong, and second, to serve as a roadmap for your database. That
is, you'll use the ER diagram when you create this database in FileMaker and again if you go
back to make changes later.
NOTE
The diagram you're about to create isn't, in the most technical sense, a real ER diagram. The most
formal kind deals with all kinds of technical details that simply don't matter in FileMaker. So some
database big shots may chastise you for calling your beautiful picture an ER diagram. Never
mind—just be glad FileMaker doesn't make you care about all that drivel.
Creating an ER Diagram
When you assemble an entity relationship diagram, you have to put all your entities and rela-
tionships together in one big picture. Each entity appears on the diagram just once but it may
be connected to several other entities by lines that explain the relationship between each pair.
Your ER diagram is crucial to a successful database designing experience. First, you almost
always find ways to improve your database as you create the diagram. Then, when you set
out to actually build the database, the ER diagram guides you through the process. Finally, a
couple of years from now, when you need to add to your database design, the ER diagram
will bring you—or your successor—up to speed on how your database fits together. So don't
toss the diagram once you've moved from the planning phase to creation.
Here's a description of the general process: Make one box for each entity you've identified
and then draw lines between them. Place the boxes on the page so there's some open space in
the middle where your lines can roam free. When that's done, start drawing lines to represent
each of the relationships you've come up with. For a simple database, you can usually get the
lines in the picture without much difficulty. But creating a larger diagram without the right
Search WWH ::




Custom Search