Database Management Systems - Chapter 1: Overall Introduction to Database Management Systems - Võ Thị Ngọc Châu

Chapter 1. Overall Introduction to Database
Management Systems
 Chapter 2. Disk Storage and Basic File Structures
 Chapter 3. Indexing Structures for Files
 Chapter 4. Query Processing and Optimization
 Chapter 5. Introduction to Transaction Processing
Concepts and Theory
 Chapter 6. Concurrency Control Techniques
 Chapter 7. Database Recovery Techniques 
pdf 32 trang xuanthi 30/12/2022 300
Bạn đang xem 20 trang mẫu của tài liệu "Database Management Systems - Chapter 1: Overall Introduction to Database Management Systems - Võ Thị Ngọc Châu", để tải tài liệu gốc về máy hãy click vào nút Download ở trên.

File đính kèm:

  • pdfdatabase_management_systems_chapter_1_overall_introduction_t.pdf

Nội dung text: Database Management Systems - Chapter 1: Overall Introduction to Database Management Systems - Võ Thị Ngọc Châu

  1. Course outline Chapter 1. Overall Introduction to Database Management Systems Chapter 2. Disk Storage and Basic File Structures Chapter 3. Indexing Structures for Files Chapter 4. Query Processing and Optimization Chapter 5. Introduction to Transaction Processing Concepts and Theory Chapter 6. Concurrency Control Techniques Chapter 7. Database Recovery Techniques 2
  2. Content What is a database management system (DBMS)? System architecture History of DBMS development Classification of database management systems When should(not) we use the DBMS approach? Human resource related to a DBMS 4
  3. What is a database management system (DBMS)? The power of database comes from a body of knowledge and technology that has developed over several decades and is embodied (included as part) in a specialized software called a database management system, or DBMS. A DBMS is a powerful tool for creating and managing large amount of data efficiently and allowing it to persist over long periods of time safely. 6
  4. system component in-memory structure control/data flow data flow Figure 1.1. Database Management System Components [3] H. G. Molina, J. D. Ullman, J. Widom, Database Systems: The Complete Book, Prentice-Hall, 2009 8
  5. Queries/Updates with Query Processing Queries/Updates with DML statements SELECT cname FROM courses WHERE cid = „CO3021‟; UPDATE courses SET credit = 3 WHERE cid = „CO3021‟; DML statements are handled by two separate subsystems:  Answering the query  Transaction processing 10
  6. Queries/Updates with Query Processing Transaction processing Queries and other actions are grouped into transactions, which are units that must be executed atomically and in isolation; often each query or modification action is a transaction itself. In addition, the execution of transactions must be durable, meaning that the effect of any completed transaction must be preserved even if the system fails in some way after completion of the transaction. The transaction processor consists of two parts:  A concurrency-control manager (scheduler) responsible for assuring atomicity and isolation of transaction,  A logging and recovery manager responsible for the durability of transactions. 12
  7. Main-memory buffers and Buffer Manager The kinds of information in the buffer that various components in DBMS may need include: Data: the content of the database itself Metadata: the database schema that describes the structure of, and the constraints on, the database. Statistics: information gathered and stored by the DBMS about data properties such as the size of, and the values in various relations or other components of the database. Indexes: data structures that support efficient access to the data. 14
  8. The Query Processor – Query Compiler A query parser, which builds a tree structure from the textual form of the query. A query preprocessor, which performs semantic checks on the query (e.g., making sure all relations mentioned by the query actually exist), and performing some tree transformations to turn the parse tree into tree of algebraic operators representing the initial query plan. A query optimizer, which transforms the initial query plan into the best available sequence of operations on the actual data. Note: The query compiler uses metadata and statistics about the data to decide which sequence of operations is likely to be the fastest. 16
  9. Transaction Processing It‟s normal to group one or more database operations into a transaction, which is a unit of work that must be executed atomically and in apparent isolation from other transactions. Besides, a DBMS offers the guarantee of durability: that the work of a completed transaction will never be lost. The transaction manager accepts transaction commands from an application, which tell the transaction manager:  when transactions begin and end  information about the expectations of the application. 18
  10. Transaction Processing Concurrent control: Transactions must appear to execute in isolation. But in most systems, there will be many transactions executing at once. Thus, the scheduler (concurrency-control manager) must assure that the individual actions of multiple transactions are executed in such an order that the net effect is the same as if the transactions had been executed in their entirety, one-at-a-time.  A typical scheduler does its work by maintaining locks on certain pieces of the database. These locks prevent two transactions from accessing the same piece of data in ways that interact badly.  Locks are stored in a main-memory lock table. The scheduler affects the execution of queries and other database operations by forbidding the execution engine from accessing locked parts of the database. 20
  11. DBMS Capabilities The capabilities that a DBMS provides its users are: Persistent Storage. A DBMS supports the storage of very large amounts of data that exists independently of any processes that are using the data. Programming Interface. A DBMS allows the user to access and modify data through a powerful query language. Transaction management. A DBMS supports concurrent access to data, i.e., simultaneously access by many distinct processes (called transaction) at once. To avoid some of the undesirable consequences of simultaneous access, the DBMS supports:  isolation  atomicity  resiliency (recovery) 22
  12. History of DBMS development 1960s, navigational DBMSs  IBM‟s IMS with the hierarchical model,  IDMS with the CODASYL network model, 1970s-late 1980s, relational DBMSs with SQL  Oracle,  MS SQL Server,  IBM‟s DB2,  MySQL, 1990s, object-oriented DBMSs (object, object-relational)  Oracle,  PostgreSQL,  Informix, 2000s, NoSQL and NewSQL  XML DBMSs: Oracle Berkely DB XML,  NoSQL DBMSs: MongoDB, Hbase, Cassandra,  NewSQL DBMSs: ScaleBase, VoltDB, 24
  13. When should(not) we use the DBMS approach? Should  Controlling Redundancy  Restricting Unauthorized Access  Providing Persistent Storage for Program Objects  Providing Storage Structures and Search Techniques for Efficient Query Processing  Providing Backup and Recovery  Providing Multiple User Interfaces  Representing Complex Relationships among Data  Enforcing Integrity Constraints  Permitting Inferencing and Actions Using Rules and Triggers  Additional Implications of Using the Database Approach Potential for Enforcing Standards Reduced Application Development Time Flexibility Availability of Up-to-Date Information Economies of Scale 26
  14. Human resource related to a DBMS Database administrators Database end-users Database designers System analysts Application developers DBMS developers 28
  15. Overall Introduction to Database Management Systems 30
  16. Check for understandings 7. Classify the following DBMSs  Oracle 8i  Oracle 12c  MS SQL Server 2008  MySQL  MongoDB  Apache Cache  IBM DB2 32