* Your assessment is very important for improving the workof artificial intelligence, which forms the content of this project
Download Introduction to Database Systems
Survey
Document related concepts
Serializability wikipedia , lookup
Microsoft Access wikipedia , lookup
Oracle Database wikipedia , lookup
Extensible Storage Engine wikipedia , lookup
Entity–attribute–value model wikipedia , lookup
Ingres (database) wikipedia , lookup
Microsoft SQL Server wikipedia , lookup
Functional Database Model wikipedia , lookup
Microsoft Jet Database Engine wikipedia , lookup
Concurrency control wikipedia , lookup
Versant Object Database wikipedia , lookup
Open Database Connectivity wikipedia , lookup
ContactPoint wikipedia , lookup
Clusterpoint wikipedia , lookup
Transcript
Introduction to Database Systems <Course Code> Lecture #1 Monday 15th October 2001 Lecturer Eric Leray TSSG, Block A, Waterford Business Park Email: [email protected] Phone: 051 302 916 {office hours} Background Working with TSSG on European Projects and writing a Masters on Information Management. WIT BSc4 Database Practical since 1999 Graduated a BSc Applied Computing in WIT in 1999 Placement in FEXCO Database Administration Communications Web page: http://macha.wit.ie/staff/eleray/Diploma All the slides and labs will be available on this intranet site Textbook(s) A First Course in Database Systems • by Jeff Ullman and Jennifer Widom Database Implementation • by Hector Garcia-Molina, Jeff Ullman and Jennifer Widom Traditional Database Application Suppose we are building a system to store the information about: students courses lecturers And who takes what, who teaches what Why use a DBMS ? What we need from a database: store the data for a long period of time large amounts (100s of GB) protect against crashes protect against unauthorized use allow users to query/update: who teaches “WD028-4” enroll “Mary” in “WD028-4” allow several (100s, 1000s) users to access the data simultaneously allow administrators to change the schema add information about Students: • Address: Mary leaves in Waterford Add or Delete a course Trying Without a DBMS Why Direct Implementation Won’t Work: Storing data: file system is limited size less than 4GB (on 32 bits machines) when system crashes we may loose data password-based authorization insufficient Query/update: need to write a new program for every new query need to worry about performance Concurrency: limited protection need to worry about interfering with other users need to offer different views to different users (e.g. students and lecturers) Schema change: need to change virtually all files and to rewrite all applications Functionality of a DBMS Storage management Data Manipulation Language - DML query language Data Definition Language – DDL Create and alter schema Transaction Management concurrency control recovery Building an Application with a DBMS Analyse and understand the real world situation This can be done by the form of interviews Requirements modeling (conceptual, pictures) Decide what entities should be part of the application and how they should be linked. Schema design and implementation Decide on a set of tables, attributes. Define the tables in the database system. Populate database (insert t-uples). Write application programs using the DBMS way easier now that the data management is taken care of. name address Conceptual Modeling name cid studnb Takes Course Student quarter Mentors Teaches Lecturer address name lid Schema Design and Implementation Tables: Students: Takes: StudNB Name Address StudNB cid 97301535 Pierre Dublin 97301535 WD028-4 98613886 Mary Waterford 98613886 WD068-2 … … … … … Courses: cid Title Year WD028-4 BSc Applied Comp. 4 WD028-2 Mary 2 … … … Separates the logical view from the physical view of the data. Querying a Database Find all courses that “Mary” takes S(tructured) Q(uery) L(anguage) select C.name from Students S, Takes T, Courses C where S.name=“Mary” and S.StudNB = T. StudNB and T.cid = C.cid Query processor figures out how to answer the query efficiently. Current and Future Data Management Current Data Management: relational data for enterprise applications storage query processing/optimization transaction processing Future Data Management: XML data for exchange on the Web Improved Transport Move from fully structured {SQL like} to semistructured {XML like} Improved information retrieval Database Industry Relational databases are a great success of theoretical ideas. “Big 3” DBMS companies are among the largest software companies in the world. IBM (with DB2) and Microsoft (SQL Server, Microsoft Access) are also important players. $20B industry. Challenged by object oriented DBMS. The Study of DBMS Several aspects: Modeling and design of databases Database programming: querying and update operations Database implementation DBMS study cuts across many fields of Computer Science: OS, languages, AI, Logic, multimedia, theory... Course Outline Database design: Entity Relationship diagrams ODL (object-oriented design language) Modeling constraints The relational model: Relational algebra Transforming E/R models to relational schemas Outline (Continued) SQL Basic SQL DML Basic SQL DDL Introduction to advance SQL DBMS Programming Interaction JDBC ODBC Outline (Continued) Storage and indexing Query optimization Transaction processing and recovery Advanced topics Structure Prerequisites: Basic knowledge on Database Basic knowledge of Java Work & Grading: {not final scheme} Homework: optional Project: 20% -*Christmas: 10% Easter: 10% Final: 60% The Project Goal: design end-to-end database application. Conceptual Modeling SQL Implementation Simple Java or VB Front-End Work in groups of 2-3 (start forming now). Choose topic on your own. Timetable for project milestones.