I have a requirement to change the output of the seeded PO Output for Communication program, so that it uses a custom RTF template to produce the documents.
To do this, I have registered this template in XML Publisher under the Purchasing application. I then navigated to Purchasing Super User > Setup > Purchasing > Document Types, and from the window opened, selected to update the Purchase Order Standard Type. From here, I updated the document name and the document type layout as my new custom template.
However, once I run the program, it completes with an error. The log file is pages and pages (that I won’t post here unless requested as necessary) but at the bottom is section produced that I think may be useful:
Updated PRINT_COUNT 1
doc Identifier: PO Document ID:14004
setFileName- m_documentType:PO, m_documentId:14004
GenerateDocument::Finished 3rd Constructor()
Setting PO template Code
Setting OKC template Code
Before calling genDocTue Jan 22 17:02:01 GMT 2013
Changed GenerateDocument::Inside the gendoc method
Calling the getDocument method
GenerateDocument::getDocument()- Set the Org Context
GenerateDocument::getDocument() - Searching in the repository
After Calling the getDocument method
Calling the getPOXsl method
Before setting the bind variables for the default layout in getPOXSL()
Document Template Code :NCC_STD_PO_RTF
Language Code :US
Document XSL Contents Tue Jan 22 17:02:01 GMT 2013
Retrieved the Document XSL Tue Jan 22 17:02:01 GMT 2013
Calling the getPOXml method
GenerateDocument::getPOXml() : l_exists 1
GenerateDocument::getPOXml() : m_whichTables MAIN
GenerateDocument::getPOXml()- Calling the POXMLGEN method Tue Jan 22 17:02:01 GMT 2013
Generated the Document XML Tue Jan 22 17:02:01 GMT 2013
Document XML Contents Tue Jan 22 17:02:01 GMT 2013
Calling the print util method:Tue Jan 22 17:02:01 GMT 2013
Passing Params to getBlobPDF :Tue Jan 22 17:02:01 GMT 2013
genDoc() : Exceptionjava.lang.Exception: Error while generating PDF :null
java.lang.Exception: Error while generating PDF :null
rolling back the complete program
As you can see it's definitely picking up my custom template (NCC_STD_PO_RTF), and it appears to error when tryign to generate it as PDF.
I have attempted to attach the seeded xsl template to my template definition - to test if the error is due to the program expecting a certain template format - but, as the seeded template is in that particular format, and my definition is expecting rdf, it will not let me.
I am wondering if anyone has a solution for this requirement. We would like to keep the business process the same as it was in 11i, by using the seeded program, but with a custom template. But I understand that in R12, creating a custom program replicated from the seeded may be the only viable solution.
This is on Oracle Applications version 12.1.3.
Any suggestions would be much appreciated, and if you think that any more information is required, let me know.
I have found the the program will only fail when the WHEN CHOOSE and OTHERWISE conditions are used in the template. Does this spark any ideas for anyone as to why that specific method of conditional formatting would cause it to fail?
What version of BI Publisher Desktop did you use to create your custom template ?
Overview of Available Patches for Oracle XML Publisher embedded in the Oracle E-Business Suite [ID 1138602.1]
Publisher version is 10.1.3.4.2.
It seemed to be a data issue. When a certain test PO with a insufficient amount of data in the XML output was put through the template, and hit these clauses, it failed, and the concurrent program errored.