Presentation is loading. Please wait.

Presentation is loading. Please wait.

Introduction Chapter 1. Reference Book  Database Systems Thomas Connolly, Carolyn Begg, Anne Strachan Addison-Wesley 1999 ISBN: 0-201-34287-1.

Similar presentations


Presentation on theme: "Introduction Chapter 1. Reference Book  Database Systems Thomas Connolly, Carolyn Begg, Anne Strachan Addison-Wesley 1999 ISBN: 0-201-34287-1."— Presentation transcript:

1 Introduction Chapter 1

2 Reference Book  Database Systems Thomas Connolly, Carolyn Begg, Anne Strachan Addison-Wesley 1999 ISBN: 0-201-34287-1

3 What is a database ? The database  is the underlying framework of the information system  fundamentally changed the way organisations operate Database technology is still in evolution due to the need for more complex information systems, handling different types of objects. This lead to new file storage and access algorithms.

4 Definitions Database:A shared collection of logically related data (and a description of these data), designed to meet the information needs of an organisation DBMS:Database Management System Software that enables users to define,create and maintain the database and which provides controlled access to the database

5 File Based Approach File-based system A collection of application programs that perform services for the end-users such as the production of reports. Each program defines and manages its own data. Program Works well if the number of items to be stored is small and related to one object type

6 File-based Processing Overlap

7 Limitations of the File-based System  Separation and isolation of data  Duplication of data  Program-Data dependence  one-shot program needed to increase the field size  File structure is defined in the program code.  Incompatibility of files (e.g. formats )  Programs are written in different languages, and so cannot easily access each others files.  Fixed queries leading to proliferation of application programs

8 Database Approach The limitations of file-based systems are attributed to two factors:  the definition of the data is embedded in the application program using the data, rather than being stored or defined separately and independently  there is no control over the access and manipulation of data beyond that imposed by the application programs being executed

9 Database Approach DB Applications

10 Explanation of the Definition The definition of a database was: A shared collection of logically related data (and a description of these data), designed to meet the information needs of an organisation.  Shared collection means that the database:  should not be seen as owned by one person or one department  holds not only the the organisation’s operational data but is also based on a common description of the data (system catalog, data dictionary, metadata, central repository) providing program-data independence.  Logically related means that :  not only the entities and the attributes but also the logical relationships between entities are represented in the database

11 The DBMS  DBMS  Software that enables users to define,create and maintain the database and which provides controlled access to the database  System software with two basic qualities:  ability to manage persistent data  ability to access large amounts of data efficiently  Other capabilities  support for at least one data model providing a user view  support for high level languages  transaction management ( concurrency )  access control: validation and authorization  recovery system

12 Database Management System (DBMS)

13 DBMS facilities  define the database through a Data Definition Language (DDL)  insert, update, delete and retrieve data from the database through a Data Manipulation Language (DML) based upon the central repository  procedural DML manipulating the database with a one-record- at-a-time logic, describing how data should be obtained  non-procedural DML operating on sets of records, describing what data should be obtained  controlled access to the database  security system  integrity system maintaining the consistency of stored data  recovery control system  user-accessible catalog

14 DBMS facilities 2  view mechanism allowing the user to have his or her preferred view of the database  the DDL allows views to be defined as a subset of the database  views provide a level of security  views provide a mechanism to customize the appearance of the database  views provide a level of data independence Modern large multi-user DBMS products offer these facilities and often much more. It are extremely complex software products which are continually evolving and extended with new functionalities

15 Components of a DBMS  Hardware  Software  Data  names, types and sizes of data items  names of relationships  integrity constraints on the data  authorization rules  indexes and storage structures  Procedures  log on  use a DBMS facility or application program  make a backup or copy  change the structure or the physical location  People

16 Components of DBMS Environment

17 History of Database Systems  First-generation  Hierarchical and Network  Second generation  Relational  Third generation  Extended Relational  Object-Oriented

18 Roles in the Database Environment  Data Administrator : management of the data resource  database planning, development, logical design, standards, policies, procedures, …  advisor of senior management concerning information plan  Database Administrator (DBA):physical aspects  physical database design, security, integrity control  Logical Database Designers  need a complete understanding of the organisation’s data, the business rules and the company strategic plan  Physical Database Designers  mapping logical model into a set of tables and constraints  select storage structures  Application programmers  End-Users : Naïve and Sophisticated

19 Advantages of database systems  Control of data redundancy  Data consistency  More information from same amount of data  Sharing of data  Improved data integrity  Improved security  Enforcement of standards  Economy of scale  Balanced conflicting requirements  Improved data accessibility and responsiveness  Improved maintenance through data independence  Increased concurrency  Improved backup and recovery services

20 Disadvantages of database systems  Complexity  Size  Cost of DBMS  Additional hardware costs  Cost of conversion  Performance  Higher impact of a failure

21 Classical database models  Relational databases  Hierarchical databases  Network databases

22 The Relational model A relational database can be seen as a set of tables with the following properties : 1.column homogeneous 2.all elements are numbers or character strings 3.all rows are different 4.the sequence of the rows is immaterial 5.columns have a different name Such a table said to be in First Normal Form

23 Sample database: Relational Model S s# sname status city S1 Smith 20London S2 Jones 10Paris S4 Clark20London P p#pnamecolorweightcity P1Nutred12London P2Boltgreen17Paris P4Screwred14London P5Camblue12Paris SP s#p#qty S2P1300 S2P2400 S4P2200 S4P4300 S4P5400

24 Sample Query : Relational Model  Find Supplier numbers for those suppliers who supply part P2. Do until no more shipments; get next shipment where P# = P2 ; print S# ; end;  Find Part numbers for parts supplied by supplier S2 Do until no more shipments; get next shipment where S# = S2 ; print P# ; end;

25 Sample Database: Hierarchical Model P1 Nut Red 12 London S2 Jones 10 Paris 300 P2 Bolt green 14 London P4 Screw red 14 LondonP5 Cam blue 12 Paris S2 Jones 10 Paris 400 S4 Clark 20 London 200 S4 Clark 20 London 400S4 Clark 20 London 300 Links are anonymous

26 Sample Query : Hierarchical Model l Find Supplier numbers for those suppliers who supply part P2. Get next part where P#=P2 do until no more suppliers under this part ; get next supplier under this part ; print S# ; end ; l Find Part numbers for parts supplied by supplier S2 Do until no more parts ; get next part ; get next supplier under this part where S# = S2 ; if found then print P# ; end;

27 Network model: Non-information Bearing Sets S2 Jones 10 Paris S4 Clark 20 London S2 P2 400S2 P1 300S4 P2 200S4 P4 300S4 P5 400 P1 Nut Red 12 LondonP2 Bolt Green 12 ParisP4 Screw Red 14 LondonP5 Cam Blue 12 Paris

28 Network model: Information Bearing Sets S2 Jones 10 Paris S4 Clark 20 London 400 300 200300400 P1 Nut Red 12 LondonP2 Bolt Green 12 ParisP4 Screw Red 14 LondonP5 Cam Blue 12 Paris

29 Sample Query : Network Model  Find Supplier numbers for those suppliers who supply part P2.  Find Part numbers for parts supplied by supplier S2 Get next part where P#=P2 ; do until no more connectors under this part ; get next connector under this part ; get supplier over this connector ; print S# ; end ; Get next supplier where S#=S2 ; do until no more connectors under this supplier ; get next connector under this supplier ; get part over this connector ; print P# ; end ;


Download ppt "Introduction Chapter 1. Reference Book  Database Systems Thomas Connolly, Carolyn Begg, Anne Strachan Addison-Wesley 1999 ISBN: 0-201-34287-1."

Similar presentations


Ads by Google