Getting Started with ER win (Erwin入门)by Dr. Peter WolcottDepartment of Information Systems and Quantitative AnalysisCollege of Information Science and TechnologyUniversity of Nebraska at Omaha(由内布拉斯加州的奥马哈大学信息科学与技术学院门的信息系统和定量分析博士彼得著)Introduction (介绍)ER win is a popular data modeling tool used by a number of major companies in Omaha and throughout the world. (Erwin是受奥马哈和世界各地的一些主要的公司欢迎的数据模型工具) The product is currently owned, developed, and marketed by Computer Associates, a leading software developer.(该产品是由具有领导地位的CA软件开发公司拥有、开发和销售) The product supports a variety of aspects of database design, including data modeling, forward engineering (the creation of a database schema and physical database on the basis of a data model), and reverse engineering (the creation of a data model on the basis of an existing database) for a wide variety of relational DBMS, including Microsoft Access, Oracle, DB2, Sybase, and others.该软件为多种多样的关系型数据库管理系统,包括Microsoft Access,甲骨文,Sybase,DB2,和其他人提供支持数据库设计的各个方面,包括数据建模、正向工程(在现有的数据模型的基础上创建数据模式和物理数据库)和逆向工程(在现在的数据库基础上创建数据模型)This brief tutorial steps you through the process of creating a data model using ER win.(你可以通过这个简单教程中的步骤运用Erwin来创建数据模型) It will not explain all aspects of ERwin, but will show you the minimum necessary to create and use data models for this class. (这个课程不可能全面地讲解Erwin,但它向你展示了必要的最基本的创建和使用数据模型的知识) It consists of three major segments, which correspond to the project-related assignments in your class: (这个课程由三个主要部分组成,它与有关项目任务相符)1.Creation of a basic data model (Conceptual data model) 创建一个基本的数据模型(概念数据模型)2.Creation of a database schema 建立数据库模式3.Creation of the database创建数据库This tutorial is a static one, suitable for printing.本教程是一个静态的,适合印刷A tutorial using screen captures and narration is also available. 一个指南使用屏幕捕捉和叙述是可用的。
Section 1. Creation of a basic data modelYou will be creating a data model similar to that created for the Heartland Properties case study used in class.教程中你将创建一个和研究心脏地带个案相似的数据模型 The Entities involved in this model include: Employee, Office, Property, and Inspection. 参与本次的实体模型包括:员工、办公、财产、及检验。
First, invoke ER win from Start->Programs->Computer Associates->All Fusion-> ERwin Data Modeler-> Erwin首先,从开始——程序——CA——所有程序——ERwin Data ModelerYou will first encounter a dialog box entitled "ModelMart Connection Manager"(经理ModelMart连接). Simply click on Cancel.将首先遇到一个对话框题为“ModelMart Connection Manager”。
只需点击“取消”。
You will be asked to choose between creating a new model, and opening an existing model, as shown in Figure 1你将被要求之间作出选择,创造了一种新的模式,开放一个现有的模型,如图1所示. For this exercise, create a new model.通过这个练习,创建一个新的模型Figure 1: Create a new modelThe next dialog box, shown in Figure 2, will ask you to choose the template to be used to create the new model. 下一个对话框,如图2所示,会让你选择的模板可以被用来创造新的模型 At this point, you may associate the model with a target DBMS product, such as Microsoft Access, Oracle, DB2, etc.在这一点上,你可以把这个模型与如Microsoft Access,甲骨文,DB2等目标数据库产品联系在一起 You will have the opportunity to change this choice later, but for now choose Microsoft Access. 你之后将有机会改变这种选择,但是现在选择Microsoft Access。
Also, choose Logical/Physical as the new model type.同时,选择的逻辑或者物理作为新模型形式 This choice will allow us to switch back and forth easily between a logical model (ER Diagram) and a physical model (database schema). 这个选择将让我们轻易之间来回切换逻辑模型(ER图)和物理模型(资料库)Figure 2: Selecting a model typeERwin will now display the main window from which most of your ER diagram development will be done, as shown in Figure 3. ERwin现在将显示在主窗口大部分你ER图发展来完成,如图3。
Figure 3: The ERwin Workplace ERwin工作场所The ERwin workplace consists of two main parts. On the left is the Model Navigator, which displays a hierarchy of items of importance, such as entities, domains, and subject areas. 左面是模型的领航员,显示某一层次的物品的重要性,如实体、领域和课题。
On the right is the Display Window, which will show the ER diagram itself. 右边是显示窗口,它能够显示ER图本身 As you create objects, they will appear in the display window (if they are visual in nature, like entities), and appear in the hierarchy within the Model Navigator.当你创建对象时,他们将会出现在显示器窗口(如果它们是视觉的自然属性,就像实体),并将出现在层级模型导航器。
Setting Preferences 偏好设置A tool like ER win can accomodate a number of data modeling notations and conventions. 像ER这样工具可以容纳大量的数据建模的符号和对话 In myclass please make the following changes to the preferences before you begin to create your model在我的课上请完成下面的改变的偏好,在你开始之前,创造你的模型:1.From the Format->Entity Display menu, make sure that Primary KeyDesignator is checked从格式- >实体显示菜单,确保主键栏进行检查2.From the Format->Entity Display menu, make sure that Foreign KeyDesignator (FK) is un checked.从格式- >实体显示菜单,确保外国关键指示器(FK)是不能检查3.From the Format->Entity Display menu, make sure that Show MigratedAttributes is un checked.从格式- >实体显示菜单,确保显示属性迁移到un checked4.From the Format->Relationship Display, make sure that Verb Phraseis checked. 从格式- >关系显示、确保动词短语进行检查In addition, you may choose between two different E-R diagramming notations. 另外,你可以选择两种不同的e - r种画图符号In ERwin, click on Model->Model Properties to see the window shown in Figure 3b:点击模型- >窗口模型属性看到如图3b.Figure 3b: Choice of notationThis tutorial is based on the Information Engineering ("Crows Foot") notation. You may also use IDEF1X, if you wish.本教程是基于信息工程(“乌鸦脚”)的符号。