What is PL/SQL
- SQL stands for Structured Query Language
- PL/SQL stands for Procedural Language (PL) Extension Of Structured Query Language (SQL).
- It is used in Oracle and integrated with Oracle Database since version 7.
Advantages of PL/SQL:
- Pl/SQL allows the developer to write the code in the procedural format in oracle.
- It gives more control to the developer by the use of conditions (if, else etc.), object oriented concepts and loops (while, for etc) in oracle.
- It allows declaration of variables, constants, functions, procedures, types and variables of those types and triggers.
- It supports Array and exception handling.
- Pl/SQL is not case sensitive, it means anyone can use lower case letter or upper case letter except within the string and character.
Use of PL/SQL:
- PL/SQL is used to write blocks (in program), functions, procedures, packages, triggers etc.
- Lexical units in PL/SQL are nothing but a line of PL/SQL text contains groups of characters.
Lexical units can be classified as below: