Skip to Main Content

Oracle Forms

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to write file in blob variable from Forms to application server directory

Peter de VaalOct 29 2025

We are replacing Oracle Reports by another tool (AOP) for reporting, while the application is still in Oracle Forms.

The output of the report is still in PDF and will be stored in a BLOB in a databasetable, the row being uniquely identified by a job number. It can be fetched simply with a plsql function in the database using the job number as parameter into a BLOB variable.

The application has the feature of printing directly to the default printer of the user with the option of first merging the pdf with a background. The merge program runs on the application server, so the pdf must first be transferred to a temporary directory on the app server, and later fetched back for finally sending it to the printer. The latter is performed using webutil functions, which is (almost) identical in the old (Reports) and the new (AOP) situation.

So, the only real problem is how to get the PDF stored in a BLOB variable to the application server directory. Here is the big difference with Reports. In that case the built-in Forms function COPY_REPORTS_OBJECT_OUTPUT is used. But in the new situation I need a way to write the contents of the BLOB variable to the application server directory. TEXT_IO package is not applicable for binary files.

Who has the solution?

Comments
Post Details
Added on Oct 29 2025
4 comments
106 views