Chapter 1 Database Modeling Past and Present 1

Chapter 1 Database Modeling Past and Present 1

Database Modeling Past and Present q The definition of a database q. The definition of a database model q. The evolution of database model q. The hierarchical and network database models q. The relational database model q. The object and object-relational database models q. Database model types q. Database design objectives q. Database design methods 2

Grasping the Concept of a Database ØWhat is the difference between database and database model? ØWhat is the difference between data and meta data? ØThe general view of a database First. Name Last. Name Salary Ahmed Shaheen Data 5000 Field Type Length First. Name Char 50 Last. Name Char 50 Salary int 10 Metadata 3

Understanding a Database model v. A database model is used to describe an organized and ordered set of information v. The Relation between database model and the application v. OLTP applications and OLTP models v. Data warehouse application and data ware house models 4

The Evolution of Database Modeling Database modeling techniques are: 1. File Systems 2. Hierarchical Database Model 3. Network Database Model 4. Relational Database Model 5. Object Database Model 6. Object-Relational Database Model 5

File Systems üNo modeling techniques are applied üData base is stored in flat files üUtilizing The structure of the operating system alone üAny searching through flat files has to be explicitly programmed üAny relationships and validation between flat files would have to be Programmed üThe capabilities is poor an dlimitede Flat file is a simple text file, containing no structure whatsoever 6

Hierarchical Database Model q The hierarchical database model is an inverted tree-like structure q The tables model support child-parent relationship q Each child table has a single parent q Each parent can have multiple child tables q Any entries in child tables can only exist where corresponding parent entries exist Example of a hierarchical database model q Hierarchical database model support one-to-many relationships 7

Network Database Model o Network database model is a refinement of the hierarchical database model o Child tables are allowed to have more than one parent o Many –to-many relationships are allowed in addition to one-to-many relationships One employee can be assigned many tasks and a task can be assigned to many employee Mangers can be a part of both departments and companies 8

Relational Database Model ØAny table can be accessed directly without having to access all parent objects ØAny tables can be link together regardless of their hierarchical structure ØAny table can be linked to both any number of parent tables and any number of child tables 9

Relational Database Management System (RDBMS) Software Development Kit (SDK) End front tools Complete management kit Example: Access RDBMS is both the database engine and any other tools that come with it 10

The History of the Relational Database Model • The relational database model was invented by Dr. Codd. • The relational database began as a way of getting a group of data from a larger data set • This were done through a process called normalization • Normalization is a process which aim at removing duplication from the data • Normalization is composed of a number of steps called normal forms • The result was the Structured Query Language (SQL) • The development of the relational database model was done in terms of the movement of personal skills 11

Object Database Model v. Object database model provides three dimensional structure to data v. Object database model is efficient for finding unique items v. Object database model performs poorly for finding more than single items v. Object database model remove the need for types and many-tomany relationship replacement tables If you can figure out who little pieces work individually, it makes the big picture 12

Object-Relational Database Model o The Object-relational database model was created in answer to conflicting capabilities of relational and object database models o Essentially, object database modeling capabilities are included in relational database Summary of the evolution of database modeling File System No database model Hierarchical Allowing one-to-many relationships Network Allowing for special relationships Relational Allowing for individual element access anywhere in the database Object Handling high-speed application of small data items within large highly complex data sets Objectrelational Including the most accountable aspects of object database into the structure of the relational database model 13

Examining the Types of Databases functionally fall into three categories: ØTransactional ØDecision support system (DSS) ØHybrid 14

Transactional Databases ü The primary function of the database is to add new data, change existing data, deleting existing data ü All operations are done in very small chunks, such individual records Examples: • Client server database: low concurrency and low throughput • OLTP database: enormously high levels of concurrent database access 15

Decision Support System DSS examples: • Data warehouse database: excessively large, OLTP is the source of the database • Data mart: a small subset of a larger data warehouse • Reporting database: a data warehouse but containing only active data ( more manageable and flexible) 16

Hybrid Databases OLTP concurrency requirements + Data warehouse requirements A smaller hybrid database is often a more cost-effective This section presented: Ø What a database does Ø The function of the database can determine the way in which the database model is built 17

Understanding the Database Model Design process involves putting your ideas on paper before actually constructing your object Use every thing (flowcharts, pretty picture, ERD, …) to insure that what you intend to build is not only what you need but also will actually work Poor design can cost a company more money than it is prepared to spend Design is needed to ensure that it works before spending humungous amounts of money finding out that it does not 18

Defining the Objectives A proper relational database model should: v. Aim for a well-structured database model: simple, easy to read, easy to comprehend v. Data integrity: data is not lost, destroyed when it should be v. Support both planned and unplanned queries v. Each table in a database model preferably represent You have to plan your steps and you also have to know what the steps are that you planning for a single subject or topic v. Future growth must be a serious consideration v. Future changes can be accommodated for v. Minimize dependent between application and database model 19

Looking at Methods of Database Design Database modeling steps: 1. Requirements analysis: nature of the data, features required and output responses 2. Conceptual Design: draw pretty pictures, ERD diagrams, creation of tables 3. Logical design: Create database language commands 4. Physical design 5. Tuning phase: indexing, normalization, security features, …. These separate steps are interchangeable, repeatable, iterative, and really anything able 20

Summary In this chapter, you learned about: ØThe difference between a database, a database model, and an application ØThe hierarchical and network database models ØThe relational database model ØThe object and object-relational database models ØWhy different database models evolved ØThe relational database model is the best all round option available ØDatabase design depends on applications ØDatabase types ØDatabase design objectives and methods 21
- Slides: 21