Copyright © 2004 Pearson Education, Inc.. Chapter 9 More SQL: Assertions, Views, and Programming Techniques.

Slides:



Advertisements
Similar presentations
Copyright © 2004 Pearson Education, Inc.. Chapter 13 Disk Storage, Basic File Structures, and Hashing.
Advertisements

Chapter 23 Database Security and Authorization Copyright © 2004 Pearson Education, Inc.
Copyright © 2004 Pearson Education, Inc.. Chapter 15 Algorithms for Query Processing and Optimization.
Chapter 15 Algorithms for Query Processing and Optimization Copyright © 2004 Pearson Education, Inc.
Copyright © 2004 Pearson Education, Inc.. Chapter 23 Database Security and Authorization.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide 1- 1.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide 2- 1.
Copyright © 2004 Pearson Education, Inc.. Chapter 5 The Relational Data Model and Relational Database Constraints.
Copyright © 2004 Pearson Education, Inc.. Chapter 14 Indexing Structures for Files.
Copyright © 2004 Pearson Education, Inc.. Chapter 10 Functional Dependencies and Normalization for Relational Databases.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 13 Introduction to SQL Programming Techniques.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide 9- 1.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2004 Pearson Education, Inc.. Chapter 11 Relational Database Design Algorithms and Further Dependencies.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2008 Pearson Education, Inc. Chapter 1 Linear Functions Copyright © 2008 Pearson Education, Inc.
Copyright © 2004 Pearson Education, Inc.. Chapter 4 Enhanced Entity- Relationship and UML Modeling.
Copyright © 2004 Pearson Education, Inc.. Chapter 1 Introduction and Conceptual Modeling.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2008 Pearson Education, Inc. Chapter 11 Probability and Calculus Copyright © 2008 Pearson Education, Inc.
Copyright © 2004 Pearson Education, Inc.. Chapter 2 Database System Concepts and Architecture.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2004 Pearson Education, Inc.. Chapter 12 Practice Database Design Methodology and Use of UML Diagrams.
Copyright © 2004 Pearson Education, Inc.. Chapter 6 The Relational Algebra and Relational Calculus.
Copyright © 2004 Pearson Education, Inc.. Chapter 12 Practical Database Design Methodology and Use of UML Diagrams.
Copyright © 2004 Pearson Education, Inc.. Chapter 3 Data Modeling Using the Entity-Relationship Model.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2008 Pearson Education, Inc. Chapter 13 The Trigonometric Functions Copyright © 2008 Pearson Education, Inc.
Copyright © 2004 Pearson Education, Inc.. Chapter 13 Disk Storage, Basic File Structures, and Hashing.
Copyright © 2004 Pearson Education, Inc.. Chapter 27 Data Mining Concepts.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2004 Pearson Education, Inc.. Chapter 8 SQL-99: Schema Definition, Basic Constraints, and Queries.
Copyright © 2004 Pearson Education, Inc.. Chapter 18 Concurrency Control Techniques.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Slide
Copyright © 2004 Pearson Education, Inc.. Chapter 19 Database Recovery Techniques.
Chapter 9 MORE SQL: Assertions, Views, and Programming Techniques Copyright © 2004 Pearson Education, Inc.
Copyright © 2004 Pearson Education, Inc.. Chapter 17 Introduction to Transaction Processing Concepts and Theory.
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Slide
Copyright © 2004 Pearson Education, Inc.. Chapter 25 Distributed Databases and Client–Server Architectures.
Copyright © 2007 Ramez Elmasri and Shamkant B. Navathe Slide 9- 1 DATADABASE PROGRAMMING 2Chapter 13 from our text.
Chapter 21 B Mapping to ODL Copyright © 2004 Pearson Education, Inc.
Chapter 4 Functional Dependencies and Normalization for Relational Databases Copyright © 2004 Pearson Education, Inc.
Copyright © 2004 Pearson Education, Inc.. Chapter 15 Algorithms for Query Processing and Optimization.
Copyright © 2004 Pearson Education, Inc.. Chapter 26 XML and Internet Databases.
Slide 6-1 Copyright © 2004 Pearson Education, Inc.
Copyright © 2003 Pearson Education, Inc. Slide 1 Computer Systems Organization & Architecture Chapters 6-7 John D. Carpinelli.
Chapter 21 C OQL Copyright © 2004 Pearson Education, Inc.
Copyright © 2004 Pearson Education, Inc.. Chapter 28 Overview of Data Warehousing and OLAP.
Chapter 6 MORE SQL: Assertions, Views, and Programming Techniques Copyright © 2004 Pearson Education, Inc.
Copyright © 2004 Pearson Education, Inc.. Chapter 21 Object Database Standards, Languages, and Design.
Copyright © 2004 Pearson Education, Inc.. Chapter 22 Object-Relational and Extended-Relational Systems.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley. Chapter 5 Integration.
Chapter 9 Database Security and Authorization Copyright © 2004 Pearson Education, Inc.
Copyright © 2004 Pearson Education, Inc.. Chapter 6 The Relational Algebra and Relational Calculus.
Copyright © 2004 Pearson Education, Inc.. Chapter 25 Distributed Databases and Client-Server Architectures.
Copyright © 2004 Pearson Education, Inc.. Chapter 24 Enhanced Data Models for Advanced Applications.
Copyright © 2004 Pearson Education, Inc.. Chapter 17 Introduction to Transaction Processing Concepts and Theory.
Chapter 2 Opener © 2014 Pearson Education, Inc.. Figure 2.1 © 2014 Pearson Education, Inc.
Copyright © 2004 Pearson Education, Inc. Chapter 1 Introduction and Conceptual Modeling.
Copyright © 2011 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 4 Basic SQL تنبيه : شرائح العرض (Slides) هي وسيلة لتوضيح الدرس واداة.
Copyright © 2016 Ramez Elmasri and Shamkant B. Navathe.
Copyright © 2004 Pearson Education, Inc.. Chapter 24 Enhanced Data Models for Advanced Applications.
Copyright © 2004 Pearson Education, Inc.. Chapter 24 Enhanced Data Models for Advanced Applications.
Introduction to SQL Programming Techniques
Chapter 4 Opener © 2014 Pearson Education, Inc..
Chapter 11 Opener © 2014 Pearson Education, Inc..
Presentation transcript:

Copyright © 2004 Pearson Education, Inc.

Chapter 9 More SQL: Assertions, Views, and Programming Techniques

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-3 FIGURE 9.1 Two views specified on the database schema of Figure 5.5.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-4 FIGURE 9.2 C program variables used in the embedded SQL examples E1 and E2.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-5 FIGURE 9.3 Program segment E1, a C program segment with embedded SQL.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-6 FIGURE 9.4 Program segment E2, a C program segment that uses cursors with embedded SQL for update purposes.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-7 FIGURE 9.5 Program segment E3, a C program segment that uses dynamic SQL for updating table.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-8 FIGURE 9.6 Importing classes needed for including SQLJ in JAVA programs in ORACLE, and establishing a connection and default context.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-9 FIGURE 9.7 JAVA program variables used in SQLJ examples J1 and J2.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-10 FIGURE 9.8 Program segment J1, a JAVA program segment with SQLJ.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-11 FIGURE 9.9 Program segment J2A, a JAVA program segment that uses a named iterator to print employee information in a particular department.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-12 FIGURE 9.10 Program segment J2B, a JAVA program segment that uses a positional iterator to print employee information in a particular department.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-13 FIGURE 9.11 Program segment CLI1, a C program segment with SQL/CLI.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-14 FIGURE 9.12 Program segment CLI2, a C program segment that uses SQL/CLI for a query with a collection of tuples in its result.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-15 FIGURE 9.13 Program segment JDBC1, a JAVA program segment with JDBC.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-16 FIGURE 9.14 Program segment JDBC2, a JAVA program segment that uses JDBC for a query with a collection of tuples in its result.

Elmasri and Navathe, Fundamentals of Database Systems, Fourth Edition Copyright © 2004 Pearson Education, Inc. Slide 9-17 FIGURE 9.15 Declaring a function in SQL/PSM.