DB2® client applications can access routines (stored procedures and user-defined functions) that are created by supported host languages or by SQL procedures. For example, the sample program spclient.pl can access the SQL procedures spserver shared library, if it exists in the database.
To build a host language routine, you must have the appropriate compiler set up on the server. SQL procedures do not require a compiler. The shared library can be built on the server only, and not from a remote client.
To create SQL procedures in a shared library and then accesses the procedures from a Perl application: