Successfully reported this slideshow.

lecture-5.ppt

967 views

Published on

  • Be the first to comment

  • Be the first to like this

lecture-5.ppt

  1. 1. WFM-6103: Hydrologic Information System (HIS) Akm Saiful Islam Lecture-5: Database Management System April-October, 2006 Institute of Water and Flood Management (IWFM) BUET Institute of Water and Flood Management (IWFM) Bangladesh University of Engineering and Technology (BUET) WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  2. 2. Outline <ul><li>Database Management System </li></ul><ul><ul><li>Introduction to Databases </li></ul></ul><ul><ul><li>File System Vs. Databases </li></ul></ul><ul><ul><li>Advantages of using databases </li></ul></ul><ul><ul><li>Database Management System </li></ul></ul>WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  3. 3. Introduction to Databases <ul><li>Information Systems process and manage data. </li></ul><ul><li>Data Management involves “Capturing”, “Retrieval,” and “Storage” of data. </li></ul><ul><li>Database Management Systems (DBMSs) are Computer systems that manage data in databases. </li></ul><ul><li>Today’s DBMSs are based on sophisticated software and powerful computer hardware. </li></ul><ul><li>Well known DBMS software includes ORACLE, Microsoft SQL Server, Sybase and MySQL(free download) among others. </li></ul>WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  4. 4. Data Storage: Terminology <ul><li>A collection of data entities is typically known as a file . </li></ul><ul><li>An individual data entity is typically known as a record . </li></ul><ul><li>Different attributes of a record are typically known as fields . </li></ul><ul><li>A key is a field or a set of fields that uniquely identifies a record. </li></ul>Fields Key Product Category + Product Type + Year File (table) WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam Records
  5. 5. A Word on Keys <ul><li>A Key maybe: </li></ul><ul><li>A field or set of fields that are used to identify the record. </li></ul><ul><li>A Primary key is a minimal set of fields that uniquely identifies the record. </li></ul><ul><li>A Foreign key is a field that is a primary key in another relation </li></ul>Primary Key Foreign Keys WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  6. 6. File Organisation <ul><li>Sequential Files </li></ul><ul><li>records are stored in a fixed sequence </li></ul><ul><li>records can only be read in that sequence, starting from the first record </li></ul><ul><li>records can only be added at the end of the file (append) </li></ul><ul><li>sequential files are not efficient </li></ul><ul><li>Indexed Files </li></ul><ul><li>Use an index to access records in a random fashion. </li></ul><ul><li>Records can be sorted according to an attribute or preference. (e.g Alphabetically, Ascending, Descending, etc.) </li></ul><ul><li>Indexed files are efficient, and faster to access. </li></ul>WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  7. 7. The File Systems Approach <ul><li>Redundant Data Storage. </li></ul><ul><li>One file is used in each application. </li></ul><ul><li>No data sharing. </li></ul><ul><li>Cross-application transfers are difficult to manage and achieve. </li></ul><ul><li>File Systems are rarely used for data processing anymore. </li></ul>WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam General Ledger File Personnel File Production Planning File Inventory File Despatch File Order Entry File Invoicing File Payroll File
  8. 8. The Database Approach <ul><li>Compactness. Data is stored in a single logical “place.” </li></ul><ul><li>Data can be shared and related between applications </li></ul><ul><li>Data transfer between applications is easier </li></ul><ul><li>Used for a wide range of applications. </li></ul>Database General Ledger Personnel Production Planning Inventory Despatch Order Entry Invoicing Payroll WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  9. 9. Database Characteristics <ul><li>• Amount </li></ul><ul><ul><li>Database size depends on the number of records or files it contains. </li></ul></ul><ul><li>Complexity </li></ul><ul><ul><li>Database complexity depends on the number of relations between the files. </li></ul></ul><ul><li>Volatility </li></ul><ul><ul><li>A measure of the changes typically required in a given period of time. </li></ul></ul><ul><li>Immediacy </li></ul><ul><ul><li>A measure of how rapidly changes must be made to data. </li></ul></ul>WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  10. 10. Advantages of using a Database Approach <ul><li>Flexible Data Access . DBMSs have various tools to manipulate, query, or report data, such as Structured Query Language (SQL), and Report Generators. Hence: </li></ul><ul><ul><li>Selected data is easily retrieved </li></ul></ul><ul><ul><li>A DBMS can accommodate different data views for different users </li></ul></ul><ul><li>Improved Data Integrity . Modern DBMSs consist of various tools and methods to: </li></ul><ul><ul><li>ensure that data is correct, consistent, and current </li></ul></ul><ul><ul><li>verify data input and check whether data is ‘reasonable’. </li></ul></ul>WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  11. 11. Advantages of DBs (continued) <ul><li>Improved Data Security . Tools such as password access, and encryption, ensure that data is not: </li></ul><ul><ul><li>deliberately or accidentally damaged or changed </li></ul></ul><ul><ul><li>accessed without proper authorisation </li></ul></ul><ul><li>Data Independence . </li></ul><ul><ul><li>Problems arising from the interdependence of data and programs are kept to a minimum. </li></ul></ul><ul><li>Reduced Data Redundancy. </li></ul><ul><ul><li>Single version of the truth. </li></ul></ul><ul><ul><li>Efficient data storage. </li></ul></ul><ul><ul><li>Efficient time management of Hardware (CPU), programmer(s), analyst(s) and user(s). </li></ul></ul><ul><ul><li>Relational DBs use Normalisation to reduce data redundancy. </li></ul></ul>WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  12. 12. Advantages of DBs (continued) <ul><li>Ability to Share and Relate Data . </li></ul><ul><ul><li>Different user groups can use the same data. </li></ul></ul><ul><ul><li>Data in different (physical or logical) parts of the system can be related for a certain application. </li></ul></ul><ul><li>Standardisation of Data . </li></ul><ul><ul><li>In general data items have common names and storage format. </li></ul></ul><ul><li>Increased Productivity . </li></ul><ul><ul><li>The various tools reduce the complexity that is otherwise associated with DB maintenance when changes are required to the system. For example Law changes, Economy Changes, User Changes. </li></ul></ul>WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  13. 13. Costs of Database Approach <ul><li>The implementation and use of DBMSs is normally associated with various costs. Such as: </li></ul><ul><ul><li>Initial expenses involve planning costs, and consultancy fees. </li></ul></ul><ul><ul><li>Computer hardware costs. </li></ul></ul><ul><ul><li>Software costs. </li></ul></ul><ul><ul><li>Database Administrator costs, and staff training costs. </li></ul></ul><ul><ul><li>Conversion costs of an existing system. </li></ul></ul><ul><ul><li>Various operational costs. </li></ul></ul>WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  14. 14. DataBase Management System (DBMS) <ul><li>A DBMS is a set of computer “programs” that control: </li></ul><ul><ul><li>Database creation </li></ul></ul><ul><ul><li>Database maintenance </li></ul></ul><ul><ul><li>Database access </li></ul></ul><ul><li>A DBMS typically includes: </li></ul><ul><ul><li>a Data Definition Language or DDL </li></ul></ul><ul><ul><li>a Data Manipulation Language or DML </li></ul></ul><ul><ul><li>a Query Language. Quite often this is Structured Query Language (SQL) , or a derivative </li></ul></ul><ul><ul><li>a Report Generator </li></ul></ul>WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam
  15. 15. The DBMS Manages the Interaction Between the End User and the Database Bangladesh University of Engineering and Technology © Dr. Akm Saiful Islam
  16. 16. References <ul><li>Alex Berson, and Stephen J. Smith, Data Warehousing Data Mining, and OLAP, McGraw Hill, 1997. Chapters 1,13(13.1-13.4 inc.). ISBN 0-07-006272-2 </li></ul><ul><li>C. J. Date, An Introduction to Database Systems, 3rd Ed. (or later), Addison-Wesley, 1981. Chapter 1. </li></ul><ul><li>J. A. Senn, Analysis and Design of Information Systems, 2nd Ed. (or later), McGraw-Hill 1989. Chapter 12 (“Design of DB Interactions”). ISBN 0-07-100606-0 </li></ul><ul><li>E. Turban J. Aronson, Decision Support Systems and Intelligent Systems, 5th Ed., Prentice-Hall, 1998. Chapter 4. ISBN 0-13-791675. </li></ul>WFM 6103: hydrologic Information System © Dr. Akm Saiful Islam

×