24 Building a Report with Dynamic Graphics

In this chapter, you will learn about reports that include graphics that change depending on the data. By following the steps in this chapter, you can generate the report output shown in Figure 24-1.

Figure 24-1 Dynamic graphics report output

Description of Figure 24-1 follows
Description of ''Figure 24-1 Dynamic graphics report output''

Concepts

Oracle Reports enables you to link to and display drawings and images that are "dynamic." That is, any changes made to the graphics will be reflected in your report output at runtime.

Data Relationships

  • One way to display dynamic graphics in a report involves creating a database column that stores the names of the graphic files you want to display. You do this in the Data Model view.

  • In the Data Model view, Oracle Reports provides a property called Read from File that enables you to pull the latest versions of the graphics into your report. When you set the Read from File property for a column listing file names, Oracle Reports displays the graphic contained within the named file, rather than the file name itself. Doing so enables Oracle Reports to pull into the report the latest version of the graphic at runtime.

  • Another way to include dynamic graphics in your report is to use the File Link tool in the Paper Layout view. This tool enables you to create a boilerplate object used to contain an external file, such as graphics and text. This example does not show you how to use this method, but you can read more about this tool in the Oracle Reports online Help.

Layout

This report uses a simple Group Above layout.

Example Scenario

In this example, you will create a simple report using the Group Above layout to display data about an employee, showing a different image depending on the location of the employee's department.

As you build this example report, you will:

To see a sample report containing dynamic graphics, open the examples folder called dynamicgraphics, then open the Oracle Reports example report named dynamicgraphics.rdf. For details on how to open it, see "Accessing the Example Reports" in the Preface.