Understanding external routines
An external routine allows a program, which is written in a language other than PL/SQL, to be used in PL/SQL. For instance, a program logic written in Java can be invoked and used from PL/SQL. The program in non-PL/SQL language is referred to as external programs. The favorable situations for the use of external routines may arise in an application development environment which follows strict regimentation of the client, API and database layers. On broader terms, an external program has to be stored as a shared library on the server followed by its publishing through call specification. Once the external routine is published, it is ready to be used in PL/SQL.
Within the scope of this chapter, we will discuss the invocation of external programs written in C and Java language from PL/SQL.
Architecture of external routines
Before we get into the core methodology followed for external routines, we will discuss some of the crucial components of Oracle architectural...