Your SlideShare is downloading. ×
Class363 1
Upcoming SlideShare
Loading in...5
×

Thanks for flagging this SlideShare!

Oops! An error has occurred.

×

Introducing the official SlideShare app

Stunning, full-screen experience for iPhone and Android

Text the download link to your phone

Standard text messaging rates apply

Class363 1

70
views

Published on

Published in: Technology

0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total Views
70
On Slideshare
0
From Embeds
0
Number of Embeds
0
Actions
Shares
0
Downloads
1
Comments
0
Likes
0
Embeds 0
No embeds

Report content
Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
No notes for slide

Transcript

  • 1. Introduction to Database Systems Lecture #1 Dated: 19-10-2007
  • 2.  Classes: 01:30 PM – 03:00 PM Thursday 11:30 AM – 01:00 PM Friday  Instructor: Nauman Riaz Chaudhry  Cell: 0300-9503200  Email: nauman.riaz@gmail.com
  • 3. Course Overview  Background and History  Data Models  E/R Model  Relational Model  Object Oriented Model  XML and Database  Database Programming  Relational Algebra  SQL  Object Oriented
  • 4. Textbook  C. J. Date “An Introduction to Database Systems ”, Seventh Edition, Pearson Education  Jeffrey D. Ullman and Jennifer Widom, “A First Course in Database Systems”, Second Edition, Prentice Hall, 2001  Other useful textbooks:  Fundamentals of Database Systems (Elmasri and Navathe)  Database System Concepts (Abraham Siberschatz, Henry F.Korth and S.Sudarshan)  Database Management Systems (Ramakrishnan)
  • 5. Tentative Schedule  Introduction (1-2 classes)  E/R Model (2-3 classes)  Relational Model (3-4 classes)  Other Models (2-3 classes)  Relational Algebra (3-4 classes)  SQL (4-5 classes)  Constraints and triggers (1-2 classes)  System Aspects of SQL (3-4 classes)  XML (3-4 classes)
  • 6. Course Load  3 - 5 homework assignments  1 project  5 Quiz's  A Midterm Exam  A Final Exam Homework and project assignments are due in the beginning of class one or two weeks that follows. Late homework will not be accepted, and a score of zero will be assigned for that assignment.
  • 7. Course Policy  exams: no access to any material nor discussion with anyone (except the instructor) is allowed.  assignments: solutions should be developed independently. Stealing, giving or receiving any code drawings, diagrams, text, or designs from another person is not allowed.  max penalty for academic dishonesty: F in the course; reported to the university.
  • 8. Grading Policy  The grade will be calculated using the following weights: Homework and Quizzes 15% Project 10% Mid-term Exams 25% Final Exam 50%
  • 9.  Starting from now … Something completely different!
  • 10. What is Database?  Essentially, a database is a set of data, or a collection of information. These data are related.  Examples: Student Information human genome sequence company products information
  • 11. More Examples  Airline Reservation Systems  Reservations by a single customer on a single flight, including such information as assigned seat or meal preference  Information about the flight, the airports thy fly from and to, the departure and arrival times, etc.  Ticket prices, requirements, and availability  Banking Systems  Customers, accounts, loans and the balances  Deposit or withdraw money
  • 12. What’s DBMS?  DataBase Management System (DBMS) A powerful tool for creating and manage large amounts of data efficiently and allowing it to persist over long periods of time, safely. It also provides efficient accesses to multiple users. It is used to manage databases.
  • 13. DBMS capabilities  Persistent Storage  Programming Interface  Transaction management
  • 14. DBMS capabilities (Cont.)  Allow users to create databases and specify their schema, using data-definition language.  Allow users to query and modify the data, using data- manipulation language.  Support the storage of very large amount of data over a long period.  Data consistency and failure recovery.
  • 15. File System  Why not using file system?  Can be used to store data information for a long period as well.  Consistency and failure recovery capability  Problems:  no query language, no efficient access for a data item  support of the creation of database is limited  consistency control is not adequate Management of Data is complex
  • 16. DBMS Evolution  File Systems  Hierarchical Model (Tree-based)  Network Model (Graph-based)  Relational Model  Object Oriented Model  Object/Relational Model
  • 17. Relational Database System  Ted Codd 1970  The view of data: relations relations, tuples, attributes tables, rows, columns  Queries could be expressed in high level language, it is simple and efficient  It is widely used in most commercial systems
  • 18. Example 1.1 AccountNo Balance Type 12345 1000.00 Savings 67890 2846.92 checking … … … Bank Account Information (Accounts)
  • 19. Example 1.1 (Cont.)  Check the balance SELECT balance FROM Accounts WHERE accountNo= 67890  Check the accountNo SELECT accountNo From Accounts WHERE type=‘savings’ AND balance < 0
  • 20. Major DBMS Products  Oracle  IBM: DB2, Informix  Microsoft: SQL Server, Access  Sybase  MySQL  Postgres All are "relational" (or "object-relational") database systems at their core.
  • 21. Schema versus data  Schema describes how data is to be structured - defined at set-up time, rarely changes (part of the "metadata")  Data is actual "instance" of database, may change rapidly  Comparable to types and variables in programming languages
  • 22. Data Definition Language (DDL)  Commands for setting up schema of database  Process of designing schema can be complex, may use design methodology and/or tool
  • 23. Data Manipulation Language (DML)  Commands to manipulate data in database: RETRIEVE, INSERT, DELETE, MODIFY  Also called "query language"
  • 24. People  DBMS implementer: builds system  Database designer: establishes schema  Database administrator: loads data, keeps whole thing running  Database user: queries/modifies data
  • 25. DBMS Evolution Trends  Size smaller and smaller using personal computer, similar to applications such as spreadsheet and word processing bigger and bigger terabytes or even petabytes data, using tertiary storage and parallel computing techniques.  Architecture Client-server architecture (Two-Tier) client database Server Multi-Tier architecture: client application server database server
  • 26. DBMS Trends (Cont.)  Versatile Data type integers, characters small storage requirement videos, audios large storage requirement  Integration Data warehouses, data mining
  • 27. Overview of DBMS  DDL commands DBA DDL Complier Execution engine …  Query Processing  Answering the query User Query Compiler Execution engine …  Transaction processing
  • 28. Storage and Buffer Management  Buffer manager  Storage manager  Data: the contents of the database  Metadata (Schema) : structure of the database  Statistics: data properties  Indexes
  • 29. Transaction Processing  Transaction manager  Logging  Concurrency control  Deadlock resolution
  • 30. Query Processor  Query complier  Query parser  Query preprocessor  Query optimizer  Execution engine
  • 31. Outline of Database System  Database design Determine the database structure  Database programming Perform database operations  Database system implementation Build the database
  • 32. Next Class  E/R Concepts