PL/SQL - Procedural Language/Structured Query Language (PL/SQL) is
Oracle Corporation's propretary extension to the
SQL language.
Since SQL is a declarative language, and (unlike some
functional programming languages such as
Scheme) the standard does not require implementations to convert
tail calls to jumps or readily provide "first row" and "rest of table" accessors, SQL cannot easily perform some constructs such as loops.
PL/SQL is a
Turing-complete procedural language which fills in these gaps and allows Oracle
database developers to interface with the underlying
relational database in an imperative manner.
SQL queries call PL/SQL functions through constructions such as triggers.
PL/SQL is analogous to the embedded procedural languages for other relational databases.
Sybase? and its derivative [Microsoft SQL Server]? have Transact-SQL, PostgreSQL has PL/pgSQL (which tries to emulate PL/SQL to an extent), and Oracle can also use methods written in the Java programming language.