xml brusting
TRANSCRIPT
-
8/10/2019 xml brusting
1/25
XML Bursting
Bursting (Email report output) in XML Publisher reports
XML Bursting is a feature available in Oracle bywhich a XML is exploded into diferentparts based on a
defined logic and the individualparts are again converted into reports based on a layoutand sentvia em
ailto designated m ailboxes.
This is a veryhelpfulfeature especialyifyou are trying to send the outputofa reportto an em ailaddress orm
ultiple em ailaddress
Benefits ofXML bursting
1.The feature is standard forXML Publisherversion 5.6.3
2.No coding is required
3.Outputis sentvia em ail.Userdoes notneed to login to Oracle to getthe report
4.The m ain reporttem plate and the bursting tem plates can be diferentfrom each other.Thus there can
be one outputfrom the concurrentprogram and a diferentlayoutto send as em ail.
Dem onstration ofXML bursting
W e created a XML Publisherreportwith using adata tem plate.The reporthas been developed to return 4
records.W e shaluse bursting to send the 4 records as 4 diferentreports to 4 em ailaddresses.For
ourexam ple we have used 1 em ailaddress across al4.
XML Data Tem plate
The data tem plate is given below,
1 spanclass="hiddenSpellError">xml version="1.0" encoding="ISO-88!-1">#
$
,
8
-
8/10/2019 xml brusting
2/25
1
1
1
-
8/10/2019 xml brusting
3/25
12/4/13
18
1!
#0
Create the concurrentprogram
Concurrentprogram registration
Registerthe data definition
Responsibility:XML PublisherAdm inistrator
Navigation:Data Definition
2
-
8/10/2019 xml brusting
4/25
12/4/13 Oracle Apps Consultant: XML Bursting
Registerdata definition
Atach the concurrentprogram to the requestgroup and execute the program to generate the XML output.
Concurrentrequest
The outputshows the folowing,
-
8/10/2019 xml brusting
5/25
---- 3
-
8/10/2019 xml brusting
6/25
12/4/13 Oracle Apps Consultant: XML Bursting
Create the layouttem plate
Reportlayouttemplate
Attach the XML as Preview Data
Responsibility:XML PublisherAdm inistrator
Navigation:Data Definition
QueryforCode = XXEMPDET
Atach the XML generated from the program outputto the Preview Data section ofthe data definition.
http://oraclemaniac.com/2012/03/29/bursting-email-report-output-in-xml-publisher-reports/bursting-3-1/http://oraclemaniac.com/2012/03/29/bursting-email-report-output-in-xml-publisher-reports/bursting-3-1/ -
8/10/2019 xml brusting
7/25
---- 4
-
8/10/2019 xml brusting
8/25
12/4/13 Oracle Apps Consultant: XML Bursting
Attach XML as Preview data
Registerthe tem plate
Navigation:Tem plates
Create a tem plate
Registerlayouttemplate
CheckPreview to see ifthe tem plate m atches with the XML.
Execute the reportto view the data
-
8/10/2019 xml brusting
9/25
---- 5
-
8/10/2019 xml brusting
10/25
12/4/13 Oracle Apps Consultant: XML Bursting
XML reportoutput
There are 4 records for4 em ployees in the report.W e are displaying 2 em ployees forease.
Create the bursting tem plate
The m ostim portantaspectofXML bursting is the bursting controlfile.This is a XML file which contains
specifictags forbursting the XML outputgenerated earlier.
1 xml version="1.0" encoding="A&B-8">
$
4 xapiCglo7al*a%a >
-
8/10/2019 xml brusting
11/25
---- 6
-
8/10/2019 xml brusting
12/25
12/4/13 Oracle Apps Consultant: XML Bursting
Explanation ofthe bursting tem plate
XML tag Explanation
xapi:requestselect=This tag in the controlfile indicates from which tag/node in the concurrentprogram outputXML should
separated forbursting
xapi:delivery This node contains alem ailrelated atributes
This tag contains the em ailatributes like,
serverorthe em ailserverIP ornam e
xapi:em ail portorthe em ailserverport
from orthe em ailaddress from which the servershould send the em ail
reply-to orthe em ailaddress to which the replies should be sent
This tag contains the atributes aboutthe em aillike,
To orthe em ailaddress where the em ailshould be sent
xapi:m essage
Subjectorthe em ailsubject
attachm ent,i.e.ifthe em ailshould contain an atachm ent
content-type ortype ofem ail
The m ailbodywilbe enclosed within thetags
This node contains the atachm entdocum entand XML tem plate related tags and atributesThe
atributes in this tag are related to the em ailatachm ent
xapi:docum ent Keyorunique identifierofeach atachm ent
Outputoratachm entfile nam e
Output-type oratachm entfile type
This node contains the tem plate inform ation like,
xapi:tem plate Type orthe file type ofthe tem plate
Location orthe directoryofthe tem plate file along with the file nam e
The folowing atributesshould contain the sam e valuesforbursting to function properly,
1. Id atribute in xapi:emailtag
2. Id atribute in xapi:message tag
3. Delivery atribute in xapi:documenttag
Ifthe 3 valuesdo notm atch then deliverywilnottake place asexpected.
Attach the bursting file to the Data Definition ofthe XML PublisherReport
Responsibility:XML PublisherAdm inistrator
Navigation:Data Defintions
-
8/10/2019 xml brusting
13/25
---- 7
-
8/10/2019 xml brusting
14/25
12/4/13 Oracle Apps Consultant: XML Bursting
Upload the bursting controlfile
Upload the bursting file in Bursting ControlFile section.
Change the tem porarydirectorylocation.
A tem porarydirectoryhas to be provided forXML Publisherengine to use forbursting.
Responsibility:XML PublisherAdm inistrator
Navigation:Adm inistration tab
-
8/10/2019 xml brusting
15/25
----
-
8/10/2019 xml brusting
16/25
12/4/13 Oracle Apps Consultant: XML Bursting
Settemporary directory
In Unix,/tm p directoryhas write perm issions foralusers.Enter/tm p directoryas the tem porarydirectory.
This directorycan be anydirectoryon which Oracle apps has write perm issions.
FTP the tem plate
FTP the layoutfile,i.e.the XML layouttem plate in the /tm p directory,as we have defined in the bursting
controlfile thatthe tem plate file location is /tm p
XML layouttemplate in /tmp directory
XML Bursting execution process
Run the XX Em ployee detailreportto generate the output.
Execute the report
After the report is generated, execute the program nam ed, XML Publisher Report Bursting
Program .This program is responsible forbursting the XML with the help ofthe bursting controlfile
atached to the concurrentprogram whose outputwilbe burst.Ensure thatthisprogram isatached to
the requestgroup ofthisresponsibility.
-
8/10/2019 xml brusting
17/25
---- !
-
8/10/2019 xml brusting
18/25
12/4/13 Oracle Apps Consultant: XML Bursting
XML PublisherReportBursting Program
Selectthe requestofthe previouslyrun reports requestid.W e shalselectthe 2ndrequestfrom the top,
i.e.RequestID:19011719
Concurrentrequestselected
Execute the bursting program
Bursting program executed
-
8/10/2019 xml brusting
19/25
---- 1"
-
8/10/2019 xml brusting
20/25
12/4/13 Oracle Apps Consultant: XML Bursting
W hen the bursting program ends,the program nam e in the SRS form changes as shown below
Bursting program name changed in SRS form
Now checkthe outputofthe bursting program .
Bursting program output
The bursting program outputshows that4 em ails were delivered.
W e shalcheckthe m ailboxnow.Rem em berthatwe had setthe em ailaddress ofalthe 4 em ployees to a
single em ailaddress forthis dem onstration within the reportquery itself.You can check the data tem plate
forthe queryatthe top.
Emails sentby bursting program
Each m ailbodylooks like the folowing,
-
8/10/2019 xml brusting
21/25
---- 11
-
8/10/2019 xml brusting
22/25
12/4/13 Oracle Apps Consultant: XML Bursting
Emailbody
The em ailbody,atachm entnam e and atachm entfile type m atch with the bursting controlfile above.The
atachm entwilcontain the data from the XX Em ployee detailreport,
Attachment
The bursting process is now com plete.
Autom atic execution ofXML PublisherReportBursting Program
Since the bursting program ,XML PublisherReportBursting Program ,has to be run m anualythis m ight
notbe feasible foralusers to use.The bursting program can be executed autom aticaly ifwe use a
rdfreportto generate the data forthe XML publisherreport.In a rdfreportwe can add the folowing piece
ofcode in the AfterReporttriggerin the reportto execute the bursting program as soon as the outputhas
been generated bythe report.
1 BA@4&IO@ a9%errepor%
#E&A@LOODE5@
3 IS
, v6re6id @A(LEM
5 LEI@
-- 4all Lrs%ing )rogram
v6re6id C=
8 9nd6rees%.s7mi%6rees% Napplica%ion => :'*O:
! program => :'*OLAS&E):
-
8/10/2019 xml brusting
23/25
10 descrip%ion => ::
----
12/14
12/4/13 Oracle Apps Consultant: XML Bursting
11 s%ar%6%ime => ::
1# s76rees% => B5DSE
1$ argmen%1 => ::
1, argmen%# => Cp6conc6rees%6id
1 argmen%$ => ::
1 --4?N0
1 --::
18 M
1!IB v6re6id = 0
#0&?E@
#1srP.(ESS5E N1#$ :Bailed %o call 7rs%ing program.:M
##E@* IBM
#$
#, srP.ASE6E'I& N:B@* SQE'I&:M
# E&A@ N&AEM
# E@*M
#
Bursting program error
The XML PublisherBursting program m ighterrorout.The log file
wiltalkaboutchecking the OutputPost processorlogs.Ihave described how to
getthe OutputPostProcessorlogs in a previous article.
Bursting program log
Afterchecking the OutputPostProcessorlogs we getthe folowing,
1 3$/##/1# #C1!C0 )(R 3$#0$81C&1!011##R 4omple%ed pos%-processing ac%ions 9or rees%1!011##.
2 3$/##/1# #C$$C10 )(R 3O))Service&hread0R )os%-processing rees% 1!011.
$ 3$/##/1# #C$$C10 )(R 3$#0$81C>&1!011R Exec%ing pos%-processing ac%ions 9or rees% 1!011.
, 3$/##/1# #C$$C10 )(R 3$#0$81C&1!011R S%ar%ing '(D )7lisher pos%-processing ac%ion.
3$/##/1# #C$$C10 )(R 3$#0$81C&1!011R
&empla%e codeC LAS&6S&5&AS6E)O&
-
8/10/2019 xml brusting
24/25
7 &empla%e appC '*O
8 DangageC en
! &erri%or+C AS
10 O%p% %+peC &B
----
13/14
-
8/10/2019 xml brusting
25/25
12/4/13 Oracle Apps Consultant: XML Bursting
11 3$/##/1# #C$$C10 )(R 3A@E')E4&E*R 3$#0$81C&1!011R Hava.lang.reec%.Invoca%ion&arge%Excep%ion
1# a% sn.reec%.@a%ive(e%hod5ccessorImpl.invoKe0N@a%ive (e%hod
1$ a% sn.reec%.@a%ive(e%hod5ccessorImpl.invoKeN@a%ive(e%hod5ccessorImpl.HavaC$!
1, a% sn.reec%.*elega%ing(e%hod5ccessorImpl.invoKeN*elega%ing(e%hod5ccessorImpl.HavaC#
1 a% Hava.lang.reec%.(e%hod.invoKeN(e%hod.HavaC!
1 a% oracle.apps.xdo.common.xml.'SD&10g1.invoKe)arseN'SD&10g1.HavaC
1 a% oracle.apps.xdo.common.xml.'SD&10g1.%rans9ormN'SD&10g1.HavaC#$118 a% oracle.apps.xdo.common.xml.'SD&Qrapper.%rans9ormN'SD&Qrapper.HavaC18#
1! a% oracle.apps.xdo.%empla%e.9o.%il.BOA%ili%+.genera%eBONBOA%ili%+.HavaC10,,
#0 a% oracle.apps.xdo.%empla%e.9o.%il.BOA%ili%+.genera%eBONBOA%ili%+.HavaC!!
#1 a% oracle.apps.xdo.%empla%e.9o.%il.BOA%ili%+.genera%eBONBOA%ili%+.HavaC#1#
## a% oracle.apps.xdo.%empla%e.BO)rocessor.crea%eBONBO)rocessor.HavaC1
#$ a% oracle.apps.xdo.%empla%e.BO)rocessor.genera%eNBO)rocessor.HavaC!
#, a% oracle.apps.xdo.oa.schema.server.&empla%e?elper.rn)rocess&empla%eN&empla%e?elper.HavaC!#
# a% oracle.apps.xdo.oa.schema.server.&empla%e?elper.process&empla%eN&empla%e?elper.HavaC$,8# a% oracle.apps.xdo.oa.schema.server.&empla%e?elper.process&empla%eN&empla%e?elper.HavaC$,
# a% oracle.apps.9nd.cp.opp.'(D)7lisher)rocessor.processN'(D)7lisher)rocessor.HavaC#!0
#8 a% oracle.apps.9nd.cp.opp.O))ees%&hread.rnNO))ees%&hread.HavaC1
#! 4ased 7+C org.xml.sax.S5')arseExcep%ionC C '(D-#0108C NBa%al ErrorO S%ar% o9 roo% elemen% expec%ed.
$0 a% oracle.xdo.parser.v#.'(DError.shError?andlerN'(DError.HavaC,,1
$1 a% oracle.xdo.parser.v#.'(DError.shErrors1N'(DError.HavaC$0$
$# a% oracle.xdo.parser.v#.@onalida%ing)arser.parseoo%Elemen%N@onalida%ing)arser.HavaC$,$
$$ a% oracle.xdo.parser.v#.@onalida%ing)arser.parse*ocmen%N@onalida%ing)arser.HavaC#8$, a% oracle.xdo.parser.v#.'(D)arser.parseN'(D)arser.HavaC#8!
$ ... 1 more
$3$/##/1# #C$$C10 )(R 3$#0$81C>&1!011R 4omple%ed pos%-processing ac%ions 9or rees% 1!011.
$&his error rela%es %o %he %empla%e in %he server. I% means %ha% '(D processor is /na7le %o Jnd %he
$8
$!
The location specified as the XML layouttem plate directoryshould be valid and alperm issions m ustbe
available on this file as welas the directory.