Skip to Main Content

APEX

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!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Genrating a PDF report from APEX and PL/SQL

LauryMar 16 2021

Hi,
I am working with APEX 20.x on an Oracle 19c RDBMS.
With APEX we can create reports and various charts, but I don't know a way to allow to print such a report in PDF format.
Does someone know if there is a plugging or a feature available to generate PDF reports with information queried from the database and charts, from APEX (via a button or a link), or through a PL/SQL block?
Thanks and Regards

This post has been answered by Laury on Apr 13 2021
Jump to Answer

Comments

Sylvain Martel

Hello Laury,
What the exact version of APEX you are working on? APEX 20.x doesn't really exist! lol
Starting with APEX 20.2, you can generate PDF directly from Interactive Reports, Interactive Grids and Classic Reports.
Is that what you are looking for?
Have a look at this blog from Monica Godoy
Exploring Report Printing in APEX 20.2 (0 Bytes)Hope this helps!

Scott Wesley

These are two solid external options - PL/PDF and AOP
https://content.dsp.co.uk/apex/pl-pdf-or-aop-which-should-i-use

Laury

Hello,
Thanks for the feedback.
I forgot to mention that I am working on a container 19c RDBMS.
@Sylvain:
I use APEX 20.1. I wrote "x" just to mention that it could have been 20.1, 20.2,... as I do belived that the functional difference might not be so big.
The link of Monica Godoy is interesting. But I do not see feature allowing to print images and or graphics. Furthermore, how can such a report be triggered through a /SQL block (in APEX it can be a link or a button)?
@Scott:
You mentioned two products, have you experiene in these, what would be your choice and why?
I did't find any documentation regarding a tutorial to use PL/PDF.
Any other suggestions?
Kind Regards

Scott Wesley

I haven't played with the native offering much, I understand it to be fairly basic, but probably improved somewhat since I last tried.
PL/PDF is more like creating PDFs with manually written PL/SQL, just like you could create HTML with the HTF package. Somewhat more manual process that I've only played with in exploration.
Further information is found in the original link, or on their website
https://explorer.co.uk/can-i-generate-pdfs-from-apex-in-the-always-free-oracle-cloud/
https://www.plpdf.com/support-examples.php
I've used AOP in a project and that's brilliant. Very much like BI Publisher were you combine a Word template with some SQL, and it's very flexible, offering all sorts of tricks, and nicely integrated.
If I had a choice, I'd go with AOP.

Sylvain Martel

Hello Laury,
Adding those precisions on your exact APEX release and the business requirements that you have is helping in guiding you in the right direction.
I strongly suggest that you look at APEX Office Print (AOP) from United Codes. It's a very complete product and we use it constantly at Insum.
You will be able to print images, graphics, submit from PL/SQL. It acts like BI Publisher where it merges a template and data.
Hope this helps!

Laury
Answer

Hi,
Thanks for all the good ideas.
I came with these conclusions for myself:

  1. The PLPDF package from the above link is really not a good solution: full of bugs, not properly documented, bad demos (and this is a commercial solution!).
  2. The AOP solution is costly, I have not explored it.
    For people interested I suggest the PL/SQL option popsted by Anton Scheffer.
    The demos are working, but it is necessary to explore the package to be able to do more.
    See:
    https://technology.amis.nl/amis/generating-a-pdf-document-with-some-plsql-as_pdf_mini-as_pdf3/
    Kind Regards
Marked as Answer by Laury · Apr 13 2021
Sylvain Martel

Hello Laury,
Why do you say AOP is costly? 35$/month for the cloud service or 6,900$ for the on-remise license doesn't sound that expensive for a professional solution.
PLPDF is also a great option and I never heard that it was full of bugs, so maybe you can list those bugs for the benefit of this forum.

InoL
  1. The PLPDF package from the above link is really not a good solution: full of bugs, not properly documented, bad demos (and this is a commercial solution!).
    I concur with Sylvain: how did you get to that conclusion? We've been using it for years, no bugs, API's are very well documented.
    The only thing that is limited (but this may have improved by now) is the generator based on templates (PL/PDF Reporter). So, we don't use it.
    I don't really like that product anyway, as it is too much old fashioned line-by-line coding. We have thousands of lines of code :-( A proper template based report generator quickly pays itself back in development time saved.
Scott Wesley

I also wouldn't call AOP costly, you get what you pay for here. A well written product that's fully supported, easy to use, and integrates well.

Laury

Hi Sylvain,
Yes you are right, for the cloud service this affordable. But we don't use cloud services for application development.
If you think that PLPDF is a great option, then show me (by posting it here for instance) concrete examples - invoice order. Until now I didn't find such good examples/demos, even when I contacted the PLPDF support...
I have found some bugs ini PLPDF, but I didn't spend much in trying to solve them. Anyway, the code itself is wrapped... This is a commercial software and as such I would expect it to be usable code.
Kind Regards

1 - 10

Post Details

Added on Mar 16 2021
10 comments
6,067 views