Benefits of PL/SQL. 2 home back first prev next last What Will I Learn? In this lesson, you will learn to: –List and explain the benefits of PL/SQL –List.

Slides:



Advertisements
Similar presentations
An Introduction to Java Programming and Object- Oriented Application Development Chapter 8 Exceptions and Assertions.
Advertisements

Copyright Ó Oracle Corporation, All rights reserved Sharing Objects and Code.
PL/SQL (Procedural Language extensions to SQL) Prepared by: Manoj Kathpalia Edited by: M V Ramakrishna.
Chapter 4B: More Advanced PL/SQL Programming
Advanced Package Concepts. 2 home back first prev next last What Will I Learn? Write packages that use the overloading feature Write packages that use.
Creating Packages. 2 home back first prev next last What Will I Learn? Describe the reasons for using a package Describe the two components of a package:
A Guide to Oracle9i1 Advanced SQL And PL/SQL Topics Chapter 9.
Chapter 12: Advanced Topics: Exception Handling Visual Basic.NET Programming: From Problem Analysis to Program Design.
C++ for Engineers and Scientists Third Edition
Copyright  Oracle Corporation, All rights reserved. 4 Creating Functions.
Introduction to PL/SQL Chapter 9. Objectives Explain the need for PL/SQL Explain the benefits of PL/SQL Identify the different types of PL/SQL blocks.
23 Copyright © 2004, Oracle. All rights reserved. Sharing Objects and Code.
1 Chapter Eight Exception Handling. 2 Objectives Learn about exceptions and the Exception class How to purposely generate a SystemException Learn about.
Exceptions Oracle Database PL/SQL 10g Programming Chapter 7.
Chapter 7 Advanced SQL Database Systems: Design, Implementation, and Management, Sixth Edition, Rob and Coronel.
I Copyright © 2004, Oracle. All rights reserved. Introduction Copyright © 2004, Oracle. All rights reserved.
BTEC Unit 06 – Lesson 08 Principals of Software Design Mr C Johnston ICT Teacher
11 Copyright س Oracle Corporation, All rights reserved. ® Overview of PL/SQL.
PL/SQLPL/SQL Oracle10g Developer: PL/SQL Programming Chapter 7 PL/SQL Packages.
INTRODUCTION TO PL/SQL. Class Agenda Introduction Introduction to PL/SQL Declaring PL/SQL Variable Creating the Executable Section Interacting with the.
1 Copyright © 2004, Oracle. All rights reserved. Introduction to PL/SQL.
University of Sunderland COM 220 Lecture Six Slide 1 Building Interactive Forms Applications using Oracle.
1 Copyright © 2004, Oracle. All rights reserved. Introduction to PL/SQL.
CIS4368: Advanced DatabaseSlide # 1 PL/SQL Dr. Peeter KirsSpring, 2003 PL/SQL.
8 1 Chapter 8 Advanced SQL Database Systems: Design, Implementation, and Management, Seventh Edition, Rob and Coronel.
Trapping Oracle Server Exceptions. 2 home back first prev next last What Will I Learn? Describe and provide an example of an error defined by the Oracle.
Database Systems Design, Implementation, and Management Coronel | Morris 11e ©2015 Cengage Learning. All Rights Reserved. May not be scanned, copied or.
Manipulating Data in PL/SQL. 2 home back first prev next last What Will I Learn? Construct and execute PL/SQL statements that manipulate data with DML.
12 Copyright © 2004, Oracle. All rights reserved. Understanding and Influencing the PL/SQL Compiler.
Recognizing PL/SQL Lexical Units. 2 home back first prev next last What Will I Learn? List and define the different types of lexical units available in.
Handling Exceptions. 2 home back first prev next last What Will I Learn? Describe several advantages of including exception handling code in PL/SQL Describe.
What is a Package? A package is an Oracle object, which holds other objects within it. Objects commonly held within a package are procedures, functions,
Using Oracle-Supplied Packages. 2 home back first prev next last What Will I Learn? Describe two common uses for the DBMS_OUTPUT server-supplied package.
3 Copyright © 2004, Oracle. All rights reserved. Working in the Forms Developer Environment.
Dynamic SQL. 2 home back first prev next last What Will I Learn? Recall the stages through which all SQL statements pass Describe the reasons for using.
Introduction to Explicit Cursors. 2 home back first prev next last What Will I Learn? Distinguish between an implicit and an explicit cursor Describe.
Cursor FOR Loops. 2 home back first prev next last What Will I Learn? List and explain the benefits of using cursor FOR loops Create PL/SQL code to declare.
Retrieving Data in PL/SQL. 2 home back first prev next last What Will I Learn? In this lesson, you will learn to: –Recognize the SQL statements that can.
Computing Higher – SD Unit - Topic 8 – Procedure and Standard Algorithms P Lynch, St Andrew’s High School Unit 2 Software Development Process Topic.
Using Functions in SQL Statements. 2 home back first prev next last What Will I Learn? List the advantages of user-defined functions in SQL statements.
Oracle10g Developer: PL/SQL Programming1 Objectives Named program units How to identify parameters The CREATE PROCEDURE statement Creating a procedure.
Text TCS INTERNAL Oracle PL/SQL – Introduction. TCS INTERNAL PL SQL Introduction PLSQL means Procedural Language extension of SQL. PLSQL is a database.
Copyright Ó Oracle Corporation, All rights reserved Debugging Triggers.
15 Copyright © 2004, Oracle. All rights reserved. Debugging Triggers.
I Copyright © 2007, Oracle. All rights reserved. Introduction.
Creating Functions. Overview of Stored Functions A function is a named PL/SQL block that returns a value. A function is a named PL/SQL block that returns.
CS 440 Database Management Systems Stored procedures & OR mapping 1.
Introduction to PL/SQL N. Dimililer. About PL/SQL –PL/SQL is an extension to SQL with design features of programming languages. –Data manipulation and.
DB Programming Course Lecture 4. Errors Two types of errors can be found in a program: compilation errors and runtime errors. There is a special section.
7.5 Using Stored-Procedure and Triggers NAME MATRIC NUM GROUP Muhammad Azwan Bin Khairul Anwar CS2305A Muhammad Faiz Bin Badrol Shah CS2305B.
© FPT SOFTWARE – TRAINING MATERIAL – Internal use 04e-BM/NS/HDCV/FSOFT v2/3 Using Stored Procedures ADO.NET - Lesson 07  Training time: 15 minutes  Author:
Oracle9i Developer: PL/SQL Programming Chapter 6 PL/SQL Packages.
11 Copyright © 2009, Oracle. All rights reserved. Enhancing ETL Performance.
Working in the Forms Developer Environment
Web Technologies IT230 Dr Mohamed Habib.
Working in the Form Builder Environment
Introduction to Triggers
UNIT - V STORED PROCEDURE.
Introduction to PL/SQL
Handling Exceptions.
PL/SQL Scripting in Oracle:
Advanced PL/SQL Programing
Handling Exceptions.
Module 10: Implementing Managed Code in the Database
Chapter 8 Advanced SQL.
MATERI PL/SQL Procedures Functions Packages Database Triggers
Using Subqueries to Solve Queries
Using Subqueries to Solve Queries
Prof. Arfaoui. COM390 Chapter 7
WRITING AN ALGORITHM, PSEUDOCODE, AND FLOWCHART LESSON 2.
Presentation transcript:

Benefits of PL/SQL

2 home back first prev next last What Will I Learn? In this lesson, you will learn to: –List and explain the benefits of PL/SQL –List differences between PL/SQL and other programming languages –Give examples of how PL/SQL can be used in other Oracle products

3 home back first prev next last Why Learn It? In this lesson, you learn about the benefits of the PL/SQL programming language. You also learn how PL/SQL compares to other programming languages. Finally, you see how PL/SQL relates to other Oracle products.

4 home back first prev next last Benefits of PL/SQL There are many benefits of using the PL/SQL programming language with an Oracle database. We will explore each of these benefits in this lesson. 1. Integration of procedural constructs with SQL 2. Modularized program development 3. Improved performance 4. Integration with Oracle tools 5. Portability 6. Exception handling

5 home back first prev next last Benefit 1 The first and foremost advantage of PL/SQL is the integration of procedural constructs with SQL. –SQL is a nonprocedural language.  When you issue a SQL command, your command tells the database server what to do.  However, you cannot specify how to do it. –PL/SQL integrates control statements and conditional statements with SQL.  This gives you better control of your SQL statements and their execution.

6 home back first prev next last Benefit 2 Modularized program development –The basic unit in a PL/SQL program is a block. –All PL/SQL programs consist of blocks. –These blocks can be thought of as modules and can be “modularized” in a sequence or nested in other blocks.

7 home back first prev next last Benefit 2: (continued) Modularized program development has the following advantages: –You can group logically related statements within blocks. –You can nest blocks inside other blocks to build powerful programs.

8 home back first prev next last Benefit 2: (continued) –You can break your application into smaller modules. If you are designing a complex application, PL/SQL allows you to break down the application into smaller, manageable, and logically related modules. –You can easily read, maintain, and debug the code.

9 home back first prev next last Benefit 3 Improved performance –PL/SQL allows you to logically combine multiple SQL statements as one unit or block. The application can send the entire block to the database instead of sending the SQL statements one at a time. This significantly reduces the number of database calls.

10 home back first prev next last Benefit 4 Integration with Oracle tools –PL/SQL is integrated in Oracle tools such as Oracle Forms Developer, Oracle Report Builder, and Application Express.

11 home back first prev next last Benefit 5 Portability –PL/SQL programs can run anywhere an Oracle server runs,  irrespective of the operating system and the platform. –PL/SQL programs do not need to be tailored for different operating systems and platforms. –You can write portable program packages and create libraries that can be reused on Oracle databases in different environments.

12 home back first prev next last Benefit 6 Exception handling –An exception is an error that occurs in the database or in a user’s program during runtime.  Examples of errors include: hardware or network failures, application logic errors, data integrity errors, and so on. –You can prepare for errors by writing exception handling code. Exception handling code tells your program what to do in the event of an exception. –PL/SQL allows you to handle database and program exceptions efficiently. You can define separate blocks for dealing with exceptions.

13 home back first prev next last PL/SQL Compared to Other Languages

14 home back first prev next last PL/SQL in Oracle Products

15 home back first prev next last Terminology Key terms used in this lesson include: –Blocks –Portability –Exceptions

16 home back first prev next last Summary In this lesson, you have learned to: –List and explain the benefits of PL/SQL –List differences between PL/SQL and other programming languages –Give examples of how PL/SQL can be used in other Oracle products

17 home back first prev next last Try It/Solve It The exercises in this lesson cover the following topics: –Listing and explaining the benefits of PL/SQL –Differentiating between PL/SQL and other programming languages –Describing how PL/SQL can be used with other Oracle products