
Diagram and Modify a Database #74
Chapter 9, Server Explorer Hacks
|
303
HACK
Database Diagrams
Database Diagrams can be used to design your database and create relation-
ships between your tables. Using the Server Explorer, you can edit and cre-
ate new database diagrams. To create a new database diagram, you simply
need to right-click on the Database Diagrams node and select New Dia-
gram. You will then see the Add Table dialog shown in Figure 9-7.
From this dialog, you can select the tables you want to work with. When
you click Add, the table will be added to your diagram. If you add multiple
tables, Visual Studio will automatically add primary/foreign key relation-
ships to the diagram. Figure 9-8 shows the Database Diagrams interface.
Figure 9-6. Server Explorer—database options
Figure 9-7. Add Table dialog