Database management system chapter13

640 views

Published on

Database Management System, Oracle SQL and PL/SQL - Chapter 13

Published in: Education, Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
640
On SlideShare
0
From Embeds
0
Number of Embeds
2
Actions
Shares
0
Downloads
16
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide

Database management system chapter13

  1. 1. DATABASE MANAGEMENT SYSTEM ORACLE SQL AND PL/SQL PART III : Advanced Concepts & Technologies Teaching Aid Material (www.phindia.com/gupta) Authors invite your valuable feedback and suggestions on the book pkdasgupta@gmail.com RadhaKrishna_P@infosys.com
  2. 2. DATABASE MANAGEMENT SYSTEM ORACLE SQL AND PL/SQL PART III : Advanced Concepts & Technologies CHAPTER 13 Query Processing File Organization Distributed Processing
  3. 3. CHAPTER 13 Query Processing 1 of 3 Page reference in the book: 321-325
  4. 4. CHAPTER 13 Query Processing 2 of 3 Major components of Query Processing Engine     Query Parser Query Optimizer Query Code Generator Run-time Database Processor Query Processing is supported by    System catalogs Database statistics Main database Page reference in the book: 321-325
  5. 5. CHAPTER 13 Query Processing 3 of 3 SELECT C.CNAME, P.PNAME FROM CUSTOMER C, PRODUCT P, SALE S WHERE C.CID=S.CID AND P.PID=S.PID AND P.PCOST>10; Two example plans for the above query are: Plan (a) Use the indexed/hashed CUSTOMER, PRODUCT and SALE tables. Find PNAME whose cost is greater than 10 and then join the three tables. Plan (b) Take cross product of tables CUSTOMER, PRODUCT and SALE, which are neither sorted nor hashed. Join rows based on CID and PID and after that select display CNAME and PNAME based on PCOST greater than 10. In case of Plan (a) execution time will be in terms of seconds Plan (b) execution time will be in terms of minutes Page reference in the book: 321-325
  6. 6. CHAPTER 13 File Organization 1 of 17 Sequential  Records are stored in sequence based on the primary key value Indexed     Index Part Data Part Dense Index Sparse Index Page reference in the book: 325 -328
  7. 7. CHAPTER 13 File Organization 2 of 17 Page reference in the book: 325 -328
  8. 8. CHAPTER 13 File Organization 3 of 17 Binary Tree Node: Parent of a node: Child: Root: Leaf Node: Height’ of a tree: Stores the actual data and links to the other node Immediate predecessor of a node An immediate successor of a parent node Designated node which has no parent Node which is at the bottom most end and does not have any child Maximum number of nodes in a path starting from the root node to a leaf node Degree’ of a node: Maximum number of children that is possible for a node A binary tree is empty or consists of a node (called root) together with two binary trees called the left subtree and right subtree of the root. A binary tree is a full binary tree if it contains the maximum possible number of nodes at all levels. Page reference in the book: 328-333
  9. 9. CHAPTER 13 File Organization 4 of 17 Page reference in the book: 328-333
  10. 10. CHAPTER 13 File Organization 5 of 17 Page reference in the book: 328-333
  11. 11. CHAPTER 13 File Organization 6 of 17 Page reference in the book: 328-333
  12. 12. CHAPTER 13 File Organization 7 of 17 Page reference in the book: 328-333
  13. 13. CHAPTER 13 File Organization 8 of 17 Page reference in the book: 328-333
  14. 14. CHAPTER 13 File Organization 9 of 17 Page reference in the book: 328-333
  15. 15. CHAPTER 13 File Organization 10 of 17 Hashing Provides key-to-Address transformation using some function known as hashing function Types of Hashing: Static Hashing Dynamic Hashing Page reference in the book: 333-339
  16. 16. CHAPTER 13 File Organization 11 of 17 Static Hashing Page reference in the book: 333-339
  17. 17. CHAPTER 13 File Organization 12 of 17 Static Hashing Page reference in the book: 333-339
  18. 18. CHAPTER 13 File Organization 13 of 17 Dynamic Hashing Page reference in the book: 333-339
  19. 19. CHAPTER 13 File Organization 14 of 17 Dynamic Hashing Page reference in the book: 333-339
  20. 20. CHAPTER 13 File Organization 15 of 17 Dynamic Hashing Page reference in the book: 333-339
  21. 21. CHAPTER 13 File Organization 16 of 17 Dynamic Hashing Page reference in the book: 333-339
  22. 22. CHAPTER 13 File Organization 17 of 17 Dynamic Hashing Page reference in the book: 333-339
  23. 23. CHAPTER 13 Distributed Processing 1 of 5 Client/Server Architecture (or Two-Tier Arch)  Client program initiates communication and  server program cater the requests Three-Tier Architecture  Data tier (back-end)  Logic tier (middle tier)  Presentation tier (front tier) Page reference in the book: 339-345
  24. 24. CHAPTER 13 Distributed Processing 2 of 5 Client/Server Architecture  Payroll software running on Oracle database server  Payroll application is developed using Visual Basic software  Three computers are used:  One for database (server side or back-end)  Two for clients (or front-ends)  TCP/IP networking protocol is used to establish the network Page reference in the book: 339-345
  25. 25. CHAPTER 13 Distributed Processing 3 of 5 Page reference in the book: 339-345
  26. 26. CHAPTER 13 Distributed Processing 4 of 5 Three-tier Architecture Message Board Oracle database server is used in the data tier (or back-end) In the logic-tier (or middletier) Dot net server is used In the front-end, Internet Explorer is used Page reference in the book: 339-345
  27. 27. CHAPTER 13 Distributed Processing 5 of 5 Page reference in the book: 339-345
  28. 28. CHAPTER 13 Short/Objective Type Questions 1 of 4 Q1. What is the correlation between ‘execution plan’ and ‘query optimization’ in query processing? Q2. Describe optimization technique used in Oracle database server. Q3. Briefly describe ISAM. Q4. What is the difference between B+ Tree and B– Tree? Q5. Illustrates advantages of dynamic hashing over static hashing. Q6. Describe advantages of two-tier and three-tier architectures. Q7. Describe ETL, OLTP and OLAP. Q8. Describe classification and association in data mining with the help of an example. Q9. Write two software suitable for middle-tier of 3-tier architecture. Q10. Elaborate query processing with the help of an appropriate diagram.
  29. 29. CHAPTER 13 Short/Objective Type Questions 2 of 4 Q11. Major component(s) of query processing is/are (a) Query parser (b) Query optimizer (c) Run-time database processor (d) Query file organizer Q12. In dense index, the number of index record is (a) More than the number of records in the data file (b) Less than the number of records in the data file (c) Equal to the number of records in the data file (d) None of the above Q13. Index part and data part are related to (a) B+ tree (b) ISAM (c) B– tree (d) Hashing
  30. 30. CHAPTER 13 Short/Objective Type Questions 3 of 4 Q14. B+ tree and B– tree are form of a (a) Binary tree (b) Balanced tree (c) Basic tree (d) Bi-variant tree Q15. The situation when static hash function generates the same bucket number for several search key values is known as (a) Overflow (b) Underflow (c) Collision (d) Spitting Q16. Two-tier architecture is known as (a) Web based architecture (b) Client server architecture (c) Multi-tier architecture (d) Master–slave architecture
  31. 31. CHAPTER 13 Short/Objective Type Questions 4 of 4 Q17. Example of presentation tier (or front-tier) in 3-tier is/are (a) Oracle database server (b) Internet explorer (c) Mozila firefox (d) Visual basic Q18. Primary job ETL is/are (a) Finding interesting patterns (b) Moving data from source to destination repositories (c) Online transaction processing (d) Online analytical processing Q19. Keyword related to data mining is/are (a) Extraction of non-trivial information (b) Data preprocessing (c) Online analytical processing (d) Revealing unexpected information
  32. 32. CHAPTER 13 Home Assignment WORKOUT SECTION
  33. 33. DATABASE MANAGEMENT SYSTEM ORACLE SQL AND PL/SQL PART III : Advanced Concepts & Technologies Periods Proposed – 12 to 18 Chapter 13 Query Processing, File Organization & Distributed Processing 2-3 Periods [Theory] Chapter 14 Transaction Processing, Concurrency Control, Oracle Architecture, Backup & Recovery 2-3 Periods [Theory] Chapter 15 Data Warehousing 2-3 Period [Theory] Chapter 16 Online Analytical Processing and Materialized Views 2-3 Period [Theory] Chapter 17 Data Mining Overview 2-3 Period [Theory] Chapter 18 Data Mining techniques 2-3 Period [Theory]
  34. 34. THE BOOK The book is organized into three parts to introduce the theoretical and programming concepts of DBMS. Part I (Basic Concepts and Oracle SQL) deals with DBMS basic, software analysis and design, data flow diagram, ER model, relational algebra, normal forms, SQL queries, functions, sub‐queries, different types of joins, DCL, DDL, DML, object constraints and security in Oracle. Part II (Application Using Oracle PL/SQL) explains PL/SQL basics, functions, procedures, packages, exception handling, triggers, implicit, explicit and advanced cursors using suitable examples. This part also covers advanced concepts related to PL/SQL, such as collection, records, objects, dynamic SQL and performance tuning. Part III (Advanced Concepts and Technologies) elaborates on advanced database concepts such as query processing, file organization, distributed architecture, backup, recovery, data warehousing, online analytical processing and data mining concepts and their techniques. KEY FEATURES  Includes about 300 examples to illustrate the concepts.  Offers about 400 objective type questions.  Provides about 100 challenging workouts. TEACHING AID MATERIAL Teaching Aid Material for all the chapters is provided on the website of PHI Learning. Visit www.phindia.com/gupta to explore the contents.
  35. 35. Visit PHI Learning Center www.phindia.com/gupta and Click on Instructor Resources to access Teaching Aid Material for all the 18 chapters of the book.

×