logo资料库

Fundamental of Database system.pdf

第1页 / 共1273页
第2页 / 共1273页
第3页 / 共1273页
第4页 / 共1273页
第5页 / 共1273页
第6页 / 共1273页
第7页 / 共1273页
第8页 / 共1273页
资料共1273页,剩余部分请下载后查看
Cover
Title Page
Copyright Page
Dedication
Preface
Acknowledgments
Contents
About the Authors
part 1 Introduction to Databases
chapter 1 Databases and Database Users
1.1 Introduction
1.2 An Example
1.3 Characteristics of the Database Approach
1.4 Actors on the Scene
1.5 Workers behind the Scene
1.6 Advantages of Using the DBMS Approach
1.7 A Brief History of Database Applications
1.8 When Not to Use a DBMS
1.9 Summary
Review Questions
Exercises
Selected Bibliography
chapter 2 Database System Concepts and Architecture
2.1 Data Models, Schemas, and Instances
2.2 Three-Schema Architecture and Data Independence
2.3 Database Languages and Interfaces
2.4 The Database System Environment
2.5 Centralized and Client/Server Architectures for DBMSs
2.6 Classification of Database Management Systems
2.7 Summary
Review Questions
Exercises
Selected Bibliography
part 2 Conceptual Data Modeling and Database Design
chapter 3 Data Modeling Using the Entity–Relationship (ER) Model
3.1 Using High-Level Conceptual Data Models for Database Design
3.2 A Sample Database Application
3.3 Entity Types, Entity Sets, Attributes, and Keys
3.4 Relationship Types, Relationship Sets, Roles, and Structural Constraints
3.5 Weak Entity Types
3.6 Refining the ER Design for the COMPANY Database
3.7 ER Diagrams, Naming Conventions, and Design Issues
3.8 Example of Other Notation: UML Class Diagrams
3.9 Relationship Types of Degree Higher than Two
3.10 Another Example: A UNIVERSITY Database
3.11 Summary
Review Questions
Exercises
Laboratory Exercises
Selected Bibliography
chapter 4 The Enhanced Entity–Relationship (EER) Model
4.1 Subclasses, Superclasses, and Inheritance
4.2 Specialization and Generalization
4.3 Constraints and Characteristics of Specialization and Generalization Hierarchies
4.4 Modeling of UNION Types Using Categories
4.5 A Sample UNIVERSITY EER Schema, Design Choices, and Formal Definitions
4.6 Example of Other Notation: Representing Specialization and Generalization in UML Class Diagrams
4.7 Data Abstraction, Knowledge Representation, and Ontology Concepts
4.8 Summary
Review Questions
Exercises
Laboratory Exercises
Selected Bibliography
part 3 The Relational Data Model and SQL
chapter 5 The Relational Data Model and Relational Database Constraints
5.1 Relational Model Concepts
5.2 Relational Model Constraints and Relational Database Schemas
5.3 Update Operations, Transactions, and Dealing with Constraint Violations
5.4 Summary
Review Questions
Exercises
Selected Bibliography
chapter 6 Basic SQL
6.1 SQL Data Definition and Data Types
6.2 Specifying Constraints in SQL
6.3 Basic Retrieval Queries in SQL
6.4 INSERT, DELETE, and UPDATE Statements in SQL
6.5 Additional Features of SQL
6.6 Summary
Review Questions
Exercises
Selected Bibliography
chapter 7 More SQL: Complex Queries, Triggers, Views, and Schema Modification
7.1 More Complex SQL Retrieval Queries
7.2 Specifying Constraints as Assertions and Actions as Triggers
7.3 Views (Virtual Tables) in SQL
7.4 Schema Change Statements in SQL
7.5 Summary
Review Questions
Exercises
Selected Bibliography
chapter 8 The Relational Algebra and Relational Calculus
8.1 Unary Relational Operations: SELECT and PROJECT
8.2 Relational Algebra Operations from Set Theory
8.3 Binary Relational Operations: JOIN and DIVISION
8.4 Additional Relational Operations
8.5 Examples of Queries in Relational Algebra
8.6 The Tuple Relational Calculus
8.7 The Domain Relational Calculus
8.8 Summary
Review Questions
Exercises
Laboratory Exercises
Selected Bibliography
chapter 9 Relational Database Design by ER- and EER-to-Relational Mapping
9.1 Relational Database Design Using ER-to-Relational Mapping
9.2 Mapping EER Model Constructs to Relations
9.3 Summary
Review Questions
Exercises
Laboratory Exercises
Selected Bibliography
part 4 Database Programming Techniques
chapter 10 Introduction to SQL Programming Techniques
10.1 Overview of Database Programming Techniques and Issues
10.2 Embedded SQL, Dynamic SQL, and SQLJ
10.3 Database Programming with Function Calls and Class Libraries: SQL/CLI and JDBC
10.4 Database Stored Procedures and SQL/PSM
10.5 Comparing the Three Approaches
10.6 Summary
Review Questions
Exercises
Selected Bibliography
chapter 11 Web Database Programming Using PHP
11.1 A Simple PHP Example
11.2 Overview of Basic Features of PHP
11.3 Overview of PHP Database Programming
11.4 Brief Overview of Java Technologies for Database Web Programming
11.5 Summary
Review Questions
Exercises
Selected Bibliography
part 5 Object, Object-Relational, and XML: Concepts, Models, Languages, and Standards
chapter 12 Object and Object-Relational Databases
12.1 Overview of Object Database Concepts
12.2 Object Database Extensions to SQL
12.3 The ODMG Object Model and the Object Definition Language ODL
12.4 Object Database Conceptual Design
12.5 The Object Query Language OQL
12.6 Overview of the C++ Language Binding in the ODMG Standard
12.7 Summary
Review Questions
Exercises
Selected Bibliography
chapter 13 XML: Extensible Markup Language
13.1 Structured, Semistructured, and Unstructured Data
13.2 XML Hierarchical (Tree) Data Model
13.3 XML Documents, DTD, and XML Schema
13.4 Storing and Extracting XML Documents from Databases
13.5 XML Languages
13.6 Extracting XML Documents from Relational Databases
13.7 XML/SQL: SQL Functions for Creating XML Data
13.8 Summary
Review Questions
Exercises
Selected Bibliography
part 6 Database Design Theory and Normalization
chapter 14 Basics of Functional Dependencies and Normalization for Relational Databases
14.1 Informal Design Guidelines for Relation Schemas
14.2 Functional Dependencies
14.3 Normal Forms Based on Primary Keys
14.4 General Definitions of Second and Third Normal Forms
14.5 Boyce-Codd Normal Form
14.6 Multivalued Dependency and Fourth Normal Form
14.7 Join Dependencies and Fifth Normal Form
14.8 Summary
Review Questions
Exercises
Laboratory Exercises
Selected Bibliography
chapter 15 Relational Database Design Algorithms and Further Dependencies
15.1 Further Topics in Functional Dependencies: Inference Rules, Equivalence, and Minimal Cover
15.2 Properties of Relational Decompositions
15.3 Algorithms for Relational Database Schema Design
15.4 About Nulls, Dangling Tuples, and Alternative Relational Designs
15.5 Further Discussion of Multivalued Dependencies and 4NF
15.6 Other Dependencies and Normal Forms
15.7 Summary
Review Questions
Exercises
Laboratory Exercises
Selected Bibliography
part 7 File Structures, Hashing, Indexing, and Physical Database Design
chapter 16 Disk Storage, Basic File Structures, Hashing, and Modern Storage Architectures
16.1 Introduction
16.2 Secondary Storage Devices
16.3 Buffering of Blocks
16.4 Placing File Records on Disk
16.5 Operations on Files
16.6 Files of Unordered Records (Heap Files)
16.7 Files of Ordered Records (Sorted Files)
16.8 Hashing Techniques
16.9 Other Primary File Organizations
16.10 Parallelizing Disk Access Using RAID Technology
16.11 Modern Storage Architectures
16.12 Summary
Review Questions
Exercises
Selected Bibliography
chapter 17 Indexing Structures for Files and Physical Database Design
17.1 Types of Single-Level Ordered Indexes
17.2 Multilevel Indexes
17.3 Dynamic Multilevel Indexes Using B-Trees and B+-Trees
17.4 Indexes on Multiple Keys
17.5 Other Types of Indexes
17.6 Some General Issues Concerning Indexing
17.7 Physical Database Design in Relational Databases
17.8 Summary
Review Questions
Exercises
Selected Bibliography
part 8 Query Processing and Optimization
chapter 18 Strategies for Query Processing
18.1 Translating SQL Queries into Relational Algebra and Other Operators
18.2 Algorithms for External Sorting
18.3 Algorithms for SELECT Operation
18.4 Implementing the JOIN Operation
18.5 Algorithms for PROJECT and Set Operations
18.6 Implementing Aggregate Operations and Different Types of JOINs
18.7 Combining Operations Using Pipelining
18.8 Parallel Algorithms for Query Processing
18.9 Summary
Review Questions
Exercises
Selected Bibliography
chapter 19 Query Optimization
19.1 Query Trees and Heuristics for Query Optimization
19.2 Choice of Query Execution Plans
19.3 Use of Selectivities in Cost-Based Optimization
19.4 Cost Functions for SELECT Operation
19.5 Cost Functions for the JOIN Operation
19.6 Example to Illustrate Cost-Based Query Optimization
19.7 Additional Issues Related to Query Optimization
19.8 An Example of Query Optimization in Data Warehouses
19.9 Overview of Query Optimization in Oracle
19.10 Semantic Query Optimization
19.11 Summary
Review Questions
Exercises
Selected Bibliography
part 9 Transaction Processing, Concurrency Control, and Recovery
chapter 20 Introduction to Transaction Processing Concepts and Theory
20.1 Introduction to Transaction Processing
20.2 Transaction and System Concepts
20.3 Desirable Properties of Transactions
20.4 Characterizing Schedules Based on Recoverability
20.5 Characterizing Schedules Based on Serializability
20.6 Transaction Support in SQL
20.7 Summary
Review Questions
Exercises
Selected Bibliography
chapter 21 Concurrency Control Techniques
21.1 Two-Phase Locking Techniques for Concurrency Control
21.2 Concurrency Control Based on Timestamp Ordering
21.3 Multiversion Concurrency Control Techniques
21.4 Validation (Optimistic) Techniques and Snapshot Isolation Concurrency Control
21.5 Granularity of Data Items and Multiple Granularity Locking
21.6 Using Locks for Concurrency Control in Indexes
21.7 Other Concurrency Control Issues
21.8 Summary
Review Questions
Exercises
Selected Bibliography
chapter 22 Database Recovery Techniques
22.1 Recovery Concepts
22.2 NO-UNDO/REDO Recovery Based on Deferred Update
22.3 Recovery Techniques Based on Immediate Update
22.4 Shadow Paging
22.5 The ARIES Recovery Algorithm
22.6 Recovery in Multidatabase Systems
22.7 Database Backup and Recovery from Catastrophic Failures
22.8 Summary
Review Questions
Exercises
Selected Bibliography
part 10 Distributed Databases, NOSQL Systems, and Big Data
chapter 23 Distributed Database Concepts
23.1 Distributed Database Concepts
23.2 Data Fragmentation, Replication, and Allocation Techniques for Distributed Database Design
23.3 Overview of Concurrency Control and Recovery in Distributed Databases
23.4 Overview of Transaction Management in Distributed Databases
23.5 Query Processing and Optimization in Distributed Databases
23.6 Types of Distributed Database Systems
23.7 Distributed Database Architectures
23.8 Distributed Catalog Management
23.9 Summary
Review Questions
Exercises
Selected Bibliography
chapter 24 NOSQL Databases and Big Data Storage Systems
24.1 Introduction to NOSQL Systems
24.2 The CAP Theorem
24.3 Document-Based NOSQL Systems and MongoDB
24.4 NOSQL Key-Value Stores
24.5 Column-Based or Wide Column NOSQL Systems
24.6 NOSQL Graph Databases and Neo4j
24.7 Summary
Review Questions
Selected Bibliography
chapter 25 Big Data Technologies Based on MapReduce and Hadoop
25.1 What Is Big Data?
25.2 Introduction to MapReduce and Hadoop
25.3 Hadoop Distributed File System (HDFS)
25.4 MapReduce: Additional Details
25.5 Hadoop v2 alias YARN
25.6 General Discussion
25.7 Summary
Review Questions
Selected Bibliography
part 11 Advanced Database Models, Systems, and Applications
chapter 26 Enhanced Data Models: Introduction to Active, Temporal, Spatial, Multimedia, and Deductive Databases
26.1 Active Database Concepts and Triggers
26.2 Temporal Database Concepts
26.3 Spatial Database Concepts
26.4 Multimedia Database Concepts
26.5 Introduction to Deductive Databases
26.6 Summary
Review Questions
Exercises
Selected Bibliography
chapter 27 Introduction to Information Retrieval and Web Search
27.1 Information Retrieval (IR) Concepts
27.2 Retrieval Models
27.3 Types of Queries in IR Systems
27.4 Text Preprocessing
27.5 Inverted Indexing
27.6 Evaluation Measures of Search Relevance
27.7 Web Search and Analysis
27.8 Trends in Information Retrieval
27.9 Summary
Review Questions
Selected Bibliography
chapter 28 Data Mining Concepts
28.1 Overview of Data Mining Technology
28.2 Association Rules
28.3 Classification
28.4 Clustering
28.5 Approaches to Other Data Mining Problems
28.6 Applications of Data Mining
28.7 Commercial Data Mining Tools
28.8 Summary
Review Questions
Exercises
Selected Bibliography
chapter 29 Overview of Data Warehousing and OLAP
29.1 Introduction, Definitions, and Terminology
29.2 Characteristics of Data Warehouses
29.3 Data Modeling for Data Warehouses
29.4 Building a Data Warehouse
29.5 Typical Functionality of a Data Warehouse
29.6 Data Warehouse versus Views
29.7 Difficulties of Implementing Data Warehouses
29.8 Summary
Review Questions
Selected Bibliography
part 12 Additional Database Topics: Security
chapter 30 Database Security
30.1 Introduction to Database Security Issues
30.2 Discretionary Access Control Based on Granting and Revoking Privileges
30.3 Mandatory Access Control and Role-Based Access Control for Multilevel Security
30.4 SQL Injection
30.5 Introduction to Statistical Database Security
30.6 Introduction to Flow Control
30.7 Encryption and Public Key Infrastructures
30.8 Privacy Issues and Preservation
30.9 Challenges to Maintaining Database Security
30.10 Oracle Label-Based Security
30.11 Summary
Review Questions
Exercises
Selected Bibliography
appendix A Alternative Diagrammatic Notations for ER Models
appendix B Parameters of Disks
appendix C Overview of the QBE Language
C.1 Basic Retrievals in QBE
C.2 Grouping, Aggregation, and Database Modification in QBE
Selected Bibliography
Index
A
B
C
D
E
F
G
H
I
J
K
L
M
N
O
P
Q
R
S
T
U
V
W
X
Y
FUNDAMENTALS OF Database Systems SEVENTH EDITION
This page intentionally left blank
FUNDAMENTALS OF Database Systems SEVENTH EDITION Ramez Elmasri Department of Computer Science and Engineering The University of Texas at Arlington Shamkant B. Navathe College of Computing Georgia Institute of Technology Boston Columbus Indianapolis New York San Francisco Hoboken Amsterdam Cape Town Dubai London Madrid Milan Munich Paris Montreal Toronto Delhi Mexico City São Paulo Sydney Hong Kong Seoul Singapore Taipei Tokyo
iEnergizer Aptara®, Ltd. Operations Specialist: Maura Zaldivar-Garcia Cover Designer: Black Horse Designs Manager, Rights and Permissions: Rachel Youdelman Associate Project Manager, Rights and Permissions: Timothy Nicholls Full-Service Project Management: Rashmi Tickyani, Composition: iEnergizer Aptara®, Ltd. Printer/Binder: Edwards Brothers Malloy Cover Printer: Phoenix Color/Hagerstown Cover Image: Micha Pawlitzki/Terra/Corbis Typeface: 10.5/12 Minion Pro Vice President and Editorial Director, ECS: Marcia J. Horton Acquisitions Editor: Matt Goldstein Editorial Assistant: Kelsey Loanes Marketing Managers: Bram Van Kempen, Demetrius Hall Marketing Assistant: Jon Bryant Senior Managing Editor: Scott Disanno Production Project Manager: Rose Kernan Program Manager: Carole Snyder Global HE Director of Vendor Sourcing and Procurement: Diane Hynes Director of Operations: Nick Sklitsis Copyright © 2016, 2011, 2007 by Ramez Elmasri and Shamkant B. Navathe. All rights reserved. Manufactured in the United States of America. This publication is protected by Copyright and permissions should be obtained from the publisher prior to any prohibited reproduction, storage in a retrieval system, or transmission in any form or by any means, electronic, mechanical, photocopying, recording, or likewise. To obtain permission(s) to use materials from this work, please submit a written request to Pearson Higher Education, Permissions Department, 221 River Street, Hoboken, NJ 07030. Many of the designations by manufacturers and seller to distinguish their products are claimed as trademarks. Where those designations appear in this book, and the publisher was aware of a trademark claim, the designations have been printed in initial caps or all caps. The author and publisher of this book have used their best efforts in preparing this book. These efforts include the development, research, and testing of theories and programs to determine their effectiveness. The author and publisher make no warranty of any kind, expressed or implied, with regard to these programs or the documentation contained in this book. The author and publisher shall not be liable in any event for incidental or consequential damages with, or arising out of, the furnishing, performance, or use of these programs. Microsoft and/or its respective suppliers make no representations about the suitability of the information contained in the documents and related graphics published as part of the services for any purpose. All such documents and related graphics are provided “as is” without warranty of any kind. Microsoft and/or its respective suppliers hereby disclaim all warranties and conditions with regard to this information, including all warranties and conditions of merchantability. Whether express, implied or statutory, fitness for a particular purpose, title and non-infringement. In no event shall microsoft and/or its respective suppliers be liable for any special, indirect or consequential damages or any damages whatsoever resulting from loss of use, data or profits, whether in an action of contract. Negligence or other tortious action, arising out of or in connection with the use or performance of information available from the services. The documents and related graphics contained herein could include technical inaccuracies or typographical errors. Changes are periodically added to the information herein. Microsoft and/or its respective suppliers may make improvements and/or changes in the product(s) and/or the program(s) described herein at any time. Partial screen shots may be viewed in full within the software version specified. Library of Congress Cataloging-in-Publication Data on File 10 9 8 7 6 5 4 3 2 1 ISBN-10: 0-13-397077-9 ISBN-13: 978-0-13-397077-7
To Amalia and to Ramy, Riyad, Katrina, and Thomas R. E. To my wife Aruna for her love, support, and understanding to Rohan, Maya, and Ayush for bringing so much joy into our lives and S.B.N.
This page intentionally left blank
Preface This book introduces the fundamental concepts necessary for designing, using, and implementing database systems and database applications. Our presentation stresses the funda- mentals of database modeling and design, the languages and models provided by the database management systems, and database system implementation techniques. The book is meant to be used as a textbook for a one- or two-semester course in database systems at the junior, senior, or graduate level, and as a reference book. Our goal is to provide an in-depth and up-to-date presentation of the most important aspects of database systems and applications, and related technologies. We assume that readers are familiar with elementary programming and data-structuring con- cepts and that they have had some exposure to the basics of computer organization. New to This Edition The following key features have been added in the seventh edition: ■ A reorganization of the chapter ordering (this was based on a survey of the instructors who use the textbook); however, the book is still organized so that the individual instructor can choose to follow the new chapter ordering or choose a different ordering of chapters (for example, follow the chapter order from the sixth edition) when presenting the materials. ■ There are two new chapters on recent advances in database systems and big data processing; one new chapter (Chapter 24) covers an introduction to the newer class of database systems known as NOSQL databases, and the other new chapter (Chapter 25) covers technologies for processing big data, including MapReduce and Hadoop. ■ The chapter on query processing and optimization has been expanded and reorganized into two chapters; Chapter 18 focuses on strategies and algo- rithms for query processing whereas Chapter 19 focuses on query optimiza- tion techniques. ■ A second UNIVERSITY database example has been added to the early chap- ters (Chapters 3 through 8) in addition to our COMPANY database example from the previous editions. ■ Many of the individual chapters have been updated to varying degrees to include newer techniques and methods; rather than discuss these enhancements here, vii
分享到:
收藏