Download presentation
Presentation is loading. Please wait.
Published byKory Charles Modified over 9 years ago
1
11 Copyright س Oracle Corporation, 2000. All rights reserved. ® Overview of PL/SQL
2
1-2 Copyright س Oracle Corporation, 2000. All rights reserved. ®SQLSQLPL/SQLPL/SQL Applications HR HR Financials Financials Manufacturing Manufacturing......Applications HR HR Financials Financials Manufacturing Manufacturing...... Data tables Data dictionary OracleDatabase Oracle Discoverer Oracle Designer Oracle Developer SQL* Plus Web-basedapplicationsWeb-basedapplicationsMultitierapplicationsMultitierapplications Oracle Complete Solution
3
1-3 Copyright س Oracle Corporation, 2000. All rights reserved. ® PL/SQL Program Constructs Anonymous block Application trigger Stored procedure/ function Database trigger Application procedure/ function PackagePackage DECLARE BEGIN EXCEPTION END; Object type
4
1-4 Copyright س Oracle Corporation, 2000. All rights reserved. ® Block Structure for Anonymous PL/SQL Blocks DECLARE (optional) Declare PL/SQL objects to be used within this block BEGIN (mandatory) Define the executable statements EXCEPTION (optional) Define the actions that take place if an error arises END; (mandatory) DECLARE (optional) Declare PL/SQL objects to be used within this block BEGIN (mandatory) Define the executable statements EXCEPTION (optional) Define the actions that take place if an error arises END; (mandatory)
5
1-5 Copyright س Oracle Corporation, 2000. All rights reserved. ® Block Structure for PL/SQL Subprograms Header IS|AS Declaration section BEGIN Executable section EXCEPTION (optional) Exception section END; Header IS|AS Declaration section BEGIN Executable section EXCEPTION (optional) Exception section END;
6
1-6 Copyright س Oracle Corporation, 2000. All rights reserved. ® Benefits of Subprograms Improved maintenance Improved data security and integrity Improved performance Improved maintenance Improved data security and integrity Improved performance
7
1-7 Copyright س Oracle Corporation, 2000. All rights reserved. ® Development Environments SQL*Plus uses the PL/SQL engine in the Oracle Server Procedure Builder uses the PL/SQL engine in the client tool or in the Oracle Server SQL*Plus uses the PL/SQL engine in the Oracle Server Procedure Builder uses the PL/SQL engine in the client tool or in the Oracle Server
8
1-8 Copyright س Oracle Corporation, 2000. All rights reserved. ® Developing Procedures and Functions Using SQL*Plus
9
1-9 Copyright س Oracle Corporation, 2000. All rights reserved. ® Developing Procedures and Functions Using Oracle Procedure Builder
10
1-10 Copyright س Oracle Corporation, 2000. All rights reserved. ® Summary In this lesson, you should have learned that: Anonymous blocks are unnamed PL/SQL blocks Subprograms are named PL/SQL blocks, declared as either procedures or functions There are two main PL/SQL development environments: –SQL*Plus –Procedure Builder In this lesson, you should have learned that: Anonymous blocks are unnamed PL/SQL blocks Subprograms are named PL/SQL blocks, declared as either procedures or functions There are two main PL/SQL development environments: –SQL*Plus –Procedure Builder
Similar presentations
© 2025 SlidePlayer.com. Inc.
All rights reserved.