You are on page 1of 29

XML REPORTS

1. What is a markup language?

Markup languages are designed for presentation of text in different formats,


and it can also be used for transporting and storing data. This markup
language specifies the code for formatting, layout and style of data .This
markup code is called Tag.

HTML and XML are examples of Markup Language.

2. What is XML?

XML is called Extensible Markup Language which is designed to carry or


transport and store data. XML tags are not as predefined as HTML, but we
can define our own user tags for simplicity. It mainly concentrates on storing
of data, not on displaying of data.

3. What are the features of XML?

Main features of XML are:

Very easy to learn and implement

XML files are text files, and no editor is required

Minimal and a limited number of syntax rules in XML

It is extensible, and it specifies that structural rules of tags

4. What are the differences between HTML and XML?

Following are the differences between HTML and XML:

XML

HTML

Markup language used to display data Markup language used to store data

Case Insensitive Case sensitive

Designing web pages Used to transport and store data

Predefined Tags Custom Tags

Does not Preserve white spaces Preserve white spaces


Static Dynamic

5. Which tag is used to find the version of XML and the syntax?

Declaring the XML version is very important for each XML document and
platform needs to be specified in which it is running.

<?xml version=1.1 encoding=

1 <?xml version=1.1 encoding=|ISO-8859-1|?>

6. What is XML DOM Document?

XML Document object represents the whole XML document, and it is the root
of a document tree. It gives access to entire XML document Nodes and
Elements, and it has its own properties.

7. What is XPath?

XPath is used to find information in an XML document and contains standard


functions. XPath is the major element in XSLT, and it is w3c recommendation.

8. What is an attribute?

An attribute provides more or additional information about an element than


otherwise.

Example
1 <Person name=Peter>

Attribute name can be given to an element person.

9. Can we have empty XML tags?

Yes, we can have empty tags in XML. Empty tags are used to indicate
elements that have no textual content. Empty tags can be represented as

1 <person></person>
2
3 <person/>

10. What are the advantages of XML DOM Document?

Advantages of XML DOM:

XML structure is traversable, and it can be randomly accessed by


traversing the tree.

XML structure is modifiable, and values can be added, changed and


removed

11. What are the basic rules while writing XML?

These are the basic rules while writing XML:

All XML should have a root element

All tags should be closed

XML tags are case sensitive

All tags should be nested properly

Tag names cannot contain spaces


Attribute value should appear within quotes

White space is preserved

12. What is XML Element?

An XML document contains XML Elements, and it starts from an elements


start tag to end tag. It can contain:

Other elements within main element

An Attribute

text

13. What is CDATA?

CDATA is unparsed character data that cannot be parsed by the XML parser.
Character < and > are illegal in XML elements. CDATA section starts with <!
[CDATA[ and end with ]]>.

14. How comment can be represented in XML?

Comment can be represented as <!- comments -> as like HTML. This


comment symbol is applicable for single or multiple lines.

15. What are XML Namespaces?

XML namespaces are used to avoid element name conflicts, and it can be
avoided by using prefix before the name.

16. What is XML Parser?

XML Parser is used to convert from XML document into an XML DOM object
which can be written in Javascript.

17. What is XSL?

XSL is a language used with XML for expressing style sheets as like CSS. It
describes how to display an XML document for a given type.

18. Who is responsible for XML?

XML is a recommendation of the W3C World Wide Web Consortium and the
development are supervised by XML working group.

19. What is an XML Schema?


An XML schema gives the definition of an XML document, and it has
following:

Elements and attributes

Elements that are child elements

Order of child elements

Data types of elements and attributes

20. What is well formed XML document?

A well-formed XML document must follow the following rules

Every start tag should end with an end tag

XML tags are case sensitive

Empty tags are necessary to close with a forward slash

All tags should be properly nested

21. Why XML has been used for development?

XML is used for development for following reasons:

Used for Database driven websites

Used to store data for e-commerce websites

Used to transport and store data on internet

XML is used for database and flat files

Generate dynamic content by applying different style sheets

22. What is SGML?

SGML is large and powerful Standard Generalized markup Language which is


used to define descriptions of the structure of different types of electronic
document.

23.Can I execute a XML?

No, we cannot execute XML, and it is not a programming language to


execute. It is just a markup language to represent the data.

24. What are the special characters used in XML?

<, > and & are the special characters used in XML. Because these characters
are used for making tags.
25. What software is available for XML?

There are thousands of programs available for XML and updated list will be
present in http://xml.coverpages.org.

26. Whether graphics can be used in XML? If so, How?

Yes, Graphics can be included in XML by using XLink and XPointer


specifications. It supports graphic file formats like GIF, JPG, TIFF, PNG, CGM,
EPS and SVG.

XLink:

1 <description
2
3 xlink:type="simple"
4
5 xlink:href="http://show.com/Cinema.gif"
6
7 xlink:show="new">
8
9 </description>
1
0 XPointer:
1
1 <description
1
2 xlink:type="simple"
1
3 xlink:href="http://show.com/Cinema.gif#Shownumber"
1
4 xlink:show="new">
1
5 </description>
1
6
1
7
1
8
1
9
2
0
2
1

27. Can I replace HTML with XML?

No, XML is not a replacement of HTML. XML provides an alternative approach


to define own set of markup elements, and it is used for processing and
storing data.

28. How can I include conditional statements in XML?

We cannot include conditional statement as like programming language.

1 <foo if{DB}="A">bar</foo>

This can be done by using Document Type Definition(DTD).

1 <xsl:if test="@foo=bar">
2
3 <xsl:text>Hello, world!</xsl:text>
4
5 </xsl:if>

29. What are the benefits of XML?

Benefits of XML are

Simple to read and understand


XML can be done with a text editor

Extensibility No fixed tags

Self descriptive

Can embed multiple data types

30. What are the disadvantages of XML?

Following are the disadvantages of XML:

XML will be just a text file if elements and attributes are not defined
properly.

Overlapping markup is not permitted

31. What is DTD?

DTD is abbreviated as Document Type Definition and it is defined to build


legal building blocks of an XML document. It defines the XML document
structure with elements and attributes.

32. Why XSLT is important for XML?

XSLT is abbreviated as eXtensible Sytlesheet Language Transformation which


is used to transform an XML document to HTML before it is displayed to the
browser.

33. What are nested elements in XML?

If one or more elements are nested inside the root element is called nested
element. Nesting can be easy to understand and also keeps order in an XML
document.

34. What is XQuery?

XQuery was designed to query XML data which is nothing but SQL for
database tables. XQuery is used to fetch the data from the XML file.

35. What is XLink and XPointer?

XLink is the standard way of creating hyperlinks in the XML files. Xpointer
which allows those hyperlinks to point to more specific parts of the XML file
or document.

36. Why XML editor is needed instead of Notepad?


XML editors are required to write error free XML documents, and it is used to
validate against DTD or schema. Editors are able to check:

Open and Close Tags

XML against DTD

XML against Schema

Color code on XML Syntax

37. What is XML Encoding?

XML documents may contain Non-ASCII characters like French and Norwegian
characters. XML Encoding is used to avoid errors and XML files have to be
saved as Unicode.

38. Which XML is set to be valid XML?

When the XML file is validated against the Document Type Definition(DTD),
then it is called valid XML. DTD is nothing but it defines the structure of an
XML file.

39. What is Simple Element?

A simple element contain only text and following are the kinds of Simple
Element:

No attributes
Doesnt contain other elements
It cannot be empty
40. What is Complex Element?

A complex element contain other elements or attributes and following are


kinds of Complex Elements:

It has empty elements


It contain other elements
It contain only text
It contain both other elements and text
41. Is there a way to describe XML data?

Yes, XML uses Document Type Definition (DTD) to describe the data.

42. What are the three parts of XSL?

XSL consists of three parts:


XSLT Used to transform XML documents
XPath Used for navigating in XML documents
XSL-FO Used for formatting XML documents
43. What is the correct syntax when we define XML version?

1 <?xml version=1.0/>

is the correct declarative syntax used to define XML version.

44. If XML attribute name itself has double quotes, then how it can
be represented?

Attribute name can be represented within single quotes if double quotes are
present in the attribute name.

Example

1 <country city='Texas "US"'></country>

45. What are the types of XML Parsers?

There are two types of parsers Non-Validating and Validating Parsers.

Name itself implies Non-Validating will not validate the XML and

Validating parser will validate the XML with DTD.

46. Whether root element is required for XML? If so, how many root
elements are required?

Yes, root element is required, and it can have only one root element in each
XML.

47. What is XML Signature?

XML Signature is recommended by W3C, and it acts as a digital signature for


XML documents. If the signature is contained outside the document, it is
called detached signature. If it contains inside the XML document, then it is
called Enveloping signature.

48. What is Data Island?

An XML Data island is XML data embedded into a HTML page. This works only
with the Internet.

49. What is DiffGram in XML?

A DiffGram is an XML format which is used to find current and original


versions of XML document.

50. What is SAX?

SAX is an interface processing XML documents using events.

51.What is a Data Template?


The Oracle XML Publisher data engine enables you to rapidly generate any
kind of XML data structure against any database in a scalable, efficient
manner. The data template is the method by which you communicate your
request for data to the data engine. It is an XML document whose elements
collectively define how the data engine will process the template to generate
the XML.

52.What Functionality is Supported?


The data engine supports the following functionality:
Schema generation
Default RTF template generation
Flexfields
Single and multiple data queries
Query links
Parameters
Aggregate functions (SUM, AVG, MIN, MAX, COUNT)
Event triggers
Multiple data groups
Unicode for XML Output
Unicode is a global character set that allows multilingual text to be
displayed in a single application. This enables you to develop a single
multilingual application and deploy it worldwide.
Canonical format
The data engine generates date elements using the canonical ISO
date format: YYYY-MM-DDTHH24:MI:SS.FF3TZH:TZM for a mapped date
element, and ######.## for number elements in the data template XML
output.
How to Design the Data Template Definition:

53. How to link the Queries in BI publishers reports ?


Ans) link the SQL operator that defines the parent-child relationship
<link name =Q1_link parentQuery=Q1 parentColumn=depno
childQuery=Q2 childColumn=depno/>

Data Template using Link:


Using Link tag

Data template Passing parameter:


Using Triggers in Data Template:

Data Triggers
Data Triggers can be used
Perform initialization tasks
Allows to build dynamic query
Data Triggers Types
beforeReport trigger: Fires before the dataQuery is executed .
afterReport trigger : Fires after you exit and after XML output has
been generated
Example :-
<dataTrigger name="beforeReport" source="employee.beforeReport()"/>
<dataTrigger name="beforeReport"
source="employee.beforeReport(:Parameter)"/>

Using Flex Fields in Data Demplate:


Flexfield aware
Support all Flexfield features

KFF related lexicals
oracle.apps.fnd.flex.kff.segments_metadata
oracle.apps.fnd.flex.kff.select
oracle.apps.fnd.flex.kff.where
oracle.apps.fnd.flex.kff.order_by

Example: Flexfield Query


54.How to Prevent Excel from suppressing leading zeros

<fo:bidi-override direction="ltr" unicode-bidi="bidi-override">


<?XML_ELEMENT?>
</fo:bidi-override>

55.How to create Summary Columns in Data Template ?


A summary column performs a computation on another column's data. Using
the function attribute of the <element> tag, you can create the following
summaries: sum, average, count, minimum, and maximum.

56. How to use the lexicla Paramters in Data Templates ?


in ur select statement where &whereaswrite the on package in like below

How to Prevent Excel from suppressing leading zeros


<fo:bidi-override direction="ltr" unicode-bidi="bidi-override"><?
XML_ELEMENT?></fo:bidi-override>

57. What are the XML publisher tables.


PER_GB_XDO_TEMPLATES
XDO_DS_DEFINITIONS_B
XDO_DS_DEFINITIONS_TL
XDO_DS_DEFINITIONS_VL
XDO_LOBS
XDO_TEMPLATES_B
XDO_TEMPLATES_TL
XDO_TEMPLATES_VL
XDO_TEMPLATE_FIELDS
XDO_TRANS_UNITS
XDO_TRANS_UNIT_PROPS
XDO_TRANS_UNIT_VALUES

58. How to write a loop in rtf template design ?


<?for-each:G_invoice_no?>
..<?end for each?>

59. How to design sub templates in rtf layout ?


Ans> using following tags..
<?template:template_name?>
This is Last Page
<?end template?>

63. How to create multi layouts in XMLP ?


Ans> using below conditions
<?choose:?>
<?when:CF_CHOICE=VENDOR?>
Your template.
<?end when?>
<?when:CF_CHOICE=INVOICE?>
Your template.
<?end when?>
<?when:CF_CHOICE=RECEIPT?>
Your template.
<?end when?>
<?end choose?>
64.How to calculate the running total in XMLP?
<?xdoxslt:set_variable($_XDOCTX, 'RTotVar', xdoxslt:get_variable($_XDOCTX,
'RTotVar') + ACCTD_AMT(This is column name) )?><?
xdoxslt:get_variable($_XDOCTX, 'RTotVar')?>

65. How to submit a layout in the backend ?


Ans> we have to write a procedure for this using the below code
fnd_request.add_layout
(template_appl_name => 'application name',
template_code => 'your template code',
template_language => 'En',
template_territory => 'US',
output_format => 'PDF'
);
66. How to display the images in XMLP?
Ans> url:{'http://image location'}
For example, enter:
url:{'http://www.oracle.com/images/ora_log.gif'}
url:{'${OA_MEDIA}/image name'}

67. How to pass the page numbers in rtf layout?


Ans> <REPORT>
<PAGESTART>200<\PAGESTART>
....
</REPORT>
Enter the following in your template:
<?initial-page-number:PAGESTART?>
68..How to display last page is differently in XML Publisher Reports.

Ans> what you want to dispay the test anything write in last of page

last page header

<?start@last-page-first:body?> <?end body?>

1)Develop the Report(.rdf) Only DataModel


2)Save the report and Compoile it.
3)Move the the .rdf into custom Top like CUS_TOP\11.5.0\Reports\US

.rdf File registration :

=========================

4)Create Executeable

====>Pass the Executeable Name :xxxxx


====>Short Name :xxxxx
====>Application name :xxxxx
=====>Execution method :oracle reports
=====>Execution file name :your .rdf file name
5) create Concurrent Program
Output = XML
6)create Request Group and attached to Concurrent program
7) Attach u r request group to based on client given Responsibility
go to file---> switch responsility----> select what ever ur add
responsibility
Go to view--->request ---> SRS
8)submit ur cp and refresh it we will get output.
9) save your output as .xml format.
10)Copy the Concurrent Program Short name
11)Open the Ms-WOrd document Design the Layout
include the follwing Tool Bar options called Form and Templete builder
13)Define the Table and Specify the Titles and Labels whatever we would like
to print
====>If we want to Develop through wizard go to Template
builder=>data->load XML Data
====> Template Builder=>Insert=>Table/form=>wizard
====>file=>save=>save Rich text format

14)Include 'Text Form Field' Double CLick => Add Help Text button enter the
following
syntax
<?for-each:G_USER_ID?> : Here G_USER_ID is Group name from .rdf Data
Model
Note: It means Indirectley Repeating Frame starting

15)Define the Fields which we would like to display

Include 'Text Form Field' Double CLick => Add Help Text button enter the
following
syntax
<?Column Name>?

Note: Define all the fields like this

16)We have to close the Repeating Frame (For each Loop)


Include 'Text Form Field' Double CLick => Add Help Text button enter the
following
syntax
<?end for-each?>

17)Save the document in .rtf(Rich Text File format)

19)Load the .xml file data and generate the Output in pdf Format
Data=>Load XMl Data=>Load the .xml File=>Once Data is Loaded
succesfully

20)Generate the Preview as per this Preview=>PDF

1)Develop the .rdf file and .rtf file


2)Register both .rdf and .rtf file

.rdf File registration :


=========================
1)Move the .rdf file into CUS_TOP\11.5.0\Reports\US
2)Create Execuiteable
Concurrent Program Output = XML
Request Group
Responsibility
User
SRS
3)Copy the Concurrent Program Short name

.rtf File Regitration:


=======================

1)Goto the XML Publisher Administrator Responsibility


2)Select Data Definations form
Enter Data Defination Name = Enter Any Name
Code = Concurrent Program Short Name
Application = Any application
startdate = Current Date

3)Copy the DataDefination name we have to add this to the Templete


4)Open the Templete Form
Enter Templete Name : Any Name
DataDefination : enter data defination whatever we have created
Code : Concurrent Program Short Name
Type : rtf
application : any Application
File : Upload the .rtf file
Laguage : English
Territory : United States

5)Select Apply button

After register the .rtf file submit concurrent Program from SRS window
system will
automatically pick the .rtf file and generates the Output.

If we want to customze the .rtf file we have to download by using templete ,


Customize then
upload the .rtf templete.

1. What is a template Builder?

The Template Builder is an extension to Microsoft Word that simplifies the


development of RTF templates. The Template Builder is tightly integrated
with Microsoft Word and allows you to perform the following functions:
Insert data fields
Insert data-driven tables
Insert data-driven forms
Insert data-driven charts
Preview your template with sample XML data
Browse and update the content of form fields
Extract boilerplate text into an XLIFF translation file and test
translations

Valid template file types are:

eText - Inbound, eText - Outbound, PDF, RTF, XSL-FO, XSL-HTML, XSL-TEXT,


and XSL-XML.
2. Sub Template into Main Template:

Import the subtemplate

<?import:file:/// D:\siva\Callsubtempalte\Subtemplatenew.rtf?>

In the subtemplate we are calling

Headers:
<?call@inlines:Tc1?><?with-param:ReportName;string(SIVA REPORT)?> <?
end call?>

Footers

<?call:Tc2?>

3. Translatable (check box)


Select this check box if you want this template to be translatable. Only RTF
templates are translatable. After the template definition is created, the
following fields are not updateable: Application, Code, and Type. Update the
template from the View Template page.

4. To handle parameterized layout

If the requirement is to display a different layout based on a user parameter


value or a List of Value selection, then the parameter can be passed to RTF
layout and conditionally display the layout.

On the Report Editor you first need to define a parameter with name
DeptName. If this parameter has to be associated with a List of Value (LOV),
then create a LOV on the Report Editor page.

Next, in the parameter definition select parameter type as Menu and then
select the LOV from the selection.

In the RTF template define a parameter using syntax - <?


param@begin:DeptName?>

Now when user selects a department name from the List of Value on the
report viewer page, the value gets passed to RTF layer into the DeptName
parameter. To display the layout based on this user selection, you can use an
IF statement or a CHOOSE statement to evaluate the parameter value and
call the associated sub template.
Use CHOOSE statement when too many conditional tests are to be done and
a default action is expected for rest of the values, for example, for each
department here we have a different sub template and if the user parameter
has a department name with no associated sub template, then a default sub
template can be called in otherwise section.

<?choose:?>

<?when:$DeptName=Accounting?><?call:tAcc?>

<?end when?>

<?when:$DeptName=Sales?><?call:tSales?>

<?end when?>

<?when:$DeptName=Marketing?><?call:tMark?>

<?end when?>

<?otherwise:?><?call:tDefault?>

<end otherwise>

<?end choose?>

5. WATERMARK

PAGE LAYOUTWATERMARK (Word 2007)

Format Background Printed Watermark (Word 2003)

6. TEXT FIELD

Developercontrolslegacy toolstext field

7. Add Total Sum in calcualtion in a new row.

8. Adding Page/Brought Forward/Carried Forward Total

Placed before the column name PT

<?add-page-total:pt;'TRANS_AMOUNT_REMAINING'?>

9. Display Page Total in Footer

<xdofo:show-page-total name="pt" format="99G999G999D00"/>


10. Display Brought Forward Total in Header

<xdofo:show-brought-forward name="pt" format="99G999G999D00"/>

11. Display Carried Forward Total in Footer

<xdofo:show-carry-forward name="pt" format="99G999G999D00"/>

22. BLOB & CLOB

Cant generate xml data for CLOB more than 40 kb in report builder.
BLOB Images are supported in XML Publisher 5.6.2 or later.
Encode BLOB to CLOB use this following function:

CREATE FUNCTION getbase64( p_source BLOB )


RETURN CLOB
IS
v_result CLOB;
BEGIN
DBMS_LOB.createtemporary(lob_loc => v_result, CACHE => FALSE, dur =>
0);
Wf_Mail_Util.EncodeBLOB ( p_source, v_result);
RETURN ( v_result );
END getbase64;

1 Define Header <?call:header?>

<?template: header?>

<?end template?>

body Contents <?start:body?>


<?end body?>

Last Page Only <?start@last-page:body?>


Content: <?end body?>

Sort (Data sorting) <?sort:trx_number?>

Sort descending: <?sort:trx_number;data-


type=number;order=descending?>
multiple sort tags: <?sort:trx_number?><?sort:trx_date?&g

Oracle Number Format <?format-number:fieldname;999G999D99?


Mask >

Mask Output for US Locale


SHORT =2/31/99
MEDIUM =Dec 31, 1999
LONG =Friday, December 31, 1999
SHORT_TIME =12/31/99 6:15 PM
MEDIUM_TIME =Dec 31, 1999 6:15 PM
LONG_TIME =Friday, December 31, 1999
6:15 PM
SHORT_TIME_TZ =12/31/99 6:15 PM GMT
MEDIUM_TIME_TZ =Dec 31, 1999 6:15 PM
GMT
LONG_TIME_TZ =Friday, December 31,
1999 6:15 PM GMT

Page Breaks: <?split-by-page-break:?>

Arthemitical Calculated <?field1 + field2?>


Fields <?field1 field2?>
<?field1 * field2?>
<?field1 / field2?>

Dynamic data columns <?split-column-header:group element


name?>
Dynamic Column <?split-column-header:group element
Header name?>

Dynamic Column Data <?split-column-data: group element name?>

Define row counter <?xdoxslt:set_variable($_XDOCTX, Counter,


variable in a form field 0)?>

Increment counter for <?xdoxslt:set_variable($_XDOCTX, Counter,


each line (again in a xdoxslt:
form field) get_variable($_XDOCTX, Counter) + 1)?>

Break if the number of <?if: xdoxslt:get_variable($_XDOCTX,


rows is reached (say 6 Counter) mod 6=0?>
rows in this example) <?split-by-page-break:?>
<?end if?

Re-grouping XML Data <?for-each-group: BASE-GROUP;GROUPING-


ELEMENT?>
<?end for-each-group?>

Can establish nested <?for-each:current-group(); GROUPING-


groupings ELEMENT?>
<?end for-each-group?>

Conditional Cell <?if:XML_ELEMENT>Value?>


Highlighting <xsl:attribute xdofo:ctx=block
name=background-color>COLOR
</xsl:attribute>
<?end-if?>

Declare variable to hold <?add-page-total:TotalFieldName;element?


page totals >

Display total field <?show-page-total:TotalFieldName;Oracle-


number-format?>

If no data found <?if:CS_CNT_ORD =0?>*************NO


message in a report DATA FOUND*************<?end if?>

lpad function <?xdofx:lpad(aaa,10,.)?>

Concatenation Function <?xdofx:3||2?>

rpad function <?xdofx:rpad(aaa,10,.)?>

trim function <?xdoxslt:trim( a )?>

ltrim function <?xdoxslt:ltrim( a )?>

rtrim function <?xdoxslt:rtrim( a )?>

decode function <?


xdofx:decode(xxx,bbb,ccc,xxx,ddd)?>

Instr function <?xdofx:Instr(abcabcabc,a,2)?>

substr function <?xdofx:substr(abcdefg,2,3)?>

left function <?xdoxslt:left(abcdefg, 3)?>

right function <?xdoxslt:right(abcdefg, 3)?>

replace function <?xdofx:replace(name,John,Jon)?>

to_number function <?xdofx:to_number(12345)?>

sysdate function <?xdofx:sysdate()?>

<?xdofx:sysdate()?>

<?xdofx:sysdate(dd-mon-yyyy)?>

<?xdofx:sysdate(dd-mm-yyyy)?>

<?xdofx:sysdate(day-dd-month-yyyy)?>

lower <?xdofx:lower (char)?>


upper <?xdofx:upper(char)?>

length <?xdofx:length(char)?>

Returns the minimum <?xdoxslt:minimum(ELEMENT_NAME)?>


value of the element in
the set

Returns the maximum <?xdoxslt:maximum(ELEMENT_NAME)?>


value of the element in
the set.

Copy the Current Node XSL Syntax : <xsl:copy-of


select=name>
BI Publisher Tag: <?copy-of:name?>

Call Template XSL Syntax: <xsl:call-template


name=name>
BI Publisher Tag: <?call-template:name?>

Call Template XSL Syntax: <xsl:template name=name>


Template Declaration BI Publisher Tag: <?template:name?>

Import Stylesheet XSL Syntax: <xsl:import href=url>


BI Publisher Tag: <?import:url?>

Variables <?xdoxslt:set_variable($_XDOCTX,variable
name, 0)?>

Variables -1 Sets the value of xdoxslt:set_variable($_XDOCTX,variable


variable_name to the current value
name,
plus the element amount
xdoxslt:get_variable($_XDOCTX,variable
name)+element name)

Variables -2 <?xdoxslt:get_variable($_XDOCTX, variable


name)?>

for-each loop <?for-each:XML group element tag name?>


<?end for-each?>

IF Stament <?if:boolean_test?>
<?end if?>
<?if:LINE_TYPE=LINE ?>
<?end if?>

Groups <?for-each:XML group element tag name?>


<?end for-each?>

Images url:{IMAGE_LOCATION}

url:
{concat(SERVER,/,IMAGE_DIR,/,IMAGE_FIL
E)}

url:{concat(${OA_MEDIA},/,IMAGE_FILE)}

To change a shapes <?shape-size-x:RATIO?>


size along the x or y <?shape-size-y:RATIO?>
axis, use:

Page Breaks <?split-by-page-break:?>

To insert Initial Page <?initial-page-number:pagenumber?>


number in different
page

Last Page Only Content <?start@last-page:body?>


<?end body?>

End on Even or End on <?section:force-page-count;end-on-even-


Odd Page layout?>

To end on an even page <?section:force-page-count;end-on-even-


with layout layout?>

To end on an odd page <?section:force-page-count;end-on-odd-


layout: layout?>

Generating Bookmarks <?copy-to-bookmark:?>


in PDF Output
directly above your table of contents and
<?end copy-to-bookmark:?>

Conditional Formatting <?if:VENDOR_NAME=COMPANY A?>


<?end if?>

Choose Statements <?choose:?>


<?when:expression?>
<?otherwise?>

Running Totals Declares the RTotVar


variable and initializes it to 0.

<?xdoxslt:set_variable($_XDOCTX, RTotVar,
0)?>

Sets the value of RTotalVar to the current


value plus the new Invoice Amount.

Retrieves the RTotalVar value for display.

<?xdoxslt:set_variable($_XDOCTX, xml_tag,
xdoxslt:get_variable($_XDOCTX, RTotVar) +
xml_tag)?><?
xdoxslt:get_variable($_XDOCTX, RTotVar)?>

Regrouping To regroup the data, use the following


syntax:
<?for-each-group: BASE-GROUP;GROUPING-
ELEMENT?>

Regrouping by an Expression

To establish nested groupings within the


already defined group, use the following
<?for-each:current-group(); GROUPING-
ELEMENT?>

(Using Variables) Use the following syntax to declare/set a


variable value:
<?xdoxslt:set_variable($_XDOCTX, variable
name, value)?>

Use the following syntax to retrieve a


variable value:
<?xdoxslt:get_variable($_XDOCTX, variable
name)?>

You can use this method to perform


calculations.
<?xdoxslt:set_variable($_XDOCTX, x,
xdoxslt:get_variable($_XDOCTX, x+1)?>

Defining Parameters Declare the parameter in the template.


Use the following syntax to declare the
parameter:
<?
param@begin:parameter_name;parameter_v
alue?>

parameter_name is the name of the


parameter
parameter_value is the default value for the
parameter (the parameter_value is optional)

You might also like