Creating Links Between Data Sets

You can use the BI Publisher data engine to combine and structure data after you extract it from the data source.

Joining and structuring data at the source into one combined data set is sometimes not possible. For example, you cannot join data at the source when data resides in disparate sources such as Microsoft SQL Server and an Oracle Database. Even if your data is coming from the same source, if you are creating large reports or documents with potentially hundreds of thousands of rows or pages, structuring your data so that it matches the intended layout optimizes document generation.

Create a link to define a master-detail or parent-child relationship between two data sets. You can create links as element-level links or group-level links. The resulting, hierarchical XML data is the same. Creating links as element-level links is the preferred method. Group-level links are provided for backward compatibility with data templates from earlier versions of Oracle BI Publisher.

A data link or parent-child relationship relates the results of multiple queries. A data link can establish these relationships:

  • Between one query's column and another query's column.

  • Between one query's group and another query's group, useful when you want the child query to know about its parent's data.

About Element-Level Links

Element-level links create a bind (join) between two data sets and define a master-detail (parent-child) relationship between them.

Create element-level links, the preferred method, to define master detail relationships between data sets. When you use element-level links to link data sets, you do not need to code a join between the two data sets through a bind variable.

About Group-Level Links

Group-level links determine how data sets are structured as hierarchical XML, but lack the join information that the data engine needs to execute the master and detail queries.

When you define a group-level link, you must update your query with a link between the two data sets through a unique bind variable.