Relational Model Design Mapping conceptual design to logical design using relational data model

1.1 Theoretical Background

1.1.1 Relational Model Design

There are two methods to design a relational data model. The type of method applied by data modeler is dependant on the size and complexity of database. These two methods include:

1. Traditional Approach

 This approach is applied to develop smaller or simpler database  Based on set of system requirements, two-dimensional table structures are created randomly  The tables need to undergo normalization process before a complete relational data model can be produced Figure 1-1 illustrates traditional approach for relational data model design. Figure 1-1 : Traditional approach. 2. Semantic Modeling Approach  This approach is adopted in developing large and complex database  Semantic model is transformed to Relational model Real -world information Random Tables Normalized Relational Data Model 2 Figure 1-2 illustrates semantic modeling approach for relational data model design. Figure 1-2: Semantic modeling approach. This practical applies the second method of relational data modeling, which is called semantic modeling. Semantic model is referred as a generic model since it is independent with type of DBMS used. In this approach, database designer adopts one of two approaches namely Object-based data model or entity-relationship ER model. ER is the most common approach to design relational data model and for this purpose, ERD Entity Relationship Diagram is used. Once conceptual data model is completed, it needs to be transformed into a logical data model. Data model transformation is shown in Figure 1-3. Figure 1-3 Data model transformation flow. Real -world information Semantic Conceptual Data Model Relational Data Model Real -world information Semantic Conceptual Data Model Relational Data Model Requirements Definition LOGICAL DESIGN PHYSICAL DESIGN Object-based Data Model OR Entity-Relationship Model 3

1.1.2 Mapping conceptual design to logical design using relational data model

The result of transformation from conceptual design to logical design can be summarized in the following table : Table 1-1: Mapping conceptual design to logical design Semantic Data Models Conceptual Design Relational Data Model Logical Design Entity-relationship data model Object-based data model Entity types Object set Relations or tables Attributes Attributes Columns Key attributes Identifiers Primary Key Relationships Relationships Foreign Key 4 The following exercise requires the students to apply and demonstrate their understandings in designing a relational database application. Based on the system requirements provided, students should be able to develop conceptual data model using ERD and logical data model using Relational notation. At the end of the process, they need to implement the data model using a relational DBMS.

1.2 Exercise

1.2.1 ConceptualSemantic Data Model for Banking Enterprise

Consider that a bank keeps track of customers, employees, accounts and bank’s loan. Develop a Chen ERD Entity relationship diagram based on these requirements: Note: Refine the ERD if necessary.  The bank is organized into branches. Each branch is located in a particular city and is identified by a unique name. The bank monitors the assets of each branch. A branch can originate one or more loans.  Bank customers are identified by their customer-id values. The bank stores customer’s name, street and city where the customer lives. Customer may have accounts and can take out loans. A customer may be advised by a particular bankeremployee, who may act as loan officer or personal banker for that customer, and that particular banker can advise one or more customers.  Bank employees are identified by their employee-id values. The bank administration stores the name and telephone number of the employee, the names of employee’s dependents and the employee-id of the employee’s manager. The bank also keeps track of the employee’s start date and the length of employment. An employee works for only one manager and that manager supervises one or more employees. 5