Creating Database Model Diagrams in Microsoft Visio Jeffery S. Horsburgh



Similar documents
How to use Wireframe in Visio

Sample Table. Columns. Column 1 Column 2 Column 3 Row 1 Cell 1 Cell 2 Cell 3 Row 2 Cell 4 Cell 5 Cell 6 Row 3 Cell 7 Cell 8 Cell 9.

Select the Crow s Foot entity relationship diagram (ERD) option. Create the entities and define their components.

Company Setup 401k Tab

Advanced Presentation Features and Animation

A Short Tutorial on Using Visio 2010 for Entity-Relationship Diagrams

MS WORD 2007 (PC) Macros and Track Changes Please note the latest Macintosh version of MS Word does not have Macros.

Microsoft Access 2007 Advanced Queries

Working with Visio Connectors

Word 2010: Mail Merge to with Attachments

How to Create Your Own Crystal Report

Creating tables of contents and figures in Word 2013

Preview DESIGNING DATABASES WITH VISIO PROFESSIONAL: A TUTORIAL

Microsoft Project 2013

Making Visio Diagrams Come Alive with Data

Create a new investment form and publish it to a SharePoint 2013 forms library

MS Excel Template Building and Mapping for Neat 5

Microsoft Excel 2013: Macro to apply Custom Margins, Titles, Gridlines, Autofit Width & Add Macro to Quick Access Toolbar & How to Delete a Macro.

Working with sections in Word

Instructions for creating a data entry form in Microsoft Excel

Microsoft Office PowerPoint Creating a new presentation from a design template. Creating a new presentation from a design template

Using Microsoft Project 2000

Advanced Excel 10/20/2011 1

Microsoft PowerPoint 2010 Computer Jeopardy Tutorial

Quick Start Guide. Microsoft Publisher 2013 looks different from previous versions, so we created this guide to help you minimize the learning curve.

Using the Cute Rich-Text Editor

Creating ER Diagrams with Visio 2010

In this example, Mrs. Smith is looking to create graphs that represent the ethnic diversity of the 24 students in her 4 th grade class.

Google Sites. How to create a site using Google Sites

ITS Training Class Charts and PivotTables Using Excel 2007

Converting Microsoft Access 2002 to Pipe-Delimited ASCII Text Files

paragraph(s). The bottom mark is for all following lines in that paragraph. The rectangle below the marks moves both marks at the same time.

Using VLOOKUP to Combine Data in Microsoft Excel

To Begin Customize Office

ECDL. European Computer Driving Licence. Spreadsheet Software BCS ITQ Level 2. Syllabus Version 5.0

Downloading RIT Account Analysis Reports into Excel

Microsoft Word 2010: How to Resize and Move Clip Art

Microsoft Excel 2013 Step-by-Step Exercises: PivotTables and PivotCharts: Exercise 1

Click on various options: Publications by Wizard Publications by Design Blank Publication

Handout: Word 2010 Tips and Shortcuts

Microsoft PowerPoint 2010 Handout

Task Card #2 SMART Board: Notebook

Planning and Managing Projects with Microsoft Project Professional 2013

Microsoft Word defaults to left justified (aligned) paragraphs. This means that new lines automatically line up with the left margin.

USING WINDOWS MOVIE MAKER TO CREATE THE MOMENT BEHIND THE PHOTO STORY PART 1

Clean Up Rules Quick Steps Search Tools Change Views Export Data Convert to tasks Contact Groups. Outlook Functions

Microsoft PowerPoint Tutorial

Planning and Creating a Custom Database

MICROSOFT ACCESS TABLES

Create a PivotTable or PivotChart report

Rev. 06 JAN Document Control User Guide: Using Outlook within Skandocs

Use signatures in Outlook 2010

Guide To Creating Academic Posters Using Microsoft PowerPoint 2010

CATIA Basic Concepts TABLE OF CONTENTS

Presentations and PowerPoint

Learning Services IT Guide. Access 2013

EXCEL EXERCISE #8: Consolidating and Linking Spreadsheets

Virtual Communities Operations Manual

Microsoft Word 2010 Basics

Migrating to Excel 2010 from Excel Excel - Microsoft Office 1 of 1

Microsoft Office 2010

Check out our website!

Digital Marketing EasyEditor Guide Dynamic

Tantalis GATOR Expanded Image Help Guide

Sage Accountants Business Cloud EasyEditor Quick Start Guide

The first thing to do is choose if you are creating a mail merge for printing or an merge for distribution over .

Microsoft Access Rollup Procedure for Microsoft Office Click on Blank Database and name it something appropriate.

Knowledgebase Article

How to Concatenate Cells in Microsoft Access

Working together with Word, Excel and PowerPoint 2013

Microsoft Outlook Introduction

Maximizing the Use of Slide Masters to Make Global Changes in PowerPoint

UF Health SharePoint 2010 Introduction to Content Administration

4. Click on the insert tab: Create a title at the top of the page using word art that says Microsoft Word PD 11-12

BIGPOND ONLINE STORAGE USER GUIDE Issue August 2005

Draw pie charts in Excel

Summary of important mathematical operations and formulas (from first tutorial):

5. You will need to confirm your registration, by entering a unique code displayed on the page and click Confirm Signup

To export data formatted for Avery labels -

Information Technology Solutions

Creating tables in Microsoft Access 2007

University of Arkansas Libraries ArcGIS Desktop Tutorial. Section 2: Manipulating Display Parameters in ArcMap. Symbolizing Features and Rasters:

Appendix A How to create a data-sharing lab

Word 2007 WOWS of Word Office 2007 brings a whole new basket of bells and whistles for our enjoyment. The whistles turn to wows.

Microsoft Word 2010 Prepared by Computing Services at the Eastman School of Music July 2010

Adobe Digital Signatures in Adobe Acrobat X Pro

Intellect Platform - Tables and Templates Basic Document Management System - A101

Excel Pivot Tables. Blue Pecan Computer Training Ltd - Onsite Training Provider :: :: info@bluepecan.co.

PA Payroll Exercise for Intermediate Excel

Access 2007 Creating Forms Table of Contents

New Features in Microsoft Office 2007

Accounts Receivable: Importing Remittance Data

Basic Microsoft Excel 2007

TxEIS on Internet Explorer 7

Create Charts in Excel

Excel Tutorial. Bio 150B Excel Tutorial 1

CDOT Monumentation Sheets

Step One. Step Two. Step Three USING EXPORTED DATA IN MICROSOFT ACCESS (LAST REVISED: 12/10/2013)

Microsoft Word 2013 Basics

What is OneDrive for Business at University of Greenwich? Accessing OneDrive from Office 365

Transcription:

Creating Database Model Diagrams in Microsoft Visio Jeffery S. Horsburgh Visio is a software tool created by Microsoft that contains tools for creating many different types of diagrams. Visio s drawing templates and pre- defined shapes can simplify the creation of a diverse set of diagram types. The following sections provide details for how to create a data model entity- relationship diagram using Visio s Database Model Diagram template. Creating a New Database Model Diagram Open Visio by clicking Start à All Programs à Microsoft Office à Microsoft Visio 2010. Visio will open and ask you to choose a template. In the Template Categories, choose Software and Database. From the Software and Database template list, choose Database Model Diagram and then click the Create button. 1

Visio will create a new drawing and will select the types of shapes that are needed for you to create a new entity relationship diagram for your data model. You can zoom in and out on your diagram by using the zoom controls at the bottom of the Visio window. 2

Creating Entities To create new entities in your drawing, click on the Entity shape in the Shapes panel on the left and drag a new shape onto the drawing. A new entity called Table1 will appear on the drawing. To adjust the location of an entity on your drawing, click on an entity and then drag it to a new location. Naming and Adding Attributes to Entities When you click on an entity in the drawing you will notice that it becomes selected and the panel at the bottom of the window will reflect the properties of the selected entity. 3

To set the name of an entity, select Definition under the list of categories and then type the name of your entity into the Physical Name text box. 4

To add attributes to your entity, select Columns under the list of categories. In the table that appears, click in the Physical Name field in the first row and type an attribute name. You can set an appropriate data type in the Data Type field and then decide whether that attribute is required to have a value and whether it should be used as the entity s primary key. You can add additional attributes at any time by selecting the shape and then typing an attribute name in the next empty row in the table. A finished Site entity might look like the following. The primary key attribute is designated at the top of the entity and required attributes are shown in bold text. 5

Creating Relationships Relationships between entities are created by first dragging a relationship from the shapes panel on the left onto the drawing. Then click on the relationship shape to select it, you will notice that there are now selection handles on either end of the shape (the little squares). 6

Next, click on the selection handle for the parent end of the relationship and drag it over the corresponding parent entity. When you drag the end of the relationship over the center of the entity that you want to connect it to, the entity will be outlined in red, at which point you can release your mouse click. That end of the relationship will then be connected to the selected entity. Visio will randomly assign a connection point. Remember that the end of the relationship with the arrowhead should point to the parent entity and the other end to the child entity. Click the selection handle for the child end of the relationship and drag it to the child entity. Your relationship should now be connected to both entities. You will notice that when you connected the child end of the relationship to the child entity, the primary key attribute from the parent entity was automatically added to the child entity as a foreign key attribute. You will also notice that in the properties of the relationship at the bottom of the window (under the Definition category) Visio is showing which attributes in each entity are participating in the relationship (the SiteID attribute in both of the entities in the example above). Under the Miscellaneous category of the relationship properties you can set the cardinality of the relationship. In this particular type of Visio diagram the cardinality options are those for the child entity. In this example, you would be telling Visio how a site entity is related to observations. In this example, the most likely relationship is for one site to be related to Zero or more observations. 7

To display the set cardinality on your diagram, select the Database tab at the top of the window and then select the Display Options button on the ribbon under the Manage group. In the window that pops up, make sure Relationships and Cardinality are selected under the list of objects to show and then click the OK button. 8

You will notice that the cardinality is now shown for the relationship in your drawing. Modifying Relationships You may find it necessary at some point to modify what Visio creates by default when you add relationships between entities. Or, you may want to be able to create multiple relationships between two entities. For example, you may have defined a Variables entity that has attributes called VariableUnitsID and TimeSupportUnitsID that you want to relate to an entity that defines attributes of Units. This will require two relationships between the two entities. When you add the first relationship between the Units entity and the Variables entity (see the following example), Visio will automatically add an attribute called UnitsID to the Variables entity. To change the foreign key for the relationship, select the relationship by clicking on it. Then under the Definition category of the properties for the relationship, select the primary key from the parent entity by clicking on it (in this example UnitsID ) and the name of the child entity attribute that you want to participate in the relationship instead of the new UnitsID attribute that was automatically added (in this example VariableUnitsID ). Then click the Associate button. 9

Once you click the Associate button you will notice that the relationship has been modified such that the primary key of the parent entity (in this example UnitsID ) has now been connected to the new foreign key in the child entity (in this example VariableUnitsID ) see below. 10

The UnitsID attribute that was automatically created when you linked the two entities with the relationship can be deleted by selecting the Variables entity by clicking on it and in the Columns category in the properties of the Variables entity select the UnitsID attribute and click the Remove button. 11

If you need to add an additional relationship between two entities, you can use the process described above. In this example, I also need a relationship between UnitsID in the Units entity and TimeUnitsID in the Variables entity. The result looks like the following: 12

Exporting the Diagram When you finish your drawing, you will want to export it as an image so you can paste it into a Word document as an appendix. At the top of the Visio window, click the File tab and then choose Save As in the list on the left panel of the window. In the Save As dialog that comes up, choose where you want to save the file, give it a name, and select a format for your exported drawing. JPEG files generally work well for pasting into documents as figures, so choose JPEG File Interchange Format from the Save as type drop down control. Then click Save. The following window will pop up: You will want to make sure that you export the image with enough resolution that it is not blurry when you print it. For most purposes a Custom resolution of 150 X 150 pixels per inch will work great. When you have set the resolution click the OK button to generate the image. You can then insert the image into a Word document. 13