Building a Data Template

The BI 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.

The data engine supports the following functionality:

The XML output generated by the data engine supports the following:

The Data Template Definition

The data template is an XML document that consists of four basic sections: define parameters, define triggers, define data query, define data structure. This structure is shown in the following graphic:

As shown in the sample figure, the data template consists of a section in which parameters are declared in child elements; a section in which the SQL queries are defined in child elements; and a section in which the output XML structure is defined.

The table below lists the elements that make up the XML data template. Each element is described in detail in the following sections. Required elements are noted.

Constructing the Data Template

You can use any text or XML editor to write a data template.

Data Template Declaration

The element is the root element. It has a set of related attributes expressed within the tag.