Enable lookup in report parameters selection page

In this post I will show how to enable the lookup functionality for selecting one or multiple values in a report parameter.
Instead of creating a new lookup I will show all the necessary configurations looking at the built-in report ‘Inventory Balance’ (inventory_balance_tbl.rptdesign).

Enabling lookup in report

Open the ‘Report Administration’ application and search for ‘Inventory Balance’ report.
Open the report details page and look at the ‘Parameters’ section. The ‘item’ parameter is the right example that what we are searching for.

The three fields we intereded in are: Attribute Name, Lookup Name and Multi-Lookup Enabled.
The ‘Attribute Name‘ specifies the database attribute on which we want to filter the results. The Inventory Balance report allows to specify one or more items.
The ‘Lookup Name‘ specifies a Maximo system lookup that will be displayed to select the parameter’s values. Just as a remainder, Maximo system lookups are available in the Application Designer through the action menu. In the chosen example the ‘item’ lookup will be displayed.
The ‘Multi-Lookup Enabled‘ field specifies if the user can select multiple values in the lookup list that is displayed.
Clicking on ‘Generate Request Page’ and then on ‘Preview’ button. You will see the following request page.

BIRT report

To see how to handle the multiple values in the BIRT code open the report design file located under [SMP_INSTALL_FOLDER]\maximo\reports\birt\reports\INVENTOR.
In the ‘open’ method you will find the following lines:

if(params["item"].value) {
params["where"]+= " and " + MXReportSqlFormat.createParamWhereClause("inventory.itemnum", params["item"].toUpperCase());

Using the createParamWhereClause function you can easily convert the items list passed by Maximo in the correct where clause.

Enable lookup in report parameters selection page

5 thoughts on “Enable lookup in report parameters selection page

  1. Hi Bruno,
    Thank you for your great efforts.
    I had a problem with enabling lookup.
    I enabled lookup to any parameter (Like location in asset object).
    when i choose any value 'i.e. BUS', and run the report, it didn't work.
    But when i remove the lookup and enter by hand the same value of location, the report has been worked correctly. any suggestions.

  2. Does anyone know if it is possible to add a conditional lookup parameter to the request page. Example, I have a field with a domain containing 2 values, if the user selects a value the next parameter field with a domain attached filters by the appropriate values liked to the one above, only allowing the user to select the correct values?
    Example, parameter 1 – SCOTLAND or SOUTHERN
    parameter 2 – one domain but only shows the values for Scotland or Southern.

  3. Hi Bruno,
    How to import cascading parameter report into Maximo 7.1? When I try to import I get this error

    BMXAA5457E – The report import process failed. Verify the specified information is correct before proceeding again.

    Please assist

Leave a Reply

Your email address will not be published. Required fields are marked *

Scroll to top