There are several ways to create PDF’s, on the client (e.g. PDFCreator) or on the middletier.
But to create PDF’s merely with packages in the database, that’s another story. Even Apex uses some Java on the middletier.
The product PLPDF on the other hand is a well known utility which provides this functionality (using open-source ‘itext’), but.. you have to pay for this.
So why not do it ourselves with itext, open-source (answer: a lot of work and knowledge of Java…).
What follows are the basics to use pl/sql in combination with ‘itext’.
1. Download itext-jar-file (itext-2.1.5.jar):
Copy the jar-file to your database server
2. load these java-classes in the database.
grant create procedure to <owner>;
grant create table to <owner>;
loadjava -user exg/exg iText-2.1.5.jar
Some explanation about loadjava:
Check if it’s correctly loaded in the database:
select object_name, object_type, status
where object_type like ‘%JAVA%’
and status <> ‘VALID’
3. A lot of Java is not valid, you need some other Java classes of ‘bouncycastle’ (encryption):