AnsweredAssumed Answered

CABI 6.2 showing boolean value in variable

Question asked by Sparasa.1 on Jun 20, 2017
Latest reply on Jul 5, 2017 by Sparasa.1

I want to show Active/Inactive/both assets in Jasper report. since the field type is boolean, I created a variable with definition like below ..


 $F{inactive}.intValue() != 1?"ACTIVE":"INACTIVE"


I could add the variable name "Active Status" in Report and see Active and Inactive assets...instead of 1 or 0.


However, If we use the parameter in Jasper server ..there is no option to select values based Variable Value.

Since Parameter and Variable are not linked.


Sample report


SQL query in report

SELECT dbo.ca_owned_resource.resource_name,
    dbo.ca_owned_resource.host_name, AS "Asset Family", AS "Service Status", AS "Lifecycle Status", AS "Class"
    FROM dbo.ca_owned_resource
    INNER JOIN dbo.ca_resource_family ON
     dbo.ca_owned_resource.resource_family =
    INNER JOIN dbo.ca_resource_status ON
     dbo.ca_owned_resource.resource_status =
    INNER JOIN dbo.ca_asset_lifecycle_status ON
     dbo.ca_owned_resource.lifecycle_status =
    INNER JOIN dbo.ca_resource_class ON
     dbo.ca_owned_resource.resource_class =
     dbo.ca_owned_resource.inactive = $P{inactive}
     AND (



How do we link parameter and Variable so that we can select 'Active' for assets with flag 1 and 'Inactive' for flag value 0 and Select both 1 and 0 for All Assets?


Instead of Showing "inactive" field as boolean field, I want to show it as List of Values?


Boolean parameter in Jasper


Variable based filtering in Boxi 3.X/4.X