Previous
Previous
 
Next
Next

Linking the Item to the Report

At this point, you have created the item, but it is not linked to the report. To link it to the report, you must edit the Region Source and add a WHERE clause.

To link the item to the report:

  1. Under Regions, click the Employees link (next to Report).

  2. Scroll down to Source.

  3. In Region Source, add the following after the existing code:

    WHERE (DEPARTMENT_ID = :P3_DEPARTMENT_ID or  (DEPARTMENT_ID is null and nvl(:P3_DEPARTMENT_ID,'1') = '-1'))
    

    This WHERE clause changes the query to display only those employees that belong to the selected department.

  4. Click Apply Changes.