Category: Jaspersoft

How to Add Days, Months and Years in a Jaspersoft Report

You can add days, months and years to a DATE field by using the following  workaround in Jaspersoft reports.   Manually add the following content in the jasper xml <import value=”org.apache.commons.lang.time.*”/>   Use the following syntax as given in the below example:   To add Days – DateUtils.addDays($F{HIREDATE},5)  – Return type date   To add Months – DateUtils.addMonths($F{HIREDATE},5)  – Return type date   To add Years – DateUtils.addYears($F{HIREDATE},5)  – Return type date

Read More +