First of all, Doxxy is a tool for developers: for APEX developers surely, but in fact for anyone who is developing against an Oracle database and who needs a printable output. This printable document may be a .DOCX file or a PDF file.
This post explains the basic fundaments of Doxxy, keeping in mind that the tools has to be simple and easy.
How does it work?
Doxxy consists of two major components:
- a front-end application (UI), used for defining the metadata that describes the documents. The actual UI is written in APEX and is available in all 4.x versions. We are also working on a Eclipse-RCP version of the UI.
- a PL/SQL engine, which contains all the intelligence and generates the desired output
1. The APEX UI
The main objective of the APEX UI is to give the developer an easy interface to configure his document. There are different screens where you can enter the metadata of your printable report. This metadata consists of:
– one or more SQL statements
– minimal 1 Word-template (DOCX)
– and optionally input parameters and/or a PL/SQL block with pre -or after processing logic
Following screenshot gives you a general idea of how the UI looks like:
2. The PL/SQL Engine
The PL/SQL Engine retrieves the metadata which is defined via the UI as input for a given document. It executes the SQL statement(s), binds them with the parameter(s) and gets the specified DOCX-template.
Thereafter, this template is unzipped. As you may know, a DOCX-document is an amalgam of different XML-files. The engine replace all data tags in the document.xml file by the corresponding business data.
At the end all XML-files are packed again in a DOCX-output-document, which is returned as a BLOB variable to the calling program.
Following picture gives a schematic overview of the concept:
Doxxy is a RAD-tool for generating operational reports. With its intuitive APEX UI, you easily configure your documents by adding DOCX-templates and SQL-queries. The engine is written in PL/SQL, which makes installation, integration and maintenance as simple as a walk in the park. The tool comes as a packaged application for APEX 4.x.