IBM Support

Configuring reusable BIRT design templates for use with ClearQuest Report Launcher

Technote (FAQ)


Question

How do you create a reusable template for BIRT report designs in IBM Rational ClearQuest, incorporating a default Data Source and parameterized credentials?

Answer

Begin inside of the BIRT Design component of the ClearQuest (CQ) RCP client in version 7.1.x, or your stand-alone BIRT design component in CQ 8.x. Use the Window menu to enter the BIRT Designer.

  1. Click File > New > New Template...



  2. Give the file a name ending in .rpttemplate

    Pick a location or keep the default.

    Click Next.



  3. Enter a Display Name. The Display Name will be visible to a user as a selection in the wizard when creating a new report design. The name should be descriptive.

    Enter a Description. The Description will be offered alongside the display name, once selected (clicked). It should be further descriptive offering the types of configuration offered by this template. An image may also be selected illustrating in the wizard what the template may look like.

    Click Finish.



  4. Create a Data Source.



  5. Select Create from a data source type in the following list.

    Select ClearQuest Query Data Source.

    Provide a Data Source Name using the default value "Data Source" or a more descriptive name.

    Click Next.



  6. Select My Default ClearQuest Connections to configure the data source as a JNI (CQ Native) connection. Alternatively, select Change Management Server and specify a valid URL to configure a CM Server connection.

    Specify a valid user name and password.

    Click Finish.

    Note: Review benefits of using the MaxMultiLineText URI parameter if implementing a CM Server data source.



  7. Parameters to pass the ClearQuest user name and password during runtime must be defined for best results.

    Right click Report Parameters. Select New Parameter.



  8. Enter "UserId" for the Name value or the value defined for reports.launcher.birt.userParameterName in the reportlauncher.properties file.

    Optionally enter a "Prompt text:" or "Help text:" to be displayed.

    Click OK.



  9. Repeat for the next parameter. Right click Report Parameters. Select New Parameter.



  10. Enter "Password" for the Name value or the value defined for reports.launcher.birt.passwordParameterName in the reportlauncher.properties file.

    Optionally enter a "Prompt text:" or "Help text:" to be displayed.

    Recommended: Select "Do not echo input" so the password does not to appear when typed on the screen.

    Optional: If empty passwords are permitted, de-select "Is Required" or reports may fail to permit login with an empty password.

    Use of a blank password is not suggested in a production environment, only for use with testing.

    Click OK.



  11. You must bind the new parameters to the DataSource.

    Right click your previously defined data source and select Edit.



  12. The "Edit Data Source" dialogue will appear.

    Click Property Binding in the left column.

    Click the ƒx expression builder besides the "User Name:" field.



  13. Click Report Parameters in the "Category" column on the left.

    Click ---All--- in the "Sub-category" column in the middle.

    Double click {} UserId in the right-side column "Double Click to insert:"

    The Expression field, the top left text box, should now display:

    1 params["UserId"]

    Click OK.



  14. Back at the "Edit Data Source" dialogue, Property Binding, you now see the "User Name:" field with value params["UserId"].

    Now, click the ƒx expression builder besides the "Password:" field.



  15. Click Report Parameters in the "Category" column on the far left.

    Click ---All--- in the "Sub-category" column in the middle.

    Double click {} Password in the right-side column "Double Click to insert:"

    The Expression field, top left text box, should now display:

    1 params["Password"]

    Click OK.



  16. You now see a value for User Name and Password.

    Click OK to complete.



  17. Save the template changes.

    Select the menu option File > Save.



  18. Register this template for use in the query wizard.

    Select the menu option File > Register Template with New Report Wizard...



  19. Make any final changes. Click Finish to publish this template.



    Note: When distributing this template to other BIRT report design authors, have them load the template and register it on each workstation they use. Currently the template is only registered to this one workstation.

  20. To create a new BIRT report using this template, select the menu option File > New > New Report...



  21. Provide a name and path in the New Report dialogue.

    Click Next.



  22. Select the new template you just created and registered. See the bottom value in "Report templates" column on left. Note the image preview and description per your template.

    Click Finish.



    Now you can design your new report based on the template.

Related information

Multiline string truncated when running data

Document information

More support for: Rational ClearQuest
Reporting

Software version: 7.1, 7.1.1, 7.1.2, 8.0

Operating system(s): Linux, Windows

Reference #: 1584423

Modified date: 16 April 2012