XML Publisher Training
1
Confidential. All trademarks appearing herein belong to their respective owners.
Key Features of XML Publisher
Rapidly develop and maintain business critical documents utilizing
colors, fonts, images, logos, watermarks, etc
Generate output in PDF, EXCEL,RTF, EFT, XML,HTML, XLS, Text
formats
Easy to build report output templates via MS-Word, Adobe, XML Editors
maintain using industry standard technology (Java, XML)
Multiple Language Support
No Additional Licensing cost. Comes free with eBusiness Application
Suite
Extract once and publish multiple times using various formats
Single data definition supports multiple layouts and multiple translations
XML Publisher separates data structure & layout.
Enables delivery of reports to multiple channels :
• Email, Fax, printer, FTP, HTTP through standard Oracle setup
• Auto-fax with addition of Fax Software/Server
2
Confidential. All trademarks appearing herein belong to their respective owners.
How XML Publisher can be used for Generating the
Report
Steps :
Select the output option of the concurrent program as XML.
Create the required template in Microsoft word with logo and other
details in desktop with XML variable names using Text Form Field
(Explained Below) and save the document as rtf (rich text file).
Register and upload the rtf template in Oracle application using “XML
Publisher Administrator” responsibility against the concurrent program.
Run the same concurrent program. In case of PO Printing, run the
concurrent Program “Printed Purchase Order Report”. The formatted
output as done in Microsoft word can be seen in view output window as
a PDF file along with the appropriate PO data and the output will be
saved automatically as a PDF file in operating system level.
3
Confidential. All trademarks appearing herein belong to their respective owners.
XML Publisher By Example
Step-1:
Add the XML Publisher Administrator responsibility to the user.
4
Confidential. All trademarks appearing herein belong to their respective owners.
Step 2:
Create an RDF report with query as
SELECT person_id,
last_name,
email_address
FROM per_all_people_f
and save the file as EMP_XML.rdf and upload in the respective directory.
Since it is a custom report so it should be uploaded into the custom directory. So
upload the file in the $CUSTOM_TOP/report/US directory if you are developing the
custom report.
5
Confidential. All trademarks appearing herein belong to their respective owners.
Step 3:
Create the report with output as XML to get the data as XML .
I created a sample report with just 3 columns . Below is the registration .
(N) Application Developer ->Concurrent ->Executable
Custom Schema Name
6
Confidential. All trademarks appearing herein belong to their respective owners.
Step 4:
(N) Application Developer ->Concurrent ->Program
Register the report but make sure that output format is XML.
7
Confidential. All trademarks appearing herein belong to their respective owners.
Step 5:
Register the report to the respective Request Group
(N) System Administrator ->Security -> Responsibility ->Request
8
Confidential. All trademarks appearing herein belong to their respective owners.
Step 6:
Switch to the responsibility in which the report is attached and run the report
9
Confidential. All trademarks appearing herein belong to their respective owners.
The output will look like this
Output will be displayed
with XML tags since we
have selected the format
as XML and no layout is
attached till now
10
Confidential. All trademarks appearing herein belong to their respective owners.
Step 7:
Now we have to create the template in RTF format to see the data .Open MS
word and then create a simple table and put the labels or the heading you
want to display .At the same time you can import some image if you want to
display in the report.
Image
Table
11
Confidential. All trademarks appearing herein belong to their respective owners.
Step 8:
Now since we want the heading to be displayed on each and every page, so
mark the entire row and right click on the table properties . Go to ‘Row’ tab and
check the repeat as header row at the top of each page.
12
Confidential. All trademarks appearing herein belong to their respective owners.
Step 9:
Now we want the image as the header .
Insert the Header tag
<?body:start?> ---------------------just after the image .
-----------------------------
----------Table------------
-----------------------------
At the end insert the Footer tag
<?body:end?>
13
Confidential. All trademarks appearing herein belong to their respective owners.
Step 10:
Now we want to insert the element in the file .
Go to View ->toolbars->Forms and click
14
Confidential. All trademarks appearing herein belong to their respective owners.
Step 11:
Click on text form field with cursor at the place where you want to insert the
same,
15
Confidential. All trademarks appearing herein belong to their respective owners.
Step 12:
Click on Add Help Text button. And enter <?Column Name?>(e.g.- <?PERSON_ID?> in the box
16
Confidential. All trademarks appearing herein belong to their respective owners.
Similarly fill the same for other fields also
17
Confidential. All trademarks appearing herein belong to their respective owners.
Step 13:
Now to loop to the record you have to group the data .
Grouping
Tag
18
Confidential. All trademarks appearing herein belong to their respective owners.
Similarly for the other fields also
19
Confidential. All trademarks appearing herein belong to their respective owners.
Should be
in .rtf
always
Now save the file as XMLTEMPLATE.rtf
20
Confidential. All trademarks appearing herein belong to their respective owners.
Step 14:
Now your template is complete and we have to register the same in the
template manager.
Note:- First the definition is registered and then the template is attached to that
data definition.
Go to XML Publisher Administrator responsibility .
(N) XML Publisher Administrator -> home -> data definition
21
Confidential. All trademarks appearing herein belong to their respective owners.
Concurrent Program short name
Create the data definition.
Click on apply button.
Any user friendly data
definition name
22
Confidential. All trademarks appearing herein belong to their respective owners.
Step 14:
Now Register the template
Since we are going to register
the template first time so click on
the create template
Upload the template file
Click on the apply button
23
Confidential. All trademarks appearing herein belong to their respective owners.
24
Confidential. All trademarks appearing herein belong to their respective owners.
Step 15:
Go to concerned responsibility where the report is attached and then submit a new
request.
Click this Option Button for output format
In the format field LOV you can select output as
PDF, Excel etc
25
Confidential. All trademarks appearing herein belong to their respective owners.
View the output after submission of the program by clicking on the
VIEW OUTPUT button. I have selected the format as PDF so it will
give the output in PDF format.
26
Confidential. All trademarks appearing herein belong to their respective owners.
Thank You
27
Confidential. All trademarks appearing herein belong to their respective owners.