tag:blogger.com,1999:blog-3062514990630749307.post6755121077822671575..comments2023-10-01T05:49:28.938-04:00Comments on Marc Sewtz: PDF Printing with Oracle Application Express 4.2.2Marc Sewtzhttp://www.blogger.com/profile/07323603133640801038noreply@blogger.comBlogger59125tag:blogger.com,1999:blog-3062514990630749307.post-42871755158284982822015-07-01T09:09:45.173-04:002015-07-01T09:09:45.173-04:00Oracle Rest Data Services (ORDS) is just the new n...Oracle Rest Data Services (ORDS) is just the new name for the APEX Listener, i.e. dependent on which version of APEX you're using, you would either pick ORDS or the APEX Listener.Marc Sewtzhttps://www.blogger.com/profile/07323603133640801038noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-80315764645515154162015-07-01T09:04:57.420-04:002015-07-01T09:04:57.420-04:00Hi Marc,
How to configure pdf printing in apex 5.0...Hi Marc,<br />How to configure pdf printing in apex 5.0? In instance setting, there ia only oracle rest data service. Is it different with apex listener? I already configure oracle rest data service but still failed. The pdf file can't load. Do you have solution? Please help meAnonymoushttps://www.blogger.com/profile/08870092849094826901noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-1478828234924340982014-02-27T15:49:58.381-05:002014-02-27T15:49:58.381-05:00Hi Joni - just to give you an update, there were a...Hi Joni - just to give you an update, there were a few special characters, like ampersand, plus, greater than, less than, that causes issues with the APEX Listener - i.e. while the "old" via of calling BI Publisher or FOP worked just fine, using the APEX Listener required a different type of character escaping. This has now been fixed in our forthcoming APEX 4.2.5 release / patch set. We do not have a release date for this yet though.Marc Sewtzhttps://www.blogger.com/profile/07323603133640801038noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-76291108583670802182014-02-18T09:52:59.043-05:002014-02-18T09:52:59.043-05:00Please take a look at the APEX Listener OTN page f...Please take a look at the APEX Listener OTN page for information on supported configurations:<br />http://www.oracle.com/technetwork/developer-tools/apex-listener/overview/index.htmlMarc Sewtzhttps://www.blogger.com/profile/07323603133640801038noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-35923315540892759112014-02-18T04:54:42.483-05:002014-02-18T04:54:42.483-05:00Hello Marc,
Sorry to bother you again, but I tried...Hello Marc,<br />Sorry to bother you again, but I tried to follow your suggestion. I created a very simple stylesheet on the EMP-table using StylusStudio. I noticed that the stylesheet looked much more simple than the one generated by StyleVision, so that seemed positive.<br />Again I'm perfectly capable of generating a pdf straight to the browser, but when I want it to be generated by APEX_UTIL.GET_PRINT_DOCUMENT I end up with a "503 - Service unavailable" and the standalone APEX-listener first saying "Feb 18, 2014 10:32:25 AM com.sun.grizzly.util.http.Parameters processParameters<br />INFO: Character decoding failed. Parameter [template] with value[...here the complete xslt-contents...] has been ignored. Note that the name and value quoted here may be corrupted due to the failed decoding. Use debug level logging to see the original, non-corrupted values.<br />java.io.CharConversionException: isHexDigit<br /><br />I've tried all signatures of the procedure (with stylesheet and data as blobs etc) but with no luck.<br /><br />Any suggestions?<br />I really need the pdf to be generated in the database for further processing to DMS etc.Anonymoushttps://www.blogger.com/profile/06001731873626746274noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-41613311223672565662014-02-11T08:20:32.222-05:002014-02-11T08:20:32.222-05:00Hi Marc,
We use a classic report. We configure th...Hi Marc,<br /><br />We use a classic report. We configure the print attributes to export the XML and there the special characters come out differently.<br />For example, as you export the XML :<br />http://apex.oracle.com/pls/apex/f?p=59743:2<br /><br />I can't seem to test it properly on apex.oracle.com because I think this environment is working with BI Publisher and not the APEX listener?<br /><br />Regards,<br />Joni<br /><br />Joni Vandenberghehttps://www.blogger.com/profile/00368827551971437036noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-80713915725862831192014-01-31T13:16:13.088-05:002014-01-31T13:16:13.088-05:00Hi Joni - hard to tell what could be causing this....Hi Joni - hard to tell what could be causing this. Are you using classic reports, report queries, or the print API? Have you tried this on apex.oracle.com, we use UTF-8 there, so at least you would know if it's character set related.Marc Sewtzhttps://www.blogger.com/profile/07323603133640801038noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-21830422094805567102014-01-31T13:14:20.280-05:002014-01-31T13:14:20.280-05:00Hi - unfortunately the file attribute does not cur...Hi - unfortunately the file attribute does not current support item substitutions,<br /><br />Regards,<br />Marc<br />Marc Sewtzhttps://www.blogger.com/profile/07323603133640801038noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-36950397031350248002014-01-31T13:13:48.615-05:002014-01-31T13:13:48.615-05:00VLG: this isn't a lot of information to go by,...VLG: this isn't a lot of information to go by, I suggest you try out a very simple RTF first, and get that to work in the Preview and in APEX, and then go from there. Also, please post your questions in our OTN forum:<br /><br />https://community.oracle.com/community/developer/english/oracle_database/application_express<br /><br />This way others can benefit from any answers, and you also have other APEX Team members, as well as APEX community members looking at this and perhaps being able to assist as well.Marc Sewtzhttps://www.blogger.com/profile/07323603133640801038noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-64236384206013900122014-01-31T13:10:54.594-05:002014-01-31T13:10:54.594-05:00Hi - could you try this out on a local instance, u...Hi - could you try this out on a local instance, using APEX 4.2.4 and the APEX Listener. We're using BI Publisher on apex.oracle.com, and for this to work you need an instance that has the APEX Listener configured as the print server.<br /> <br />Regards,<br />MarcMarc Sewtzhttps://www.blogger.com/profile/07323603133640801038noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-63472031176676188902014-01-31T13:09:43.041-05:002014-01-31T13:09:43.041-05:00do i need weblogic or glassfish server to use orac...do i need weblogic or glassfish server to use oracle apex listener in production ?Anonymoushttps://www.blogger.com/profile/03683642067380716870noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-21396070676873871532014-01-31T11:07:44.097-05:002014-01-31T11:07:44.097-05:00Marc, when you have some time please look into thi...Marc, when you have some time please look into this issue posted on Oracle APEX forum. https://community.oracle.com/message/11343580<br /><br />I am having trouble getting images to render in the PDF.<br /><br />Thanks!<br />JMcGAnonymousnoreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-68581393119343706012014-01-29T06:16:17.096-05:002014-01-29T06:16:17.096-05:00Hı Marc,
Thank you for the demоs and answers.
But ...Hı Marc,<br />Thank you for the demоs and answers.<br />But I have the problem.<br />I created the rtf-template in Word (PI PUBLISHER plugin). Preview - I see the result.<br /> But “Report query – Test Report” report empty.<br />What is the reason? Help us, please.VLGnoreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-35806750294542063332014-01-29T05:28:11.411-05:002014-01-29T05:28:11.411-05:00Marc, We have a problem with the "File Name&q...Marc, We have a problem with the "File Name". We would like this to be the same als one of the fields on the screen. I have tried &P20_NAAM. and :P20_NAAM but both don’t work.<br />Is this a bug?<br />Anonymoushttps://www.blogger.com/profile/17619116635711277986noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-6540638599217750162014-01-28T11:21:26.713-05:002014-01-28T11:21:26.713-05:00Hi Marc,
Thank you for your excellent blog. It re...Hi Marc,<br /><br />Thank you for your excellent blog. It really helped a lot! We are using APEX listener 2.0.5 and our database settings has WE8MSWIN1252 as character set. However the listener seems to have problems with character sets. For example & comes out in the XML as %26amp;. <br />We use APEX 4.2.2<br />Do you have any idea what the cause could be? Or what we can change to fix this?<br /><br />Kind regards,<br />Joni<br /><br />Joni Vandenberghehttps://www.blogger.com/profile/00368827551971437036noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-90155139322774383062014-01-28T11:18:06.758-05:002014-01-28T11:18:06.758-05:00Hi Marc,
We have a problem with special character...Hi Marc,<br /><br />We have a problem with special characters in our APEX listener. For example the character "&" comes out as %26amp; when the XML is exported. Our database NLS_CHARACTERSET is WE8MSWIN1252. Does the Listener not use this set automaticly? Any idea what we need to configure to get this to work?<br /><br />Regards,<br />JoniJoni Vandenberghehttps://www.blogger.com/profile/00368827551971437036noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-38536018308700617772014-01-23T10:34:31.247-05:002014-01-23T10:34:31.247-05:00HI Marc
Thank for this video.
Running into issue, ...HI Marc<br />Thank for this video.<br />Running into issue, install latest apex 4.2.4 with listener 2.05 standalone just to try this. But PDF downloaded gives me error "because it is either not a supported file type or because the file has been damaged. " when download it as RTF then it shows "Syntax error in 'node()|@* except @altova-DisableOutputEscaping'." any suggestions.Neelnoreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-15608739343617232652014-01-22T12:40:07.926-05:002014-01-22T12:40:07.926-05:00looks like an issue with some special characters. ...looks like an issue with some special characters. I suggest you take a look at you XSLT and see if there's anything that needs escaping or can be removed. I had similar issues with Stylevision generated XSLT files, where I had to manually remove some unneeded special characters, especially with the line breaks inserted by that tool. Also, when using the print APIs, you need to ensure you're escaping special characters in your XML data. The built-in print functions do that automatically. But the APIs don't know anything about your content, so you need to do your own escaping. I suggest you try a very simple example first (just a few records with a simple stylesheet) to make sure you overall process flow works, and then iterate to a more complex case.Marc Sewtzhttps://www.blogger.com/profile/07323603133640801038noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-54786228182089677202014-01-22T10:04:51.704-05:002014-01-22T10:04:51.704-05:00Hello Marc,
Thanks for the quick response.
Allt...Hello Marc,<br /><br />Thanks for the quick response. <br /><br />Allthough I had already added the entry you mentioned to the defaults.xml, I haven't been able to get this to work.<br /><br />I had my Apex Listener installed in GlassFish, so I decided to try this with the standalone listener first, but without succes so far.<br /><br />When I run the procedure "apex_util.get_print_document" in my APEX-application, the Apex Listener console first reports an informational message saying "INFO: Character decoding failed. Parameter [#x200B;....".<br />A little further down it says " <br /> <br /><br /><br />I don't know how to work around this....do you have a clue?<br /><br />Hope you can help me finalizing my application!<br /><br />Thanks in advance!<br /><br />Best regards,<br />Marco<br /><br />By the way, my APEX version is 4.2.4.00.08Anonymoushttps://www.blogger.com/profile/06001731873626746274noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-83245280050137265772014-01-21T15:08:21.955-05:002014-01-21T15:08:21.955-05:00Marco: quick follow up, looks like my XML did not ...Marco: quick follow up, looks like my XML did not get posted correctly, so in PDF whitepaper, search for "misc.enableOldFOP", that is the attribute you will need to setMarc Sewtzhttps://www.blogger.com/profile/07323603133640801038noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-85835355045021437602014-01-21T15:06:54.333-05:002014-01-21T15:06:54.333-05:00Hi Marco,
If you want to store the PDF as a BLOB ...Hi Marco,<br /><br />If you want to store the PDF as a BLOB in the database, you will need to make sure that your APEX Listener is configured in such a way, that it accepts PDF rendering request directly from the database. Take a look at our whitepaper on "Creating Custom PDF Reports with Application Express and the APEX Listener" here:<br /><br />http://www.oracle.com/technetwork/developer-tools/apex/application-express/apex-white-papers-1866964.html<br /><br />This paper outlined how you will need to add the following line to the defaults.xml file of the APEX Listener:<br /><br />true<br /><br />Also, make sure to use APEX 4.2.2 or newer. Looks like you are using APEX 4.2.0, which does not support this setup.<br /><br />Regards,<br />Marc<br /><br /><br /><br />Marc Sewtzhttps://www.blogger.com/profile/07323603133640801038noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-84496891213638524302014-01-21T06:30:22.600-05:002014-01-21T06:30:22.600-05:00Hello Marc, this tutorial was of great help to me ...Hello Marc, this tutorial was of great help to me and I used it to develop an application we use to create a large number of documents on a daily basis, however, there's one more thing I need and I hope you can help me out.<br /><br />For the application I created a report-query together with a xsl-fo report-layout created in Altova Stylevision.<br />I've enabled and configured print-options (APEX Listener) and when I press my application button, I'm perfectly capable of viewing and/or saving the pdf-version of my report.<br /><br />Additionally I want to save my report as BLOB in the database, but when I try this using apex_util.get_print_document, all I get in my table is a html-page containing the message "503-service unavailable".<br /><br />Meanwhile I found out that Apex Listener is doing all of the PDF-renedering and is therefore not being sent back to the database.<br />I really do need the pdf going to the database, so do you know of a way to achieve this?<br /><br />Any help will be greatly appreciated!<br />Marco de Haan<br />Etten-Leur Netherlands<br /><br />APEX 4.2.0.4.00.08<br />GlassFish 3.1.2.2 with the Apex Listener 2.0.5<br />Oracle 10.2.0.5 database<br />Anonymoushttps://www.blogger.com/profile/06001731873626746274noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-87278695575746029472014-01-17T15:49:30.414-05:002014-01-17T15:49:30.414-05:00Hi Rob - APEX support both XSLT and RTF templates,...Hi Rob - APEX support both XSLT and RTF templates, however the APEX Listener only support XSLT, so if you want to use RTF templates, then you will need to configure Oracle BI Publisher as your backend print server.Marc Sewtzhttps://www.blogger.com/profile/07323603133640801038noreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-17702779531849782632014-01-16T07:36:37.771-05:002014-01-16T07:36:37.771-05:00With best wishes from Russia! I am very glad when ...With best wishes from Russia! I am very glad when find your blog. Thank you, thank you very much. I was looking for such solution not one month.<br />Thanks for help.OrchiRussianoreply@blogger.comtag:blogger.com,1999:blog-3062514990630749307.post-47191408457361044362014-01-16T04:02:39.119-05:002014-01-16T04:02:39.119-05:00Hello Marc,
A question from one of the earlier po...Hello Marc,<br /><br />A question from one of the earlier posts: "In the second video, it says that either XSLT or RTF files can be uploaded, so I'm hoping we can reuse the RTF files we already have."<br /><br />Can PDF printing use only the XSLT as template or also RTF files?<br /><br />Regards,<br /><br />Rob van Merle<br />Groningen The NetherlandsAnonymoushttps://www.blogger.com/profile/17619116635711277986noreply@blogger.com